1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by Autoconf 2.52.
4#
5# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
6# Free Software Foundation, Inc.
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9
10# Find the correct PATH separator.  Usually this is `:', but
11# DJGPP uses `;' like DOS.
12if test "X${PATH_SEPARATOR+set}" != Xset; then
13  UNAME=${UNAME-`uname 2>/dev/null`}
14  case X$UNAME in
15    *-DOS) lt_cv_sys_path_separator=';' ;;
16    *)     lt_cv_sys_path_separator=':' ;;
17  esac
18fi
19
20# Check that we are running under the correct shell.
21SHELL=${CONFIG_SHELL-/bin/sh}
22
23case X$ECHO in
24X*--fallback-echo)
25  # Remove one level of quotation (which was required for Make).
26  ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','`
27  ;;
28esac
29
30echo=${ECHO-echo}
31if test "X$1" = X--no-reexec; then
32  # Discard the --no-reexec flag, and continue.
33  shift
34elif test "X$1" = X--fallback-echo; then
35  # Avoid inline document here, it may be left over
36  :
37elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then
38  # Yippee, $echo works!
39  :
40else
41  # Restart under the correct shell.
42  exec $SHELL "$0" --no-reexec ${1+"$@"}
43fi
44
45if test "X$1" = X--fallback-echo; then
46  # used as fallback echo
47  shift
48  cat <<EOF
49
50EOF
51  exit 0
52fi
53
54# The HP-UX ksh and POSIX shell print the target directory to stdout
55# if CDPATH is set.
56if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
57
58if test -z "$ECHO"; then
59if test "X${echo_test_string+set}" != Xset; then
60# find a string as large as possible, as long as the shell can cope with it
61  for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
62    # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
63    if (echo_test_string="`eval $cmd`") 2>/dev/null &&
64       echo_test_string="`eval $cmd`" &&
65       (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
66    then
67      break
68    fi
69  done
70fi
71
72if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
73   echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
74   test "X$echo_testing_string" = "X$echo_test_string"; then
75  :
76else
77  # The Solaris, AIX, and Digital Unix default echo programs unquote
78  # backslashes.  This makes it impossible to quote backslashes using
79  #   echo "$something" | sed 's/\\/\\\\/g'
80  #
81  # So, first we look for a working echo in the user's PATH.
82
83  IFS="${IFS= 	}"; save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}"
84  for dir in $PATH /usr/ucb; do
85    if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
86       test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
87       echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
88       test "X$echo_testing_string" = "X$echo_test_string"; then
89      echo="$dir/echo"
90      break
91    fi
92  done
93  IFS="$save_ifs"
94
95  if test "X$echo" = Xecho; then
96    # We didn't find a better echo, so look for alternatives.
97    if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
98       echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
99       test "X$echo_testing_string" = "X$echo_test_string"; then
100      # This shell has a builtin print -r that does the trick.
101      echo='print -r'
102    elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
103	 test "X$CONFIG_SHELL" != X/bin/ksh; then
104      # If we have ksh, try running configure again with it.
105      ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
106      export ORIGINAL_CONFIG_SHELL
107      CONFIG_SHELL=/bin/ksh
108      export CONFIG_SHELL
109      exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
110    else
111      # Try using printf.
112      echo='printf %s\n'
113      if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
114	 echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
115	 test "X$echo_testing_string" = "X$echo_test_string"; then
116	# Cool, printf works
117	:
118      elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
119	   test "X$echo_testing_string" = 'X\t' &&
120	   echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
121	   test "X$echo_testing_string" = "X$echo_test_string"; then
122	CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
123	export CONFIG_SHELL
124	SHELL="$CONFIG_SHELL"
125	export SHELL
126	echo="$CONFIG_SHELL $0 --fallback-echo"
127      elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
128	   test "X$echo_testing_string" = 'X\t' &&
129	   echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
130	   test "X$echo_testing_string" = "X$echo_test_string"; then
131	echo="$CONFIG_SHELL $0 --fallback-echo"
132      else
133	# maybe with a smaller string...
134	prev=:
135
136	for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
137	  if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
138	  then
139	    break
140	  fi
141	  prev="$cmd"
142	done
143
144	if test "$prev" != 'sed 50q "$0"'; then
145	  echo_test_string=`eval $prev`
146	  export echo_test_string
147	  exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
148	else
149	  # Oops.  We lost completely, so just stick with echo.
150	  echo=echo
151	fi
152      fi
153    fi
154  fi
155fi
156fi
157
158# Copy echo and quote the copy suitably for passing to libtool from
159# the Makefile, instead of quoting the original, which is used later.
160ECHO=$echo
161if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
162   ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
163fi
164
165# Avoid depending upon Character Ranges.
166as_cr_letters='abcdefghijklmnopqrstuvwxyz'
167as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
168as_cr_Letters=$as_cr_letters$as_cr_LETTERS
169as_cr_digits='0123456789'
170as_cr_alnum=$as_cr_Letters$as_cr_digits
171
172# Sed expression to map a string onto a valid variable name.
173as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
174
175# Sed expression to map a string onto a valid CPP name.
176as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
177
178# Be Bourne compatible
179if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
180  emulate sh
181  NULLCMD=:
182elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
183  set -o posix
184fi
185
186# Name of the executable.
187as_me=`echo "$0" |sed 's,.*[\\/],,'`
188
189if expr a : '\(a\)' >/dev/null 2>&1; then
190  as_expr=expr
191else
192  as_expr=false
193fi
194
195rm -f conf$$ conf$$.exe conf$$.file
196echo >conf$$.file
197if ln -s conf$$.file conf$$ 2>/dev/null; then
198  # We could just check for DJGPP; but this test a) works b) is more generic
199  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
200  if test -f conf$$.exe; then
201    # Don't use ln at all; we don't have any links
202    as_ln_s='cp -p'
203  else
204    as_ln_s='ln -s'
205  fi
206elif ln conf$$.file conf$$ 2>/dev/null; then
207  as_ln_s=ln
208else
209  as_ln_s='cp -p'
210fi
211rm -f conf$$ conf$$.exe conf$$.file
212
213as_executable_p="test -f"
214
215# Support unset when possible.
216if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
217  as_unset=unset
218else
219  as_unset=false
220fi
221
222# NLS nuisances.
223$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
224$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
225$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
226$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
227$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
228$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
229$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
230$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
231
232# IFS
233# We need space, tab and new line, in precisely that order.
234as_nl='
235'
236IFS=" 	$as_nl"
237
238# CDPATH.
239$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
240
241# Name of the host.
242# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
243# so uname gets run too.
244ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
245
246exec 6>&1
247
248#
249# Initializations.
250#
251ac_default_prefix=/usr/local
252cross_compiling=no
253subdirs=
254MFLAGS= MAKEFLAGS=
255SHELL=${CONFIG_SHELL-/bin/sh}
256
257# Maximum number of lines to put in a shell here document.
258# This variable seems obsolete.  It should probably be removed, and
259# only ac_max_sed_lines should be used.
260: ${ac_max_here_lines=38}
261
262ac_unique_file="FTBitmapFont.C"
263ac_default_prefix=${GLTT_DIR:-/usr/local}
264
265# Initialize some variables set by options.
266ac_init_help=
267ac_init_version=false
268# The variables have the same names as the options, with
269# dashes changed to underlines.
270cache_file=/dev/null
271exec_prefix=NONE
272no_create=
273no_recursion=
274prefix=NONE
275program_prefix=NONE
276program_suffix=NONE
277program_transform_name=s,x,x,
278silent=
279site=
280srcdir=
281verbose=
282x_includes=NONE
283x_libraries=NONE
284
285# Installation directory options.
286# These are left unexpanded so users can "make install exec_prefix=/foo"
287# and all the variables that are supposed to be based on exec_prefix
288# by default will actually change.
289# Use braces instead of parens because sh, perl, etc. also accept them.
290bindir='${exec_prefix}/bin'
291sbindir='${exec_prefix}/sbin'
292libexecdir='${exec_prefix}/libexec'
293datadir='${prefix}/share'
294sysconfdir='${prefix}/etc'
295sharedstatedir='${prefix}/com'
296localstatedir='${prefix}/var'
297libdir='${exec_prefix}/lib'
298includedir='${prefix}/include'
299oldincludedir='/usr/include'
300infodir='${prefix}/info'
301mandir='${prefix}/man'
302
303# Identity of this package.
304PACKAGE_NAME=
305PACKAGE_TARNAME=
306PACKAGE_VERSION=
307PACKAGE_STRING=
308PACKAGE_BUGREPORT=
309
310ac_prev=
311for ac_option
312do
313  # If the previous option needs an argument, assign it.
314  if test -n "$ac_prev"; then
315    eval "$ac_prev=\$ac_option"
316    ac_prev=
317    continue
318  fi
319
320  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
321
322  # Accept the important Cygnus configure options, so we can diagnose typos.
323
324  case $ac_option in
325
326  -bindir | --bindir | --bindi | --bind | --bin | --bi)
327    ac_prev=bindir ;;
328  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
329    bindir=$ac_optarg ;;
330
331  -build | --build | --buil | --bui | --bu)
332    ac_prev=build_alias ;;
333  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
334    build_alias=$ac_optarg ;;
335
336  -cache-file | --cache-file | --cache-fil | --cache-fi \
337  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
338    ac_prev=cache_file ;;
339  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
340  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
341    cache_file=$ac_optarg ;;
342
343  --config-cache | -C)
344    cache_file=config.cache ;;
345
346  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
347    ac_prev=datadir ;;
348  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
349  | --da=*)
350    datadir=$ac_optarg ;;
351
352  -disable-* | --disable-*)
353    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
354    # Reject names that are not valid shell variable names.
355    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
356      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
357   { (exit 1); exit 1; }; }
358    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
359    eval "enable_$ac_feature=no" ;;
360
361  -enable-* | --enable-*)
362    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
363    # Reject names that are not valid shell variable names.
364    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
365      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
366   { (exit 1); exit 1; }; }
367    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
368    case $ac_option in
369      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
370      *) ac_optarg=yes ;;
371    esac
372    eval "enable_$ac_feature='$ac_optarg'" ;;
373
374  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
375  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
376  | --exec | --exe | --ex)
377    ac_prev=exec_prefix ;;
378  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
379  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
380  | --exec=* | --exe=* | --ex=*)
381    exec_prefix=$ac_optarg ;;
382
383  -gas | --gas | --ga | --g)
384    # Obsolete; use --with-gas.
385    with_gas=yes ;;
386
387  -help | --help | --hel | --he | -h)
388    ac_init_help=long ;;
389  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
390    ac_init_help=recursive ;;
391  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
392    ac_init_help=short ;;
393
394  -host | --host | --hos | --ho)
395    ac_prev=host_alias ;;
396  -host=* | --host=* | --hos=* | --ho=*)
397    host_alias=$ac_optarg ;;
398
399  -includedir | --includedir | --includedi | --included | --include \
400  | --includ | --inclu | --incl | --inc)
401    ac_prev=includedir ;;
402  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
403  | --includ=* | --inclu=* | --incl=* | --inc=*)
404    includedir=$ac_optarg ;;
405
406  -infodir | --infodir | --infodi | --infod | --info | --inf)
407    ac_prev=infodir ;;
408  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
409    infodir=$ac_optarg ;;
410
411  -libdir | --libdir | --libdi | --libd)
412    ac_prev=libdir ;;
413  -libdir=* | --libdir=* | --libdi=* | --libd=*)
414    libdir=$ac_optarg ;;
415
416  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
417  | --libexe | --libex | --libe)
418    ac_prev=libexecdir ;;
419  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
420  | --libexe=* | --libex=* | --libe=*)
421    libexecdir=$ac_optarg ;;
422
423  -localstatedir | --localstatedir | --localstatedi | --localstated \
424  | --localstate | --localstat | --localsta | --localst \
425  | --locals | --local | --loca | --loc | --lo)
426    ac_prev=localstatedir ;;
427  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
428  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
429  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
430    localstatedir=$ac_optarg ;;
431
432  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
433    ac_prev=mandir ;;
434  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
435    mandir=$ac_optarg ;;
436
437  -nfp | --nfp | --nf)
438    # Obsolete; use --without-fp.
439    with_fp=no ;;
440
441  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
442  | --no-cr | --no-c)
443    no_create=yes ;;
444
445  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
446  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
447    no_recursion=yes ;;
448
449  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
450  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
451  | --oldin | --oldi | --old | --ol | --o)
452    ac_prev=oldincludedir ;;
453  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
454  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
455  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
456    oldincludedir=$ac_optarg ;;
457
458  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
459    ac_prev=prefix ;;
460  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
461    prefix=$ac_optarg ;;
462
463  -program-prefix | --program-prefix | --program-prefi | --program-pref \
464  | --program-pre | --program-pr | --program-p)
465    ac_prev=program_prefix ;;
466  -program-prefix=* | --program-prefix=* | --program-prefi=* \
467  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
468    program_prefix=$ac_optarg ;;
469
470  -program-suffix | --program-suffix | --program-suffi | --program-suff \
471  | --program-suf | --program-su | --program-s)
472    ac_prev=program_suffix ;;
473  -program-suffix=* | --program-suffix=* | --program-suffi=* \
474  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
475    program_suffix=$ac_optarg ;;
476
477  -program-transform-name | --program-transform-name \
478  | --program-transform-nam | --program-transform-na \
479  | --program-transform-n | --program-transform- \
480  | --program-transform | --program-transfor \
481  | --program-transfo | --program-transf \
482  | --program-trans | --program-tran \
483  | --progr-tra | --program-tr | --program-t)
484    ac_prev=program_transform_name ;;
485  -program-transform-name=* | --program-transform-name=* \
486  | --program-transform-nam=* | --program-transform-na=* \
487  | --program-transform-n=* | --program-transform-=* \
488  | --program-transform=* | --program-transfor=* \
489  | --program-transfo=* | --program-transf=* \
490  | --program-trans=* | --program-tran=* \
491  | --progr-tra=* | --program-tr=* | --program-t=*)
492    program_transform_name=$ac_optarg ;;
493
494  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
495  | -silent | --silent | --silen | --sile | --sil)
496    silent=yes ;;
497
498  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
499    ac_prev=sbindir ;;
500  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
501  | --sbi=* | --sb=*)
502    sbindir=$ac_optarg ;;
503
504  -sharedstatedir | --sharedstatedir | --sharedstatedi \
505  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
506  | --sharedst | --shareds | --shared | --share | --shar \
507  | --sha | --sh)
508    ac_prev=sharedstatedir ;;
509  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
510  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
511  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
512  | --sha=* | --sh=*)
513    sharedstatedir=$ac_optarg ;;
514
515  -site | --site | --sit)
516    ac_prev=site ;;
517  -site=* | --site=* | --sit=*)
518    site=$ac_optarg ;;
519
520  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
521    ac_prev=srcdir ;;
522  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
523    srcdir=$ac_optarg ;;
524
525  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
526  | --syscon | --sysco | --sysc | --sys | --sy)
527    ac_prev=sysconfdir ;;
528  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
529  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
530    sysconfdir=$ac_optarg ;;
531
532  -target | --target | --targe | --targ | --tar | --ta | --t)
533    ac_prev=target_alias ;;
534  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
535    target_alias=$ac_optarg ;;
536
537  -v | -verbose | --verbose | --verbos | --verbo | --verb)
538    verbose=yes ;;
539
540  -version | --version | --versio | --versi | --vers | -V)
541    ac_init_version=: ;;
542
543  -with-* | --with-*)
544    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
545    # Reject names that are not valid shell variable names.
546    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
547      { echo "$as_me: error: invalid package name: $ac_package" >&2
548   { (exit 1); exit 1; }; }
549    ac_package=`echo $ac_package| sed 's/-/_/g'`
550    case $ac_option in
551      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
552      *) ac_optarg=yes ;;
553    esac
554    eval "with_$ac_package='$ac_optarg'" ;;
555
556  -without-* | --without-*)
557    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
558    # Reject names that are not valid shell variable names.
559    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
560      { echo "$as_me: error: invalid package name: $ac_package" >&2
561   { (exit 1); exit 1; }; }
562    ac_package=`echo $ac_package | sed 's/-/_/g'`
563    eval "with_$ac_package=no" ;;
564
565  --x)
566    # Obsolete; use --with-x.
567    with_x=yes ;;
568
569  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
570  | --x-incl | --x-inc | --x-in | --x-i)
571    ac_prev=x_includes ;;
572  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
573  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
574    x_includes=$ac_optarg ;;
575
576  -x-libraries | --x-libraries | --x-librarie | --x-librari \
577  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
578    ac_prev=x_libraries ;;
579  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
580  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
581    x_libraries=$ac_optarg ;;
582
583  -*) { echo "$as_me: error: unrecognized option: $ac_option
584Try \`$0 --help' for more information." >&2
585   { (exit 1); exit 1; }; }
586    ;;
587
588  *=*)
589    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
590    # Reject names that are not valid shell variable names.
591    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
592      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
593   { (exit 1); exit 1; }; }
594    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
595    eval "$ac_envvar='$ac_optarg'"
596    export $ac_envvar ;;
597
598  *)
599    # FIXME: should be removed in autoconf 3.0.
600    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
601    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
602      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
603    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
604    ;;
605
606  esac
607done
608
609if test -n "$ac_prev"; then
610  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
611  { echo "$as_me: error: missing argument to $ac_option" >&2
612   { (exit 1); exit 1; }; }
613fi
614
615# Be sure to have absolute paths.
616for ac_var in exec_prefix prefix
617do
618  eval ac_val=$`echo $ac_var`
619  case $ac_val in
620    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
621    *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
622   { (exit 1); exit 1; }; };;
623  esac
624done
625
626# Be sure to have absolute paths.
627for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
628              localstatedir libdir includedir oldincludedir infodir mandir
629do
630  eval ac_val=$`echo $ac_var`
631  case $ac_val in
632    [\\/$]* | ?:[\\/]* ) ;;
633    *)  { echo "$as_me: error: expected an absolute path for --$ac_var: $ac_val" >&2
634   { (exit 1); exit 1; }; };;
635  esac
636done
637
638# There might be people who depend on the old broken behavior: `$host'
639# used to hold the argument of --host etc.
640build=$build_alias
641host=$host_alias
642target=$target_alias
643
644# FIXME: should be removed in autoconf 3.0.
645if test "x$host_alias" != x; then
646  if test "x$build_alias" = x; then
647    cross_compiling=maybe
648    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
649    If a cross compiler is detected then cross compile mode will be used." >&2
650  elif test "x$build_alias" != "x$host_alias"; then
651    cross_compiling=yes
652  fi
653fi
654
655ac_tool_prefix=
656test -n "$host_alias" && ac_tool_prefix=$host_alias-
657
658test "$silent" = yes && exec 6>/dev/null
659
660# Find the source files, if location was not specified.
661if test -z "$srcdir"; then
662  ac_srcdir_defaulted=yes
663  # Try the directory containing this script, then its parent.
664  ac_prog=$0
665  ac_confdir=`echo "$ac_prog" | sed 's%[\\/][^\\/][^\\/]*$%%'`
666  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
667  srcdir=$ac_confdir
668  if test ! -r $srcdir/$ac_unique_file; then
669    srcdir=..
670  fi
671else
672  ac_srcdir_defaulted=no
673fi
674if test ! -r $srcdir/$ac_unique_file; then
675  if test "$ac_srcdir_defaulted" = yes; then
676    { echo "$as_me: error: cannot find sources in $ac_confdir or .." >&2
677   { (exit 1); exit 1; }; }
678  else
679    { echo "$as_me: error: cannot find sources in $srcdir" >&2
680   { (exit 1); exit 1; }; }
681  fi
682fi
683srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
684ac_env_build_alias_set=${build_alias+set}
685ac_env_build_alias_value=$build_alias
686ac_cv_env_build_alias_set=${build_alias+set}
687ac_cv_env_build_alias_value=$build_alias
688ac_env_host_alias_set=${host_alias+set}
689ac_env_host_alias_value=$host_alias
690ac_cv_env_host_alias_set=${host_alias+set}
691ac_cv_env_host_alias_value=$host_alias
692ac_env_target_alias_set=${target_alias+set}
693ac_env_target_alias_value=$target_alias
694ac_cv_env_target_alias_set=${target_alias+set}
695ac_cv_env_target_alias_value=$target_alias
696ac_env_CC_set=${CC+set}
697ac_env_CC_value=$CC
698ac_cv_env_CC_set=${CC+set}
699ac_cv_env_CC_value=$CC
700ac_env_CFLAGS_set=${CFLAGS+set}
701ac_env_CFLAGS_value=$CFLAGS
702ac_cv_env_CFLAGS_set=${CFLAGS+set}
703ac_cv_env_CFLAGS_value=$CFLAGS
704ac_env_LDFLAGS_set=${LDFLAGS+set}
705ac_env_LDFLAGS_value=$LDFLAGS
706ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
707ac_cv_env_LDFLAGS_value=$LDFLAGS
708ac_env_CPPFLAGS_set=${CPPFLAGS+set}
709ac_env_CPPFLAGS_value=$CPPFLAGS
710ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
711ac_cv_env_CPPFLAGS_value=$CPPFLAGS
712ac_env_CPP_set=${CPP+set}
713ac_env_CPP_value=$CPP
714ac_cv_env_CPP_set=${CPP+set}
715ac_cv_env_CPP_value=$CPP
716ac_env_CXX_set=${CXX+set}
717ac_env_CXX_value=$CXX
718ac_cv_env_CXX_set=${CXX+set}
719ac_cv_env_CXX_value=$CXX
720ac_env_CXXFLAGS_set=${CXXFLAGS+set}
721ac_env_CXXFLAGS_value=$CXXFLAGS
722ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set}
723ac_cv_env_CXXFLAGS_value=$CXXFLAGS
724ac_env_CXXCPP_set=${CXXCPP+set}
725ac_env_CXXCPP_value=$CXXCPP
726ac_cv_env_CXXCPP_set=${CXXCPP+set}
727ac_cv_env_CXXCPP_value=$CXXCPP
728
729#
730# Report the --help message.
731#
732if test "$ac_init_help" = "long"; then
733  # Omit some internal or obsolete options to make the list less imposing.
734  # This message is too long to be a string in the A/UX 3.1 sh.
735  cat <<EOF
736\`configure' configures this package to adapt to many kinds of systems.
737
738Usage: $0 [OPTION]... [VAR=VALUE]...
739
740To assign environment variables (e.g., CC, CFLAGS...), specify them as
741VAR=VALUE.  See below for descriptions of some of the useful variables.
742
743Defaults for the options are specified in brackets.
744
745Configuration:
746  -h, --help              display this help and exit
747      --help=short        display options specific to this package
748      --help=recursive    display the short help of all the included packages
749  -V, --version           display version information and exit
750  -q, --quiet, --silent   do not print \`checking...' messages
751      --cache-file=FILE   cache test results in FILE [disabled]
752  -C, --config-cache      alias for \`--cache-file=config.cache'
753  -n, --no-create         do not create output files
754      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
755
756EOF
757
758  cat <<EOF
759Installation directories:
760  --prefix=PREFIX         install architecture-independent files in PREFIX
761                          [$ac_default_prefix]
762  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
763                          [PREFIX]
764
765By default, \`make install' will install all the files in
766\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
767an installation prefix other than \`$ac_default_prefix' using \`--prefix',
768for instance \`--prefix=\$HOME'.
769
770For better control, use the options below.
771
772Fine tuning of the installation directories:
773  --bindir=DIR           user executables [EPREFIX/bin]
774  --sbindir=DIR          system admin executables [EPREFIX/sbin]
775  --libexecdir=DIR       program executables [EPREFIX/libexec]
776  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
777  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
778  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
779  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
780  --libdir=DIR           object code libraries [EPREFIX/lib]
781  --includedir=DIR       C header files [PREFIX/include]
782  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
783  --infodir=DIR          info documentation [PREFIX/info]
784  --mandir=DIR           man documentation [PREFIX/man]
785EOF
786
787  cat <<\EOF
788
789Program names:
790  --program-prefix=PREFIX            prepend PREFIX to installed program names
791  --program-suffix=SUFFIX            append SUFFIX to installed program names
792  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
793
794X features:
795  --x-includes=DIR    X include files are in DIR
796  --x-libraries=DIR   X library files are in DIR
797
798System types:
799  --build=BUILD     configure for building on BUILD [guessed]
800  --host=HOST       build programs to run on HOST [BUILD]
801EOF
802fi
803
804if test -n "$ac_init_help"; then
805
806  cat <<\EOF
807
808Optional Features:
809  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
810  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
811  --enable-shared=PKGS  build shared libraries default=yes
812  --enable-static=PKGS  build static libraries default=yes
813  --enable-fast-install=PKGS  optimize for fast installation default=yes
814  --disable-libtool-lock  avoid locking (might break parallel builds)
815
816Optional Packages:
817  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
818  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
819  --with-gnu-ld           assume the C compiler uses GNU ld default=no
820  --with-pic              try to use only PIC/non-PIC objects default=use both
821  --with-ttf-dir          where the root of freetype is installed
822  --with-ttf-includes     where the freetype includes are.
823  --with-ttf-libraries    where the freetype library is installed.
824  --with-x                use the X Window System
825  --with-gl-dir           where the root of OpenGL is installed
826  --with-gl-includes      where the OpenGL includes are.
827  --with-gl-libraries     where the OpenGL library is installed.
828  --with-glut-dir         where the root of glut is installed
829  --with-glut-includes    where the glut includes are.
830  --with-glut-libraries   where the glut library is installed.
831
832Some influential environment variables:
833  CC          C compiler command
834  CFLAGS      C compiler flags
835  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
836              nonstandard directory <lib dir>
837  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
838              headers in a nonstandard directory <include dir>
839  CPP         C preprocessor
840  CXX         C++ compiler command
841  CXXFLAGS    C++ compiler flags
842  CXXCPP      C++ preprocessor
843
844Use these variables to override the choices made by `configure' or to help
845it to find libraries and programs with nonstandard names/locations.
846
847EOF
848fi
849
850if test "$ac_init_help" = "recursive"; then
851  # If there are subdirs, report their specific --help.
852  ac_popdir=`pwd`
853  for ac_subdir in : $ac_subdirs_all; do test "x$ac_subdir" = x: && continue
854    cd $ac_subdir
855    # A "../" for each directory in /$ac_subdir.
856    ac_dots=`echo $ac_subdir |
857             sed 's,^\./,,;s,[^/]$,&/,;s,[^/]*/,../,g'`
858
859    case $srcdir in
860    .) # No --srcdir option.  We are building in place.
861      ac_sub_srcdir=$srcdir ;;
862    [\\/]* | ?:[\\/]* ) # Absolute path.
863      ac_sub_srcdir=$srcdir/$ac_subdir ;;
864    *) # Relative path.
865      ac_sub_srcdir=$ac_dots$srcdir/$ac_subdir ;;
866    esac
867
868    # Check for guested configure; otherwise get Cygnus style configure.
869    if test -f $ac_sub_srcdir/configure.gnu; then
870      echo
871      $SHELL $ac_sub_srcdir/configure.gnu  --help=recursive
872    elif test -f $ac_sub_srcdir/configure; then
873      echo
874      $SHELL $ac_sub_srcdir/configure  --help=recursive
875    elif test -f $ac_sub_srcdir/configure.ac ||
876           test -f $ac_sub_srcdir/configure.in; then
877      echo
878      $ac_configure --help
879    else
880      echo "$as_me: WARNING: no configuration information is in $ac_subdir" >&2
881    fi
882    cd $ac_popdir
883  done
884fi
885
886test -n "$ac_init_help" && exit 0
887if $ac_init_version; then
888  cat <<\EOF
889
890Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
891Free Software Foundation, Inc.
892This configure script is free software; the Free Software Foundation
893gives unlimited permission to copy, distribute and modify it.
894EOF
895  exit 0
896fi
897exec 5>config.log
898cat >&5 <<EOF
899This file contains any messages produced by compilers while
900running configure, to aid debugging if configure makes a mistake.
901
902It was created by $as_me, which was
903generated by GNU Autoconf 2.52.  Invocation command line was
904
905  $ $0 $@
906
907EOF
908{
909cat <<_ASUNAME
910## ---------- ##
911## Platform.  ##
912## ---------- ##
913
914hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
915uname -m = `(uname -m) 2>/dev/null || echo unknown`
916uname -r = `(uname -r) 2>/dev/null || echo unknown`
917uname -s = `(uname -s) 2>/dev/null || echo unknown`
918uname -v = `(uname -v) 2>/dev/null || echo unknown`
919
920/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
921/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
922
923/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
924/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
925/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
926hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
927/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
928/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
929/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
930
931PATH = $PATH
932
933_ASUNAME
934} >&5
935
936cat >&5 <<EOF
937## ------------ ##
938## Core tests.  ##
939## ------------ ##
940
941EOF
942
943# Keep a trace of the command line.
944# Strip out --no-create and --no-recursion so they do not pile up.
945# Also quote any args containing shell meta-characters.
946ac_configure_args=
947ac_sep=
948for ac_arg
949do
950  case $ac_arg in
951  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
952  | --no-cr | --no-c) ;;
953  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
954  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
955  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
956    ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
957    ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
958    ac_sep=" " ;;
959  *) ac_configure_args="$ac_configure_args$ac_sep$ac_arg"
960     ac_sep=" " ;;
961  esac
962  # Get rid of the leading space.
963done
964
965# When interrupted or exit'd, cleanup temporary files, and complete
966# config.log.  We remove comments because anyway the quotes in there
967# would cause problems or look ugly.
968trap 'exit_status=$?
969  # Save into config.log some information that might help in debugging.
970  echo >&5
971  echo "## ----------------- ##" >&5
972  echo "## Cache variables.  ##" >&5
973  echo "## ----------------- ##" >&5
974  echo >&5
975  # The following way of writing the cache mishandles newlines in values,
976{
977  (set) 2>&1 |
978    case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
979    *ac_space=\ *)
980      sed -n \
981        "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
982    	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
983      ;;
984    *)
985      sed -n \
986        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
987      ;;
988    esac;
989} >&5
990  sed "/^$/d" confdefs.h >conftest.log
991  if test -s conftest.log; then
992    echo >&5
993    echo "## ------------ ##" >&5
994    echo "## confdefs.h.  ##" >&5
995    echo "## ------------ ##" >&5
996    echo >&5
997    cat conftest.log >&5
998  fi
999  (echo; echo) >&5
1000  test "$ac_signal" != 0 &&
1001    echo "$as_me: caught signal $ac_signal" >&5
1002  echo "$as_me: exit $exit_status" >&5
1003  rm -rf conftest* confdefs* core core.* *.core conf$$* $ac_clean_files &&
1004    exit $exit_status
1005     ' 0
1006for ac_signal in 1 2 13 15; do
1007  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1008done
1009ac_signal=0
1010
1011# confdefs.h avoids OS command line length limits that DEFS can exceed.
1012rm -rf conftest* confdefs.h
1013# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1014echo >confdefs.h
1015
1016# Let the site file select an alternate cache file if it wants to.
1017# Prefer explicitly selected file to automatically selected ones.
1018if test -z "$CONFIG_SITE"; then
1019  if test "x$prefix" != xNONE; then
1020    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1021  else
1022    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1023  fi
1024fi
1025for ac_site_file in $CONFIG_SITE; do
1026  if test -r "$ac_site_file"; then
1027    { echo "$as_me:1027: loading site script $ac_site_file" >&5
1028echo "$as_me: loading site script $ac_site_file" >&6;}
1029    cat "$ac_site_file" >&5
1030    . "$ac_site_file"
1031  fi
1032done
1033
1034if test -r "$cache_file"; then
1035  # Some versions of bash will fail to source /dev/null (special
1036  # files actually), so we avoid doing that.
1037  if test -f "$cache_file"; then
1038    { echo "$as_me:1038: loading cache $cache_file" >&5
1039echo "$as_me: loading cache $cache_file" >&6;}
1040    case $cache_file in
1041      [\\/]* | ?:[\\/]* ) . $cache_file;;
1042      *)                      . ./$cache_file;;
1043    esac
1044  fi
1045else
1046  { echo "$as_me:1046: creating cache $cache_file" >&5
1047echo "$as_me: creating cache $cache_file" >&6;}
1048  >$cache_file
1049fi
1050
1051# Check that the precious variables saved in the cache have kept the same
1052# value.
1053ac_cache_corrupted=false
1054for ac_var in `(set) 2>&1 |
1055               sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1056  eval ac_old_set=\$ac_cv_env_${ac_var}_set
1057  eval ac_new_set=\$ac_env_${ac_var}_set
1058  eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1059  eval ac_new_val="\$ac_env_${ac_var}_value"
1060  case $ac_old_set,$ac_new_set in
1061    set,)
1062      { echo "$as_me:1062: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1063echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1064      ac_cache_corrupted=: ;;
1065    ,set)
1066      { echo "$as_me:1066: error: \`$ac_var' was not set in the previous run" >&5
1067echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1068      ac_cache_corrupted=: ;;
1069    ,);;
1070    *)
1071      if test "x$ac_old_val" != "x$ac_new_val"; then
1072        { echo "$as_me:1072: error: \`$ac_var' has changed since the previous run:" >&5
1073echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1074        { echo "$as_me:1074:   former value:  $ac_old_val" >&5
1075echo "$as_me:   former value:  $ac_old_val" >&2;}
1076        { echo "$as_me:1076:   current value: $ac_new_val" >&5
1077echo "$as_me:   current value: $ac_new_val" >&2;}
1078        ac_cache_corrupted=:
1079      fi;;
1080  esac
1081  # Pass precious variables to config.status.  It doesn't matter if
1082  # we pass some twice (in addition to the command line arguments).
1083  if test "$ac_new_set" = set; then
1084    case $ac_new_val in
1085    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1086      ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"`
1087      ac_configure_args="$ac_configure_args '$ac_arg'"
1088      ;;
1089    *) ac_configure_args="$ac_configure_args $ac_var=$ac_new_val"
1090       ;;
1091    esac
1092  fi
1093done
1094if $ac_cache_corrupted; then
1095  { echo "$as_me:1095: error: changes in the environment can compromise the build" >&5
1096echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1097  { { echo "$as_me:1097: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1098echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1099   { (exit 1); exit 1; }; }
1100fi
1101
1102ac_ext=c
1103ac_cpp='$CPP $CPPFLAGS'
1104ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1105ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1106ac_compiler_gnu=$ac_cv_c_compiler_gnu
1107
1108case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
1109  *c*,-n*) ECHO_N= ECHO_C='
1110' ECHO_T='	' ;;
1111  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
1112  *)      ECHO_N= ECHO_C='\c' ECHO_T= ;;
1113esac
1114echo "#! $SHELL" >conftest.sh
1115echo  "exit 0"   >>conftest.sh
1116chmod +x conftest.sh
1117if { (echo "$as_me:1117: PATH=\".;.\"; conftest.sh") >&5
1118  (PATH=".;."; conftest.sh) 2>&5
1119  ac_status=$?
1120  echo "$as_me:1120: \$? = $ac_status" >&5
1121  (exit $ac_status); }; then
1122  ac_path_separator=';'
1123else
1124  ac_path_separator=:
1125fi
1126PATH_SEPARATOR="$ac_path_separator"
1127rm -f conftest.sh
1128
1129ac_aux_dir=
1130for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1131  if test -f $ac_dir/install-sh; then
1132    ac_aux_dir=$ac_dir
1133    ac_install_sh="$ac_aux_dir/install-sh -c"
1134    break
1135  elif test -f $ac_dir/install.sh; then
1136    ac_aux_dir=$ac_dir
1137    ac_install_sh="$ac_aux_dir/install.sh -c"
1138    break
1139  elif test -f $ac_dir/shtool; then
1140    ac_aux_dir=$ac_dir
1141    ac_install_sh="$ac_aux_dir/shtool install -c"
1142    break
1143  fi
1144done
1145if test -z "$ac_aux_dir"; then
1146  { { echo "$as_me:1146: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
1147echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
1148   { (exit 1); exit 1; }; }
1149fi
1150ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1151ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1152ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1153
1154# Find a good install program.  We prefer a C program (faster),
1155# so one script is as good as another.  But avoid the broken or
1156# incompatible versions:
1157# SysV /etc/install, /usr/sbin/install
1158# SunOS /usr/etc/install
1159# IRIX /sbin/install
1160# AIX /bin/install
1161# AmigaOS /C/install, which installs bootblocks on floppy discs
1162# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1163# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1164# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1165# ./install, which can be erroneously created by make from ./install.sh.
1166echo "$as_me:1166: checking for a BSD compatible install" >&5
1167echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
1168if test -z "$INSTALL"; then
1169if test "${ac_cv_path_install+set}" = set; then
1170  echo $ECHO_N "(cached) $ECHO_C" >&6
1171else
1172    ac_save_IFS=$IFS; IFS=$ac_path_separator
1173  for ac_dir in $PATH; do
1174    IFS=$ac_save_IFS
1175    # Account for people who put trailing slashes in PATH elements.
1176    case $ac_dir/ in
1177    / | ./ | .// | /cC/* \
1178    | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
1179    | /usr/ucb/* ) ;;
1180    *)
1181      # OSF1 and SCO ODT 3.0 have their own names for install.
1182      # Don't use installbsd from OSF since it installs stuff as root
1183      # by default.
1184      for ac_prog in ginstall scoinst install; do
1185        if $as_executable_p "$ac_dir/$ac_prog"; then
1186	  if test $ac_prog = install &&
1187            grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
1188	    # AIX install.  It has an incompatible calling convention.
1189	    :
1190	  elif test $ac_prog = install &&
1191	    grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
1192	    # program-specific install script used by HP pwplus--don't use.
1193	    :
1194	  else
1195	    ac_cv_path_install="$ac_dir/$ac_prog -c"
1196	    break 2
1197	  fi
1198	fi
1199      done
1200      ;;
1201    esac
1202  done
1203
1204fi
1205  if test "${ac_cv_path_install+set}" = set; then
1206    INSTALL=$ac_cv_path_install
1207  else
1208    # As a last resort, use the slow shell script.  We don't cache a
1209    # path for INSTALL within a source directory, because that will
1210    # break other packages using the cache if that directory is
1211    # removed, or if the path is relative.
1212    INSTALL=$ac_install_sh
1213  fi
1214fi
1215echo "$as_me:1215: result: $INSTALL" >&5
1216echo "${ECHO_T}$INSTALL" >&6
1217
1218# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1219# It thinks the first close brace ends the variable substitution.
1220test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1221
1222test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
1223
1224test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1225
1226echo "$as_me:1226: checking whether build environment is sane" >&5
1227echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6
1228# Just in case
1229sleep 1
1230echo timestamp > conftestfile
1231# Do `set' in a subshell so we don't clobber the current shell's
1232# arguments.  Must try -L first in case configure is actually a
1233# symlink; some systems play weird games with the mod time of symlinks
1234# (eg FreeBSD returns the mod time of the symlink's containing
1235# directory).
1236if (
1237   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
1238   if test "$*" = "X"; then
1239      # -L didn't work.
1240      set X `ls -t $srcdir/configure conftestfile`
1241   fi
1242   if test "$*" != "X $srcdir/configure conftestfile" \
1243      && test "$*" != "X conftestfile $srcdir/configure"; then
1244
1245      # If neither matched, then we have a broken ls.  This can happen
1246      # if, for instance, CONFIG_SHELL is bash and it inherits a
1247      # broken ls alias from the environment.  This has actually
1248      # happened.  Such a system could not be considered "sane".
1249      { { echo "$as_me:1249: error: ls -t appears to fail.  Make sure there is not a broken
1250alias in your environment" >&5
1251echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
1252alias in your environment" >&2;}
1253   { (exit 1); exit 1; }; }
1254   fi
1255
1256   test "$2" = conftestfile
1257   )
1258then
1259   # Ok.
1260   :
1261else
1262   { { echo "$as_me:1262: error: newly created file is older than distributed files!
1263Check your system clock" >&5
1264echo "$as_me: error: newly created file is older than distributed files!
1265Check your system clock" >&2;}
1266   { (exit 1); exit 1; }; }
1267fi
1268rm -f conftest*
1269echo "$as_me:1269: result: yes" >&5
1270echo "${ECHO_T}yes" >&6
1271test "$program_prefix" != NONE &&
1272  program_transform_name="s,^,$program_prefix,;$program_transform_name"
1273# Use a double $ so make ignores it.
1274test "$program_suffix" != NONE &&
1275  program_transform_name="s,\$,$program_suffix,;$program_transform_name"
1276# Double any \ or $.  echo might interpret backslashes.
1277# By default was `s,x,x', remove it if useless.
1278cat <<\_ACEOF >conftest.sed
1279s/[\\$]/&&/g;s/;s,x,x,$//
1280_ACEOF
1281program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
1282rm conftest.sed
1283
1284echo "$as_me:1284: checking whether ${MAKE-make} sets \${MAKE}" >&5
1285echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
1286set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
1287if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
1288  echo $ECHO_N "(cached) $ECHO_C" >&6
1289else
1290  cat >conftest.make <<\EOF
1291all:
1292	@echo 'ac_maketemp="${MAKE}"'
1293EOF
1294# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1295eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=`
1296if test -n "$ac_maketemp"; then
1297  eval ac_cv_prog_make_${ac_make}_set=yes
1298else
1299  eval ac_cv_prog_make_${ac_make}_set=no
1300fi
1301rm -f conftest.make
1302fi
1303if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1304  echo "$as_me:1304: result: yes" >&5
1305echo "${ECHO_T}yes" >&6
1306  SET_MAKE=
1307else
1308  echo "$as_me:1308: result: no" >&5
1309echo "${ECHO_T}no" >&6
1310  SET_MAKE="MAKE=${MAKE-make}"
1311fi
1312
1313PACKAGE=gltt
1314
1315VERSION=2.5.2
1316
1317if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
1318  { { echo "$as_me:1318: error: source directory already configured; run \"make distclean\" there first" >&5
1319echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
1320   { (exit 1); exit 1; }; }
1321fi
1322
1323cat >>confdefs.h <<EOF
1324#define PACKAGE "$PACKAGE"
1325EOF
1326
1327cat >>confdefs.h <<EOF
1328#define VERSION "$VERSION"
1329EOF
1330
1331missing_dir=`cd $ac_aux_dir && pwd`
1332echo "$as_me:1332: checking for working aclocal" >&5
1333echo $ECHO_N "checking for working aclocal... $ECHO_C" >&6
1334# Run test in a subshell; some versions of sh will print an error if
1335# an executable is not found, even if stderr is redirected.
1336# Redirect stdin to placate older versions of autoconf.  Sigh.
1337if (aclocal --version) < /dev/null > /dev/null 2>&1; then
1338   ACLOCAL=aclocal
1339   echo "$as_me:1339: result: found" >&5
1340echo "${ECHO_T}found" >&6
1341else
1342   ACLOCAL="$missing_dir/missing aclocal"
1343   echo "$as_me:1343: result: missing" >&5
1344echo "${ECHO_T}missing" >&6
1345fi
1346
1347echo "$as_me:1347: checking for working autoconf" >&5
1348echo $ECHO_N "checking for working autoconf... $ECHO_C" >&6
1349# Run test in a subshell; some versions of sh will print an error if
1350# an executable is not found, even if stderr is redirected.
1351# Redirect stdin to placate older versions of autoconf.  Sigh.
1352if (autoconf --version) < /dev/null > /dev/null 2>&1; then
1353   AUTOCONF=autoconf
1354   echo "$as_me:1354: result: found" >&5
1355echo "${ECHO_T}found" >&6
1356else
1357   AUTOCONF="$missing_dir/missing autoconf"
1358   echo "$as_me:1358: result: missing" >&5
1359echo "${ECHO_T}missing" >&6
1360fi
1361
1362echo "$as_me:1362: checking for working automake" >&5
1363echo $ECHO_N "checking for working automake... $ECHO_C" >&6
1364# Run test in a subshell; some versions of sh will print an error if
1365# an executable is not found, even if stderr is redirected.
1366# Redirect stdin to placate older versions of autoconf.  Sigh.
1367if (automake --version) < /dev/null > /dev/null 2>&1; then
1368   AUTOMAKE=automake
1369   echo "$as_me:1369: result: found" >&5
1370echo "${ECHO_T}found" >&6
1371else
1372   AUTOMAKE="$missing_dir/missing automake"
1373   echo "$as_me:1373: result: missing" >&5
1374echo "${ECHO_T}missing" >&6
1375fi
1376
1377echo "$as_me:1377: checking for working autoheader" >&5
1378echo $ECHO_N "checking for working autoheader... $ECHO_C" >&6
1379# Run test in a subshell; some versions of sh will print an error if
1380# an executable is not found, even if stderr is redirected.
1381# Redirect stdin to placate older versions of autoconf.  Sigh.
1382if (autoheader --version) < /dev/null > /dev/null 2>&1; then
1383   AUTOHEADER=autoheader
1384   echo "$as_me:1384: result: found" >&5
1385echo "${ECHO_T}found" >&6
1386else
1387   AUTOHEADER="$missing_dir/missing autoheader"
1388   echo "$as_me:1388: result: missing" >&5
1389echo "${ECHO_T}missing" >&6
1390fi
1391
1392echo "$as_me:1392: checking for working makeinfo" >&5
1393echo $ECHO_N "checking for working makeinfo... $ECHO_C" >&6
1394# Run test in a subshell; some versions of sh will print an error if
1395# an executable is not found, even if stderr is redirected.
1396# Redirect stdin to placate older versions of autoconf.  Sigh.
1397if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
1398   MAKEINFO=makeinfo
1399   echo "$as_me:1399: result: found" >&5
1400echo "${ECHO_T}found" >&6
1401else
1402   MAKEINFO="$missing_dir/missing makeinfo"
1403   echo "$as_me:1403: result: missing" >&5
1404echo "${ECHO_T}missing" >&6
1405fi
1406
1407ac_config_headers="$ac_config_headers config.h"
1408
1409ac_config_commands="$ac_config_commands default-1"
1410
1411ac_ext=c
1412ac_cpp='$CPP $CPPFLAGS'
1413ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1414ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1415ac_compiler_gnu=$ac_cv_c_compiler_gnu
1416if test -n "$ac_tool_prefix"; then
1417  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1418set dummy ${ac_tool_prefix}gcc; ac_word=$2
1419echo "$as_me:1419: checking for $ac_word" >&5
1420echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1421if test "${ac_cv_prog_CC+set}" = set; then
1422  echo $ECHO_N "(cached) $ECHO_C" >&6
1423else
1424  if test -n "$CC"; then
1425  ac_cv_prog_CC="$CC" # Let the user override the test.
1426else
1427  ac_save_IFS=$IFS; IFS=$ac_path_separator
1428ac_dummy="$PATH"
1429for ac_dir in $ac_dummy; do
1430  IFS=$ac_save_IFS
1431  test -z "$ac_dir" && ac_dir=.
1432  $as_executable_p "$ac_dir/$ac_word" || continue
1433ac_cv_prog_CC="${ac_tool_prefix}gcc"
1434echo "$as_me:1434: found $ac_dir/$ac_word" >&5
1435break
1436done
1437
1438fi
1439fi
1440CC=$ac_cv_prog_CC
1441if test -n "$CC"; then
1442  echo "$as_me:1442: result: $CC" >&5
1443echo "${ECHO_T}$CC" >&6
1444else
1445  echo "$as_me:1445: result: no" >&5
1446echo "${ECHO_T}no" >&6
1447fi
1448
1449fi
1450if test -z "$ac_cv_prog_CC"; then
1451  ac_ct_CC=$CC
1452  # Extract the first word of "gcc", so it can be a program name with args.
1453set dummy gcc; ac_word=$2
1454echo "$as_me:1454: checking for $ac_word" >&5
1455echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1456if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1457  echo $ECHO_N "(cached) $ECHO_C" >&6
1458else
1459  if test -n "$ac_ct_CC"; then
1460  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1461else
1462  ac_save_IFS=$IFS; IFS=$ac_path_separator
1463ac_dummy="$PATH"
1464for ac_dir in $ac_dummy; do
1465  IFS=$ac_save_IFS
1466  test -z "$ac_dir" && ac_dir=.
1467  $as_executable_p "$ac_dir/$ac_word" || continue
1468ac_cv_prog_ac_ct_CC="gcc"
1469echo "$as_me:1469: found $ac_dir/$ac_word" >&5
1470break
1471done
1472
1473fi
1474fi
1475ac_ct_CC=$ac_cv_prog_ac_ct_CC
1476if test -n "$ac_ct_CC"; then
1477  echo "$as_me:1477: result: $ac_ct_CC" >&5
1478echo "${ECHO_T}$ac_ct_CC" >&6
1479else
1480  echo "$as_me:1480: result: no" >&5
1481echo "${ECHO_T}no" >&6
1482fi
1483
1484  CC=$ac_ct_CC
1485else
1486  CC="$ac_cv_prog_CC"
1487fi
1488
1489if test -z "$CC"; then
1490  if test -n "$ac_tool_prefix"; then
1491  # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1492set dummy ${ac_tool_prefix}cc; ac_word=$2
1493echo "$as_me:1493: checking for $ac_word" >&5
1494echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1495if test "${ac_cv_prog_CC+set}" = set; then
1496  echo $ECHO_N "(cached) $ECHO_C" >&6
1497else
1498  if test -n "$CC"; then
1499  ac_cv_prog_CC="$CC" # Let the user override the test.
1500else
1501  ac_save_IFS=$IFS; IFS=$ac_path_separator
1502ac_dummy="$PATH"
1503for ac_dir in $ac_dummy; do
1504  IFS=$ac_save_IFS
1505  test -z "$ac_dir" && ac_dir=.
1506  $as_executable_p "$ac_dir/$ac_word" || continue
1507ac_cv_prog_CC="${ac_tool_prefix}cc"
1508echo "$as_me:1508: found $ac_dir/$ac_word" >&5
1509break
1510done
1511
1512fi
1513fi
1514CC=$ac_cv_prog_CC
1515if test -n "$CC"; then
1516  echo "$as_me:1516: result: $CC" >&5
1517echo "${ECHO_T}$CC" >&6
1518else
1519  echo "$as_me:1519: result: no" >&5
1520echo "${ECHO_T}no" >&6
1521fi
1522
1523fi
1524if test -z "$ac_cv_prog_CC"; then
1525  ac_ct_CC=$CC
1526  # Extract the first word of "cc", so it can be a program name with args.
1527set dummy cc; ac_word=$2
1528echo "$as_me:1528: checking for $ac_word" >&5
1529echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1530if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1531  echo $ECHO_N "(cached) $ECHO_C" >&6
1532else
1533  if test -n "$ac_ct_CC"; then
1534  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1535else
1536  ac_save_IFS=$IFS; IFS=$ac_path_separator
1537ac_dummy="$PATH"
1538for ac_dir in $ac_dummy; do
1539  IFS=$ac_save_IFS
1540  test -z "$ac_dir" && ac_dir=.
1541  $as_executable_p "$ac_dir/$ac_word" || continue
1542ac_cv_prog_ac_ct_CC="cc"
1543echo "$as_me:1543: found $ac_dir/$ac_word" >&5
1544break
1545done
1546
1547fi
1548fi
1549ac_ct_CC=$ac_cv_prog_ac_ct_CC
1550if test -n "$ac_ct_CC"; then
1551  echo "$as_me:1551: result: $ac_ct_CC" >&5
1552echo "${ECHO_T}$ac_ct_CC" >&6
1553else
1554  echo "$as_me:1554: result: no" >&5
1555echo "${ECHO_T}no" >&6
1556fi
1557
1558  CC=$ac_ct_CC
1559else
1560  CC="$ac_cv_prog_CC"
1561fi
1562
1563fi
1564if test -z "$CC"; then
1565  # Extract the first word of "cc", so it can be a program name with args.
1566set dummy cc; ac_word=$2
1567echo "$as_me:1567: checking for $ac_word" >&5
1568echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1569if test "${ac_cv_prog_CC+set}" = set; then
1570  echo $ECHO_N "(cached) $ECHO_C" >&6
1571else
1572  if test -n "$CC"; then
1573  ac_cv_prog_CC="$CC" # Let the user override the test.
1574else
1575  ac_prog_rejected=no
1576  ac_save_IFS=$IFS; IFS=$ac_path_separator
1577ac_dummy="$PATH"
1578for ac_dir in $ac_dummy; do
1579  IFS=$ac_save_IFS
1580  test -z "$ac_dir" && ac_dir=.
1581  $as_executable_p "$ac_dir/$ac_word" || continue
1582if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1583  ac_prog_rejected=yes
1584  continue
1585fi
1586ac_cv_prog_CC="cc"
1587echo "$as_me:1587: found $ac_dir/$ac_word" >&5
1588break
1589done
1590
1591if test $ac_prog_rejected = yes; then
1592  # We found a bogon in the path, so make sure we never use it.
1593  set dummy $ac_cv_prog_CC
1594  shift
1595  if test $# != 0; then
1596    # We chose a different compiler from the bogus one.
1597    # However, it has the same basename, so the bogon will be chosen
1598    # first if we set CC to just the basename; use the full file name.
1599    shift
1600    set dummy "$ac_dir/$ac_word" ${1+"$@"}
1601    shift
1602    ac_cv_prog_CC="$@"
1603  fi
1604fi
1605fi
1606fi
1607CC=$ac_cv_prog_CC
1608if test -n "$CC"; then
1609  echo "$as_me:1609: result: $CC" >&5
1610echo "${ECHO_T}$CC" >&6
1611else
1612  echo "$as_me:1612: result: no" >&5
1613echo "${ECHO_T}no" >&6
1614fi
1615
1616fi
1617if test -z "$CC"; then
1618  if test -n "$ac_tool_prefix"; then
1619  for ac_prog in cl
1620  do
1621    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1622set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1623echo "$as_me:1623: checking for $ac_word" >&5
1624echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1625if test "${ac_cv_prog_CC+set}" = set; then
1626  echo $ECHO_N "(cached) $ECHO_C" >&6
1627else
1628  if test -n "$CC"; then
1629  ac_cv_prog_CC="$CC" # Let the user override the test.
1630else
1631  ac_save_IFS=$IFS; IFS=$ac_path_separator
1632ac_dummy="$PATH"
1633for ac_dir in $ac_dummy; do
1634  IFS=$ac_save_IFS
1635  test -z "$ac_dir" && ac_dir=.
1636  $as_executable_p "$ac_dir/$ac_word" || continue
1637ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1638echo "$as_me:1638: found $ac_dir/$ac_word" >&5
1639break
1640done
1641
1642fi
1643fi
1644CC=$ac_cv_prog_CC
1645if test -n "$CC"; then
1646  echo "$as_me:1646: result: $CC" >&5
1647echo "${ECHO_T}$CC" >&6
1648else
1649  echo "$as_me:1649: result: no" >&5
1650echo "${ECHO_T}no" >&6
1651fi
1652
1653    test -n "$CC" && break
1654  done
1655fi
1656if test -z "$CC"; then
1657  ac_ct_CC=$CC
1658  for ac_prog in cl
1659do
1660  # Extract the first word of "$ac_prog", so it can be a program name with args.
1661set dummy $ac_prog; ac_word=$2
1662echo "$as_me:1662: checking for $ac_word" >&5
1663echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1664if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1665  echo $ECHO_N "(cached) $ECHO_C" >&6
1666else
1667  if test -n "$ac_ct_CC"; then
1668  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1669else
1670  ac_save_IFS=$IFS; IFS=$ac_path_separator
1671ac_dummy="$PATH"
1672for ac_dir in $ac_dummy; do
1673  IFS=$ac_save_IFS
1674  test -z "$ac_dir" && ac_dir=.
1675  $as_executable_p "$ac_dir/$ac_word" || continue
1676ac_cv_prog_ac_ct_CC="$ac_prog"
1677echo "$as_me:1677: found $ac_dir/$ac_word" >&5
1678break
1679done
1680
1681fi
1682fi
1683ac_ct_CC=$ac_cv_prog_ac_ct_CC
1684if test -n "$ac_ct_CC"; then
1685  echo "$as_me:1685: result: $ac_ct_CC" >&5
1686echo "${ECHO_T}$ac_ct_CC" >&6
1687else
1688  echo "$as_me:1688: result: no" >&5
1689echo "${ECHO_T}no" >&6
1690fi
1691
1692  test -n "$ac_ct_CC" && break
1693done
1694
1695  CC=$ac_ct_CC
1696fi
1697
1698fi
1699
1700test -z "$CC" && { { echo "$as_me:1700: error: no acceptable cc found in \$PATH" >&5
1701echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
1702   { (exit 1); exit 1; }; }
1703
1704# Provide some information about the compiler.
1705echo "$as_me:1705:" \
1706     "checking for C compiler version" >&5
1707ac_compiler=`set X $ac_compile; echo $2`
1708{ (eval echo "$as_me:1708: \"$ac_compiler --version </dev/null >&5\"") >&5
1709  (eval $ac_compiler --version </dev/null >&5) 2>&5
1710  ac_status=$?
1711  echo "$as_me:1711: \$? = $ac_status" >&5
1712  (exit $ac_status); }
1713{ (eval echo "$as_me:1713: \"$ac_compiler -v </dev/null >&5\"") >&5
1714  (eval $ac_compiler -v </dev/null >&5) 2>&5
1715  ac_status=$?
1716  echo "$as_me:1716: \$? = $ac_status" >&5
1717  (exit $ac_status); }
1718{ (eval echo "$as_me:1718: \"$ac_compiler -V </dev/null >&5\"") >&5
1719  (eval $ac_compiler -V </dev/null >&5) 2>&5
1720  ac_status=$?
1721  echo "$as_me:1721: \$? = $ac_status" >&5
1722  (exit $ac_status); }
1723
1724cat >conftest.$ac_ext <<_ACEOF
1725#line 1725 "configure"
1726#include "confdefs.h"
1727
1728int
1729main ()
1730{
1731
1732  ;
1733  return 0;
1734}
1735_ACEOF
1736ac_clean_files_save=$ac_clean_files
1737ac_clean_files="$ac_clean_files a.out a.exe"
1738# Try to create an executable without -o first, disregard a.out.
1739# It will help us diagnose broken compilers, and finding out an intuition
1740# of exeext.
1741echo "$as_me:1741: checking for C compiler default output" >&5
1742echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1743ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1744if { (eval echo "$as_me:1744: \"$ac_link_default\"") >&5
1745  (eval $ac_link_default) 2>&5
1746  ac_status=$?
1747  echo "$as_me:1747: \$? = $ac_status" >&5
1748  (exit $ac_status); }; then
1749  # Find the output, starting from the most likely.  This scheme is
1750# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1751# resort.
1752for ac_file in `ls a.exe conftest.exe 2>/dev/null;
1753                ls a.out conftest 2>/dev/null;
1754                ls a.* conftest.* 2>/dev/null`; do
1755  case $ac_file in
1756    *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1757    a.out ) # We found the default executable, but exeext='' is most
1758            # certainly right.
1759            break;;
1760    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1761          # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1762          export ac_cv_exeext
1763          break;;
1764    * ) break;;
1765  esac
1766done
1767else
1768  echo "$as_me: failed program was:" >&5
1769cat conftest.$ac_ext >&5
1770{ { echo "$as_me:1770: error: C compiler cannot create executables" >&5
1771echo "$as_me: error: C compiler cannot create executables" >&2;}
1772   { (exit 77); exit 77; }; }
1773fi
1774
1775ac_exeext=$ac_cv_exeext
1776echo "$as_me:1776: result: $ac_file" >&5
1777echo "${ECHO_T}$ac_file" >&6
1778
1779# Check the compiler produces executables we can run.  If not, either
1780# the compiler is broken, or we cross compile.
1781echo "$as_me:1781: checking whether the C compiler works" >&5
1782echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
1783# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1784# If not cross compiling, check that we can run a simple program.
1785if test "$cross_compiling" != yes; then
1786  if { ac_try='./$ac_file'
1787  { (eval echo "$as_me:1787: \"$ac_try\"") >&5
1788  (eval $ac_try) 2>&5
1789  ac_status=$?
1790  echo "$as_me:1790: \$? = $ac_status" >&5
1791  (exit $ac_status); }; }; then
1792    cross_compiling=no
1793  else
1794    if test "$cross_compiling" = maybe; then
1795	cross_compiling=yes
1796    else
1797	{ { echo "$as_me:1797: error: cannot run C compiled programs.
1798If you meant to cross compile, use \`--host'." >&5
1799echo "$as_me: error: cannot run C compiled programs.
1800If you meant to cross compile, use \`--host'." >&2;}
1801   { (exit 1); exit 1; }; }
1802    fi
1803  fi
1804fi
1805echo "$as_me:1805: result: yes" >&5
1806echo "${ECHO_T}yes" >&6
1807
1808rm -f a.out a.exe conftest$ac_cv_exeext
1809ac_clean_files=$ac_clean_files_save
1810# Check the compiler produces executables we can run.  If not, either
1811# the compiler is broken, or we cross compile.
1812echo "$as_me:1812: checking whether we are cross compiling" >&5
1813echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1814echo "$as_me:1814: result: $cross_compiling" >&5
1815echo "${ECHO_T}$cross_compiling" >&6
1816
1817echo "$as_me:1817: checking for executable suffix" >&5
1818echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
1819if { (eval echo "$as_me:1819: \"$ac_link\"") >&5
1820  (eval $ac_link) 2>&5
1821  ac_status=$?
1822  echo "$as_me:1822: \$? = $ac_status" >&5
1823  (exit $ac_status); }; then
1824  # If both `conftest.exe' and `conftest' are `present' (well, observable)
1825# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
1826# work properly (i.e., refer to `conftest.exe'), while it won't with
1827# `rm'.
1828for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1829  case $ac_file in
1830    *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1831    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1832          export ac_cv_exeext
1833          break;;
1834    * ) break;;
1835  esac
1836done
1837else
1838  { { echo "$as_me:1838: error: cannot compute EXEEXT: cannot compile and link" >&5
1839echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
1840   { (exit 1); exit 1; }; }
1841fi
1842
1843rm -f conftest$ac_cv_exeext
1844echo "$as_me:1844: result: $ac_cv_exeext" >&5
1845echo "${ECHO_T}$ac_cv_exeext" >&6
1846
1847rm -f conftest.$ac_ext
1848EXEEXT=$ac_cv_exeext
1849ac_exeext=$EXEEXT
1850echo "$as_me:1850: checking for object suffix" >&5
1851echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
1852if test "${ac_cv_objext+set}" = set; then
1853  echo $ECHO_N "(cached) $ECHO_C" >&6
1854else
1855  cat >conftest.$ac_ext <<_ACEOF
1856#line 1856 "configure"
1857#include "confdefs.h"
1858
1859int
1860main ()
1861{
1862
1863  ;
1864  return 0;
1865}
1866_ACEOF
1867rm -f conftest.o conftest.obj
1868if { (eval echo "$as_me:1868: \"$ac_compile\"") >&5
1869  (eval $ac_compile) 2>&5
1870  ac_status=$?
1871  echo "$as_me:1871: \$? = $ac_status" >&5
1872  (exit $ac_status); }; then
1873  for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
1874  case $ac_file in
1875    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
1876    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
1877       break;;
1878  esac
1879done
1880else
1881  echo "$as_me: failed program was:" >&5
1882cat conftest.$ac_ext >&5
1883{ { echo "$as_me:1883: error: cannot compute OBJEXT: cannot compile" >&5
1884echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
1885   { (exit 1); exit 1; }; }
1886fi
1887
1888rm -f conftest.$ac_cv_objext conftest.$ac_ext
1889fi
1890echo "$as_me:1890: result: $ac_cv_objext" >&5
1891echo "${ECHO_T}$ac_cv_objext" >&6
1892OBJEXT=$ac_cv_objext
1893ac_objext=$OBJEXT
1894echo "$as_me:1894: checking whether we are using the GNU C compiler" >&5
1895echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
1896if test "${ac_cv_c_compiler_gnu+set}" = set; then
1897  echo $ECHO_N "(cached) $ECHO_C" >&6
1898else
1899  cat >conftest.$ac_ext <<_ACEOF
1900#line 1900 "configure"
1901#include "confdefs.h"
1902
1903int
1904main ()
1905{
1906#ifndef __GNUC__
1907       choke me
1908#endif
1909
1910  ;
1911  return 0;
1912}
1913_ACEOF
1914rm -f conftest.$ac_objext
1915if { (eval echo "$as_me:1915: \"$ac_compile\"") >&5
1916  (eval $ac_compile) 2>&5
1917  ac_status=$?
1918  echo "$as_me:1918: \$? = $ac_status" >&5
1919  (exit $ac_status); } &&
1920         { ac_try='test -s conftest.$ac_objext'
1921  { (eval echo "$as_me:1921: \"$ac_try\"") >&5
1922  (eval $ac_try) 2>&5
1923  ac_status=$?
1924  echo "$as_me:1924: \$? = $ac_status" >&5
1925  (exit $ac_status); }; }; then
1926  ac_compiler_gnu=yes
1927else
1928  echo "$as_me: failed program was:" >&5
1929cat conftest.$ac_ext >&5
1930ac_compiler_gnu=no
1931fi
1932rm -f conftest.$ac_objext conftest.$ac_ext
1933ac_cv_c_compiler_gnu=$ac_compiler_gnu
1934
1935fi
1936echo "$as_me:1936: result: $ac_cv_c_compiler_gnu" >&5
1937echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
1938GCC=`test $ac_compiler_gnu = yes && echo yes`
1939ac_test_CFLAGS=${CFLAGS+set}
1940ac_save_CFLAGS=$CFLAGS
1941CFLAGS="-g"
1942echo "$as_me:1942: checking whether $CC accepts -g" >&5
1943echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
1944if test "${ac_cv_prog_cc_g+set}" = set; then
1945  echo $ECHO_N "(cached) $ECHO_C" >&6
1946else
1947  cat >conftest.$ac_ext <<_ACEOF
1948#line 1948 "configure"
1949#include "confdefs.h"
1950
1951int
1952main ()
1953{
1954
1955  ;
1956  return 0;
1957}
1958_ACEOF
1959rm -f conftest.$ac_objext
1960if { (eval echo "$as_me:1960: \"$ac_compile\"") >&5
1961  (eval $ac_compile) 2>&5
1962  ac_status=$?
1963  echo "$as_me:1963: \$? = $ac_status" >&5
1964  (exit $ac_status); } &&
1965         { ac_try='test -s conftest.$ac_objext'
1966  { (eval echo "$as_me:1966: \"$ac_try\"") >&5
1967  (eval $ac_try) 2>&5
1968  ac_status=$?
1969  echo "$as_me:1969: \$? = $ac_status" >&5
1970  (exit $ac_status); }; }; then
1971  ac_cv_prog_cc_g=yes
1972else
1973  echo "$as_me: failed program was:" >&5
1974cat conftest.$ac_ext >&5
1975ac_cv_prog_cc_g=no
1976fi
1977rm -f conftest.$ac_objext conftest.$ac_ext
1978fi
1979echo "$as_me:1979: result: $ac_cv_prog_cc_g" >&5
1980echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
1981if test "$ac_test_CFLAGS" = set; then
1982  CFLAGS=$ac_save_CFLAGS
1983elif test $ac_cv_prog_cc_g = yes; then
1984  if test "$GCC" = yes; then
1985    CFLAGS="-g -O2"
1986  else
1987    CFLAGS="-g"
1988  fi
1989else
1990  if test "$GCC" = yes; then
1991    CFLAGS="-O2"
1992  else
1993    CFLAGS=
1994  fi
1995fi
1996# Some people use a C++ compiler to compile C.  Since we use `exit',
1997# in C++ we need to declare it.  In case someone uses the same compiler
1998# for both compiling C and C++ we need to have the C++ compiler decide
1999# the declaration of exit, since it's the most demanding environment.
2000cat >conftest.$ac_ext <<_ACEOF
2001#ifndef __cplusplus
2002  choke me
2003#endif
2004_ACEOF
2005rm -f conftest.$ac_objext
2006if { (eval echo "$as_me:2006: \"$ac_compile\"") >&5
2007  (eval $ac_compile) 2>&5
2008  ac_status=$?
2009  echo "$as_me:2009: \$? = $ac_status" >&5
2010  (exit $ac_status); } &&
2011         { ac_try='test -s conftest.$ac_objext'
2012  { (eval echo "$as_me:2012: \"$ac_try\"") >&5
2013  (eval $ac_try) 2>&5
2014  ac_status=$?
2015  echo "$as_me:2015: \$? = $ac_status" >&5
2016  (exit $ac_status); }; }; then
2017  for ac_declaration in \
2018   ''\
2019   '#include <stdlib.h>' \
2020   'extern "C" void std::exit (int) throw (); using std::exit;' \
2021   'extern "C" void std::exit (int); using std::exit;' \
2022   'extern "C" void exit (int) throw ();' \
2023   'extern "C" void exit (int);' \
2024   'void exit (int);'
2025do
2026  cat >conftest.$ac_ext <<_ACEOF
2027#line 2027 "configure"
2028#include "confdefs.h"
2029#include <stdlib.h>
2030$ac_declaration
2031int
2032main ()
2033{
2034exit (42);
2035  ;
2036  return 0;
2037}
2038_ACEOF
2039rm -f conftest.$ac_objext
2040if { (eval echo "$as_me:2040: \"$ac_compile\"") >&5
2041  (eval $ac_compile) 2>&5
2042  ac_status=$?
2043  echo "$as_me:2043: \$? = $ac_status" >&5
2044  (exit $ac_status); } &&
2045         { ac_try='test -s conftest.$ac_objext'
2046  { (eval echo "$as_me:2046: \"$ac_try\"") >&5
2047  (eval $ac_try) 2>&5
2048  ac_status=$?
2049  echo "$as_me:2049: \$? = $ac_status" >&5
2050  (exit $ac_status); }; }; then
2051  :
2052else
2053  echo "$as_me: failed program was:" >&5
2054cat conftest.$ac_ext >&5
2055continue
2056fi
2057rm -f conftest.$ac_objext conftest.$ac_ext
2058  cat >conftest.$ac_ext <<_ACEOF
2059#line 2059 "configure"
2060#include "confdefs.h"
2061$ac_declaration
2062int
2063main ()
2064{
2065exit (42);
2066  ;
2067  return 0;
2068}
2069_ACEOF
2070rm -f conftest.$ac_objext
2071if { (eval echo "$as_me:2071: \"$ac_compile\"") >&5
2072  (eval $ac_compile) 2>&5
2073  ac_status=$?
2074  echo "$as_me:2074: \$? = $ac_status" >&5
2075  (exit $ac_status); } &&
2076         { ac_try='test -s conftest.$ac_objext'
2077  { (eval echo "$as_me:2077: \"$ac_try\"") >&5
2078  (eval $ac_try) 2>&5
2079  ac_status=$?
2080  echo "$as_me:2080: \$? = $ac_status" >&5
2081  (exit $ac_status); }; }; then
2082  break
2083else
2084  echo "$as_me: failed program was:" >&5
2085cat conftest.$ac_ext >&5
2086fi
2087rm -f conftest.$ac_objext conftest.$ac_ext
2088done
2089rm -f conftest*
2090if test -n "$ac_declaration"; then
2091  echo '#ifdef __cplusplus' >>confdefs.h
2092  echo $ac_declaration      >>confdefs.h
2093  echo '#endif'             >>confdefs.h
2094fi
2095
2096else
2097  echo "$as_me: failed program was:" >&5
2098cat conftest.$ac_ext >&5
2099fi
2100rm -f conftest.$ac_objext conftest.$ac_ext
2101ac_ext=c
2102ac_cpp='$CPP $CPPFLAGS'
2103ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2104ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2105ac_compiler_gnu=$ac_cv_c_compiler_gnu
2106
2107ac_ext=c
2108ac_cpp='$CPP $CPPFLAGS'
2109ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2110ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2111ac_compiler_gnu=$ac_cv_c_compiler_gnu
2112echo "$as_me:2112: checking how to run the C preprocessor" >&5
2113echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2114# On Suns, sometimes $CPP names a directory.
2115if test -n "$CPP" && test -d "$CPP"; then
2116  CPP=
2117fi
2118if test -z "$CPP"; then
2119  if test "${ac_cv_prog_CPP+set}" = set; then
2120  echo $ECHO_N "(cached) $ECHO_C" >&6
2121else
2122      # Double quotes because CPP needs to be expanded
2123    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2124    do
2125      ac_preproc_ok=false
2126for ac_c_preproc_warn_flag in '' yes
2127do
2128  # Use a header file that comes with gcc, so configuring glibc
2129  # with a fresh cross-compiler works.
2130  # On the NeXT, cc -E runs the code through the compiler's parser,
2131  # not just through cpp. "Syntax error" is here to catch this case.
2132  cat >conftest.$ac_ext <<_ACEOF
2133#line 2133 "configure"
2134#include "confdefs.h"
2135#include <assert.h>
2136                     Syntax error
2137_ACEOF
2138if { (eval echo "$as_me:2138: \"$ac_cpp conftest.$ac_ext\"") >&5
2139  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2140  ac_status=$?
2141  egrep -v '^ *\+' conftest.er1 >conftest.err
2142  rm -f conftest.er1
2143  cat conftest.err >&5
2144  echo "$as_me:2144: \$? = $ac_status" >&5
2145  (exit $ac_status); } >/dev/null; then
2146  if test -s conftest.err; then
2147    ac_cpp_err=$ac_c_preproc_warn_flag
2148  else
2149    ac_cpp_err=
2150  fi
2151else
2152  ac_cpp_err=yes
2153fi
2154if test -z "$ac_cpp_err"; then
2155  :
2156else
2157  echo "$as_me: failed program was:" >&5
2158  cat conftest.$ac_ext >&5
2159  # Broken: fails on valid input.
2160continue
2161fi
2162rm -f conftest.err conftest.$ac_ext
2163
2164  # OK, works on sane cases.  Now check whether non-existent headers
2165  # can be detected and how.
2166  cat >conftest.$ac_ext <<_ACEOF
2167#line 2167 "configure"
2168#include "confdefs.h"
2169#include <ac_nonexistent.h>
2170_ACEOF
2171if { (eval echo "$as_me:2171: \"$ac_cpp conftest.$ac_ext\"") >&5
2172  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2173  ac_status=$?
2174  egrep -v '^ *\+' conftest.er1 >conftest.err
2175  rm -f conftest.er1
2176  cat conftest.err >&5
2177  echo "$as_me:2177: \$? = $ac_status" >&5
2178  (exit $ac_status); } >/dev/null; then
2179  if test -s conftest.err; then
2180    ac_cpp_err=$ac_c_preproc_warn_flag
2181  else
2182    ac_cpp_err=
2183  fi
2184else
2185  ac_cpp_err=yes
2186fi
2187if test -z "$ac_cpp_err"; then
2188  # Broken: success on invalid input.
2189continue
2190else
2191  echo "$as_me: failed program was:" >&5
2192  cat conftest.$ac_ext >&5
2193  # Passes both tests.
2194ac_preproc_ok=:
2195break
2196fi
2197rm -f conftest.err conftest.$ac_ext
2198
2199done
2200# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2201rm -f conftest.err conftest.$ac_ext
2202if $ac_preproc_ok; then
2203  break
2204fi
2205
2206    done
2207    ac_cv_prog_CPP=$CPP
2208
2209fi
2210  CPP=$ac_cv_prog_CPP
2211else
2212  ac_cv_prog_CPP=$CPP
2213fi
2214echo "$as_me:2214: result: $CPP" >&5
2215echo "${ECHO_T}$CPP" >&6
2216ac_preproc_ok=false
2217for ac_c_preproc_warn_flag in '' yes
2218do
2219  # Use a header file that comes with gcc, so configuring glibc
2220  # with a fresh cross-compiler works.
2221  # On the NeXT, cc -E runs the code through the compiler's parser,
2222  # not just through cpp. "Syntax error" is here to catch this case.
2223  cat >conftest.$ac_ext <<_ACEOF
2224#line 2224 "configure"
2225#include "confdefs.h"
2226#include <assert.h>
2227                     Syntax error
2228_ACEOF
2229if { (eval echo "$as_me:2229: \"$ac_cpp conftest.$ac_ext\"") >&5
2230  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2231  ac_status=$?
2232  egrep -v '^ *\+' conftest.er1 >conftest.err
2233  rm -f conftest.er1
2234  cat conftest.err >&5
2235  echo "$as_me:2235: \$? = $ac_status" >&5
2236  (exit $ac_status); } >/dev/null; then
2237  if test -s conftest.err; then
2238    ac_cpp_err=$ac_c_preproc_warn_flag
2239  else
2240    ac_cpp_err=
2241  fi
2242else
2243  ac_cpp_err=yes
2244fi
2245if test -z "$ac_cpp_err"; then
2246  :
2247else
2248  echo "$as_me: failed program was:" >&5
2249  cat conftest.$ac_ext >&5
2250  # Broken: fails on valid input.
2251continue
2252fi
2253rm -f conftest.err conftest.$ac_ext
2254
2255  # OK, works on sane cases.  Now check whether non-existent headers
2256  # can be detected and how.
2257  cat >conftest.$ac_ext <<_ACEOF
2258#line 2258 "configure"
2259#include "confdefs.h"
2260#include <ac_nonexistent.h>
2261_ACEOF
2262if { (eval echo "$as_me:2262: \"$ac_cpp conftest.$ac_ext\"") >&5
2263  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2264  ac_status=$?
2265  egrep -v '^ *\+' conftest.er1 >conftest.err
2266  rm -f conftest.er1
2267  cat conftest.err >&5
2268  echo "$as_me:2268: \$? = $ac_status" >&5
2269  (exit $ac_status); } >/dev/null; then
2270  if test -s conftest.err; then
2271    ac_cpp_err=$ac_c_preproc_warn_flag
2272  else
2273    ac_cpp_err=
2274  fi
2275else
2276  ac_cpp_err=yes
2277fi
2278if test -z "$ac_cpp_err"; then
2279  # Broken: success on invalid input.
2280continue
2281else
2282  echo "$as_me: failed program was:" >&5
2283  cat conftest.$ac_ext >&5
2284  # Passes both tests.
2285ac_preproc_ok=:
2286break
2287fi
2288rm -f conftest.err conftest.$ac_ext
2289
2290done
2291# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2292rm -f conftest.err conftest.$ac_ext
2293if $ac_preproc_ok; then
2294  :
2295else
2296  { { echo "$as_me:2296: error: C preprocessor \"$CPP\" fails sanity check" >&5
2297echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2298   { (exit 1); exit 1; }; }
2299fi
2300
2301ac_ext=c
2302ac_cpp='$CPP $CPPFLAGS'
2303ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2304ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2305ac_compiler_gnu=$ac_cv_c_compiler_gnu
2306
2307ac_ext=cc
2308ac_cpp='$CXXCPP $CPPFLAGS'
2309ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2310ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2311ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
2312if test -n "$ac_tool_prefix"; then
2313  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2314  do
2315    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2316set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2317echo "$as_me:2317: checking for $ac_word" >&5
2318echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2319if test "${ac_cv_prog_CXX+set}" = set; then
2320  echo $ECHO_N "(cached) $ECHO_C" >&6
2321else
2322  if test -n "$CXX"; then
2323  ac_cv_prog_CXX="$CXX" # Let the user override the test.
2324else
2325  ac_save_IFS=$IFS; IFS=$ac_path_separator
2326ac_dummy="$PATH"
2327for ac_dir in $ac_dummy; do
2328  IFS=$ac_save_IFS
2329  test -z "$ac_dir" && ac_dir=.
2330  $as_executable_p "$ac_dir/$ac_word" || continue
2331ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
2332echo "$as_me:2332: found $ac_dir/$ac_word" >&5
2333break
2334done
2335
2336fi
2337fi
2338CXX=$ac_cv_prog_CXX
2339if test -n "$CXX"; then
2340  echo "$as_me:2340: result: $CXX" >&5
2341echo "${ECHO_T}$CXX" >&6
2342else
2343  echo "$as_me:2343: result: no" >&5
2344echo "${ECHO_T}no" >&6
2345fi
2346
2347    test -n "$CXX" && break
2348  done
2349fi
2350if test -z "$CXX"; then
2351  ac_ct_CXX=$CXX
2352  for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl FCC KCC RCC xlC_r xlC
2353do
2354  # Extract the first word of "$ac_prog", so it can be a program name with args.
2355set dummy $ac_prog; ac_word=$2
2356echo "$as_me:2356: checking for $ac_word" >&5
2357echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2358if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
2359  echo $ECHO_N "(cached) $ECHO_C" >&6
2360else
2361  if test -n "$ac_ct_CXX"; then
2362  ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
2363else
2364  ac_save_IFS=$IFS; IFS=$ac_path_separator
2365ac_dummy="$PATH"
2366for ac_dir in $ac_dummy; do
2367  IFS=$ac_save_IFS
2368  test -z "$ac_dir" && ac_dir=.
2369  $as_executable_p "$ac_dir/$ac_word" || continue
2370ac_cv_prog_ac_ct_CXX="$ac_prog"
2371echo "$as_me:2371: found $ac_dir/$ac_word" >&5
2372break
2373done
2374
2375fi
2376fi
2377ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
2378if test -n "$ac_ct_CXX"; then
2379  echo "$as_me:2379: result: $ac_ct_CXX" >&5
2380echo "${ECHO_T}$ac_ct_CXX" >&6
2381else
2382  echo "$as_me:2382: result: no" >&5
2383echo "${ECHO_T}no" >&6
2384fi
2385
2386  test -n "$ac_ct_CXX" && break
2387done
2388test -n "$ac_ct_CXX" || ac_ct_CXX="g++"
2389
2390  CXX=$ac_ct_CXX
2391fi
2392
2393# Provide some information about the compiler.
2394echo "$as_me:2394:" \
2395     "checking for C++ compiler version" >&5
2396ac_compiler=`set X $ac_compile; echo $2`
2397{ (eval echo "$as_me:2397: \"$ac_compiler --version </dev/null >&5\"") >&5
2398  (eval $ac_compiler --version </dev/null >&5) 2>&5
2399  ac_status=$?
2400  echo "$as_me:2400: \$? = $ac_status" >&5
2401  (exit $ac_status); }
2402{ (eval echo "$as_me:2402: \"$ac_compiler -v </dev/null >&5\"") >&5
2403  (eval $ac_compiler -v </dev/null >&5) 2>&5
2404  ac_status=$?
2405  echo "$as_me:2405: \$? = $ac_status" >&5
2406  (exit $ac_status); }
2407{ (eval echo "$as_me:2407: \"$ac_compiler -V </dev/null >&5\"") >&5
2408  (eval $ac_compiler -V </dev/null >&5) 2>&5
2409  ac_status=$?
2410  echo "$as_me:2410: \$? = $ac_status" >&5
2411  (exit $ac_status); }
2412
2413echo "$as_me:2413: checking whether we are using the GNU C++ compiler" >&5
2414echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
2415if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
2416  echo $ECHO_N "(cached) $ECHO_C" >&6
2417else
2418  cat >conftest.$ac_ext <<_ACEOF
2419#line 2419 "configure"
2420#include "confdefs.h"
2421
2422int
2423main ()
2424{
2425#ifndef __GNUC__
2426       choke me
2427#endif
2428
2429  ;
2430  return 0;
2431}
2432_ACEOF
2433rm -f conftest.$ac_objext
2434if { (eval echo "$as_me:2434: \"$ac_compile\"") >&5
2435  (eval $ac_compile) 2>&5
2436  ac_status=$?
2437  echo "$as_me:2437: \$? = $ac_status" >&5
2438  (exit $ac_status); } &&
2439         { ac_try='test -s conftest.$ac_objext'
2440  { (eval echo "$as_me:2440: \"$ac_try\"") >&5
2441  (eval $ac_try) 2>&5
2442  ac_status=$?
2443  echo "$as_me:2443: \$? = $ac_status" >&5
2444  (exit $ac_status); }; }; then
2445  ac_compiler_gnu=yes
2446else
2447  echo "$as_me: failed program was:" >&5
2448cat conftest.$ac_ext >&5
2449ac_compiler_gnu=no
2450fi
2451rm -f conftest.$ac_objext conftest.$ac_ext
2452ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
2453
2454fi
2455echo "$as_me:2455: result: $ac_cv_cxx_compiler_gnu" >&5
2456echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
2457GXX=`test $ac_compiler_gnu = yes && echo yes`
2458ac_test_CXXFLAGS=${CXXFLAGS+set}
2459ac_save_CXXFLAGS=$CXXFLAGS
2460CXXFLAGS="-g"
2461echo "$as_me:2461: checking whether $CXX accepts -g" >&5
2462echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
2463if test "${ac_cv_prog_cxx_g+set}" = set; then
2464  echo $ECHO_N "(cached) $ECHO_C" >&6
2465else
2466  cat >conftest.$ac_ext <<_ACEOF
2467#line 2467 "configure"
2468#include "confdefs.h"
2469
2470int
2471main ()
2472{
2473
2474  ;
2475  return 0;
2476}
2477_ACEOF
2478rm -f conftest.$ac_objext
2479if { (eval echo "$as_me:2479: \"$ac_compile\"") >&5
2480  (eval $ac_compile) 2>&5
2481  ac_status=$?
2482  echo "$as_me:2482: \$? = $ac_status" >&5
2483  (exit $ac_status); } &&
2484         { ac_try='test -s conftest.$ac_objext'
2485  { (eval echo "$as_me:2485: \"$ac_try\"") >&5
2486  (eval $ac_try) 2>&5
2487  ac_status=$?
2488  echo "$as_me:2488: \$? = $ac_status" >&5
2489  (exit $ac_status); }; }; then
2490  ac_cv_prog_cxx_g=yes
2491else
2492  echo "$as_me: failed program was:" >&5
2493cat conftest.$ac_ext >&5
2494ac_cv_prog_cxx_g=no
2495fi
2496rm -f conftest.$ac_objext conftest.$ac_ext
2497fi
2498echo "$as_me:2498: result: $ac_cv_prog_cxx_g" >&5
2499echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
2500if test "$ac_test_CXXFLAGS" = set; then
2501  CXXFLAGS=$ac_save_CXXFLAGS
2502elif test $ac_cv_prog_cxx_g = yes; then
2503  if test "$GXX" = yes; then
2504    CXXFLAGS="-g -O2"
2505  else
2506    CXXFLAGS="-g"
2507  fi
2508else
2509  if test "$GXX" = yes; then
2510    CXXFLAGS="-O2"
2511  else
2512    CXXFLAGS=
2513  fi
2514fi
2515for ac_declaration in \
2516   ''\
2517   '#include <stdlib.h>' \
2518   'extern "C" void std::exit (int) throw (); using std::exit;' \
2519   'extern "C" void std::exit (int); using std::exit;' \
2520   'extern "C" void exit (int) throw ();' \
2521   'extern "C" void exit (int);' \
2522   'void exit (int);'
2523do
2524  cat >conftest.$ac_ext <<_ACEOF
2525#line 2525 "configure"
2526#include "confdefs.h"
2527#include <stdlib.h>
2528$ac_declaration
2529int
2530main ()
2531{
2532exit (42);
2533  ;
2534  return 0;
2535}
2536_ACEOF
2537rm -f conftest.$ac_objext
2538if { (eval echo "$as_me:2538: \"$ac_compile\"") >&5
2539  (eval $ac_compile) 2>&5
2540  ac_status=$?
2541  echo "$as_me:2541: \$? = $ac_status" >&5
2542  (exit $ac_status); } &&
2543         { ac_try='test -s conftest.$ac_objext'
2544  { (eval echo "$as_me:2544: \"$ac_try\"") >&5
2545  (eval $ac_try) 2>&5
2546  ac_status=$?
2547  echo "$as_me:2547: \$? = $ac_status" >&5
2548  (exit $ac_status); }; }; then
2549  :
2550else
2551  echo "$as_me: failed program was:" >&5
2552cat conftest.$ac_ext >&5
2553continue
2554fi
2555rm -f conftest.$ac_objext conftest.$ac_ext
2556  cat >conftest.$ac_ext <<_ACEOF
2557#line 2557 "configure"
2558#include "confdefs.h"
2559$ac_declaration
2560int
2561main ()
2562{
2563exit (42);
2564  ;
2565  return 0;
2566}
2567_ACEOF
2568rm -f conftest.$ac_objext
2569if { (eval echo "$as_me:2569: \"$ac_compile\"") >&5
2570  (eval $ac_compile) 2>&5
2571  ac_status=$?
2572  echo "$as_me:2572: \$? = $ac_status" >&5
2573  (exit $ac_status); } &&
2574         { ac_try='test -s conftest.$ac_objext'
2575  { (eval echo "$as_me:2575: \"$ac_try\"") >&5
2576  (eval $ac_try) 2>&5
2577  ac_status=$?
2578  echo "$as_me:2578: \$? = $ac_status" >&5
2579  (exit $ac_status); }; }; then
2580  break
2581else
2582  echo "$as_me: failed program was:" >&5
2583cat conftest.$ac_ext >&5
2584fi
2585rm -f conftest.$ac_objext conftest.$ac_ext
2586done
2587rm -f conftest*
2588if test -n "$ac_declaration"; then
2589  echo '#ifdef __cplusplus' >>confdefs.h
2590  echo $ac_declaration      >>confdefs.h
2591  echo '#endif'             >>confdefs.h
2592fi
2593
2594ac_ext=c
2595ac_cpp='$CPP $CPPFLAGS'
2596ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2597ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2598ac_compiler_gnu=$ac_cv_c_compiler_gnu
2599
2600# Check whether --enable-shared or --disable-shared was given.
2601if test "${enable_shared+set}" = set; then
2602  enableval="$enable_shared"
2603  p=${PACKAGE-default}
2604case $enableval in
2605yes) enable_shared=yes ;;
2606no) enable_shared=no ;;
2607*)
2608  enable_shared=no
2609  # Look at the argument we got.  We use all the common list separators.
2610  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2611  for pkg in $enableval; do
2612    if test "X$pkg" = "X$p"; then
2613      enable_shared=yes
2614    fi
2615  done
2616  IFS="$ac_save_ifs"
2617  ;;
2618esac
2619else
2620  enable_shared=yes
2621fi;
2622# Check whether --enable-static or --disable-static was given.
2623if test "${enable_static+set}" = set; then
2624  enableval="$enable_static"
2625  p=${PACKAGE-default}
2626case $enableval in
2627yes) enable_static=yes ;;
2628no) enable_static=no ;;
2629*)
2630  enable_static=no
2631  # Look at the argument we got.  We use all the common list separators.
2632  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2633  for pkg in $enableval; do
2634    if test "X$pkg" = "X$p"; then
2635      enable_static=yes
2636    fi
2637  done
2638  IFS="$ac_save_ifs"
2639  ;;
2640esac
2641else
2642  enable_static=yes
2643fi;
2644# Check whether --enable-fast-install or --disable-fast-install was given.
2645if test "${enable_fast_install+set}" = set; then
2646  enableval="$enable_fast_install"
2647  p=${PACKAGE-default}
2648case $enableval in
2649yes) enable_fast_install=yes ;;
2650no) enable_fast_install=no ;;
2651*)
2652  enable_fast_install=no
2653  # Look at the argument we got.  We use all the common list separators.
2654  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
2655  for pkg in $enableval; do
2656    if test "X$pkg" = "X$p"; then
2657      enable_fast_install=yes
2658    fi
2659  done
2660  IFS="$ac_save_ifs"
2661  ;;
2662esac
2663else
2664  enable_fast_install=yes
2665fi;
2666# Make sure we can run config.sub.
2667$ac_config_sub sun4 >/dev/null 2>&1 ||
2668  { { echo "$as_me:2668: error: cannot run $ac_config_sub" >&5
2669echo "$as_me: error: cannot run $ac_config_sub" >&2;}
2670   { (exit 1); exit 1; }; }
2671
2672echo "$as_me:2672: checking build system type" >&5
2673echo $ECHO_N "checking build system type... $ECHO_C" >&6
2674if test "${ac_cv_build+set}" = set; then
2675  echo $ECHO_N "(cached) $ECHO_C" >&6
2676else
2677  ac_cv_build_alias=$build_alias
2678test -z "$ac_cv_build_alias" &&
2679  ac_cv_build_alias=`$ac_config_guess`
2680test -z "$ac_cv_build_alias" &&
2681  { { echo "$as_me:2681: error: cannot guess build type; you must specify one" >&5
2682echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2683   { (exit 1); exit 1; }; }
2684ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
2685  { { echo "$as_me:2685: error: $ac_config_sub $ac_cv_build_alias failed." >&5
2686echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
2687   { (exit 1); exit 1; }; }
2688
2689fi
2690echo "$as_me:2690: result: $ac_cv_build" >&5
2691echo "${ECHO_T}$ac_cv_build" >&6
2692build=$ac_cv_build
2693build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
2694build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
2695build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
2696
2697echo "$as_me:2697: checking host system type" >&5
2698echo $ECHO_N "checking host system type... $ECHO_C" >&6
2699if test "${ac_cv_host+set}" = set; then
2700  echo $ECHO_N "(cached) $ECHO_C" >&6
2701else
2702  ac_cv_host_alias=$host_alias
2703test -z "$ac_cv_host_alias" &&
2704  ac_cv_host_alias=$ac_cv_build_alias
2705ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
2706  { { echo "$as_me:2706: error: $ac_config_sub $ac_cv_host_alias failed" >&5
2707echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
2708   { (exit 1); exit 1; }; }
2709
2710fi
2711echo "$as_me:2711: result: $ac_cv_host" >&5
2712echo "${ECHO_T}$ac_cv_host" >&6
2713host=$ac_cv_host
2714host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
2715host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
2716host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
2717
2718# Check whether --with-gnu-ld or --without-gnu-ld was given.
2719if test "${with_gnu_ld+set}" = set; then
2720  withval="$with_gnu_ld"
2721  test "$withval" = no || with_gnu_ld=yes
2722else
2723  with_gnu_ld=no
2724fi;
2725ac_prog=ld
2726if test "$GCC" = yes; then
2727  # Check if gcc -print-prog-name=ld gives a path.
2728  echo "$as_me:2728: checking for ld used by GCC" >&5
2729echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
2730  case $host in
2731  *-*-mingw*)
2732    # gcc leaves a trailing carriage return which upsets mingw
2733    ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
2734  *)
2735    ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
2736  esac
2737  case $ac_prog in
2738    # Accept absolute paths.
2739    [\\/]* | [A-Za-z]:[\\/]*)
2740      re_direlt='/[^/][^/]*/\.\./'
2741      # Canonicalize the path of ld
2742      ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
2743      while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
2744	ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
2745      done
2746      test -z "$LD" && LD="$ac_prog"
2747      ;;
2748  "")
2749    # If it fails, then pretend we aren't using GCC.
2750    ac_prog=ld
2751    ;;
2752  *)
2753    # If it is relative, then search for the first ld in PATH.
2754    with_gnu_ld=unknown
2755    ;;
2756  esac
2757elif test "$with_gnu_ld" = yes; then
2758  echo "$as_me:2758: checking for GNU ld" >&5
2759echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
2760else
2761  echo "$as_me:2761: checking for non-GNU ld" >&5
2762echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
2763fi
2764if test "${lt_cv_path_LD+set}" = set; then
2765  echo $ECHO_N "(cached) $ECHO_C" >&6
2766else
2767  if test -z "$LD"; then
2768  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2769  for ac_dir in $PATH; do
2770    test -z "$ac_dir" && ac_dir=.
2771    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
2772      lt_cv_path_LD="$ac_dir/$ac_prog"
2773      # Check to see if the program is GNU ld.  I'd rather use --version,
2774      # but apparently some GNU ld's only accept -v.
2775      # Break only if it was the GNU/non-GNU ld that we prefer.
2776      if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
2777	test "$with_gnu_ld" != no && break
2778      else
2779	test "$with_gnu_ld" != yes && break
2780      fi
2781    fi
2782  done
2783  IFS="$ac_save_ifs"
2784else
2785  lt_cv_path_LD="$LD" # Let the user override the test with a path.
2786fi
2787fi
2788
2789LD="$lt_cv_path_LD"
2790if test -n "$LD"; then
2791  echo "$as_me:2791: result: $LD" >&5
2792echo "${ECHO_T}$LD" >&6
2793else
2794  echo "$as_me:2794: result: no" >&5
2795echo "${ECHO_T}no" >&6
2796fi
2797test -z "$LD" && { { echo "$as_me:2797: error: no acceptable ld found in \$PATH" >&5
2798echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
2799   { (exit 1); exit 1; }; }
2800echo "$as_me:2800: checking if the linker ($LD) is GNU ld" >&5
2801echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
2802if test "${lt_cv_prog_gnu_ld+set}" = set; then
2803  echo $ECHO_N "(cached) $ECHO_C" >&6
2804else
2805  # I'd rather use --version here, but apparently some GNU ld's only accept -v.
2806if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
2807  lt_cv_prog_gnu_ld=yes
2808else
2809  lt_cv_prog_gnu_ld=no
2810fi
2811fi
2812echo "$as_me:2812: result: $lt_cv_prog_gnu_ld" >&5
2813echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6
2814with_gnu_ld=$lt_cv_prog_gnu_ld
2815
2816echo "$as_me:2816: checking for $LD option to reload object files" >&5
2817echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6
2818if test "${lt_cv_ld_reload_flag+set}" = set; then
2819  echo $ECHO_N "(cached) $ECHO_C" >&6
2820else
2821  lt_cv_ld_reload_flag='-r'
2822fi
2823echo "$as_me:2823: result: $lt_cv_ld_reload_flag" >&5
2824echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6
2825reload_flag=$lt_cv_ld_reload_flag
2826test -n "$reload_flag" && reload_flag=" $reload_flag"
2827
2828echo "$as_me:2828: checking for BSD-compatible nm" >&5
2829echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6
2830if test "${lt_cv_path_NM+set}" = set; then
2831  echo $ECHO_N "(cached) $ECHO_C" >&6
2832else
2833  if test -n "$NM"; then
2834  # Let the user override the test.
2835  lt_cv_path_NM="$NM"
2836else
2837  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
2838  for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
2839    test -z "$ac_dir" && ac_dir=.
2840    tmp_nm=$ac_dir/${ac_tool_prefix}nm
2841    if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
2842      # Check to see if the nm accepts a BSD-compat flag.
2843      # Adding the `sed 1q' prevents false positives on HP-UX, which says:
2844      #   nm: unknown option "B" ignored
2845      # Tru64's nm complains that /dev/null is an invalid object file
2846      if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
2847	lt_cv_path_NM="$tmp_nm -B"
2848	break
2849      elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
2850	lt_cv_path_NM="$tmp_nm -p"
2851	break
2852      else
2853	lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
2854	continue # so that we can try to find one that supports BSD flags
2855      fi
2856    fi
2857  done
2858  IFS="$ac_save_ifs"
2859  test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
2860fi
2861fi
2862
2863NM="$lt_cv_path_NM"
2864echo "$as_me:2864: result: $NM" >&5
2865echo "${ECHO_T}$NM" >&6
2866
2867echo "$as_me:2867: checking whether ln -s works" >&5
2868echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
2869LN_S=$as_ln_s
2870if test "$LN_S" = "ln -s"; then
2871  echo "$as_me:2871: result: yes" >&5
2872echo "${ECHO_T}yes" >&6
2873else
2874  echo "$as_me:2874: result: no, using $LN_S" >&5
2875echo "${ECHO_T}no, using $LN_S" >&6
2876fi
2877
2878echo "$as_me:2878: checking how to recognise dependant libraries" >&5
2879echo $ECHO_N "checking how to recognise dependant libraries... $ECHO_C" >&6
2880if test "${lt_cv_deplibs_check_method+set}" = set; then
2881  echo $ECHO_N "(cached) $ECHO_C" >&6
2882else
2883  lt_cv_file_magic_cmd='$MAGIC_CMD'
2884lt_cv_file_magic_test_file=
2885lt_cv_deplibs_check_method='unknown'
2886# Need to set the preceding variable on all platforms that support
2887# interlibrary dependencies.
2888# 'none' -- dependencies not supported.
2889# `unknown' -- same as none, but documents that we really don't know.
2890# 'pass_all' -- all dependencies passed with no checks.
2891# 'test_compile' -- check by making test program.
2892# ['file_magic [regex]'] -- check by looking for files in library path
2893# which responds to the $file_magic_cmd with a given egrep regex.
2894# If you have `file' or equivalent on your system and you're not sure
2895# whether `pass_all' will *always* work, you probably want this one.
2896
2897case $host_os in
2898aix4* | aix5*)
2899  lt_cv_deplibs_check_method=pass_all
2900  ;;
2901
2902beos*)
2903  lt_cv_deplibs_check_method=pass_all
2904  ;;
2905
2906bsdi4*)
2907  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
2908  lt_cv_file_magic_cmd='/usr/bin/file -L'
2909  lt_cv_file_magic_test_file=/shlib/libc.so
2910  ;;
2911
2912cygwin* | mingw* | pw32*)
2913  lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
2914  lt_cv_file_magic_cmd='$OBJDUMP -f'
2915  ;;
2916
2917darwin* | rhapsody*)
2918  lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
2919  lt_cv_file_magic_cmd='/usr/bin/file -L'
2920  case "$host_os" in
2921  rhapsody* | darwin1.012)
2922    lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1`
2923    ;;
2924  *) # Darwin 1.3 on
2925    lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
2926    ;;
2927  esac
2928  ;;
2929
2930freebsd*)
2931  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2932    case $host_cpu in
2933    i*86 )
2934      # Not sure whether the presence of OpenBSD here was a mistake.
2935      # Let's accept both of them until this is cleared up.
2936      lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library'
2937      lt_cv_file_magic_cmd=/usr/bin/file
2938      lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
2939      ;;
2940    esac
2941  else
2942    lt_cv_deplibs_check_method=pass_all
2943  fi
2944  ;;
2945
2946gnu*)
2947  lt_cv_deplibs_check_method=pass_all
2948  ;;
2949
2950hpux10.20*|hpux11*)
2951  lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
2952  lt_cv_file_magic_cmd=/usr/bin/file
2953  lt_cv_file_magic_test_file=/usr/lib/libc.sl
2954  ;;
2955
2956irix5* | irix6*)
2957  case $host_os in
2958  irix5*)
2959    # this will be overridden with pass_all, but let us keep it just in case
2960    lt_cv_deplibs_check_method="file_magic ELF 32-bit MSB dynamic lib MIPS - version 1"
2961    ;;
2962  *)
2963    case $LD in
2964    *-32|*"-32 ") libmagic=32-bit;;
2965    *-n32|*"-n32 ") libmagic=N32;;
2966    *-64|*"-64 ") libmagic=64-bit;;
2967    *) libmagic=never-match;;
2968    esac
2969    # this will be overridden with pass_all, but let us keep it just in case
2970    lt_cv_deplibs_check_method="file_magic ELF ${libmagic} MSB mips-[1234] dynamic lib MIPS - version 1"
2971    ;;
2972  esac
2973  lt_cv_file_magic_test_file=`echo /lib${libsuff}/libc.so*`
2974  lt_cv_deplibs_check_method=pass_all
2975  ;;
2976
2977# This must be Linux ELF.
2978linux-gnu*)
2979  case $host_cpu in
2980  alpha* | i*86 | powerpc* | sparc* | ia64* )
2981    lt_cv_deplibs_check_method=pass_all ;;
2982  *)
2983    # glibc up to 2.1.1 does not perform some relocations on ARM
2984    lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;;
2985  esac
2986  lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
2987  ;;
2988
2989netbsd*)
2990  if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
2991    lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so\.[0-9]+\.[0-9]+$'
2992  else
2993    lt_cv_deplibs_check_method='match_pattern /lib[^/\.]+\.so$'
2994  fi
2995  ;;
2996
2997newos6*)
2998  lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
2999  lt_cv_file_magic_cmd=/usr/bin/file
3000  lt_cv_file_magic_test_file=/usr/lib/libnls.so
3001  ;;
3002
3003osf3* | osf4* | osf5*)
3004  # this will be overridden with pass_all, but let us keep it just in case
3005  lt_cv_deplibs_check_method='file_magic COFF format alpha shared library'
3006  lt_cv_file_magic_test_file=/shlib/libc.so
3007  lt_cv_deplibs_check_method=pass_all
3008  ;;
3009
3010sco3.2v5*)
3011  lt_cv_deplibs_check_method=pass_all
3012  ;;
3013
3014solaris*)
3015  lt_cv_deplibs_check_method=pass_all
3016  lt_cv_file_magic_test_file=/lib/libc.so
3017  ;;
3018
3019sysv5uw[78]* | sysv4*uw2*)
3020  lt_cv_deplibs_check_method=pass_all
3021  ;;
3022
3023sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
3024  case $host_vendor in
3025  motorola)
3026    lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
3027    lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
3028    ;;
3029  ncr)
3030    lt_cv_deplibs_check_method=pass_all
3031    ;;
3032  sequent)
3033    lt_cv_file_magic_cmd='/bin/file'
3034    lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
3035    ;;
3036  sni)
3037    lt_cv_file_magic_cmd='/bin/file'
3038    lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
3039    lt_cv_file_magic_test_file=/lib/libc.so
3040    ;;
3041  esac
3042  ;;
3043esac
3044
3045fi
3046echo "$as_me:3046: result: $lt_cv_deplibs_check_method" >&5
3047echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6
3048file_magic_cmd=$lt_cv_file_magic_cmd
3049deplibs_check_method=$lt_cv_deplibs_check_method
3050
3051# Check for command to grab the raw symbol name followed by C symbol from nm.
3052echo "$as_me:3052: checking command to parse $NM output" >&5
3053echo $ECHO_N "checking command to parse $NM output... $ECHO_C" >&6
3054if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
3055  echo $ECHO_N "(cached) $ECHO_C" >&6
3056else
3057
3058# These are sane defaults that work on at least a few old systems.
3059# [They come from Ultrix.  What could be older than Ultrix?!! ;)]
3060
3061# Character class describing NM global symbol codes.
3062symcode='[BCDEGRST]'
3063
3064# Regexp to match symbols that can be accessed directly from C.
3065sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
3066
3067# Transform the above into a raw symbol and a C symbol.
3068symxfrm='\1 \2\3 \3'
3069
3070# Transform an extracted symbol line into a proper C declaration
3071lt_cv_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
3072
3073# Define system-specific variables.
3074case $host_os in
3075aix*)
3076  symcode='[BCDT]'
3077  ;;
3078cygwin* | mingw* | pw32*)
3079  symcode='[ABCDGISTW]'
3080  ;;
3081hpux*) # Its linker distinguishes data from code symbols
3082  lt_cv_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
3083  ;;
3084irix*)
3085  symcode='[BCDEGRST]'
3086  ;;
3087solaris* | sysv5*)
3088  symcode='[BDT]'
3089  ;;
3090sysv4)
3091  symcode='[DFNSTU]'
3092  ;;
3093esac
3094
3095# Handle CRLF in mingw tool chain
3096opt_cr=
3097case $host_os in
3098mingw*)
3099  opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
3100  ;;
3101esac
3102
3103# If we're using GNU nm, then use its standard symbol codes.
3104if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
3105  symcode='[ABCDGISTW]'
3106fi
3107
3108# Try without a prefix undercore, then with it.
3109for ac_symprfx in "" "_"; do
3110
3111  # Write the raw and C identifiers.
3112lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ 	]\($symcode$symcode*\)[ 	][ 	]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
3113
3114  # Check to see that the pipe works correctly.
3115  pipe_works=no
3116  rm -f conftest*
3117  cat > conftest.$ac_ext <<EOF
3118#ifdef __cplusplus
3119extern "C" {
3120#endif
3121char nm_test_var;
3122void nm_test_func(){}
3123#ifdef __cplusplus
3124}
3125#endif
3126int main(){nm_test_var='a';nm_test_func();return(0);}
3127EOF
3128
3129  if { (eval echo "$as_me:3129: \"$ac_compile\"") >&5
3130  (eval $ac_compile) 2>&5
3131  ac_status=$?
3132  echo "$as_me:3132: \$? = $ac_status" >&5
3133  (exit $ac_status); }; then
3134    # Now try to grab the symbols.
3135    nlist=conftest.nm
3136    if { (eval echo "$as_me:3136: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
3137  (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
3138  ac_status=$?
3139  echo "$as_me:3139: \$? = $ac_status" >&5
3140  (exit $ac_status); } && test -s "$nlist"; then
3141      # Try sorting and uniquifying the output.
3142      if sort "$nlist" | uniq > "$nlist"T; then
3143	mv -f "$nlist"T "$nlist"
3144      else
3145	rm -f "$nlist"T
3146      fi
3147
3148      # Make sure that we snagged all the symbols we need.
3149      if egrep ' nm_test_var$' "$nlist" >/dev/null; then
3150	if egrep ' nm_test_func$' "$nlist" >/dev/null; then
3151	  cat <<EOF > conftest.$ac_ext
3152#ifdef __cplusplus
3153extern "C" {
3154#endif
3155
3156EOF
3157	  # Now generate the symbol file.
3158	  eval "$lt_cv_global_symbol_to_cdecl"' < "$nlist" >> conftest.$ac_ext'
3159
3160	  cat <<EOF >> conftest.$ac_ext
3161#if defined (__STDC__) && __STDC__
3162# define lt_ptr_t void *
3163#else
3164# define lt_ptr_t char *
3165# define const
3166#endif
3167
3168/* The mapping between symbol names and symbols. */
3169const struct {
3170  const char *name;
3171  lt_ptr_t address;
3172}
3173lt_preloaded_symbols[] =
3174{
3175EOF
3176	  sed "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" >> conftest.$ac_ext
3177	  cat <<\EOF >> conftest.$ac_ext
3178  {0, (lt_ptr_t) 0}
3179};
3180
3181#ifdef __cplusplus
3182}
3183#endif
3184EOF
3185	  # Now try linking the two files.
3186	  mv conftest.$ac_objext conftstm.$ac_objext
3187	  save_LIBS="$LIBS"
3188	  save_CFLAGS="$CFLAGS"
3189	  LIBS="conftstm.$ac_objext"
3190	  CFLAGS="$CFLAGS$no_builtin_flag"
3191	  if { (eval echo "$as_me:3191: \"$ac_link\"") >&5
3192  (eval $ac_link) 2>&5
3193  ac_status=$?
3194  echo "$as_me:3194: \$? = $ac_status" >&5
3195  (exit $ac_status); } && test -s conftest; then
3196	    pipe_works=yes
3197	  fi
3198	  LIBS="$save_LIBS"
3199	  CFLAGS="$save_CFLAGS"
3200	else
3201	  echo "cannot find nm_test_func in $nlist" >&5
3202	fi
3203      else
3204	echo "cannot find nm_test_var in $nlist" >&5
3205      fi
3206    else
3207      echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
3208    fi
3209  else
3210    echo "$progname: failed program was:" >&5
3211    cat conftest.$ac_ext >&5
3212  fi
3213  rm -f conftest* conftst*
3214
3215  # Do not use the global_symbol_pipe unless it works.
3216  if test "$pipe_works" = yes; then
3217    break
3218  else
3219    lt_cv_sys_global_symbol_pipe=
3220  fi
3221done
3222
3223fi
3224
3225global_symbol_pipe="$lt_cv_sys_global_symbol_pipe"
3226if test -z "$lt_cv_sys_global_symbol_pipe"; then
3227  global_symbol_to_cdecl=
3228else
3229  global_symbol_to_cdecl="$lt_cv_global_symbol_to_cdecl"
3230fi
3231if test -z "$global_symbol_pipe$global_symbol_to_cdecl"; then
3232  echo "$as_me:3232: result: failed" >&5
3233echo "${ECHO_T}failed" >&6
3234else
3235  echo "$as_me:3235: result: ok" >&5
3236echo "${ECHO_T}ok" >&6
3237fi
3238
3239for ac_header in dlfcn.h
3240do
3241as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3242echo "$as_me:3242: checking for $ac_header" >&5
3243echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3244if eval "test \"\${$as_ac_Header+set}\" = set"; then
3245  echo $ECHO_N "(cached) $ECHO_C" >&6
3246else
3247  cat >conftest.$ac_ext <<_ACEOF
3248#line 3248 "configure"
3249#include "confdefs.h"
3250#include <$ac_header>
3251_ACEOF
3252if { (eval echo "$as_me:3252: \"$ac_cpp conftest.$ac_ext\"") >&5
3253  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3254  ac_status=$?
3255  egrep -v '^ *\+' conftest.er1 >conftest.err
3256  rm -f conftest.er1
3257  cat conftest.err >&5
3258  echo "$as_me:3258: \$? = $ac_status" >&5
3259  (exit $ac_status); } >/dev/null; then
3260  if test -s conftest.err; then
3261    ac_cpp_err=$ac_c_preproc_warn_flag
3262  else
3263    ac_cpp_err=
3264  fi
3265else
3266  ac_cpp_err=yes
3267fi
3268if test -z "$ac_cpp_err"; then
3269  eval "$as_ac_Header=yes"
3270else
3271  echo "$as_me: failed program was:" >&5
3272  cat conftest.$ac_ext >&5
3273  eval "$as_ac_Header=no"
3274fi
3275rm -f conftest.err conftest.$ac_ext
3276fi
3277echo "$as_me:3277: result: `eval echo '${'$as_ac_Header'}'`" >&5
3278echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3279if test `eval echo '${'$as_ac_Header'}'` = yes; then
3280  cat >>confdefs.h <<EOF
3281#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3282EOF
3283
3284fi
3285done
3286
3287# Only perform the check for file, if the check method requires it
3288case $deplibs_check_method in
3289file_magic*)
3290  if test "$file_magic_cmd" = '$MAGIC_CMD'; then
3291    echo "$as_me:3291: checking for ${ac_tool_prefix}file" >&5
3292echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6
3293if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
3294  echo $ECHO_N "(cached) $ECHO_C" >&6
3295else
3296  case $MAGIC_CMD in
3297  /*)
3298  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3299  ;;
3300  ?:/*)
3301  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3302  ;;
3303  *)
3304  ac_save_MAGIC_CMD="$MAGIC_CMD"
3305  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3306  ac_dummy="/usr/bin:$PATH"
3307  for ac_dir in $ac_dummy; do
3308    test -z "$ac_dir" && ac_dir=.
3309    if test -f $ac_dir/${ac_tool_prefix}file; then
3310      lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
3311      if test -n "$file_magic_test_file"; then
3312	case $deplibs_check_method in
3313	"file_magic "*)
3314	  file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3315	  MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3316	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3317	    egrep "$file_magic_regex" > /dev/null; then
3318	    :
3319	  else
3320	    cat <<EOF 1>&2
3321
3322*** Warning: the command libtool uses to detect shared libraries,
3323*** $file_magic_cmd, produces output that libtool cannot recognize.
3324*** The result is that libtool may fail to recognize shared libraries
3325*** as such.  This will affect the creation of libtool libraries that
3326*** depend on shared libraries, but programs linked with such libtool
3327*** libraries will work regardless of this problem.  Nevertheless, you
3328*** may want to report the problem to your system manager and/or to
3329*** bug-libtool@gnu.org
3330
3331EOF
3332	  fi ;;
3333	esac
3334      fi
3335      break
3336    fi
3337  done
3338  IFS="$ac_save_ifs"
3339  MAGIC_CMD="$ac_save_MAGIC_CMD"
3340  ;;
3341esac
3342fi
3343
3344MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3345if test -n "$MAGIC_CMD"; then
3346  echo "$as_me:3346: result: $MAGIC_CMD" >&5
3347echo "${ECHO_T}$MAGIC_CMD" >&6
3348else
3349  echo "$as_me:3349: result: no" >&5
3350echo "${ECHO_T}no" >&6
3351fi
3352
3353if test -z "$lt_cv_path_MAGIC_CMD"; then
3354  if test -n "$ac_tool_prefix"; then
3355    echo "$as_me:3355: checking for file" >&5
3356echo $ECHO_N "checking for file... $ECHO_C" >&6
3357if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
3358  echo $ECHO_N "(cached) $ECHO_C" >&6
3359else
3360  case $MAGIC_CMD in
3361  /*)
3362  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3363  ;;
3364  ?:/*)
3365  lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
3366  ;;
3367  *)
3368  ac_save_MAGIC_CMD="$MAGIC_CMD"
3369  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
3370  ac_dummy="/usr/bin:$PATH"
3371  for ac_dir in $ac_dummy; do
3372    test -z "$ac_dir" && ac_dir=.
3373    if test -f $ac_dir/file; then
3374      lt_cv_path_MAGIC_CMD="$ac_dir/file"
3375      if test -n "$file_magic_test_file"; then
3376	case $deplibs_check_method in
3377	"file_magic "*)
3378	  file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
3379	  MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3380	  if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
3381	    egrep "$file_magic_regex" > /dev/null; then
3382	    :
3383	  else
3384	    cat <<EOF 1>&2
3385
3386*** Warning: the command libtool uses to detect shared libraries,
3387*** $file_magic_cmd, produces output that libtool cannot recognize.
3388*** The result is that libtool may fail to recognize shared libraries
3389*** as such.  This will affect the creation of libtool libraries that
3390*** depend on shared libraries, but programs linked with such libtool
3391*** libraries will work regardless of this problem.  Nevertheless, you
3392*** may want to report the problem to your system manager and/or to
3393*** bug-libtool@gnu.org
3394
3395EOF
3396	  fi ;;
3397	esac
3398      fi
3399      break
3400    fi
3401  done
3402  IFS="$ac_save_ifs"
3403  MAGIC_CMD="$ac_save_MAGIC_CMD"
3404  ;;
3405esac
3406fi
3407
3408MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3409if test -n "$MAGIC_CMD"; then
3410  echo "$as_me:3410: result: $MAGIC_CMD" >&5
3411echo "${ECHO_T}$MAGIC_CMD" >&6
3412else
3413  echo "$as_me:3413: result: no" >&5
3414echo "${ECHO_T}no" >&6
3415fi
3416
3417  else
3418    MAGIC_CMD=:
3419  fi
3420fi
3421
3422  fi
3423  ;;
3424esac
3425
3426if test -n "$ac_tool_prefix"; then
3427  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3428set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3429echo "$as_me:3429: checking for $ac_word" >&5
3430echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3431if test "${ac_cv_prog_RANLIB+set}" = set; then
3432  echo $ECHO_N "(cached) $ECHO_C" >&6
3433else
3434  if test -n "$RANLIB"; then
3435  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3436else
3437  ac_save_IFS=$IFS; IFS=$ac_path_separator
3438ac_dummy="$PATH"
3439for ac_dir in $ac_dummy; do
3440  IFS=$ac_save_IFS
3441  test -z "$ac_dir" && ac_dir=.
3442  $as_executable_p "$ac_dir/$ac_word" || continue
3443ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3444echo "$as_me:3444: found $ac_dir/$ac_word" >&5
3445break
3446done
3447
3448fi
3449fi
3450RANLIB=$ac_cv_prog_RANLIB
3451if test -n "$RANLIB"; then
3452  echo "$as_me:3452: result: $RANLIB" >&5
3453echo "${ECHO_T}$RANLIB" >&6
3454else
3455  echo "$as_me:3455: result: no" >&5
3456echo "${ECHO_T}no" >&6
3457fi
3458
3459fi
3460if test -z "$ac_cv_prog_RANLIB"; then
3461  ac_ct_RANLIB=$RANLIB
3462  # Extract the first word of "ranlib", so it can be a program name with args.
3463set dummy ranlib; ac_word=$2
3464echo "$as_me:3464: checking for $ac_word" >&5
3465echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3466if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3467  echo $ECHO_N "(cached) $ECHO_C" >&6
3468else
3469  if test -n "$ac_ct_RANLIB"; then
3470  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3471else
3472  ac_save_IFS=$IFS; IFS=$ac_path_separator
3473ac_dummy="$PATH"
3474for ac_dir in $ac_dummy; do
3475  IFS=$ac_save_IFS
3476  test -z "$ac_dir" && ac_dir=.
3477  $as_executable_p "$ac_dir/$ac_word" || continue
3478ac_cv_prog_ac_ct_RANLIB="ranlib"
3479echo "$as_me:3479: found $ac_dir/$ac_word" >&5
3480break
3481done
3482
3483  test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3484fi
3485fi
3486ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3487if test -n "$ac_ct_RANLIB"; then
3488  echo "$as_me:3488: result: $ac_ct_RANLIB" >&5
3489echo "${ECHO_T}$ac_ct_RANLIB" >&6
3490else
3491  echo "$as_me:3491: result: no" >&5
3492echo "${ECHO_T}no" >&6
3493fi
3494
3495  RANLIB=$ac_ct_RANLIB
3496else
3497  RANLIB="$ac_cv_prog_RANLIB"
3498fi
3499
3500if test -n "$ac_tool_prefix"; then
3501  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3502set dummy ${ac_tool_prefix}strip; ac_word=$2
3503echo "$as_me:3503: checking for $ac_word" >&5
3504echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3505if test "${ac_cv_prog_STRIP+set}" = set; then
3506  echo $ECHO_N "(cached) $ECHO_C" >&6
3507else
3508  if test -n "$STRIP"; then
3509  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3510else
3511  ac_save_IFS=$IFS; IFS=$ac_path_separator
3512ac_dummy="$PATH"
3513for ac_dir in $ac_dummy; do
3514  IFS=$ac_save_IFS
3515  test -z "$ac_dir" && ac_dir=.
3516  $as_executable_p "$ac_dir/$ac_word" || continue
3517ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3518echo "$as_me:3518: found $ac_dir/$ac_word" >&5
3519break
3520done
3521
3522fi
3523fi
3524STRIP=$ac_cv_prog_STRIP
3525if test -n "$STRIP"; then
3526  echo "$as_me:3526: result: $STRIP" >&5
3527echo "${ECHO_T}$STRIP" >&6
3528else
3529  echo "$as_me:3529: result: no" >&5
3530echo "${ECHO_T}no" >&6
3531fi
3532
3533fi
3534if test -z "$ac_cv_prog_STRIP"; then
3535  ac_ct_STRIP=$STRIP
3536  # Extract the first word of "strip", so it can be a program name with args.
3537set dummy strip; ac_word=$2
3538echo "$as_me:3538: checking for $ac_word" >&5
3539echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3540if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
3541  echo $ECHO_N "(cached) $ECHO_C" >&6
3542else
3543  if test -n "$ac_ct_STRIP"; then
3544  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3545else
3546  ac_save_IFS=$IFS; IFS=$ac_path_separator
3547ac_dummy="$PATH"
3548for ac_dir in $ac_dummy; do
3549  IFS=$ac_save_IFS
3550  test -z "$ac_dir" && ac_dir=.
3551  $as_executable_p "$ac_dir/$ac_word" || continue
3552ac_cv_prog_ac_ct_STRIP="strip"
3553echo "$as_me:3553: found $ac_dir/$ac_word" >&5
3554break
3555done
3556
3557  test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
3558fi
3559fi
3560ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3561if test -n "$ac_ct_STRIP"; then
3562  echo "$as_me:3562: result: $ac_ct_STRIP" >&5
3563echo "${ECHO_T}$ac_ct_STRIP" >&6
3564else
3565  echo "$as_me:3565: result: no" >&5
3566echo "${ECHO_T}no" >&6
3567fi
3568
3569  STRIP=$ac_ct_STRIP
3570else
3571  STRIP="$ac_cv_prog_STRIP"
3572fi
3573
3574enable_dlopen=no
3575enable_win32_dll=no
3576
3577# Check whether --enable-libtool-lock or --disable-libtool-lock was given.
3578if test "${enable_libtool_lock+set}" = set; then
3579  enableval="$enable_libtool_lock"
3580
3581fi;
3582test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
3583
3584# Some flags need to be propagated to the compiler or linker for good
3585# libtool support.
3586case $host in
3587*-*-irix6*)
3588  # Find out which ABI we are using.
3589  echo '#line 3589 "configure"' > conftest.$ac_ext
3590  if { (eval echo "$as_me:3590: \"$ac_compile\"") >&5
3591  (eval $ac_compile) 2>&5
3592  ac_status=$?
3593  echo "$as_me:3593: \$? = $ac_status" >&5
3594  (exit $ac_status); }; then
3595    case `/usr/bin/file conftest.$ac_objext` in
3596    *32-bit*)
3597      LD="${LD-ld} -32"
3598      ;;
3599    *N32*)
3600      LD="${LD-ld} -n32"
3601      ;;
3602    *64-bit*)
3603      LD="${LD-ld} -64"
3604      ;;
3605    esac
3606  fi
3607  rm -rf conftest*
3608  ;;
3609
3610*-*-sco3.2v5*)
3611  # On SCO OpenServer 5, we need -belf to get full-featured binaries.
3612  SAVE_CFLAGS="$CFLAGS"
3613  CFLAGS="$CFLAGS -belf"
3614  echo "$as_me:3614: checking whether the C compiler needs -belf" >&5
3615echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6
3616if test "${lt_cv_cc_needs_belf+set}" = set; then
3617  echo $ECHO_N "(cached) $ECHO_C" >&6
3618else
3619
3620     ac_ext=c
3621ac_cpp='$CPP $CPPFLAGS'
3622ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3623ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3624ac_compiler_gnu=$ac_cv_c_compiler_gnu
3625
3626     cat >conftest.$ac_ext <<_ACEOF
3627#line 3627 "configure"
3628#include "confdefs.h"
3629
3630int
3631main ()
3632{
3633
3634  ;
3635  return 0;
3636}
3637_ACEOF
3638rm -f conftest.$ac_objext conftest$ac_exeext
3639if { (eval echo "$as_me:3639: \"$ac_link\"") >&5
3640  (eval $ac_link) 2>&5
3641  ac_status=$?
3642  echo "$as_me:3642: \$? = $ac_status" >&5
3643  (exit $ac_status); } &&
3644         { ac_try='test -s conftest$ac_exeext'
3645  { (eval echo "$as_me:3645: \"$ac_try\"") >&5
3646  (eval $ac_try) 2>&5
3647  ac_status=$?
3648  echo "$as_me:3648: \$? = $ac_status" >&5
3649  (exit $ac_status); }; }; then
3650  lt_cv_cc_needs_belf=yes
3651else
3652  echo "$as_me: failed program was:" >&5
3653cat conftest.$ac_ext >&5
3654lt_cv_cc_needs_belf=no
3655fi
3656rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3657     ac_ext=c
3658ac_cpp='$CPP $CPPFLAGS'
3659ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3660ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3661ac_compiler_gnu=$ac_cv_c_compiler_gnu
3662
3663fi
3664echo "$as_me:3664: result: $lt_cv_cc_needs_belf" >&5
3665echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6
3666  if test x"$lt_cv_cc_needs_belf" != x"yes"; then
3667    # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
3668    CFLAGS="$SAVE_CFLAGS"
3669  fi
3670  ;;
3671
3672esac
3673
3674# Sed substitution that helps us do robust quoting.  It backslashifies
3675# metacharacters that are still active within double-quoted strings.
3676Xsed='sed -e s/^X//'
3677sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
3678
3679# Same as above, but do not quote variable references.
3680double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
3681
3682# Sed substitution to delay expansion of an escaped shell variable in a
3683# double_quote_subst'ed string.
3684delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
3685
3686# Constants:
3687rm="rm -f"
3688
3689# Global variables:
3690default_ofile=libtool
3691can_build_shared=yes
3692
3693# All known linkers require a `.a' archive for static linking (except M$VC,
3694# which needs '.lib').
3695libext=a
3696ltmain="$ac_aux_dir/ltmain.sh"
3697ofile="$default_ofile"
3698with_gnu_ld="$lt_cv_prog_gnu_ld"
3699need_locks="$enable_libtool_lock"
3700
3701old_CC="$CC"
3702old_CFLAGS="$CFLAGS"
3703
3704# Set sane defaults for various variables
3705test -z "$AR" && AR=ar
3706test -z "$AR_FLAGS" && AR_FLAGS=cru
3707test -z "$AS" && AS=as
3708test -z "$CC" && CC=cc
3709test -z "$DLLTOOL" && DLLTOOL=dlltool
3710test -z "$LD" && LD=ld
3711test -z "$LN_S" && LN_S="ln -s"
3712test -z "$MAGIC_CMD" && MAGIC_CMD=file
3713test -z "$NM" && NM=nm
3714test -z "$OBJDUMP" && OBJDUMP=objdump
3715test -z "$RANLIB" && RANLIB=:
3716test -z "$STRIP" && STRIP=:
3717test -z "$ac_objext" && ac_objext=o
3718
3719if test x"$host" != x"$build"; then
3720  ac_tool_prefix=${host_alias}-
3721else
3722  ac_tool_prefix=
3723fi
3724
3725# Transform linux* to *-*-linux-gnu*, to support old configure scripts.
3726case $host_os in
3727linux-gnu*) ;;
3728linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
3729esac
3730
3731case $host_os in
3732aix3*)
3733  # AIX sometimes has problems with the GCC collect2 program.  For some
3734  # reason, if we set the COLLECT_NAMES environment variable, the problems
3735  # vanish in a puff of smoke.
3736  if test "X${COLLECT_NAMES+set}" != Xset; then
3737    COLLECT_NAMES=
3738    export COLLECT_NAMES
3739  fi
3740  ;;
3741esac
3742
3743# Determine commands to create old-style static archives.
3744old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
3745old_postinstall_cmds='chmod 644 $oldlib'
3746old_postuninstall_cmds=
3747
3748if test -n "$RANLIB"; then
3749  old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
3750  old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
3751fi
3752
3753# Allow CC to be a program name with arguments.
3754set dummy $CC
3755compiler="$2"
3756
3757echo "$as_me:3757: checking for objdir" >&5
3758echo $ECHO_N "checking for objdir... $ECHO_C" >&6
3759rm -f .libs 2>/dev/null
3760mkdir .libs 2>/dev/null
3761if test -d .libs; then
3762  objdir=.libs
3763else
3764  # MS-DOS does not allow filenames that begin with a dot.
3765  objdir=_libs
3766fi
3767rmdir .libs 2>/dev/null
3768echo "$as_me:3768: result: $objdir" >&5
3769echo "${ECHO_T}$objdir" >&6
3770
3771# Check whether --with-pic or --without-pic was given.
3772if test "${with_pic+set}" = set; then
3773  withval="$with_pic"
3774  pic_mode="$withval"
3775else
3776  pic_mode=default
3777fi;
3778test -z "$pic_mode" && pic_mode=default
3779
3780# We assume here that the value for lt_cv_prog_cc_pic will not be cached
3781# in isolation, and that seeing it set (from the cache) indicates that
3782# the associated values are set (in the cache) correctly too.
3783echo "$as_me:3783: checking for $compiler option to produce PIC" >&5
3784echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6
3785if test "${lt_cv_prog_cc_pic+set}" = set; then
3786  echo $ECHO_N "(cached) $ECHO_C" >&6
3787else
3788   lt_cv_prog_cc_pic=
3789  lt_cv_prog_cc_shlib=
3790  lt_cv_prog_cc_wl=
3791  lt_cv_prog_cc_static=
3792  lt_cv_prog_cc_no_builtin=
3793  lt_cv_prog_cc_can_build_shared=$can_build_shared
3794
3795  if test "$GCC" = yes; then
3796    lt_cv_prog_cc_wl='-Wl,'
3797    lt_cv_prog_cc_static='-static'
3798
3799    case $host_os in
3800    aix*)
3801      # Below there is a dirty hack to force normal static linking with -ldl
3802      # The problem is because libdl dynamically linked with both libc and
3803      # libC (AIX C++ library), which obviously doesn't included in libraries
3804      # list by gcc. This cause undefined symbols with -static flags.
3805      # This hack allows C programs to be linked with "-static -ldl", but
3806      # we not sure about C++ programs.
3807      lt_cv_prog_cc_static="$lt_cv_prog_cc_static ${lt_cv_prog_cc_wl}-lC"
3808      ;;
3809    amigaos*)
3810      # FIXME: we need at least 68020 code to build shared libraries, but
3811      # adding the `-m68020' flag to GCC prevents building anything better,
3812      # like `-m68040'.
3813      lt_cv_prog_cc_pic='-m68020 -resident32 -malways-restore-a4'
3814      ;;
3815    beos* | irix5* | irix6* | osf3* | osf4* | osf5*)
3816      # PIC is the default for these OSes.
3817      ;;
3818    darwin* | rhapsody*)
3819      # PIC is the default on this platform
3820      # Common symbols not allowed in MH_DYLIB files
3821      lt_cv_prog_cc_pic='-fno-common'
3822      ;;
3823    cygwin* | mingw* | pw32* | os2*)
3824      # This hack is so that the source file can tell whether it is being
3825      # built for inclusion in a dll (and should export symbols for example).
3826      lt_cv_prog_cc_pic='-DDLL_EXPORT'
3827      ;;
3828    sysv4*MP*)
3829      if test -d /usr/nec; then
3830	 lt_cv_prog_cc_pic=-Kconform_pic
3831      fi
3832      ;;
3833    *)
3834      lt_cv_prog_cc_pic='-fPIC'
3835      ;;
3836    esac
3837  else
3838    # PORTME Check for PIC flags for the system compiler.
3839    case $host_os in
3840    aix3* | aix4* | aix5*)
3841      # All AIX code is PIC.
3842      if test "$host_cpu" = ia64; then
3843        # AIX 5 now supports IA64 processor
3844        lt_cv_prog_cc_static='-Bstatic'
3845        lt_cv_prog_cc_wl='-Wl,'
3846      else
3847        lt_cv_prog_cc_static='-bnso -bI:/lib/syscalls.exp'
3848      fi
3849      ;;
3850
3851    hpux9* | hpux10* | hpux11*)
3852      # Is there a better lt_cv_prog_cc_static that works with the bundled CC?
3853      lt_cv_prog_cc_wl='-Wl,'
3854      lt_cv_prog_cc_static="${lt_cv_prog_cc_wl}-a ${lt_cv_prog_cc_wl}archive"
3855      lt_cv_prog_cc_pic='+Z'
3856      ;;
3857
3858    irix5* | irix6*)
3859      lt_cv_prog_cc_wl='-Wl,'
3860      lt_cv_prog_cc_static='-non_shared'
3861      # PIC (with -KPIC) is the default.
3862      ;;
3863
3864    cygwin* | mingw* | pw32* | os2*)
3865      # This hack is so that the source file can tell whether it is being
3866      # built for inclusion in a dll (and should export symbols for example).
3867      lt_cv_prog_cc_pic='-DDLL_EXPORT'
3868      ;;
3869
3870    newsos6)
3871      lt_cv_prog_cc_pic='-KPIC'
3872      lt_cv_prog_cc_static='-Bstatic'
3873      ;;
3874
3875    osf3* | osf4* | osf5*)
3876      # All OSF/1 code is PIC.
3877      lt_cv_prog_cc_wl='-Wl,'
3878      lt_cv_prog_cc_static='-non_shared'
3879      ;;
3880
3881    sco3.2v5*)
3882      lt_cv_prog_cc_pic='-Kpic'
3883      lt_cv_prog_cc_static='-dn'
3884      lt_cv_prog_cc_shlib='-belf'
3885      ;;
3886
3887    solaris*)
3888      lt_cv_prog_cc_pic='-KPIC'
3889      lt_cv_prog_cc_static='-Bstatic'
3890      lt_cv_prog_cc_wl='-Wl,'
3891      ;;
3892
3893    sunos4*)
3894      lt_cv_prog_cc_pic='-PIC'
3895      lt_cv_prog_cc_static='-Bstatic'
3896      lt_cv_prog_cc_wl='-Qoption ld '
3897      ;;
3898
3899    sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
3900      lt_cv_prog_cc_pic='-KPIC'
3901      lt_cv_prog_cc_static='-Bstatic'
3902      if test "x$host_vendor" = xsni; then
3903        lt_cv_prog_cc_wl='-LD'
3904      else
3905        lt_cv_prog_cc_wl='-Wl,'
3906      fi
3907      ;;
3908
3909    uts4*)
3910      lt_cv_prog_cc_pic='-pic'
3911      lt_cv_prog_cc_static='-Bstatic'
3912      ;;
3913
3914    sysv4*MP*)
3915      if test -d /usr/nec ;then
3916	lt_cv_prog_cc_pic='-Kconform_pic'
3917	lt_cv_prog_cc_static='-Bstatic'
3918      fi
3919      ;;
3920
3921    *)
3922      lt_cv_prog_cc_can_build_shared=no
3923      ;;
3924    esac
3925  fi
3926
3927fi
3928
3929if test -z "$lt_cv_prog_cc_pic"; then
3930  echo "$as_me:3930: result: none" >&5
3931echo "${ECHO_T}none" >&6
3932else
3933  echo "$as_me:3933: result: $lt_cv_prog_cc_pic" >&5
3934echo "${ECHO_T}$lt_cv_prog_cc_pic" >&6
3935
3936  # Check to make sure the pic_flag actually works.
3937  echo "$as_me:3937: checking if $compiler PIC flag $lt_cv_prog_cc_pic works" >&5
3938echo $ECHO_N "checking if $compiler PIC flag $lt_cv_prog_cc_pic works... $ECHO_C" >&6
3939  if test "${lt_cv_prog_cc_pic_works+set}" = set; then
3940  echo $ECHO_N "(cached) $ECHO_C" >&6
3941else
3942      save_CFLAGS="$CFLAGS"
3943    CFLAGS="$CFLAGS $lt_cv_prog_cc_pic -DPIC"
3944    cat >conftest.$ac_ext <<_ACEOF
3945#line 3945 "configure"
3946#include "confdefs.h"
3947
3948int
3949main ()
3950{
3951
3952  ;
3953  return 0;
3954}
3955_ACEOF
3956rm -f conftest.$ac_objext
3957if { (eval echo "$as_me:3957: \"$ac_compile\"") >&5
3958  (eval $ac_compile) 2>&5
3959  ac_status=$?
3960  echo "$as_me:3960: \$? = $ac_status" >&5
3961  (exit $ac_status); } &&
3962         { ac_try='test -s conftest.$ac_objext'
3963  { (eval echo "$as_me:3963: \"$ac_try\"") >&5
3964  (eval $ac_try) 2>&5
3965  ac_status=$?
3966  echo "$as_me:3966: \$? = $ac_status" >&5
3967  (exit $ac_status); }; }; then
3968        case $host_os in
3969      hpux9* | hpux10* | hpux11*)
3970	# On HP-UX, both CC and GCC only warn that PIC is supported... then
3971	# they create non-PIC objects.  So, if there were any warnings, we
3972	# assume that PIC is not supported.
3973	if test -s conftest.err; then
3974	  lt_cv_prog_cc_pic_works=no
3975	else
3976	  lt_cv_prog_cc_pic_works=yes
3977	fi
3978	;;
3979      *)
3980	lt_cv_prog_cc_pic_works=yes
3981	;;
3982      esac
3983
3984else
3985  echo "$as_me: failed program was:" >&5
3986cat conftest.$ac_ext >&5
3987      lt_cv_prog_cc_pic_works=no
3988
3989fi
3990rm -f conftest.$ac_objext conftest.$ac_ext
3991    CFLAGS="$save_CFLAGS"
3992
3993fi
3994
3995  if test "X$lt_cv_prog_cc_pic_works" = Xno; then
3996    lt_cv_prog_cc_pic=
3997    lt_cv_prog_cc_can_build_shared=no
3998  else
3999    lt_cv_prog_cc_pic=" $lt_cv_prog_cc_pic"
4000  fi
4001
4002  echo "$as_me:4002: result: $lt_cv_prog_cc_pic_works" >&5
4003echo "${ECHO_T}$lt_cv_prog_cc_pic_works" >&6
4004fi
4005
4006# Check for any special shared library compilation flags.
4007if test -n "$lt_cv_prog_cc_shlib"; then
4008  { echo "$as_me:4008: WARNING: \`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries" >&5
4009echo "$as_me: WARNING: \`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries" >&2;}
4010  if echo "$old_CC $old_CFLAGS " | egrep -e "[ 	]$lt_cv_prog_cc_shlib[ 	]" >/dev/null; then :
4011  else
4012   { echo "$as_me:4012: WARNING: add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5
4013echo "$as_me: WARNING: add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;}
4014    lt_cv_prog_cc_can_build_shared=no
4015  fi
4016fi
4017
4018echo "$as_me:4018: checking if $compiler static flag $lt_cv_prog_cc_static works" >&5
4019echo $ECHO_N "checking if $compiler static flag $lt_cv_prog_cc_static works... $ECHO_C" >&6
4020if test "${lt_cv_prog_cc_static_works+set}" = set; then
4021  echo $ECHO_N "(cached) $ECHO_C" >&6
4022else
4023    lt_cv_prog_cc_static_works=no
4024  save_LDFLAGS="$LDFLAGS"
4025  LDFLAGS="$LDFLAGS $lt_cv_prog_cc_static"
4026  cat >conftest.$ac_ext <<_ACEOF
4027#line 4027 "configure"
4028#include "confdefs.h"
4029
4030int
4031main ()
4032{
4033
4034  ;
4035  return 0;
4036}
4037_ACEOF
4038rm -f conftest.$ac_objext conftest$ac_exeext
4039if { (eval echo "$as_me:4039: \"$ac_link\"") >&5
4040  (eval $ac_link) 2>&5
4041  ac_status=$?
4042  echo "$as_me:4042: \$? = $ac_status" >&5
4043  (exit $ac_status); } &&
4044         { ac_try='test -s conftest$ac_exeext'
4045  { (eval echo "$as_me:4045: \"$ac_try\"") >&5
4046  (eval $ac_try) 2>&5
4047  ac_status=$?
4048  echo "$as_me:4048: \$? = $ac_status" >&5
4049  (exit $ac_status); }; }; then
4050  lt_cv_prog_cc_static_works=yes
4051else
4052  echo "$as_me: failed program was:" >&5
4053cat conftest.$ac_ext >&5
4054fi
4055rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4056  LDFLAGS="$save_LDFLAGS"
4057
4058fi
4059
4060# Belt *and* braces to stop my trousers falling down:
4061test "X$lt_cv_prog_cc_static_works" = Xno && lt_cv_prog_cc_static=
4062echo "$as_me:4062: result: $lt_cv_prog_cc_static_works" >&5
4063echo "${ECHO_T}$lt_cv_prog_cc_static_works" >&6
4064
4065pic_flag="$lt_cv_prog_cc_pic"
4066special_shlib_compile_flags="$lt_cv_prog_cc_shlib"
4067wl="$lt_cv_prog_cc_wl"
4068link_static_flag="$lt_cv_prog_cc_static"
4069no_builtin_flag="$lt_cv_prog_cc_no_builtin"
4070can_build_shared="$lt_cv_prog_cc_can_build_shared"
4071
4072# Check to see if options -o and -c are simultaneously supported by compiler
4073echo "$as_me:4073: checking if $compiler supports -c -o file.$ac_objext" >&5
4074echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6
4075if test "${lt_cv_compiler_c_o+set}" = set; then
4076  echo $ECHO_N "(cached) $ECHO_C" >&6
4077else
4078
4079$rm -r conftest 2>/dev/null
4080mkdir conftest
4081cd conftest
4082echo "int some_variable = 0;" > conftest.$ac_ext
4083mkdir out
4084# According to Tom Tromey, Ian Lance Taylor reported there are C compilers
4085# that will create temporary files in the current directory regardless of
4086# the output directory.  Thus, making CWD read-only will cause this test
4087# to fail, enabling locking or at least warning the user not to do parallel
4088# builds.
4089chmod -w .
4090save_CFLAGS="$CFLAGS"
4091CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
4092compiler_c_o=no
4093if { (eval echo configure:4093: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
4094  # The compiler can only warn and ignore the option if not recognized
4095  # So say no if there are warnings
4096  if test -s out/conftest.err; then
4097    lt_cv_compiler_c_o=no
4098  else
4099    lt_cv_compiler_c_o=yes
4100  fi
4101else
4102  # Append any errors to the config.log.
4103  cat out/conftest.err 1>&5
4104  lt_cv_compiler_c_o=no
4105fi
4106CFLAGS="$save_CFLAGS"
4107chmod u+w .
4108$rm conftest* out/*
4109rmdir out
4110cd ..
4111rmdir conftest
4112$rm -r conftest 2>/dev/null
4113
4114fi
4115
4116compiler_c_o=$lt_cv_compiler_c_o
4117echo "$as_me:4117: result: $compiler_c_o" >&5
4118echo "${ECHO_T}$compiler_c_o" >&6
4119
4120if test x"$compiler_c_o" = x"yes"; then
4121  # Check to see if we can write to a .lo
4122  echo "$as_me:4122: checking if $compiler supports -c -o file.lo" >&5
4123echo $ECHO_N "checking if $compiler supports -c -o file.lo... $ECHO_C" >&6
4124  if test "${lt_cv_compiler_o_lo+set}" = set; then
4125  echo $ECHO_N "(cached) $ECHO_C" >&6
4126else
4127
4128  lt_cv_compiler_o_lo=no
4129  save_CFLAGS="$CFLAGS"
4130  CFLAGS="$CFLAGS -c -o conftest.lo"
4131  cat >conftest.$ac_ext <<_ACEOF
4132#line 4132 "configure"
4133#include "confdefs.h"
4134
4135int
4136main ()
4137{
4138int some_variable = 0;
4139  ;
4140  return 0;
4141}
4142_ACEOF
4143rm -f conftest.$ac_objext
4144if { (eval echo "$as_me:4144: \"$ac_compile\"") >&5
4145  (eval $ac_compile) 2>&5
4146  ac_status=$?
4147  echo "$as_me:4147: \$? = $ac_status" >&5
4148  (exit $ac_status); } &&
4149         { ac_try='test -s conftest.$ac_objext'
4150  { (eval echo "$as_me:4150: \"$ac_try\"") >&5
4151  (eval $ac_try) 2>&5
4152  ac_status=$?
4153  echo "$as_me:4153: \$? = $ac_status" >&5
4154  (exit $ac_status); }; }; then
4155      # The compiler can only warn and ignore the option if not recognized
4156    # So say no if there are warnings
4157    if test -s conftest.err; then
4158      lt_cv_compiler_o_lo=no
4159    else
4160      lt_cv_compiler_o_lo=yes
4161    fi
4162
4163else
4164  echo "$as_me: failed program was:" >&5
4165cat conftest.$ac_ext >&5
4166fi
4167rm -f conftest.$ac_objext conftest.$ac_ext
4168  CFLAGS="$save_CFLAGS"
4169
4170fi
4171
4172  compiler_o_lo=$lt_cv_compiler_o_lo
4173  echo "$as_me:4173: result: $compiler_c_lo" >&5
4174echo "${ECHO_T}$compiler_c_lo" >&6
4175else
4176  compiler_o_lo=no
4177fi
4178
4179# Check to see if we can do hard links to lock some files if needed
4180hard_links="nottested"
4181if test "$compiler_c_o" = no && test "$need_locks" != no; then
4182  # do not overwrite the value of need_locks provided by the user
4183  echo "$as_me:4183: checking if we can lock with hard links" >&5
4184echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6
4185  hard_links=yes
4186  $rm conftest*
4187  ln conftest.a conftest.b 2>/dev/null && hard_links=no
4188  touch conftest.a
4189  ln conftest.a conftest.b 2>&5 || hard_links=no
4190  ln conftest.a conftest.b 2>/dev/null && hard_links=no
4191  echo "$as_me:4191: result: $hard_links" >&5
4192echo "${ECHO_T}$hard_links" >&6
4193  if test "$hard_links" = no; then
4194    { echo "$as_me:4194: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
4195echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
4196    need_locks=warn
4197  fi
4198else
4199  need_locks=no
4200fi
4201
4202if test "$GCC" = yes; then
4203  # Check to see if options -fno-rtti -fno-exceptions are supported by compiler
4204  echo "$as_me:4204: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
4205echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6
4206  echo "int some_variable = 0;" > conftest.$ac_ext
4207  save_CFLAGS="$CFLAGS"
4208  CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.$ac_ext"
4209  compiler_rtti_exceptions=no
4210  cat >conftest.$ac_ext <<_ACEOF
4211#line 4211 "configure"
4212#include "confdefs.h"
4213
4214int
4215main ()
4216{
4217int some_variable = 0;
4218  ;
4219  return 0;
4220}
4221_ACEOF
4222rm -f conftest.$ac_objext
4223if { (eval echo "$as_me:4223: \"$ac_compile\"") >&5
4224  (eval $ac_compile) 2>&5
4225  ac_status=$?
4226  echo "$as_me:4226: \$? = $ac_status" >&5
4227  (exit $ac_status); } &&
4228         { ac_try='test -s conftest.$ac_objext'
4229  { (eval echo "$as_me:4229: \"$ac_try\"") >&5
4230  (eval $ac_try) 2>&5
4231  ac_status=$?
4232  echo "$as_me:4232: \$? = $ac_status" >&5
4233  (exit $ac_status); }; }; then
4234      # The compiler can only warn and ignore the option if not recognized
4235    # So say no if there are warnings
4236    if test -s conftest.err; then
4237      compiler_rtti_exceptions=no
4238    else
4239      compiler_rtti_exceptions=yes
4240    fi
4241
4242else
4243  echo "$as_me: failed program was:" >&5
4244cat conftest.$ac_ext >&5
4245fi
4246rm -f conftest.$ac_objext conftest.$ac_ext
4247  CFLAGS="$save_CFLAGS"
4248  echo "$as_me:4248: result: $compiler_rtti_exceptions" >&5
4249echo "${ECHO_T}$compiler_rtti_exceptions" >&6
4250
4251  if test "$compiler_rtti_exceptions" = "yes"; then
4252    no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions'
4253  else
4254    no_builtin_flag=' -fno-builtin'
4255  fi
4256fi
4257
4258# See if the linker supports building shared libraries.
4259echo "$as_me:4259: checking whether the linker ($LD) supports shared libraries" >&5
4260echo $ECHO_N "checking whether the linker ($LD) supports shared libraries... $ECHO_C" >&6
4261
4262allow_undefined_flag=
4263no_undefined_flag=
4264need_lib_prefix=unknown
4265need_version=unknown
4266# when you set need_version to no, make sure it does not cause -set_version
4267# flags to be left without arguments
4268archive_cmds=
4269archive_expsym_cmds=
4270old_archive_from_new_cmds=
4271old_archive_from_expsyms_cmds=
4272export_dynamic_flag_spec=
4273whole_archive_flag_spec=
4274thread_safe_flag_spec=
4275hardcode_into_libs=no
4276hardcode_libdir_flag_spec=
4277hardcode_libdir_separator=
4278hardcode_direct=no
4279hardcode_minus_L=no
4280hardcode_shlibpath_var=unsupported
4281runpath_var=
4282link_all_deplibs=unknown
4283always_export_symbols=no
4284export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
4285# include_expsyms should be a list of space-separated symbols to be *always*
4286# included in the symbol list
4287include_expsyms=
4288# exclude_expsyms can be an egrep regular expression of symbols to exclude
4289# it will be wrapped by ` (' and `)$', so one must not match beginning or
4290# end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4291# as well as any symbol that contains `d'.
4292exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
4293# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
4294# platforms (ab)use it in PIC code, but their linkers get confused if
4295# the symbol is explicitly referenced.  Since portable code cannot
4296# rely on this symbol name, it's probably fine to never include it in
4297# preloaded symbol tables.
4298extract_expsyms_cmds=
4299
4300case $host_os in
4301cygwin* | mingw* | pw32* )
4302  # FIXME: the MSVC++ port hasn't been tested in a loooong time
4303  # When not using gcc, we currently assume that we are using
4304  # Microsoft Visual C++.
4305  if test "$GCC" != yes; then
4306    with_gnu_ld=no
4307  fi
4308  ;;
4309
4310esac
4311
4312ld_shlibs=yes
4313if test "$with_gnu_ld" = yes; then
4314  # If archive_cmds runs LD, not CC, wlarc should be empty
4315  wlarc='${wl}'
4316
4317  # See if GNU ld supports shared libraries.
4318  case $host_os in
4319  aix3* | aix4* | aix5*)
4320    # On AIX, the GNU linker is very broken
4321    # Note:Check GNU linker on AIX 5-IA64 when/if it becomes available.
4322    ld_shlibs=no
4323    cat <<EOF 1>&2
4324
4325*** Warning: the GNU linker, at least up to release 2.9.1, is reported
4326*** to be unable to reliably create shared libraries on AIX.
4327*** Therefore, libtool is disabling shared libraries support.  If you
4328*** really care for shared libraries, you may want to modify your PATH
4329*** so that a non-GNU linker is found, and then restart.
4330
4331EOF
4332    ;;
4333
4334  amigaos*)
4335    archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
4336    hardcode_libdir_flag_spec='-L$libdir'
4337    hardcode_minus_L=yes
4338
4339    # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
4340    # that the semantics of dynamic libraries on AmigaOS, at least up
4341    # to version 4, is to share data among multiple programs linked
4342    # with the same dynamic library.  Since this doesn't match the
4343    # behavior of shared libraries on other platforms, we can use
4344    # them.
4345    ld_shlibs=no
4346    ;;
4347
4348  beos*)
4349    if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
4350      allow_undefined_flag=unsupported
4351      # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
4352      # support --undefined.  This deserves some investigation.  FIXME
4353      archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4354    else
4355      ld_shlibs=no
4356    fi
4357    ;;
4358
4359  cygwin* | mingw* | pw32*)
4360    # hardcode_libdir_flag_spec is actually meaningless, as there is
4361    # no search path for DLLs.
4362    hardcode_libdir_flag_spec='-L$libdir'
4363    allow_undefined_flag=unsupported
4364    always_export_symbols=yes
4365
4366    extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
4367      sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
4368      test -f $output_objdir/impgen.exe || (cd $output_objdir && \
4369      if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
4370      else $CC -o impgen impgen.c ; fi)~
4371      $output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
4372
4373    old_archive_from_expsyms_cmds='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
4374
4375    # cygwin and mingw dlls have different entry points and sets of symbols
4376    # to exclude.
4377    # FIXME: what about values for MSVC?
4378    dll_entry=__cygwin_dll_entry@12
4379    dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
4380    case $host_os in
4381    mingw*)
4382      # mingw values
4383      dll_entry=_DllMainCRTStartup@12
4384      dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
4385      ;;
4386    esac
4387
4388    # mingw and cygwin differ, and it's simplest to just exclude the union
4389    # of the two symbol sets.
4390    dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
4391
4392    # recent cygwin and mingw systems supply a stub DllMain which the user
4393    # can override, but on older systems we have to supply one (in ltdll.c)
4394    if test "x$lt_cv_need_dllmain" = "xyes"; then
4395      ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
4396      ltdll_cmds='test -f $output_objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < [$]0 > $output_objdir/$soname-ltdll.c~
4397	test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
4398    else
4399      ltdll_obj=
4400      ltdll_cmds=
4401    fi
4402
4403    # Extract the symbol export list from an `--export-all' def file,
4404    # then regenerate the def file from the symbol export list, so that
4405    # the compiled dll only exports the symbol export list.
4406    # Be careful not to strip the DATA tag left be newer dlltools.
4407    export_symbols_cmds="$ltdll_cmds"'
4408      $DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
4409      sed -e "1,/EXPORTS/d" -e "s/ @ [0-9]*//" -e "s/ *;.*$//" < $output_objdir/$soname-def > $export_symbols'
4410
4411    # If the export-symbols file already is a .def file (1st line
4412    # is EXPORTS), use it as is.
4413    # If DATA tags from a recent dlltool are present, honour them!
4414    archive_expsym_cmds='if test "x`head -1 $export_symbols`" = xEXPORTS; then
4415        cp $export_symbols $output_objdir/$soname-def;
4416      else
4417        echo EXPORTS > $output_objdir/$soname-def;
4418        _lt_hint=1;
4419        cat $export_symbols | while read symbol; do
4420         set dummy \$symbol;
4421         case \$# in
4422           2) echo "   \$2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
4423           *) echo "     \$2 @ \$_lt_hint \$3 ; " >> $output_objdir/$soname-def;;
4424         esac;
4425         _lt_hint=`expr 1 + \$_lt_hint`;
4426        done;
4427      fi~
4428      '"$ltdll_cmds"'
4429      $CC -Wl,--base-file,$output_objdir/$soname-base '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
4430      $DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp~
4431      $CC -Wl,--base-file,$output_objdir/$soname-base $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
4432      $DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp --output-lib $output_objdir/$libname.dll.a~
4433      $CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
4434    ;;
4435
4436  netbsd*)
4437    if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4438      archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
4439      wlarc=
4440    else
4441      archive_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4442      archive_expsym_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4443    fi
4444    ;;
4445
4446  solaris* | sysv5*)
4447    if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
4448      ld_shlibs=no
4449      cat <<EOF 1>&2
4450
4451*** Warning: The releases 2.8.* of the GNU linker cannot reliably
4452*** create shared libraries on Solaris systems.  Therefore, libtool
4453*** is disabling shared libraries support.  We urge you to upgrade GNU
4454*** binutils to release 2.9.1 or newer.  Another option is to modify
4455*** your PATH or compiler configuration so that the native linker is
4456*** used, and then restart.
4457
4458EOF
4459    elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
4460      archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4461      archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4462    else
4463      ld_shlibs=no
4464    fi
4465    ;;
4466
4467  sunos4*)
4468    archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
4469    wlarc=
4470    hardcode_direct=yes
4471    hardcode_shlibpath_var=no
4472    ;;
4473
4474  *)
4475    if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
4476      archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4477      archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
4478    else
4479      ld_shlibs=no
4480    fi
4481    ;;
4482  esac
4483
4484  if test "$ld_shlibs" = yes; then
4485    runpath_var=LD_RUN_PATH
4486    hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
4487    export_dynamic_flag_spec='${wl}--export-dynamic'
4488    case $host_os in
4489    cygwin* | mingw* | pw32*)
4490      # dlltool doesn't understand --whole-archive et. al.
4491      whole_archive_flag_spec=
4492      ;;
4493    *)
4494      # ancient GNU ld didn't support --whole-archive et. al.
4495      if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
4496	whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
4497      else
4498	whole_archive_flag_spec=
4499      fi
4500      ;;
4501    esac
4502  fi
4503else
4504  # PORTME fill in a description of your system's linker (not GNU ld)
4505  case $host_os in
4506  aix3*)
4507    allow_undefined_flag=unsupported
4508    always_export_symbols=yes
4509    archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
4510    # Note: this linker hardcodes the directories in LIBPATH if there
4511    # are no directories specified by -L.
4512    hardcode_minus_L=yes
4513    if test "$GCC" = yes && test -z "$link_static_flag"; then
4514      # Neither direct hardcoding nor static linking is supported with a
4515      # broken collect2.
4516      hardcode_direct=unsupported
4517    fi
4518    ;;
4519
4520  aix4* | aix5*)
4521    # When large executables or shared objects are built, AIX ld can
4522    # have problems creating the table of contents.  If linking a library
4523    # or program results in "error TOC overflow" add -mminimal-toc to
4524    # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
4525    # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
4526
4527    archive_cmds=''
4528    hardcode_libdir_separator=':'
4529    if test "$GCC" = yes; then
4530      collect2name=`${CC} -print-prog-name=collect2`
4531      if test -f "$collect2name" && \
4532	 strings "$collect2name" | grep resolve_lib_name >/dev/null
4533      then
4534	# We have reworked collect2
4535	hardcode_direct=yes
4536      else
4537        # We have old collect2
4538        hardcode_direct=unsupported
4539        # It fails to find uninstalled libraries when the uninstalled
4540        # path is not listed in the libpath.  Setting hardcode_minus_L
4541        # to unsupported forces relinking
4542        hardcode_minus_L=yes
4543        hardcode_libdir_flag_spec='-L$libdir'
4544        hardcode_libdir_separator=
4545      fi
4546      shared_flag='-shared'
4547    else
4548      if test "$host_cpu" = ia64; then
4549        shared_flag='-G'
4550      else
4551        shared_flag='${wl}-bM:SRE'
4552      fi
4553      hardcode_direct=yes
4554    fi
4555
4556    if test "$host_cpu" = ia64; then
4557      # On IA64, the linker does run time linking by default, so we don't
4558      # have to do anything special.
4559      aix_use_runtimelinking=no
4560      exp_sym_flag='-Bexport'
4561      no_entry_flag=""
4562    else
4563      # Test if we are trying to use run time linking, or normal AIX style linking.
4564      # If -brtl is somewhere in LDFLAGS, we need to do run time linking.
4565      aix_use_runtimelinking=no
4566      for ld_flag in $LDFLAGS; do
4567        if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl" ); then
4568          aix_use_runtimelinking=yes
4569          break
4570        fi
4571      done
4572      exp_sym_flag='-bexport'
4573      no_entry_flag='-bnoentry'
4574    fi
4575    # It seems that -bexpall can do strange things, so it is better to
4576    # generate a list of symbols to export.
4577    always_export_symbols=yes
4578    if test "$aix_use_runtimelinking" = yes; then
4579      hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
4580      allow_undefined_flag=' -Wl,-G'
4581      archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
4582    else
4583      if test "$host_cpu" = ia64; then
4584        hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
4585       allow_undefined_flag="-znodefs"
4586        archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname ${wl}-h$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
4587      else
4588        hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
4589        # Warning - without using the other run time loading flags, -berok will
4590        #           link without error, but may produce a broken library.
4591        allow_undefined_flag='${wl}-berok"
4592        # This is a bit strange, but is similar to how AIX traditionally builds
4593        # it's shared libraries.
4594        archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"' ~$AR -crlo $objdir/$libname$release.a $objdir/$soname'
4595      fi
4596    fi
4597    ;;
4598
4599  amigaos*)
4600    archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
4601    hardcode_libdir_flag_spec='-L$libdir'
4602    hardcode_minus_L=yes
4603    # see comment about different semantics on the GNU ld section
4604    ld_shlibs=no
4605    ;;
4606
4607  cygwin* | mingw* | pw32*)
4608    # When not using gcc, we currently assume that we are using
4609    # Microsoft Visual C++.
4610    # hardcode_libdir_flag_spec is actually meaningless, as there is
4611    # no search path for DLLs.
4612    hardcode_libdir_flag_spec=' '
4613    allow_undefined_flag=unsupported
4614    # Tell ltmain to make .lib files, not .a files.
4615    libext=lib
4616    # FIXME: Setting linknames here is a bad hack.
4617    archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
4618    # The linker will automatically build a .lib file if we build a DLL.
4619    old_archive_from_new_cmds='true'
4620    # FIXME: Should let the user specify the lib program.
4621    old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
4622    fix_srcfile_path='`cygpath -w "$srcfile"`'
4623    ;;
4624
4625  darwin* | rhapsody*)
4626    allow_undefined_flag='-undefined suppress'
4627    # FIXME: Relying on posixy $() will cause problems for
4628    #        cross-compilation, but unfortunately the echo tests do not
4629    #        yet detect zsh echo's removal of \ escapes.
4630    archive_cmds='$CC $(test .$module = .yes && echo -bundle || echo -dynamiclib) $allow_undefined_flag -o $lib $libobjs $deplibs$linkopts -install_name $rpath/$soname $(test -n "$verstring" -a x$verstring != x0.0 && echo $verstring)'
4631    # We need to add '_' to the symbols in $export_symbols first
4632    #archive_expsym_cmds="$archive_cmds"' && strip -s $export_symbols'
4633    hardcode_direct=yes
4634    hardcode_shlibpath_var=no
4635    whole_archive_flag_spec='-all_load $convenience'
4636    ;;
4637
4638  freebsd1*)
4639    ld_shlibs=no
4640    ;;
4641
4642  # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
4643  # support.  Future versions do this automatically, but an explicit c++rt0.o
4644  # does not break anything, and helps significantly (at the cost of a little
4645  # extra space).
4646  freebsd2.2*)
4647    archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
4648    hardcode_libdir_flag_spec='-R$libdir'
4649    hardcode_direct=yes
4650    hardcode_shlibpath_var=no
4651    ;;
4652
4653  # Unfortunately, older versions of FreeBSD 2 do not have this feature.
4654  freebsd2*)
4655    archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
4656    hardcode_direct=yes
4657    hardcode_minus_L=yes
4658    hardcode_shlibpath_var=no
4659    ;;
4660
4661  # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
4662  freebsd*)
4663    archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
4664    hardcode_libdir_flag_spec='-R$libdir'
4665    hardcode_direct=yes
4666    hardcode_shlibpath_var=no
4667    ;;
4668
4669  hpux9* | hpux10* | hpux11*)
4670    case $host_os in
4671    hpux9*) archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
4672    *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
4673    esac
4674    hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
4675    hardcode_libdir_separator=:
4676    hardcode_direct=yes
4677    hardcode_minus_L=yes # Not in the search PATH, but as the default
4678			 # location of the library.
4679    export_dynamic_flag_spec='${wl}-E'
4680    ;;
4681
4682  irix5* | irix6*)
4683    if test "$GCC" = yes; then
4684      archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4685    else
4686      archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4687    fi
4688    hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
4689    hardcode_libdir_separator=:
4690    link_all_deplibs=yes
4691    ;;
4692
4693  netbsd*)
4694    if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
4695      archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
4696    else
4697      archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
4698    fi
4699    hardcode_libdir_flag_spec='-R$libdir'
4700    hardcode_direct=yes
4701    hardcode_shlibpath_var=no
4702    ;;
4703
4704  newsos6)
4705    archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linkopts'
4706    hardcode_direct=yes
4707    hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
4708    hardcode_libdir_separator=:
4709    hardcode_shlibpath_var=no
4710    ;;
4711
4712  openbsd*)
4713    archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
4714    hardcode_libdir_flag_spec='-R$libdir'
4715    hardcode_direct=yes
4716    hardcode_shlibpath_var=no
4717    ;;
4718
4719  os2*)
4720    hardcode_libdir_flag_spec='-L$libdir'
4721    hardcode_minus_L=yes
4722    allow_undefined_flag=unsupported
4723    archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
4724    old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
4725    ;;
4726
4727  osf3*)
4728    if test "$GCC" = yes; then
4729      allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
4730      archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4731    else
4732      allow_undefined_flag=' -expect_unresolved \*'
4733      archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4734    fi
4735    hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
4736    hardcode_libdir_separator=:
4737    ;;
4738
4739  osf4* | osf5*)	# as osf3* with the addition of -msym flag
4740    if test "$GCC" = yes; then
4741      allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
4742      archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
4743      hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
4744    else
4745      allow_undefined_flag=' -expect_unresolved \*'
4746      archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
4747      archive_expsym_cmds='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
4748      $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
4749
4750      #Both c and cxx compiler support -rpath directly
4751      hardcode_libdir_flag_spec='-rpath $libdir'
4752    fi
4753    hardcode_libdir_separator=:
4754    ;;
4755
4756  sco3.2v5*)
4757    archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4758    hardcode_shlibpath_var=no
4759    runpath_var=LD_RUN_PATH
4760    hardcode_runpath_var=yes
4761    ;;
4762
4763  solaris*)
4764    no_undefined_flag=' -z defs'
4765    # $CC -shared without GNU ld will not create a library from C++
4766    # object files and a static libstdc++, better avoid it by now
4767    archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
4768    archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4769		$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
4770    hardcode_libdir_flag_spec='-R$libdir'
4771    hardcode_shlibpath_var=no
4772    case $host_os in
4773    solaris2.[0-5] | solaris2.[0-5].*) ;;
4774    *) # Supported since Solaris 2.6 (maybe 2.5.1?)
4775      whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
4776    esac
4777    link_all_deplibs=yes
4778    ;;
4779
4780  sunos4*)
4781    if test "x$host_vendor" = xsequent; then
4782      # Use $CC to link under sequent, because it throws in some extra .o
4783      # files that make .init and .fini sections work.
4784      archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
4785    else
4786      archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
4787    fi
4788    hardcode_libdir_flag_spec='-L$libdir'
4789    hardcode_direct=yes
4790    hardcode_minus_L=yes
4791    hardcode_shlibpath_var=no
4792    ;;
4793
4794  sysv4)
4795    if test "x$host_vendor" = xsno; then
4796      archive_cmds='$LD -G -Bsymbolic -h $soname -o $lib $libobjs $deplibs $linkopts'
4797      hardcode_direct=yes # is this really true???
4798    else
4799      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4800      hardcode_direct=no #Motorola manual says yes, but my tests say they lie
4801    fi
4802    runpath_var='LD_RUN_PATH'
4803    hardcode_shlibpath_var=no
4804    ;;
4805
4806  sysv4.3*)
4807    archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4808    hardcode_shlibpath_var=no
4809    export_dynamic_flag_spec='-Bexport'
4810    ;;
4811
4812  sysv5*)
4813    no_undefined_flag=' -z text'
4814    # $CC -shared without GNU ld will not create a library from C++
4815    # object files and a static libstdc++, better avoid it by now
4816    archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
4817    archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
4818		$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
4819    hardcode_libdir_flag_spec=
4820    hardcode_shlibpath_var=no
4821    runpath_var='LD_RUN_PATH'
4822    ;;
4823
4824  uts4*)
4825    archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4826    hardcode_libdir_flag_spec='-L$libdir'
4827    hardcode_shlibpath_var=no
4828    ;;
4829
4830  dgux*)
4831    archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4832    hardcode_libdir_flag_spec='-L$libdir'
4833    hardcode_shlibpath_var=no
4834    ;;
4835
4836  sysv4*MP*)
4837    if test -d /usr/nec; then
4838      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
4839      hardcode_shlibpath_var=no
4840      runpath_var=LD_RUN_PATH
4841      hardcode_runpath_var=yes
4842      ld_shlibs=yes
4843    fi
4844    ;;
4845
4846  sysv4.2uw2*)
4847    archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
4848    hardcode_direct=yes
4849    hardcode_minus_L=no
4850    hardcode_shlibpath_var=no
4851    hardcode_runpath_var=yes
4852    runpath_var=LD_RUN_PATH
4853    ;;
4854
4855  sysv5uw7* | unixware7*)
4856    no_undefined_flag='${wl}-z ${wl}text'
4857    if test "$GCC" = yes; then
4858      archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
4859    else
4860      archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
4861    fi
4862    runpath_var='LD_RUN_PATH'
4863    hardcode_shlibpath_var=no
4864    ;;
4865
4866  *)
4867    ld_shlibs=no
4868    ;;
4869  esac
4870fi
4871echo "$as_me:4871: result: $ld_shlibs" >&5
4872echo "${ECHO_T}$ld_shlibs" >&6
4873test "$ld_shlibs" = no && can_build_shared=no
4874
4875# Check hardcoding attributes.
4876echo "$as_me:4876: checking how to hardcode library paths into programs" >&5
4877echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6
4878hardcode_action=
4879if test -n "$hardcode_libdir_flag_spec" || \
4880   test -n "$runpath_var"; then
4881
4882  # We can hardcode non-existant directories.
4883  if test "$hardcode_direct" != no &&
4884     # If the only mechanism to avoid hardcoding is shlibpath_var, we
4885     # have to relink, otherwise we might link with an installed library
4886     # when we should be linking with a yet-to-be-installed one
4887     ## test "$hardcode_shlibpath_var" != no &&
4888     test "$hardcode_minus_L" != no; then
4889    # Linking always hardcodes the temporary library directory.
4890    hardcode_action=relink
4891  else
4892    # We can link without hardcoding, and we can hardcode nonexisting dirs.
4893    hardcode_action=immediate
4894  fi
4895else
4896  # We cannot hardcode anything, or else we can only hardcode existing
4897  # directories.
4898  hardcode_action=unsupported
4899fi
4900echo "$as_me:4900: result: $hardcode_action" >&5
4901echo "${ECHO_T}$hardcode_action" >&6
4902
4903striplib=
4904old_striplib=
4905echo "$as_me:4905: checking whether stripping libraries is possible" >&5
4906echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6
4907if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
4908  test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
4909  test -z "$striplib" && striplib="$STRIP --strip-unneeded"
4910  echo "$as_me:4910: result: yes" >&5
4911echo "${ECHO_T}yes" >&6
4912else
4913  echo "$as_me:4913: result: no" >&5
4914echo "${ECHO_T}no" >&6
4915fi
4916
4917reload_cmds='$LD$reload_flag -o $output$reload_objs'
4918test -z "$deplibs_check_method" && deplibs_check_method=unknown
4919
4920# PORTME Fill in your ld.so characteristics
4921echo "$as_me:4921: checking dynamic linker characteristics" >&5
4922echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6
4923library_names_spec=
4924libname_spec='lib$name'
4925soname_spec=
4926postinstall_cmds=
4927postuninstall_cmds=
4928finish_cmds=
4929finish_eval=
4930shlibpath_var=
4931shlibpath_overrides_runpath=unknown
4932version_type=none
4933dynamic_linker="$host_os ld.so"
4934sys_lib_dlsearch_path_spec="/lib /usr/lib"
4935sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
4936
4937case $host_os in
4938aix3*)
4939  version_type=linux
4940  library_names_spec='${libname}${release}.so$versuffix $libname.a'
4941  shlibpath_var=LIBPATH
4942
4943  # AIX has no versioning support, so we append a major version to the name.
4944  soname_spec='${libname}${release}.so$major'
4945  ;;
4946
4947aix4* | aix5*)
4948  version_type=linux
4949  if test "$host_cpu" = ia64; then
4950    # AIX 5 supports IA64
4951    library_names_spec='${libname}${release}.so$major ${libname}${release}.so$versuffix $libname.so'
4952    shlibpath_var=LD_LIBRARY_PATH
4953  else
4954    # With GCC up to 2.95.x, collect2 would create an import file
4955    # for dependence libraries.  The import file would start with
4956    # the line `#! .'.  This would cause the generated library to
4957    # depend on `.', always an invalid library.  This was fixed in
4958    # development snapshots of GCC prior to 3.0.
4959    case $host_os in
4960       aix4 | aix4.[01] | aix4.[01].*)
4961      if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
4962           echo ' yes '
4963           echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
4964        :
4965      else
4966        can_build_shared=no
4967      fi
4968      ;;
4969    esac
4970    # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
4971    # soname into executable. Probably we can add versioning support to
4972    # collect2, so additional links can be useful in future.
4973    if test "$aix_use_runtimelinking" = yes; then
4974      # If using run time linking (on AIX 4.2 or later) use lib<name>.so instead of
4975      # lib<name>.a to let people know that these are not typical AIX shared libraries.
4976      library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
4977    else
4978      # We preserve .a as extension for shared libraries through AIX4.2
4979      # and later when we are not doing run time linking.
4980      library_names_spec='${libname}${release}.a $libname.a'
4981      soname_spec='${libname}${release}.so$major'
4982    fi
4983    shlibpath_var=LIBPATH
4984    deplibs_check_method=pass_all
4985  fi
4986  ;;
4987
4988amigaos*)
4989  library_names_spec='$libname.ixlibrary $libname.a'
4990  # Create ${libname}_ixlibrary.a entries in /sys/libs.
4991  finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "(cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a)"; (cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a) || exit 1; done'
4992  ;;
4993
4994beos*)
4995  library_names_spec='${libname}.so'
4996  dynamic_linker="$host_os ld.so"
4997  shlibpath_var=LIBRARY_PATH
4998  ;;
4999
5000bsdi4*)
5001  version_type=linux
5002  need_version=no
5003  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5004  soname_spec='${libname}${release}.so$major'
5005  finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
5006  shlibpath_var=LD_LIBRARY_PATH
5007  sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
5008  sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
5009  export_dynamic_flag_spec=-rdynamic
5010  # the default ld.so.conf also contains /usr/contrib/lib and
5011  # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
5012  # libtool to hard-code these into programs
5013  ;;
5014
5015cygwin* | mingw* | pw32*)
5016  version_type=windows
5017  need_version=no
5018  need_lib_prefix=no
5019  case $GCC,$host_os in
5020  yes,cygwin*)
5021    library_names_spec='$libname.dll.a'
5022    soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
5023    postinstall_cmds='dlpath=`bash 2>&1 -c '\''. $dir/${file}i;echo \$dlname'\''`~
5024      dldir=$destdir/`dirname \$dlpath`~
5025      test -d \$dldir || mkdir -p \$dldir~
5026      $install_prog .libs/$dlname \$dldir/$dlname'
5027    postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
5028      dlpath=$dir/\$dldll~
5029       $rm \$dlpath'
5030    ;;
5031  yes,mingw*)
5032    library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
5033    sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g"`
5034    ;;
5035  yes,pw32*)
5036    library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/./-/g'`${versuffix}.dll'
5037    ;;
5038  *)
5039    library_names_spec='${libname}`echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll $libname.lib'
5040    ;;
5041  esac
5042  dynamic_linker='Win32 ld.exe'
5043  # FIXME: first we should search . and the directory the executable is in
5044  shlibpath_var=PATH
5045  ;;
5046
5047darwin* | rhapsody*)
5048  dynamic_linker="$host_os dyld"
5049  version_type=darwin
5050  need_lib_prefix=no
5051  need_version=no
5052  # FIXME: Relying on posixy $() will cause problems for
5053  #        cross-compilation, but unfortunately the echo tests do not
5054  #        yet detect zsh echo's removal of \ escapes.
5055  library_names_spec='${libname}${release}${versuffix}.$(test .$module = .yes && echo so || echo dylib) ${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib) ${libname}.$(test .$module = .yes && echo so || echo dylib)'
5056  soname_spec='${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib)'
5057  shlibpath_overrides_runpath=yes
5058  shlibpath_var=DYLD_LIBRARY_PATH
5059  ;;
5060
5061freebsd1*)
5062  dynamic_linker=no
5063  ;;
5064
5065freebsd*)
5066  objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
5067  version_type=freebsd-$objformat
5068  case $version_type in
5069    freebsd-elf*)
5070      library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
5071      need_version=no
5072      need_lib_prefix=no
5073      ;;
5074    freebsd-*)
5075      library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix'
5076      need_version=yes
5077      ;;
5078  esac
5079  shlibpath_var=LD_LIBRARY_PATH
5080  case $host_os in
5081  freebsd2*)
5082    shlibpath_overrides_runpath=yes
5083    ;;
5084  *)
5085    shlibpath_overrides_runpath=no
5086    hardcode_into_libs=yes
5087    ;;
5088  esac
5089  ;;
5090
5091gnu*)
5092  version_type=linux
5093  need_lib_prefix=no
5094  need_version=no
5095  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
5096  soname_spec='${libname}${release}.so$major'
5097  shlibpath_var=LD_LIBRARY_PATH
5098  hardcode_into_libs=yes
5099  ;;
5100
5101hpux9* | hpux10* | hpux11*)
5102  # Give a soname corresponding to the major version so that dld.sl refuses to
5103  # link against other versions.
5104  dynamic_linker="$host_os dld.sl"
5105  version_type=sunos
5106  need_lib_prefix=no
5107  need_version=no
5108  shlibpath_var=SHLIB_PATH
5109  shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
5110  library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
5111  soname_spec='${libname}${release}.sl$major'
5112  # HP-UX runs *really* slowly unless shared libraries are mode 555.
5113  postinstall_cmds='chmod 555 $lib'
5114  ;;
5115
5116irix5* | irix6*)
5117  version_type=irix
5118  need_lib_prefix=no
5119  need_version=no
5120  soname_spec='${libname}${release}.so$major'
5121  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so $libname.so'
5122  case $host_os in
5123  irix5*)
5124    libsuff= shlibsuff=
5125    ;;
5126  *)
5127    case $LD in # libtool.m4 will add one of these switches to LD
5128    *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
5129    *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
5130    *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
5131    *) libsuff= shlibsuff= libmagic=never-match;;
5132    esac
5133    ;;
5134  esac
5135  shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
5136  shlibpath_overrides_runpath=no
5137  sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
5138  sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
5139  ;;
5140
5141# No shared lib support for Linux oldld, aout, or coff.
5142linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
5143  dynamic_linker=no
5144  ;;
5145
5146# This must be Linux ELF.
5147linux-gnu*)
5148  version_type=linux
5149  need_lib_prefix=no
5150  need_version=no
5151  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5152  soname_spec='${libname}${release}.so$major'
5153  finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
5154  shlibpath_var=LD_LIBRARY_PATH
5155  shlibpath_overrides_runpath=no
5156  # This implies no fast_install, which is unacceptable.
5157  # Some rework will be needed to allow for fast_install
5158  # before this can be enabled.
5159  hardcode_into_libs=yes
5160
5161  # We used to test for /lib/ld.so.1 and disable shared libraries on
5162  # powerpc, because MkLinux only supported shared libraries with the
5163  # GNU dynamic linker.  Since this was broken with cross compilers,
5164  # most powerpc-linux boxes support dynamic linking these days and
5165  # people can always --disable-shared, the test was removed, and we
5166  # assume the GNU/Linux dynamic linker is in use.
5167  dynamic_linker='GNU/Linux ld.so'
5168  ;;
5169
5170netbsd*)
5171  version_type=sunos
5172  need_lib_prefix=no
5173  need_version=no
5174  if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
5175    library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
5176    finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
5177    dynamic_linker='NetBSD (a.out) ld.so'
5178  else
5179    library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so'
5180    soname_spec='${libname}${release}.so$major'
5181    dynamic_linker='NetBSD ld.elf_so'
5182  fi
5183  shlibpath_var=LD_LIBRARY_PATH
5184  shlibpath_overrides_runpath=yes
5185  hardcode_into_libs=yes
5186  ;;
5187
5188newsos6)
5189  version_type=linux
5190  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5191  shlibpath_var=LD_LIBRARY_PATH
5192  shlibpath_overrides_runpath=yes
5193  ;;
5194
5195openbsd*)
5196  version_type=sunos
5197  if test "$with_gnu_ld" = yes; then
5198    need_lib_prefix=no
5199    need_version=no
5200  fi
5201  library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
5202  finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
5203  shlibpath_var=LD_LIBRARY_PATH
5204  ;;
5205
5206os2*)
5207  libname_spec='$name'
5208  need_lib_prefix=no
5209  library_names_spec='$libname.dll $libname.a'
5210  dynamic_linker='OS/2 ld.exe'
5211  shlibpath_var=LIBPATH
5212  ;;
5213
5214osf3* | osf4* | osf5*)
5215  version_type=osf
5216  need_version=no
5217  soname_spec='${libname}${release}.so'
5218  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
5219  shlibpath_var=LD_LIBRARY_PATH
5220  sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
5221  sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
5222  ;;
5223
5224sco3.2v5*)
5225  version_type=osf
5226  soname_spec='${libname}${release}.so$major'
5227  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5228  shlibpath_var=LD_LIBRARY_PATH
5229  ;;
5230
5231solaris*)
5232  version_type=linux
5233  need_lib_prefix=no
5234  need_version=no
5235  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5236  soname_spec='${libname}${release}.so$major'
5237  shlibpath_var=LD_LIBRARY_PATH
5238  shlibpath_overrides_runpath=yes
5239  hardcode_into_libs=yes
5240  # ldd complains unless libraries are executable
5241  postinstall_cmds='chmod +x $lib'
5242  ;;
5243
5244sunos4*)
5245  version_type=sunos
5246  library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
5247  finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
5248  shlibpath_var=LD_LIBRARY_PATH
5249  shlibpath_overrides_runpath=yes
5250  if test "$with_gnu_ld" = yes; then
5251    need_lib_prefix=no
5252  fi
5253  need_version=yes
5254  ;;
5255
5256sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5257  version_type=linux
5258  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5259  soname_spec='${libname}${release}.so$major'
5260  shlibpath_var=LD_LIBRARY_PATH
5261  case $host_vendor in
5262    sni)
5263      shlibpath_overrides_runpath=no
5264      ;;
5265    motorola)
5266      need_lib_prefix=no
5267      need_version=no
5268      shlibpath_overrides_runpath=no
5269      sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
5270      ;;
5271  esac
5272  ;;
5273
5274uts4*)
5275  version_type=linux
5276  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5277  soname_spec='${libname}${release}.so$major'
5278  shlibpath_var=LD_LIBRARY_PATH
5279  ;;
5280
5281dgux*)
5282  version_type=linux
5283  need_lib_prefix=no
5284  need_version=no
5285  library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
5286  soname_spec='${libname}${release}.so$major'
5287  shlibpath_var=LD_LIBRARY_PATH
5288  ;;
5289
5290sysv4*MP*)
5291  if test -d /usr/nec ;then
5292    version_type=linux
5293    library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
5294    soname_spec='$libname.so.$major'
5295    shlibpath_var=LD_LIBRARY_PATH
5296  fi
5297  ;;
5298
5299*)
5300  dynamic_linker=no
5301  ;;
5302esac
5303echo "$as_me:5303: result: $dynamic_linker" >&5
5304echo "${ECHO_T}$dynamic_linker" >&6
5305test "$dynamic_linker" = no && can_build_shared=no
5306
5307# Report the final consequences.
5308echo "$as_me:5308: checking if libtool supports shared libraries" >&5
5309echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6
5310echo "$as_me:5310: result: $can_build_shared" >&5
5311echo "${ECHO_T}$can_build_shared" >&6
5312
5313if test "$hardcode_action" = relink; then
5314  # Fast installation is not supported
5315  enable_fast_install=no
5316elif test "$shlibpath_overrides_runpath" = yes ||
5317     test "$enable_shared" = no; then
5318  # Fast installation is not necessary
5319  enable_fast_install=needless
5320fi
5321
5322variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
5323if test "$GCC" = yes; then
5324  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
5325fi
5326
5327if test "x$enable_dlopen" != xyes; then
5328  enable_dlopen=unknown
5329  enable_dlopen_self=unknown
5330  enable_dlopen_self_static=unknown
5331else
5332  lt_cv_dlopen=no
5333  lt_cv_dlopen_libs=
5334
5335  case $host_os in
5336  beos*)
5337    lt_cv_dlopen="load_add_on"
5338    lt_cv_dlopen_libs=
5339    lt_cv_dlopen_self=yes
5340    ;;
5341
5342  cygwin* | mingw* | pw32*)
5343    lt_cv_dlopen="LoadLibrary"
5344    lt_cv_dlopen_libs=
5345   ;;
5346
5347  *)
5348    echo "$as_me:5348: checking for dlopen in -ldl" >&5
5349echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
5350if test "${ac_cv_lib_dl_dlopen+set}" = set; then
5351  echo $ECHO_N "(cached) $ECHO_C" >&6
5352else
5353  ac_check_lib_save_LIBS=$LIBS
5354LIBS="-ldl  $LIBS"
5355cat >conftest.$ac_ext <<_ACEOF
5356#line 5356 "configure"
5357#include "confdefs.h"
5358
5359/* Override any gcc2 internal prototype to avoid an error.  */
5360#ifdef __cplusplus
5361extern "C"
5362#endif
5363/* We use char because int might match the return type of a gcc2
5364   builtin and then its argument prototype would still apply.  */
5365char dlopen ();
5366int
5367main ()
5368{
5369dlopen ();
5370  ;
5371  return 0;
5372}
5373_ACEOF
5374rm -f conftest.$ac_objext conftest$ac_exeext
5375if { (eval echo "$as_me:5375: \"$ac_link\"") >&5
5376  (eval $ac_link) 2>&5
5377  ac_status=$?
5378  echo "$as_me:5378: \$? = $ac_status" >&5
5379  (exit $ac_status); } &&
5380         { ac_try='test -s conftest$ac_exeext'
5381  { (eval echo "$as_me:5381: \"$ac_try\"") >&5
5382  (eval $ac_try) 2>&5
5383  ac_status=$?
5384  echo "$as_me:5384: \$? = $ac_status" >&5
5385  (exit $ac_status); }; }; then
5386  ac_cv_lib_dl_dlopen=yes
5387else
5388  echo "$as_me: failed program was:" >&5
5389cat conftest.$ac_ext >&5
5390ac_cv_lib_dl_dlopen=no
5391fi
5392rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5393LIBS=$ac_check_lib_save_LIBS
5394fi
5395echo "$as_me:5395: result: $ac_cv_lib_dl_dlopen" >&5
5396echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
5397if test $ac_cv_lib_dl_dlopen = yes; then
5398  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
5399else
5400  echo "$as_me:5400: checking for dlopen" >&5
5401echo $ECHO_N "checking for dlopen... $ECHO_C" >&6
5402if test "${ac_cv_func_dlopen+set}" = set; then
5403  echo $ECHO_N "(cached) $ECHO_C" >&6
5404else
5405  cat >conftest.$ac_ext <<_ACEOF
5406#line 5406 "configure"
5407#include "confdefs.h"
5408/* System header to define __stub macros and hopefully few prototypes,
5409    which can conflict with char dlopen (); below.  */
5410#include <assert.h>
5411/* Override any gcc2 internal prototype to avoid an error.  */
5412#ifdef __cplusplus
5413extern "C"
5414#endif
5415/* We use char because int might match the return type of a gcc2
5416   builtin and then its argument prototype would still apply.  */
5417char dlopen ();
5418char (*f) ();
5419
5420int
5421main ()
5422{
5423/* The GNU C library defines this for functions which it implements
5424    to always fail with ENOSYS.  Some functions are actually named
5425    something starting with __ and the normal name is an alias.  */
5426#if defined (__stub_dlopen) || defined (__stub___dlopen)
5427choke me
5428#else
5429f = dlopen;
5430#endif
5431
5432  ;
5433  return 0;
5434}
5435_ACEOF
5436rm -f conftest.$ac_objext conftest$ac_exeext
5437if { (eval echo "$as_me:5437: \"$ac_link\"") >&5
5438  (eval $ac_link) 2>&5
5439  ac_status=$?
5440  echo "$as_me:5440: \$? = $ac_status" >&5
5441  (exit $ac_status); } &&
5442         { ac_try='test -s conftest$ac_exeext'
5443  { (eval echo "$as_me:5443: \"$ac_try\"") >&5
5444  (eval $ac_try) 2>&5
5445  ac_status=$?
5446  echo "$as_me:5446: \$? = $ac_status" >&5
5447  (exit $ac_status); }; }; then
5448  ac_cv_func_dlopen=yes
5449else
5450  echo "$as_me: failed program was:" >&5
5451cat conftest.$ac_ext >&5
5452ac_cv_func_dlopen=no
5453fi
5454rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5455fi
5456echo "$as_me:5456: result: $ac_cv_func_dlopen" >&5
5457echo "${ECHO_T}$ac_cv_func_dlopen" >&6
5458if test $ac_cv_func_dlopen = yes; then
5459  lt_cv_dlopen="dlopen"
5460else
5461  echo "$as_me:5461: checking for shl_load" >&5
5462echo $ECHO_N "checking for shl_load... $ECHO_C" >&6
5463if test "${ac_cv_func_shl_load+set}" = set; then
5464  echo $ECHO_N "(cached) $ECHO_C" >&6
5465else
5466  cat >conftest.$ac_ext <<_ACEOF
5467#line 5467 "configure"
5468#include "confdefs.h"
5469/* System header to define __stub macros and hopefully few prototypes,
5470    which can conflict with char shl_load (); below.  */
5471#include <assert.h>
5472/* Override any gcc2 internal prototype to avoid an error.  */
5473#ifdef __cplusplus
5474extern "C"
5475#endif
5476/* We use char because int might match the return type of a gcc2
5477   builtin and then its argument prototype would still apply.  */
5478char shl_load ();
5479char (*f) ();
5480
5481int
5482main ()
5483{
5484/* The GNU C library defines this for functions which it implements
5485    to always fail with ENOSYS.  Some functions are actually named
5486    something starting with __ and the normal name is an alias.  */
5487#if defined (__stub_shl_load) || defined (__stub___shl_load)
5488choke me
5489#else
5490f = shl_load;
5491#endif
5492
5493  ;
5494  return 0;
5495}
5496_ACEOF
5497rm -f conftest.$ac_objext conftest$ac_exeext
5498if { (eval echo "$as_me:5498: \"$ac_link\"") >&5
5499  (eval $ac_link) 2>&5
5500  ac_status=$?
5501  echo "$as_me:5501: \$? = $ac_status" >&5
5502  (exit $ac_status); } &&
5503         { ac_try='test -s conftest$ac_exeext'
5504  { (eval echo "$as_me:5504: \"$ac_try\"") >&5
5505  (eval $ac_try) 2>&5
5506  ac_status=$?
5507  echo "$as_me:5507: \$? = $ac_status" >&5
5508  (exit $ac_status); }; }; then
5509  ac_cv_func_shl_load=yes
5510else
5511  echo "$as_me: failed program was:" >&5
5512cat conftest.$ac_ext >&5
5513ac_cv_func_shl_load=no
5514fi
5515rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5516fi
5517echo "$as_me:5517: result: $ac_cv_func_shl_load" >&5
5518echo "${ECHO_T}$ac_cv_func_shl_load" >&6
5519if test $ac_cv_func_shl_load = yes; then
5520  lt_cv_dlopen="shl_load"
5521else
5522  echo "$as_me:5522: checking for dlopen in -lsvld" >&5
5523echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6
5524if test "${ac_cv_lib_svld_dlopen+set}" = set; then
5525  echo $ECHO_N "(cached) $ECHO_C" >&6
5526else
5527  ac_check_lib_save_LIBS=$LIBS
5528LIBS="-lsvld  $LIBS"
5529cat >conftest.$ac_ext <<_ACEOF
5530#line 5530 "configure"
5531#include "confdefs.h"
5532
5533/* Override any gcc2 internal prototype to avoid an error.  */
5534#ifdef __cplusplus
5535extern "C"
5536#endif
5537/* We use char because int might match the return type of a gcc2
5538   builtin and then its argument prototype would still apply.  */
5539char dlopen ();
5540int
5541main ()
5542{
5543dlopen ();
5544  ;
5545  return 0;
5546}
5547_ACEOF
5548rm -f conftest.$ac_objext conftest$ac_exeext
5549if { (eval echo "$as_me:5549: \"$ac_link\"") >&5
5550  (eval $ac_link) 2>&5
5551  ac_status=$?
5552  echo "$as_me:5552: \$? = $ac_status" >&5
5553  (exit $ac_status); } &&
5554         { ac_try='test -s conftest$ac_exeext'
5555  { (eval echo "$as_me:5555: \"$ac_try\"") >&5
5556  (eval $ac_try) 2>&5
5557  ac_status=$?
5558  echo "$as_me:5558: \$? = $ac_status" >&5
5559  (exit $ac_status); }; }; then
5560  ac_cv_lib_svld_dlopen=yes
5561else
5562  echo "$as_me: failed program was:" >&5
5563cat conftest.$ac_ext >&5
5564ac_cv_lib_svld_dlopen=no
5565fi
5566rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5567LIBS=$ac_check_lib_save_LIBS
5568fi
5569echo "$as_me:5569: result: $ac_cv_lib_svld_dlopen" >&5
5570echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6
5571if test $ac_cv_lib_svld_dlopen = yes; then
5572  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
5573else
5574  echo "$as_me:5574: checking for shl_load in -ldld" >&5
5575echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
5576if test "${ac_cv_lib_dld_shl_load+set}" = set; then
5577  echo $ECHO_N "(cached) $ECHO_C" >&6
5578else
5579  ac_check_lib_save_LIBS=$LIBS
5580LIBS="-ldld  $LIBS"
5581cat >conftest.$ac_ext <<_ACEOF
5582#line 5582 "configure"
5583#include "confdefs.h"
5584
5585/* Override any gcc2 internal prototype to avoid an error.  */
5586#ifdef __cplusplus
5587extern "C"
5588#endif
5589/* We use char because int might match the return type of a gcc2
5590   builtin and then its argument prototype would still apply.  */
5591char shl_load ();
5592int
5593main ()
5594{
5595shl_load ();
5596  ;
5597  return 0;
5598}
5599_ACEOF
5600rm -f conftest.$ac_objext conftest$ac_exeext
5601if { (eval echo "$as_me:5601: \"$ac_link\"") >&5
5602  (eval $ac_link) 2>&5
5603  ac_status=$?
5604  echo "$as_me:5604: \$? = $ac_status" >&5
5605  (exit $ac_status); } &&
5606         { ac_try='test -s conftest$ac_exeext'
5607  { (eval echo "$as_me:5607: \"$ac_try\"") >&5
5608  (eval $ac_try) 2>&5
5609  ac_status=$?
5610  echo "$as_me:5610: \$? = $ac_status" >&5
5611  (exit $ac_status); }; }; then
5612  ac_cv_lib_dld_shl_load=yes
5613else
5614  echo "$as_me: failed program was:" >&5
5615cat conftest.$ac_ext >&5
5616ac_cv_lib_dld_shl_load=no
5617fi
5618rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5619LIBS=$ac_check_lib_save_LIBS
5620fi
5621echo "$as_me:5621: result: $ac_cv_lib_dld_shl_load" >&5
5622echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
5623if test $ac_cv_lib_dld_shl_load = yes; then
5624  lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
5625fi
5626
5627fi
5628
5629fi
5630
5631fi
5632
5633fi
5634
5635    ;;
5636  esac
5637
5638  if test "x$lt_cv_dlopen" != xno; then
5639    enable_dlopen=yes
5640  else
5641    enable_dlopen=no
5642  fi
5643
5644  case $lt_cv_dlopen in
5645  dlopen)
5646    save_CPPFLAGS="$CPPFLAGS"
5647        test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
5648
5649    save_LDFLAGS="$LDFLAGS"
5650    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
5651
5652    save_LIBS="$LIBS"
5653    LIBS="$lt_cv_dlopen_libs $LIBS"
5654
5655    echo "$as_me:5655: checking whether a program can dlopen itself" >&5
5656echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6
5657if test "${lt_cv_dlopen_self+set}" = set; then
5658  echo $ECHO_N "(cached) $ECHO_C" >&6
5659else
5660  	  if test "$cross_compiling" = yes; then :
5661  lt_cv_dlopen_self=cross
5662else
5663    lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
5664  lt_status=$lt_dlunknown
5665  cat > conftest.$ac_ext <<EOF
5666#line 5666 "configure"
5667#include "confdefs.h"
5668
5669#if HAVE_DLFCN_H
5670#include <dlfcn.h>
5671#endif
5672
5673#include <stdio.h>
5674
5675#ifdef RTLD_GLOBAL
5676#  define LT_DLGLOBAL		RTLD_GLOBAL
5677#else
5678#  ifdef DL_GLOBAL
5679#    define LT_DLGLOBAL		DL_GLOBAL
5680#  else
5681#    define LT_DLGLOBAL		0
5682#  endif
5683#endif
5684
5685/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
5686   find out it does not work in some platform. */
5687#ifndef LT_DLLAZY_OR_NOW
5688#  ifdef RTLD_LAZY
5689#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
5690#  else
5691#    ifdef DL_LAZY
5692#      define LT_DLLAZY_OR_NOW		DL_LAZY
5693#    else
5694#      ifdef RTLD_NOW
5695#        define LT_DLLAZY_OR_NOW	RTLD_NOW
5696#      else
5697#        ifdef DL_NOW
5698#          define LT_DLLAZY_OR_NOW	DL_NOW
5699#        else
5700#          define LT_DLLAZY_OR_NOW	0
5701#        endif
5702#      endif
5703#    endif
5704#  endif
5705#endif
5706
5707#ifdef __cplusplus
5708extern "C" void exit (int);
5709#endif
5710
5711void fnord() { int i=42;}
5712int main ()
5713{
5714  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
5715  int status = $lt_dlunknown;
5716
5717  if (self)
5718    {
5719      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
5720      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
5721      /* dlclose (self); */
5722    }
5723
5724    exit (status);
5725}
5726EOF
5727  if { (eval echo "$as_me:5727: \"$ac_link\"") >&5
5728  (eval $ac_link) 2>&5
5729  ac_status=$?
5730  echo "$as_me:5730: \$? = $ac_status" >&5
5731  (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
5732    (./conftest; exit; ) 2>/dev/null
5733    lt_status=$?
5734    case x$lt_status in
5735      x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
5736      x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
5737      x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
5738    esac
5739  else :
5740    # compilation failed
5741    lt_cv_dlopen_self=no
5742  fi
5743fi
5744rm -fr conftest*
5745
5746fi
5747echo "$as_me:5747: result: $lt_cv_dlopen_self" >&5
5748echo "${ECHO_T}$lt_cv_dlopen_self" >&6
5749
5750    if test "x$lt_cv_dlopen_self" = xyes; then
5751      LDFLAGS="$LDFLAGS $link_static_flag"
5752      echo "$as_me:5752: checking whether a statically linked program can dlopen itself" >&5
5753echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6
5754if test "${lt_cv_dlopen_self_static+set}" = set; then
5755  echo $ECHO_N "(cached) $ECHO_C" >&6
5756else
5757  	  if test "$cross_compiling" = yes; then :
5758  lt_cv_dlopen_self_static=cross
5759else
5760    lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
5761  lt_status=$lt_dlunknown
5762  cat > conftest.$ac_ext <<EOF
5763#line 5763 "configure"
5764#include "confdefs.h"
5765
5766#if HAVE_DLFCN_H
5767#include <dlfcn.h>
5768#endif
5769
5770#include <stdio.h>
5771
5772#ifdef RTLD_GLOBAL
5773#  define LT_DLGLOBAL		RTLD_GLOBAL
5774#else
5775#  ifdef DL_GLOBAL
5776#    define LT_DLGLOBAL		DL_GLOBAL
5777#  else
5778#    define LT_DLGLOBAL		0
5779#  endif
5780#endif
5781
5782/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
5783   find out it does not work in some platform. */
5784#ifndef LT_DLLAZY_OR_NOW
5785#  ifdef RTLD_LAZY
5786#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
5787#  else
5788#    ifdef DL_LAZY
5789#      define LT_DLLAZY_OR_NOW		DL_LAZY
5790#    else
5791#      ifdef RTLD_NOW
5792#        define LT_DLLAZY_OR_NOW	RTLD_NOW
5793#      else
5794#        ifdef DL_NOW
5795#          define LT_DLLAZY_OR_NOW	DL_NOW
5796#        else
5797#          define LT_DLLAZY_OR_NOW	0
5798#        endif
5799#      endif
5800#    endif
5801#  endif
5802#endif
5803
5804#ifdef __cplusplus
5805extern "C" void exit (int);
5806#endif
5807
5808void fnord() { int i=42;}
5809int main ()
5810{
5811  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
5812  int status = $lt_dlunknown;
5813
5814  if (self)
5815    {
5816      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
5817      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
5818      /* dlclose (self); */
5819    }
5820
5821    exit (status);
5822}
5823EOF
5824  if { (eval echo "$as_me:5824: \"$ac_link\"") >&5
5825  (eval $ac_link) 2>&5
5826  ac_status=$?
5827  echo "$as_me:5827: \$? = $ac_status" >&5
5828  (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
5829    (./conftest; exit; ) 2>/dev/null
5830    lt_status=$?
5831    case x$lt_status in
5832      x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
5833      x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
5834      x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
5835    esac
5836  else :
5837    # compilation failed
5838    lt_cv_dlopen_self_static=no
5839  fi
5840fi
5841rm -fr conftest*
5842
5843fi
5844echo "$as_me:5844: result: $lt_cv_dlopen_self_static" >&5
5845echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6
5846    fi
5847
5848    CPPFLAGS="$save_CPPFLAGS"
5849    LDFLAGS="$save_LDFLAGS"
5850    LIBS="$save_LIBS"
5851    ;;
5852  esac
5853
5854  case $lt_cv_dlopen_self in
5855  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
5856  *) enable_dlopen_self=unknown ;;
5857  esac
5858
5859  case $lt_cv_dlopen_self_static in
5860  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
5861  *) enable_dlopen_self_static=unknown ;;
5862  esac
5863fi
5864
5865if test "$enable_shared" = yes && test "$GCC" = yes; then
5866  case $archive_cmds in
5867  *'~'*)
5868    # FIXME: we may have to deal with multi-command sequences.
5869    ;;
5870  '$CC '*)
5871    # Test whether the compiler implicitly links with -lc since on some
5872    # systems, -lgcc has to come before -lc. If gcc already passes -lc
5873    # to ld, don't add -lc before -lgcc.
5874    echo "$as_me:5874: checking whether -lc should be explicitly linked in" >&5
5875echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6
5876    if test "${lt_cv_archive_cmds_need_lc+set}" = set; then
5877  echo $ECHO_N "(cached) $ECHO_C" >&6
5878else
5879  $rm conftest*
5880    echo 'static int dummy;' > conftest.$ac_ext
5881
5882    if { (eval echo "$as_me:5882: \"$ac_compile\"") >&5
5883  (eval $ac_compile) 2>&5
5884  ac_status=$?
5885  echo "$as_me:5885: \$? = $ac_status" >&5
5886  (exit $ac_status); }; then
5887      soname=conftest
5888      lib=conftest
5889      libobjs=conftest.$ac_objext
5890      deplibs=
5891      wl=$lt_cv_prog_cc_wl
5892      compiler_flags=-v
5893      linker_flags=-v
5894      verstring=
5895      output_objdir=.
5896      libname=conftest
5897      save_allow_undefined_flag=$allow_undefined_flag
5898      allow_undefined_flag=
5899      if { (eval echo "$as_me:5899: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
5900  (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
5901  ac_status=$?
5902  echo "$as_me:5902: \$? = $ac_status" >&5
5903  (exit $ac_status); }
5904      then
5905	lt_cv_archive_cmds_need_lc=no
5906      else
5907	lt_cv_archive_cmds_need_lc=yes
5908      fi
5909      allow_undefined_flag=$save_allow_undefined_flag
5910    else
5911      cat conftest.err 1>&5
5912    fi
5913fi
5914
5915    echo "$as_me:5915: result: $lt_cv_archive_cmds_need_lc" >&5
5916echo "${ECHO_T}$lt_cv_archive_cmds_need_lc" >&6
5917    ;;
5918  esac
5919fi
5920need_lc=${lt_cv_archive_cmds_need_lc-yes}
5921
5922# The second clause should only fire when bootstrapping the
5923# libtool distribution, otherwise you forgot to ship ltmain.sh
5924# with your package, and you will get complaints that there are
5925# no rules to generate ltmain.sh.
5926if test -f "$ltmain"; then
5927  :
5928else
5929  # If there is no Makefile yet, we rely on a make rule to execute
5930  # `config.status --recheck' to rerun these tests and create the
5931  # libtool script then.
5932  test -f Makefile && make "$ltmain"
5933fi
5934
5935if test -f "$ltmain"; then
5936  trap "$rm \"${ofile}T\"; exit 1" 1 2 15
5937  $rm -f "${ofile}T"
5938
5939  echo creating $ofile
5940
5941  # Now quote all the things that may contain metacharacters while being
5942  # careful not to overquote the AC_SUBSTed values.  We take copies of the
5943  # variables and quote the copies for generation of the libtool script.
5944  for var in echo old_CC old_CFLAGS \
5945    AR AR_FLAGS CC LD LN_S NM SHELL \
5946    reload_flag reload_cmds wl \
5947    pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \
5948    thread_safe_flag_spec whole_archive_flag_spec libname_spec \
5949    library_names_spec soname_spec \
5950    RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \
5951    old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds \
5952    postuninstall_cmds extract_expsyms_cmds old_archive_from_expsyms_cmds \
5953    old_striplib striplib file_magic_cmd export_symbols_cmds \
5954    deplibs_check_method allow_undefined_flag no_undefined_flag \
5955    finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
5956    hardcode_libdir_flag_spec hardcode_libdir_separator  \
5957    sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
5958    compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
5959
5960    case $var in
5961    reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
5962    old_postinstall_cmds | old_postuninstall_cmds | \
5963    export_symbols_cmds | archive_cmds | archive_expsym_cmds | \
5964    extract_expsyms_cmds | old_archive_from_expsyms_cmds | \
5965    postinstall_cmds | postuninstall_cmds | \
5966    finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
5967      # Double-quote double-evaled strings.
5968      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
5969      ;;
5970    *)
5971      eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
5972      ;;
5973    esac
5974  done
5975
5976  cat <<__EOF__ > "${ofile}T"
5977#! $SHELL
5978
5979# `$echo "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
5980# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
5981# NOTE: Changes made to this file will be lost: look at ltmain.sh.
5982#
5983# Copyright (C) 1996-2000 Free Software Foundation, Inc.
5984# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
5985#
5986# This program is free software; you can redistribute it and/or modify
5987# it under the terms of the GNU General Public License as published by
5988# the Free Software Foundation; either version 2 of the License, or
5989# (at your option) any later version.
5990#
5991# This program is distributed in the hope that it will be useful, but
5992# WITHOUT ANY WARRANTY; without even the implied warranty of
5993# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
5994# General Public License for more details.
5995#
5996# You should have received a copy of the GNU General Public License
5997# along with this program; if not, write to the Free Software
5998# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
5999#
6000# As a special exception to the GNU General Public License, if you
6001# distribute this file as part of a program that contains a
6002# configuration script generated by Autoconf, you may include it under
6003# the same distribution terms that you use for the rest of that program.
6004
6005# Sed that helps us avoid accidentally triggering echo(1) options like -n.
6006Xsed="sed -e s/^X//"
6007
6008# The HP-UX ksh and POSIX shell print the target directory to stdout
6009# if CDPATH is set.
6010if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
6011
6012# ### BEGIN LIBTOOL CONFIG
6013
6014# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
6015
6016# Shell to use when invoking shell scripts.
6017SHELL=$lt_SHELL
6018
6019# Whether or not to build shared libraries.
6020build_libtool_libs=$enable_shared
6021
6022# Whether or not to add -lc for building shared libraries.
6023build_libtool_need_lc=$need_lc
6024
6025# Whether or not to build static libraries.
6026build_old_libs=$enable_static
6027
6028# Whether or not to optimize for fast installation.
6029fast_install=$enable_fast_install
6030
6031# The host system.
6032host_alias=$host_alias
6033host=$host
6034
6035# An echo program that does not interpret backslashes.
6036echo=$lt_echo
6037
6038# The archiver.
6039AR=$lt_AR
6040AR_FLAGS=$lt_AR_FLAGS
6041
6042# The default C compiler.
6043CC=$lt_CC
6044
6045# Is the compiler the GNU C compiler?
6046with_gcc=$GCC
6047
6048# The linker used to build libraries.
6049LD=$lt_LD
6050
6051# Whether we need hard or soft links.
6052LN_S=$lt_LN_S
6053
6054# A BSD-compatible nm program.
6055NM=$lt_NM
6056
6057# A symbol stripping program
6058STRIP=$STRIP
6059
6060# Used to examine libraries when file_magic_cmd begins "file"
6061MAGIC_CMD=$MAGIC_CMD
6062
6063# Used on cygwin: DLL creation program.
6064DLLTOOL="$DLLTOOL"
6065
6066# Used on cygwin: object dumper.
6067OBJDUMP="$OBJDUMP"
6068
6069# Used on cygwin: assembler.
6070AS="$AS"
6071
6072# The name of the directory that contains temporary libtool files.
6073objdir=$objdir
6074
6075# How to create reloadable object files.
6076reload_flag=$lt_reload_flag
6077reload_cmds=$lt_reload_cmds
6078
6079# How to pass a linker flag through the compiler.
6080wl=$lt_wl
6081
6082# Object file suffix (normally "o").
6083objext="$ac_objext"
6084
6085# Old archive suffix (normally "a").
6086libext="$libext"
6087
6088# Executable file suffix (normally "").
6089exeext="$exeext"
6090
6091# Additional compiler flags for building library objects.
6092pic_flag=$lt_pic_flag
6093pic_mode=$pic_mode
6094
6095# Does compiler simultaneously support -c and -o options?
6096compiler_c_o=$lt_compiler_c_o
6097
6098# Can we write directly to a .lo ?
6099compiler_o_lo=$lt_compiler_o_lo
6100
6101# Must we lock files when doing compilation ?
6102need_locks=$lt_need_locks
6103
6104# Do we need the lib prefix for modules?
6105need_lib_prefix=$need_lib_prefix
6106
6107# Do we need a version for libraries?
6108need_version=$need_version
6109
6110# Whether dlopen is supported.
6111dlopen_support=$enable_dlopen
6112
6113# Whether dlopen of programs is supported.
6114dlopen_self=$enable_dlopen_self
6115
6116# Whether dlopen of statically linked programs is supported.
6117dlopen_self_static=$enable_dlopen_self_static
6118
6119# Compiler flag to prevent dynamic linking.
6120link_static_flag=$lt_link_static_flag
6121
6122# Compiler flag to turn off builtin functions.
6123no_builtin_flag=$lt_no_builtin_flag
6124
6125# Compiler flag to allow reflexive dlopens.
6126export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
6127
6128# Compiler flag to generate shared objects directly from archives.
6129whole_archive_flag_spec=$lt_whole_archive_flag_spec
6130
6131# Compiler flag to generate thread-safe objects.
6132thread_safe_flag_spec=$lt_thread_safe_flag_spec
6133
6134# Library versioning type.
6135version_type=$version_type
6136
6137# Format of library name prefix.
6138libname_spec=$lt_libname_spec
6139
6140# List of archive names.  First name is the real one, the rest are links.
6141# The last name is the one that the linker finds with -lNAME.
6142library_names_spec=$lt_library_names_spec
6143
6144# The coded name of the library, if different from the real name.
6145soname_spec=$lt_soname_spec
6146
6147# Commands used to build and install an old-style archive.
6148RANLIB=$lt_RANLIB
6149old_archive_cmds=$lt_old_archive_cmds
6150old_postinstall_cmds=$lt_old_postinstall_cmds
6151old_postuninstall_cmds=$lt_old_postuninstall_cmds
6152
6153# Create an old-style archive from a shared archive.
6154old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
6155
6156# Create a temporary old-style archive to link instead of a shared archive.
6157old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
6158
6159# Commands used to build and install a shared archive.
6160archive_cmds=$lt_archive_cmds
6161archive_expsym_cmds=$lt_archive_expsym_cmds
6162postinstall_cmds=$lt_postinstall_cmds
6163postuninstall_cmds=$lt_postuninstall_cmds
6164
6165# Commands to strip libraries.
6166old_striplib=$lt_old_striplib
6167striplib=$lt_striplib
6168
6169# Method to check whether dependent libraries are shared objects.
6170deplibs_check_method=$lt_deplibs_check_method
6171
6172# Command to use when deplibs_check_method == file_magic.
6173file_magic_cmd=$lt_file_magic_cmd
6174
6175# Flag that allows shared libraries with undefined symbols to be built.
6176allow_undefined_flag=$lt_allow_undefined_flag
6177
6178# Flag that forces no undefined symbols.
6179no_undefined_flag=$lt_no_undefined_flag
6180
6181# Commands used to finish a libtool library installation in a directory.
6182finish_cmds=$lt_finish_cmds
6183
6184# Same as above, but a single script fragment to be evaled but not shown.
6185finish_eval=$lt_finish_eval
6186
6187# Take the output of nm and produce a listing of raw symbols and C names.
6188global_symbol_pipe=$lt_global_symbol_pipe
6189
6190# Transform the output of nm in a proper C declaration
6191global_symbol_to_cdecl=$lt_global_symbol_to_cdecl
6192
6193# This is the shared library runtime path variable.
6194runpath_var=$runpath_var
6195
6196# This is the shared library path variable.
6197shlibpath_var=$shlibpath_var
6198
6199# Is shlibpath searched before the hard-coded library search path?
6200shlibpath_overrides_runpath=$shlibpath_overrides_runpath
6201
6202# How to hardcode a shared library path into an executable.
6203hardcode_action=$hardcode_action
6204
6205# Whether we should hardcode library paths into libraries.
6206hardcode_into_libs=$hardcode_into_libs
6207
6208# Flag to hardcode \$libdir into a binary during linking.
6209# This must work even if \$libdir does not exist.
6210hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
6211
6212# Whether we need a single -rpath flag with a separated argument.
6213hardcode_libdir_separator=$lt_hardcode_libdir_separator
6214
6215# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
6216# resulting binary.
6217hardcode_direct=$hardcode_direct
6218
6219# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
6220# resulting binary.
6221hardcode_minus_L=$hardcode_minus_L
6222
6223# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
6224# the resulting binary.
6225hardcode_shlibpath_var=$hardcode_shlibpath_var
6226
6227# Variables whose values should be saved in libtool wrapper scripts and
6228# restored at relink time.
6229variables_saved_for_relink="$variables_saved_for_relink"
6230
6231# Whether libtool must link a program against all its dependency libraries.
6232link_all_deplibs=$link_all_deplibs
6233
6234# Compile-time system search path for libraries
6235sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
6236
6237# Run-time system search path for libraries
6238sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
6239
6240# Fix the shell variable \$srcfile for the compiler.
6241fix_srcfile_path="$fix_srcfile_path"
6242
6243# Set to yes if exported symbols are required.
6244always_export_symbols=$always_export_symbols
6245
6246# The commands to list exported symbols.
6247export_symbols_cmds=$lt_export_symbols_cmds
6248
6249# The commands to extract the exported symbol list from a shared archive.
6250extract_expsyms_cmds=$lt_extract_expsyms_cmds
6251
6252# Symbols that should not be listed in the preloaded symbols.
6253exclude_expsyms=$lt_exclude_expsyms
6254
6255# Symbols that must always be exported.
6256include_expsyms=$lt_include_expsyms
6257
6258# ### END LIBTOOL CONFIG
6259
6260__EOF__
6261
6262  case $host_os in
6263  aix3*)
6264    cat <<\EOF >> "${ofile}T"
6265
6266# AIX sometimes has problems with the GCC collect2 program.  For some
6267# reason, if we set the COLLECT_NAMES environment variable, the problems
6268# vanish in a puff of smoke.
6269if test "X${COLLECT_NAMES+set}" != Xset; then
6270  COLLECT_NAMES=
6271  export COLLECT_NAMES
6272fi
6273EOF
6274    ;;
6275  esac
6276
6277  case $host_os in
6278  cygwin* | mingw* | pw32* | os2*)
6279    cat <<'EOF' >> "${ofile}T"
6280      # This is a source program that is used to create dlls on Windows
6281      # Don't remove nor modify the starting and closing comments
6282# /* ltdll.c starts here */
6283# #define WIN32_LEAN_AND_MEAN
6284# #include <windows.h>
6285# #undef WIN32_LEAN_AND_MEAN
6286# #include <stdio.h>
6287#
6288# #ifndef __CYGWIN__
6289# #  ifdef __CYGWIN32__
6290# #    define __CYGWIN__ __CYGWIN32__
6291# #  endif
6292# #endif
6293#
6294# #ifdef __cplusplus
6295# extern "C" {
6296# #endif
6297# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
6298# #ifdef __cplusplus
6299# }
6300# #endif
6301#
6302# #ifdef __CYGWIN__
6303# #include <cygwin/cygwin_dll.h>
6304# DECLARE_CYGWIN_DLL( DllMain );
6305# #endif
6306# HINSTANCE __hDllInstance_base;
6307#
6308# BOOL APIENTRY
6309# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
6310# {
6311#   __hDllInstance_base = hInst;
6312#   return TRUE;
6313# }
6314# /* ltdll.c ends here */
6315        # This is a source program that is used to create import libraries
6316        # on Windows for dlls which lack them. Don't remove nor modify the
6317        # starting and closing comments
6318# /* impgen.c starts here */
6319# /*   Copyright (C) 1999-2000 Free Software Foundation, Inc.
6320#
6321#  This file is part of GNU libtool.
6322#
6323#  This program is free software; you can redistribute it and/or modify
6324#  it under the terms of the GNU General Public License as published by
6325#  the Free Software Foundation; either version 2 of the License, or
6326#  (at your option) any later version.
6327#
6328#  This program is distributed in the hope that it will be useful,
6329#  but WITHOUT ANY WARRANTY; without even the implied warranty of
6330#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
6331#  GNU General Public License for more details.
6332#
6333#  You should have received a copy of the GNU General Public License
6334#  along with this program; if not, write to the Free Software
6335#  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
6336#  */
6337#
6338# #include <stdio.h>		/* for printf() */
6339# #include <unistd.h>		/* for open(), lseek(), read() */
6340# #include <fcntl.h>		/* for O_RDONLY, O_BINARY */
6341# #include <string.h>		/* for strdup() */
6342#
6343# /* O_BINARY isn't required (or even defined sometimes) under Unix */
6344# #ifndef O_BINARY
6345# #define O_BINARY 0
6346# #endif
6347#
6348# static unsigned int
6349# pe_get16 (fd, offset)
6350#      int fd;
6351#      int offset;
6352# {
6353#   unsigned char b[2];
6354#   lseek (fd, offset, SEEK_SET);
6355#   read (fd, b, 2);
6356#   return b[0] + (b[1]<<8);
6357# }
6358#
6359# static unsigned int
6360# pe_get32 (fd, offset)
6361#     int fd;
6362#     int offset;
6363# {
6364#   unsigned char b[4];
6365#   lseek (fd, offset, SEEK_SET);
6366#   read (fd, b, 4);
6367#   return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
6368# }
6369#
6370# static unsigned int
6371# pe_as32 (ptr)
6372#      void *ptr;
6373# {
6374#   unsigned char *b = ptr;
6375#   return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
6376# }
6377#
6378# int
6379# main (argc, argv)
6380#     int argc;
6381#     char *argv[];
6382# {
6383#     int dll;
6384#     unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
6385#     unsigned long export_rva, export_size, nsections, secptr, expptr;
6386#     unsigned long name_rvas, nexp;
6387#     unsigned char *expdata, *erva;
6388#     char *filename, *dll_name;
6389#
6390#     filename = argv[1];
6391#
6392#     dll = open(filename, O_RDONLY|O_BINARY);
6393#     if (dll < 1)
6394# 	return 1;
6395#
6396#     dll_name = filename;
6397#
6398#     for (i=0; filename[i]; i++)
6399# 	if (filename[i] == '/' || filename[i] == '\\'  || filename[i] == ':')
6400# 	    dll_name = filename + i +1;
6401#
6402#     pe_header_offset = pe_get32 (dll, 0x3c);
6403#     opthdr_ofs = pe_header_offset + 4 + 20;
6404#     num_entries = pe_get32 (dll, opthdr_ofs + 92);
6405#
6406#     if (num_entries < 1) /* no exports */
6407# 	return 1;
6408#
6409#     export_rva = pe_get32 (dll, opthdr_ofs + 96);
6410#     export_size = pe_get32 (dll, opthdr_ofs + 100);
6411#     nsections = pe_get16 (dll, pe_header_offset + 4 +2);
6412#     secptr = (pe_header_offset + 4 + 20 +
6413# 	      pe_get16 (dll, pe_header_offset + 4 + 16));
6414#
6415#     expptr = 0;
6416#     for (i = 0; i < nsections; i++)
6417#     {
6418# 	char sname[8];
6419# 	unsigned long secptr1 = secptr + 40 * i;
6420# 	unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
6421# 	unsigned long vsize = pe_get32 (dll, secptr1 + 16);
6422# 	unsigned long fptr = pe_get32 (dll, secptr1 + 20);
6423# 	lseek(dll, secptr1, SEEK_SET);
6424# 	read(dll, sname, 8);
6425# 	if (vaddr <= export_rva && vaddr+vsize > export_rva)
6426# 	{
6427# 	    expptr = fptr + (export_rva - vaddr);
6428# 	    if (export_rva + export_size > vaddr + vsize)
6429# 		export_size = vsize - (export_rva - vaddr);
6430# 	    break;
6431# 	}
6432#     }
6433#
6434#     expdata = (unsigned char*)malloc(export_size);
6435#     lseek (dll, expptr, SEEK_SET);
6436#     read (dll, expdata, export_size);
6437#     erva = expdata - export_rva;
6438#
6439#     nexp = pe_as32 (expdata+24);
6440#     name_rvas = pe_as32 (expdata+32);
6441#
6442#     printf ("EXPORTS\n");
6443#     for (i = 0; i<nexp; i++)
6444#     {
6445# 	unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
6446# 	printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
6447#     }
6448#
6449#     return 0;
6450# }
6451# /* impgen.c ends here */
6452
6453EOF
6454    ;;
6455  esac
6456
6457  # We use sed instead of cat because bash on DJGPP gets confused if
6458  # if finds mixed CR/LF and LF-only lines.  Since sed operates in
6459  # text mode, it properly converts lines to CR/LF.  This bash problem
6460  # is reportedly fixed, but why not run on old versions too?
6461  sed '$q' "$ltmain" >> "${ofile}T" || (rm -f "${ofile}T"; exit 1)
6462
6463  mv -f "${ofile}T" "$ofile" || \
6464    (rm -f "$ofile" && cp "${ofile}T" "$ofile" && rm -f "${ofile}T")
6465  chmod +x "$ofile"
6466fi
6467
6468# This can be used to rebuild libtool when needed
6469LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
6470
6471# Always use our own libtool.
6472LIBTOOL='$(SHELL) $(top_builddir)/libtool'
6473
6474# Prevent multiple expansion
6475
6476if test -n "$ac_tool_prefix"; then
6477  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6478set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6479echo "$as_me:6479: checking for $ac_word" >&5
6480echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6481if test "${ac_cv_prog_RANLIB+set}" = set; then
6482  echo $ECHO_N "(cached) $ECHO_C" >&6
6483else
6484  if test -n "$RANLIB"; then
6485  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6486else
6487  ac_save_IFS=$IFS; IFS=$ac_path_separator
6488ac_dummy="$PATH"
6489for ac_dir in $ac_dummy; do
6490  IFS=$ac_save_IFS
6491  test -z "$ac_dir" && ac_dir=.
6492  $as_executable_p "$ac_dir/$ac_word" || continue
6493ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6494echo "$as_me:6494: found $ac_dir/$ac_word" >&5
6495break
6496done
6497
6498fi
6499fi
6500RANLIB=$ac_cv_prog_RANLIB
6501if test -n "$RANLIB"; then
6502  echo "$as_me:6502: result: $RANLIB" >&5
6503echo "${ECHO_T}$RANLIB" >&6
6504else
6505  echo "$as_me:6505: result: no" >&5
6506echo "${ECHO_T}no" >&6
6507fi
6508
6509fi
6510if test -z "$ac_cv_prog_RANLIB"; then
6511  ac_ct_RANLIB=$RANLIB
6512  # Extract the first word of "ranlib", so it can be a program name with args.
6513set dummy ranlib; ac_word=$2
6514echo "$as_me:6514: checking for $ac_word" >&5
6515echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
6516if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6517  echo $ECHO_N "(cached) $ECHO_C" >&6
6518else
6519  if test -n "$ac_ct_RANLIB"; then
6520  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6521else
6522  ac_save_IFS=$IFS; IFS=$ac_path_separator
6523ac_dummy="$PATH"
6524for ac_dir in $ac_dummy; do
6525  IFS=$ac_save_IFS
6526  test -z "$ac_dir" && ac_dir=.
6527  $as_executable_p "$ac_dir/$ac_word" || continue
6528ac_cv_prog_ac_ct_RANLIB="ranlib"
6529echo "$as_me:6529: found $ac_dir/$ac_word" >&5
6530break
6531done
6532
6533  test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
6534fi
6535fi
6536ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6537if test -n "$ac_ct_RANLIB"; then
6538  echo "$as_me:6538: result: $ac_ct_RANLIB" >&5
6539echo "${ECHO_T}$ac_ct_RANLIB" >&6
6540else
6541  echo "$as_me:6541: result: no" >&5
6542echo "${ECHO_T}no" >&6
6543fi
6544
6545  RANLIB=$ac_ct_RANLIB
6546else
6547  RANLIB="$ac_cv_prog_RANLIB"
6548fi
6549
6550# Find a good install program.  We prefer a C program (faster),
6551# so one script is as good as another.  But avoid the broken or
6552# incompatible versions:
6553# SysV /etc/install, /usr/sbin/install
6554# SunOS /usr/etc/install
6555# IRIX /sbin/install
6556# AIX /bin/install
6557# AmigaOS /C/install, which installs bootblocks on floppy discs
6558# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6559# AFS /usr/afsws/bin/install, which mishandles nonexistent args
6560# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6561# ./install, which can be erroneously created by make from ./install.sh.
6562echo "$as_me:6562: checking for a BSD compatible install" >&5
6563echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
6564if test -z "$INSTALL"; then
6565if test "${ac_cv_path_install+set}" = set; then
6566  echo $ECHO_N "(cached) $ECHO_C" >&6
6567else
6568    ac_save_IFS=$IFS; IFS=$ac_path_separator
6569  for ac_dir in $PATH; do
6570    IFS=$ac_save_IFS
6571    # Account for people who put trailing slashes in PATH elements.
6572    case $ac_dir/ in
6573    / | ./ | .// | /cC/* \
6574    | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* \
6575    | /usr/ucb/* ) ;;
6576    *)
6577      # OSF1 and SCO ODT 3.0 have their own names for install.
6578      # Don't use installbsd from OSF since it installs stuff as root
6579      # by default.
6580      for ac_prog in ginstall scoinst install; do
6581        if $as_executable_p "$ac_dir/$ac_prog"; then
6582	  if test $ac_prog = install &&
6583            grep dspmsg "$ac_dir/$ac_prog" >/dev/null 2>&1; then
6584	    # AIX install.  It has an incompatible calling convention.
6585	    :
6586	  elif test $ac_prog = install &&
6587	    grep pwplus "$ac_dir/$ac_prog" >/dev/null 2>&1; then
6588	    # program-specific install script used by HP pwplus--don't use.
6589	    :
6590	  else
6591	    ac_cv_path_install="$ac_dir/$ac_prog -c"
6592	    break 2
6593	  fi
6594	fi
6595      done
6596      ;;
6597    esac
6598  done
6599
6600fi
6601  if test "${ac_cv_path_install+set}" = set; then
6602    INSTALL=$ac_cv_path_install
6603  else
6604    # As a last resort, use the slow shell script.  We don't cache a
6605    # path for INSTALL within a source directory, because that will
6606    # break other packages using the cache if that directory is
6607    # removed, or if the path is relative.
6608    INSTALL=$ac_install_sh
6609  fi
6610fi
6611echo "$as_me:6611: result: $INSTALL" >&5
6612echo "${ECHO_T}$INSTALL" >&6
6613
6614# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
6615# It thinks the first close brace ends the variable substitution.
6616test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
6617
6618test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
6619
6620test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
6621
6622echo "$as_me:6622: checking for ANSI C header files" >&5
6623echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
6624if test "${ac_cv_header_stdc+set}" = set; then
6625  echo $ECHO_N "(cached) $ECHO_C" >&6
6626else
6627  cat >conftest.$ac_ext <<_ACEOF
6628#line 6628 "configure"
6629#include "confdefs.h"
6630#include <stdlib.h>
6631#include <stdarg.h>
6632#include <string.h>
6633#include <float.h>
6634
6635_ACEOF
6636if { (eval echo "$as_me:6636: \"$ac_cpp conftest.$ac_ext\"") >&5
6637  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6638  ac_status=$?
6639  egrep -v '^ *\+' conftest.er1 >conftest.err
6640  rm -f conftest.er1
6641  cat conftest.err >&5
6642  echo "$as_me:6642: \$? = $ac_status" >&5
6643  (exit $ac_status); } >/dev/null; then
6644  if test -s conftest.err; then
6645    ac_cpp_err=$ac_c_preproc_warn_flag
6646  else
6647    ac_cpp_err=
6648  fi
6649else
6650  ac_cpp_err=yes
6651fi
6652if test -z "$ac_cpp_err"; then
6653  ac_cv_header_stdc=yes
6654else
6655  echo "$as_me: failed program was:" >&5
6656  cat conftest.$ac_ext >&5
6657  ac_cv_header_stdc=no
6658fi
6659rm -f conftest.err conftest.$ac_ext
6660
6661if test $ac_cv_header_stdc = yes; then
6662  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6663  cat >conftest.$ac_ext <<_ACEOF
6664#line 6664 "configure"
6665#include "confdefs.h"
6666#include <string.h>
6667
6668_ACEOF
6669if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6670  egrep "memchr" >/dev/null 2>&1; then
6671  :
6672else
6673  ac_cv_header_stdc=no
6674fi
6675rm -f conftest*
6676
6677fi
6678
6679if test $ac_cv_header_stdc = yes; then
6680  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6681  cat >conftest.$ac_ext <<_ACEOF
6682#line 6682 "configure"
6683#include "confdefs.h"
6684#include <stdlib.h>
6685
6686_ACEOF
6687if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6688  egrep "free" >/dev/null 2>&1; then
6689  :
6690else
6691  ac_cv_header_stdc=no
6692fi
6693rm -f conftest*
6694
6695fi
6696
6697if test $ac_cv_header_stdc = yes; then
6698  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6699  if test "$cross_compiling" = yes; then
6700  :
6701else
6702  cat >conftest.$ac_ext <<_ACEOF
6703#line 6703 "configure"
6704#include "confdefs.h"
6705#include <ctype.h>
6706#if ((' ' & 0x0FF) == 0x020)
6707# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6708# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6709#else
6710# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
6711                     || ('j' <= (c) && (c) <= 'r') \
6712                     || ('s' <= (c) && (c) <= 'z'))
6713# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6714#endif
6715
6716#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6717int
6718main ()
6719{
6720  int i;
6721  for (i = 0; i < 256; i++)
6722    if (XOR (islower (i), ISLOWER (i))
6723        || toupper (i) != TOUPPER (i))
6724      exit(2);
6725  exit (0);
6726}
6727_ACEOF
6728rm -f conftest$ac_exeext
6729if { (eval echo "$as_me:6729: \"$ac_link\"") >&5
6730  (eval $ac_link) 2>&5
6731  ac_status=$?
6732  echo "$as_me:6732: \$? = $ac_status" >&5
6733  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6734  { (eval echo "$as_me:6734: \"$ac_try\"") >&5
6735  (eval $ac_try) 2>&5
6736  ac_status=$?
6737  echo "$as_me:6737: \$? = $ac_status" >&5
6738  (exit $ac_status); }; }; then
6739  :
6740else
6741  echo "$as_me: program exited with status $ac_status" >&5
6742echo "$as_me: failed program was:" >&5
6743cat conftest.$ac_ext >&5
6744ac_cv_header_stdc=no
6745fi
6746rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6747fi
6748fi
6749fi
6750echo "$as_me:6750: result: $ac_cv_header_stdc" >&5
6751echo "${ECHO_T}$ac_cv_header_stdc" >&6
6752if test $ac_cv_header_stdc = yes; then
6753
6754cat >>confdefs.h <<\EOF
6755#define STDC_HEADERS 1
6756EOF
6757
6758fi
6759
6760for ac_header in sys/time.h unistd.h
6761do
6762as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6763echo "$as_me:6763: checking for $ac_header" >&5
6764echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
6765if eval "test \"\${$as_ac_Header+set}\" = set"; then
6766  echo $ECHO_N "(cached) $ECHO_C" >&6
6767else
6768  cat >conftest.$ac_ext <<_ACEOF
6769#line 6769 "configure"
6770#include "confdefs.h"
6771#include <$ac_header>
6772_ACEOF
6773if { (eval echo "$as_me:6773: \"$ac_cpp conftest.$ac_ext\"") >&5
6774  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
6775  ac_status=$?
6776  egrep -v '^ *\+' conftest.er1 >conftest.err
6777  rm -f conftest.er1
6778  cat conftest.err >&5
6779  echo "$as_me:6779: \$? = $ac_status" >&5
6780  (exit $ac_status); } >/dev/null; then
6781  if test -s conftest.err; then
6782    ac_cpp_err=$ac_c_preproc_warn_flag
6783  else
6784    ac_cpp_err=
6785  fi
6786else
6787  ac_cpp_err=yes
6788fi
6789if test -z "$ac_cpp_err"; then
6790  eval "$as_ac_Header=yes"
6791else
6792  echo "$as_me: failed program was:" >&5
6793  cat conftest.$ac_ext >&5
6794  eval "$as_ac_Header=no"
6795fi
6796rm -f conftest.err conftest.$ac_ext
6797fi
6798echo "$as_me:6798: result: `eval echo '${'$as_ac_Header'}'`" >&5
6799echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
6800if test `eval echo '${'$as_ac_Header'}'` = yes; then
6801  cat >>confdefs.h <<EOF
6802#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
6803EOF
6804
6805fi
6806done
6807
6808echo "$as_me:6808: checking for $CC option to accept ANSI C" >&5
6809echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
6810if test "${ac_cv_prog_cc_stdc+set}" = set; then
6811  echo $ECHO_N "(cached) $ECHO_C" >&6
6812else
6813  ac_cv_prog_cc_stdc=no
6814ac_save_CC=$CC
6815cat >conftest.$ac_ext <<_ACEOF
6816#line 6816 "configure"
6817#include "confdefs.h"
6818#include <stdarg.h>
6819#include <stdio.h>
6820#include <sys/types.h>
6821#include <sys/stat.h>
6822/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
6823struct buf { int x; };
6824FILE * (*rcsopen) (struct buf *, struct stat *, int);
6825static char *e (p, i)
6826     char **p;
6827     int i;
6828{
6829  return p[i];
6830}
6831static char *f (char * (*g) (char **, int), char **p, ...)
6832{
6833  char *s;
6834  va_list v;
6835  va_start (v,p);
6836  s = g (p, va_arg (v,int));
6837  va_end (v);
6838  return s;
6839}
6840int test (int i, double x);
6841struct s1 {int (*f) (int a);};
6842struct s2 {int (*f) (double a);};
6843int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6844int argc;
6845char **argv;
6846int
6847main ()
6848{
6849return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
6850  ;
6851  return 0;
6852}
6853_ACEOF
6854# Don't try gcc -ansi; that turns off useful extensions and
6855# breaks some systems' header files.
6856# AIX			-qlanglvl=ansi
6857# Ultrix and OSF/1	-std1
6858# HP-UX 10.20 and later	-Ae
6859# HP-UX older versions	-Aa -D_HPUX_SOURCE
6860# SVR4			-Xc -D__EXTENSIONS__
6861for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6862do
6863  CC="$ac_save_CC $ac_arg"
6864  rm -f conftest.$ac_objext
6865if { (eval echo "$as_me:6865: \"$ac_compile\"") >&5
6866  (eval $ac_compile) 2>&5
6867  ac_status=$?
6868  echo "$as_me:6868: \$? = $ac_status" >&5
6869  (exit $ac_status); } &&
6870         { ac_try='test -s conftest.$ac_objext'
6871  { (eval echo "$as_me:6871: \"$ac_try\"") >&5
6872  (eval $ac_try) 2>&5
6873  ac_status=$?
6874  echo "$as_me:6874: \$? = $ac_status" >&5
6875  (exit $ac_status); }; }; then
6876  ac_cv_prog_cc_stdc=$ac_arg
6877break
6878else
6879  echo "$as_me: failed program was:" >&5
6880cat conftest.$ac_ext >&5
6881fi
6882rm -f conftest.$ac_objext
6883done
6884rm -f conftest.$ac_ext conftest.$ac_objext
6885CC=$ac_save_CC
6886
6887fi
6888
6889case "x$ac_cv_prog_cc_stdc" in
6890  x|xno)
6891    echo "$as_me:6891: result: none needed" >&5
6892echo "${ECHO_T}none needed" >&6 ;;
6893  *)
6894    echo "$as_me:6894: result: $ac_cv_prog_cc_stdc" >&5
6895echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
6896    CC="$CC $ac_cv_prog_cc_stdc" ;;
6897esac
6898
6899echo "$as_me:6899: checking for an ANSI C-conforming const" >&5
6900echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
6901if test "${ac_cv_c_const+set}" = set; then
6902  echo $ECHO_N "(cached) $ECHO_C" >&6
6903else
6904  cat >conftest.$ac_ext <<_ACEOF
6905#line 6905 "configure"
6906#include "confdefs.h"
6907
6908int
6909main ()
6910{
6911/* FIXME: Include the comments suggested by Paul. */
6912#ifndef __cplusplus
6913  /* Ultrix mips cc rejects this.  */
6914  typedef int charset[2];
6915  const charset x;
6916  /* SunOS 4.1.1 cc rejects this.  */
6917  char const *const *ccp;
6918  char **p;
6919  /* NEC SVR4.0.2 mips cc rejects this.  */
6920  struct point {int x, y;};
6921  static struct point const zero = {0,0};
6922  /* AIX XL C 1.02.0.0 rejects this.
6923     It does not let you subtract one const X* pointer from another in
6924     an arm of an if-expression whose if-part is not a constant
6925     expression */
6926  const char *g = "string";
6927  ccp = &g + (g ? g-g : 0);
6928  /* HPUX 7.0 cc rejects these. */
6929  ++ccp;
6930  p = (char**) ccp;
6931  ccp = (char const *const *) p;
6932  { /* SCO 3.2v4 cc rejects this.  */
6933    char *t;
6934    char const *s = 0 ? (char *) 0 : (char const *) 0;
6935
6936    *t++ = 0;
6937  }
6938  { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
6939    int x[] = {25, 17};
6940    const int *foo = &x[0];
6941    ++foo;
6942  }
6943  { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
6944    typedef const int *iptr;
6945    iptr p = 0;
6946    ++p;
6947  }
6948  { /* AIX XL C 1.02.0.0 rejects this saying
6949       "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
6950    struct s { int j; const int *ap[3]; };
6951    struct s *b; b->j = 5;
6952  }
6953  { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
6954    const int foo = 10;
6955  }
6956#endif
6957
6958  ;
6959  return 0;
6960}
6961_ACEOF
6962rm -f conftest.$ac_objext
6963if { (eval echo "$as_me:6963: \"$ac_compile\"") >&5
6964  (eval $ac_compile) 2>&5
6965  ac_status=$?
6966  echo "$as_me:6966: \$? = $ac_status" >&5
6967  (exit $ac_status); } &&
6968         { ac_try='test -s conftest.$ac_objext'
6969  { (eval echo "$as_me:6969: \"$ac_try\"") >&5
6970  (eval $ac_try) 2>&5
6971  ac_status=$?
6972  echo "$as_me:6972: \$? = $ac_status" >&5
6973  (exit $ac_status); }; }; then
6974  ac_cv_c_const=yes
6975else
6976  echo "$as_me: failed program was:" >&5
6977cat conftest.$ac_ext >&5
6978ac_cv_c_const=no
6979fi
6980rm -f conftest.$ac_objext conftest.$ac_ext
6981fi
6982echo "$as_me:6982: result: $ac_cv_c_const" >&5
6983echo "${ECHO_T}$ac_cv_c_const" >&6
6984if test $ac_cv_c_const = no; then
6985
6986cat >>confdefs.h <<\EOF
6987#define const
6988EOF
6989
6990fi
6991
6992echo "$as_me:6992: checking whether time.h and sys/time.h may both be included" >&5
6993echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
6994if test "${ac_cv_header_time+set}" = set; then
6995  echo $ECHO_N "(cached) $ECHO_C" >&6
6996else
6997  cat >conftest.$ac_ext <<_ACEOF
6998#line 6998 "configure"
6999#include "confdefs.h"
7000#include <sys/types.h>
7001#include <sys/time.h>
7002#include <time.h>
7003
7004int
7005main ()
7006{
7007if ((struct tm *) 0)
7008return 0;
7009  ;
7010  return 0;
7011}
7012_ACEOF
7013rm -f conftest.$ac_objext
7014if { (eval echo "$as_me:7014: \"$ac_compile\"") >&5
7015  (eval $ac_compile) 2>&5
7016  ac_status=$?
7017  echo "$as_me:7017: \$? = $ac_status" >&5
7018  (exit $ac_status); } &&
7019         { ac_try='test -s conftest.$ac_objext'
7020  { (eval echo "$as_me:7020: \"$ac_try\"") >&5
7021  (eval $ac_try) 2>&5
7022  ac_status=$?
7023  echo "$as_me:7023: \$? = $ac_status" >&5
7024  (exit $ac_status); }; }; then
7025  ac_cv_header_time=yes
7026else
7027  echo "$as_me: failed program was:" >&5
7028cat conftest.$ac_ext >&5
7029ac_cv_header_time=no
7030fi
7031rm -f conftest.$ac_objext conftest.$ac_ext
7032fi
7033echo "$as_me:7033: result: $ac_cv_header_time" >&5
7034echo "${ECHO_T}$ac_cv_header_time" >&6
7035if test $ac_cv_header_time = yes; then
7036
7037cat >>confdefs.h <<\EOF
7038#define TIME_WITH_SYS_TIME 1
7039EOF
7040
7041fi
7042
7043for ac_func in gettimeofday select usleep
7044do
7045as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
7046echo "$as_me:7046: checking for $ac_func" >&5
7047echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
7048if eval "test \"\${$as_ac_var+set}\" = set"; then
7049  echo $ECHO_N "(cached) $ECHO_C" >&6
7050else
7051  cat >conftest.$ac_ext <<_ACEOF
7052#line 7052 "configure"
7053#include "confdefs.h"
7054/* System header to define __stub macros and hopefully few prototypes,
7055    which can conflict with char $ac_func (); below.  */
7056#include <assert.h>
7057/* Override any gcc2 internal prototype to avoid an error.  */
7058#ifdef __cplusplus
7059extern "C"
7060#endif
7061/* We use char because int might match the return type of a gcc2
7062   builtin and then its argument prototype would still apply.  */
7063char $ac_func ();
7064char (*f) ();
7065
7066int
7067main ()
7068{
7069/* The GNU C library defines this for functions which it implements
7070    to always fail with ENOSYS.  Some functions are actually named
7071    something starting with __ and the normal name is an alias.  */
7072#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
7073choke me
7074#else
7075f = $ac_func;
7076#endif
7077
7078  ;
7079  return 0;
7080}
7081_ACEOF
7082rm -f conftest.$ac_objext conftest$ac_exeext
7083if { (eval echo "$as_me:7083: \"$ac_link\"") >&5
7084  (eval $ac_link) 2>&5
7085  ac_status=$?
7086  echo "$as_me:7086: \$? = $ac_status" >&5
7087  (exit $ac_status); } &&
7088         { ac_try='test -s conftest$ac_exeext'
7089  { (eval echo "$as_me:7089: \"$ac_try\"") >&5
7090  (eval $ac_try) 2>&5
7091  ac_status=$?
7092  echo "$as_me:7092: \$? = $ac_status" >&5
7093  (exit $ac_status); }; }; then
7094  eval "$as_ac_var=yes"
7095else
7096  echo "$as_me: failed program was:" >&5
7097cat conftest.$ac_ext >&5
7098eval "$as_ac_var=no"
7099fi
7100rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7101fi
7102echo "$as_me:7102: result: `eval echo '${'$as_ac_var'}'`" >&5
7103echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
7104if test `eval echo '${'$as_ac_var'}'` = yes; then
7105  cat >>confdefs.h <<EOF
7106#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
7107EOF
7108
7109fi
7110done
7111
7112echo "$as_me:7112: checking for FreeType" >&5
7113echo $ECHO_N "checking for FreeType... $ECHO_C" >&6
7114ac_ttf_includes=NO ac_ttf_libraries=NO
7115ttf_libraries=""
7116ttf_includes=""
7117
7118# Check whether --with-ttf-dir or --without-ttf-dir was given.
7119if test "${with_ttf_dir+set}" = set; then
7120  withval="$with_ttf_dir"
7121    ac_ttf_includes="$withval"/include
7122       ac_ttf_libraries="$withval"/lib
7123
7124fi;
7125
7126# Check whether --with-ttf-includes or --without-ttf-includes was given.
7127if test "${with_ttf_includes+set}" = set; then
7128  withval="$with_ttf_includes"
7129
7130       ac_ttf_includes="$withval"
7131
7132fi;
7133
7134# Check whether --with-ttf-libraries or --without-ttf-libraries was given.
7135if test "${with_ttf_libraries+set}" = set; then
7136  withval="$with_ttf_libraries"
7137    ac_ttf_libraries="$withval"
7138
7139fi;
7140
7141if test "$ac_ttf_includes" = NO || test "$ac_ttf_libraries" = NO; then
7142
7143if test "${ac_cv_have_ttf+set}" = set; then
7144  echo $ECHO_N "(cached) $ECHO_C" >&6
7145else
7146  #try to guess ttf locations
7147
7148ttf_incdirs="$ac_ttf_includes /usr/lib/freetype/include /usr/local/freetype/include /usr/include/freetype /usr/include/freetype1 /usr/include/freetype2 /usr/include /usr/local/include /usr/local/ttf $TTF_INC"
7149test -n "$TTFDIR" && ttf_incdirs="$TTFDIR/include $TTFDIR $ttf_incdirs"
7150
7151ttf_incdir=NO
7152for i in $ttf_incdirs;
7153do
7154  for j in freetype/freetype.h;
7155  do
7156    if test -r "$i/$j"; then
7157      ttf_incdir=$i
7158      break 2
7159    fi
7160  done
7161done
7162
7163ac_ttf_includes=$ttf_incdir
7164
7165ttf_libdirs="$ac_ttf_libraries /usr/lib/freetype/lib /usr/local/freetype/lib /usr/lib/freetype /usr/lib /usr/local/lib /usr/local/ttf/lib $TTFLIB"
7166test -n "$TTFDIR" && ttf_libdirs="$TTFDIR/lib $TTFDIR $ttf_libdirs"
7167
7168ttf_libdir=NO
7169for i in $ttf_libdirs;
7170do
7171  for j in libttf.so libttf.so.1.0.0 libttt.so.1 libttf.a libttf.sl;
7172  do
7173    if test -r "$i/$j"; then
7174      ttf_libdir=$i
7175      break 2
7176    fi
7177  done
7178done
7179
7180ac_ttf_libraries=$ttf_libdir
7181
7182ac_cxxflags_safe=$CXXFLAGS
7183ac_ldflags_safe=$LDFLAGS
7184ac_libs_safe=$LIBS
7185
7186CXXFLAGS="$CXXFLAGS -I$ttf_incdir"
7187LDFLAGS="-L$ttf_libdir"
7188LIBS="$LIBS -lttf"
7189
7190ac_ext=cc
7191ac_cpp='$CXXCPP $CPPFLAGS'
7192ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7193ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7194ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7195
7196cat > conftest.$ac_ext <<EOF
7197#include "confdefs.h"
7198#include "freetype/freetype.h"
7199int main() {
7200  TT_Engine engine;
7201  TT_Init_FreeType(&engine);
7202  return 0;
7203}
7204EOF
7205
7206if { (eval echo "$as_me:7206: \"$ac_link\"") >&5
7207  (eval $ac_link) 2>&5
7208  ac_status=$?
7209  echo "$as_me:7209: \$? = $ac_status" >&5
7210  (exit $ac_status); } && test -s conftest; then
7211  rm -f conftest*
7212else
7213  echo "configure: failed program was:" >&5
7214  cat conftest.$ac_ext >&5
7215  ac_ttf_libraries="NO"
7216fi
7217rm -f conftest*
7218CXXFLAGS=$ac_cxxflags_safe
7219LDFLAGS=$ac_ldflags_safe
7220LIBS=$ac_libs_safe
7221
7222# Don't give up just yet. Try freetype-config.
7223freetype_config_cflags="`freetype-config --cflags`"
7224freetype_config_libs="`freetype-config --libs`"
7225
7226CXXFLAGS="$CXXFLAGS $freetype_config_cflags"
7227LIBS="$LIBS $freetype_config_libs"
7228
7229ac_ext=cc
7230ac_cpp='$CXXCPP $CPPFLAGS'
7231ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7232ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7233ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7234
7235cat > conftest.$ac_ext <<EOF
7236#include "confdefs.h"
7237#include "freetype/freetype.h"
7238int main() {
7239  TT_Engine engine;
7240  TT_Init_FreeType(&engine);
7241  return 0;
7242}
7243EOF
7244
7245if { (eval echo "$as_me:7245: \"$ac_link\"") >&5
7246  (eval $ac_link) 2>&5
7247  ac_status=$?
7248  echo "$as_me:7248: \$? = $ac_status" >&5
7249  (exit $ac_status); } && test -s conftest; then
7250  rm -f conftest*
7251else
7252  echo "configure: failed program was:" >&5
7253  cat conftest.$ac_ext >&5
7254  freetype_config_works="NO"
7255fi
7256rm -f conftest*
7257CXXFLAGS=$ac_cxxflags_safe
7258LDFLAGS=$ac_ldflags_safe
7259LIBS=$ac_libs_safe
7260
7261if test "$freetype_config_works" = NO; then
7262  if test "$ac_ttf_includes" = NO || test "$ac_ttf_libraries" = NO; then
7263    ac_cv_have_ttf="have_ttf=no"
7264    ac_ttf_notfound=""
7265    if test "$ac_ttf_includes" = NO; then
7266      if test "$ac_ttf_libraries" = NO; then
7267        ac_ttf_notfound="(headers and libraries)";
7268      else
7269        ac_ttf_notfound="(headers)";
7270      fi
7271    else
7272      ac_ttf_notfound="(libraries)";
7273    fi
7274
7275    { { echo "$as_me:7275: error: FreeType $ac_ttf_notfound not found. Please check your installation! " >&5
7276echo "$as_me: error: FreeType $ac_ttf_notfound not found. Please check your installation! " >&2;}
7277   { (exit 1); exit 1; }; };
7278  else
7279    have_ttf="yes"
7280  fi
7281else
7282  have_ttf="yes"
7283fi
7284
7285fi
7286
7287else
7288  have_ttf="yes"
7289fi
7290
7291eval "$ac_cv_have_ttf"
7292
7293if test "$have_ttf" != yes; then
7294  echo "$as_me:7294: result: $have_ttf" >&5
7295echo "${ECHO_T}$have_ttf" >&6;
7296else
7297  ac_cv_have_ttf="have_ttf=yes \
7298    ac_ttf_includes=$ac_ttf_includes ac_ttf_libraries=$ac_ttf_libraries"
7299  echo "$as_me:7299: result: libraries $ac_ttf_libraries, headers $ac_ttf_includes" >&5
7300echo "${ECHO_T}libraries $ac_ttf_libraries, headers $ac_ttf_includes" >&6
7301
7302  ttf_libraries=$ac_ttf_libraries
7303  ttf_includes=$ac_ttf_includes
7304fi
7305
7306if test "$ttf_includes" = "$x_includes" || \
7307   test "$ttf_includes" = "/usr/include" || \
7308   test -z "$ttf_includes"; then
7309 TTF_INCLUDES="";
7310else
7311 TTF_INCLUDES="-I$ttf_includes"
7312 all_includes="$TTF_INCLUDES $all_includes"
7313fi
7314
7315if test "$ttf_libraries" = "$x_libraries" || \
7316   test "$ttf_libraries" = "/usr/lib" || \
7317   test "$ttf_libraries" = "/usr/local/lib" || \
7318   test -z "$ttf_libraries"; then
7319 TTF_LDFLAGS=""
7320else
7321 TTF_LDFLAGS="-L$ttf_libraries"
7322 all_libraries="$TTF_LDFLAGS $all_libraries"
7323fi
7324
7325if test "$freetype_config_works" != NO; then
7326  TTF_INCLUDES="$TTF_INCLUDES $freetype_config_cflags"
7327  TTF_LDFLAGS="$TTF_LDFLAGS $freetype_config_ldflags"
7328fi
7329
7330echo "$as_me:7330: checking for socket in -lsocket" >&5
7331echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6
7332if test "${ac_cv_lib_socket_socket+set}" = set; then
7333  echo $ECHO_N "(cached) $ECHO_C" >&6
7334else
7335  ac_check_lib_save_LIBS=$LIBS
7336LIBS="-lsocket  $LIBS"
7337cat >conftest.$ac_ext <<_ACEOF
7338#line 7338 "configure"
7339#include "confdefs.h"
7340
7341/* Override any gcc2 internal prototype to avoid an error.  */
7342#ifdef __cplusplus
7343extern "C"
7344#endif
7345/* We use char because int might match the return type of a gcc2
7346   builtin and then its argument prototype would still apply.  */
7347char socket ();
7348int
7349main ()
7350{
7351socket ();
7352  ;
7353  return 0;
7354}
7355_ACEOF
7356rm -f conftest.$ac_objext conftest$ac_exeext
7357if { (eval echo "$as_me:7357: \"$ac_link\"") >&5
7358  (eval $ac_link) 2>&5
7359  ac_status=$?
7360  echo "$as_me:7360: \$? = $ac_status" >&5
7361  (exit $ac_status); } &&
7362         { ac_try='test -s conftest$ac_exeext'
7363  { (eval echo "$as_me:7363: \"$ac_try\"") >&5
7364  (eval $ac_try) 2>&5
7365  ac_status=$?
7366  echo "$as_me:7366: \$? = $ac_status" >&5
7367  (exit $ac_status); }; }; then
7368  ac_cv_lib_socket_socket=yes
7369else
7370  echo "$as_me: failed program was:" >&5
7371cat conftest.$ac_ext >&5
7372ac_cv_lib_socket_socket=no
7373fi
7374rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7375LIBS=$ac_check_lib_save_LIBS
7376fi
7377echo "$as_me:7377: result: $ac_cv_lib_socket_socket" >&5
7378echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6
7379if test $ac_cv_lib_socket_socket = yes; then
7380  LIBSOCKET="-lsocket -lnsl"
7381fi
7382
7383echo "$as_me:7383: checking for killpg in -lucb" >&5
7384echo $ECHO_N "checking for killpg in -lucb... $ECHO_C" >&6
7385if test "${ac_cv_lib_ucb_killpg+set}" = set; then
7386  echo $ECHO_N "(cached) $ECHO_C" >&6
7387else
7388  ac_check_lib_save_LIBS=$LIBS
7389LIBS="-lucb  $LIBS"
7390cat >conftest.$ac_ext <<_ACEOF
7391#line 7391 "configure"
7392#include "confdefs.h"
7393
7394/* Override any gcc2 internal prototype to avoid an error.  */
7395#ifdef __cplusplus
7396extern "C"
7397#endif
7398/* We use char because int might match the return type of a gcc2
7399   builtin and then its argument prototype would still apply.  */
7400char killpg ();
7401int
7402main ()
7403{
7404killpg ();
7405  ;
7406  return 0;
7407}
7408_ACEOF
7409rm -f conftest.$ac_objext conftest$ac_exeext
7410if { (eval echo "$as_me:7410: \"$ac_link\"") >&5
7411  (eval $ac_link) 2>&5
7412  ac_status=$?
7413  echo "$as_me:7413: \$? = $ac_status" >&5
7414  (exit $ac_status); } &&
7415         { ac_try='test -s conftest$ac_exeext'
7416  { (eval echo "$as_me:7416: \"$ac_try\"") >&5
7417  (eval $ac_try) 2>&5
7418  ac_status=$?
7419  echo "$as_me:7419: \$? = $ac_status" >&5
7420  (exit $ac_status); }; }; then
7421  ac_cv_lib_ucb_killpg=yes
7422else
7423  echo "$as_me: failed program was:" >&5
7424cat conftest.$ac_ext >&5
7425ac_cv_lib_ucb_killpg=no
7426fi
7427rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7428LIBS=$ac_check_lib_save_LIBS
7429fi
7430echo "$as_me:7430: result: $ac_cv_lib_ucb_killpg" >&5
7431echo "${ECHO_T}$ac_cv_lib_ucb_killpg" >&6
7432if test $ac_cv_lib_ucb_killpg = yes; then
7433  LIBUCB="-lucb"
7434fi
7435
7436ac_ext=cc
7437ac_cpp='$CXXCPP $CPPFLAGS'
7438ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7439ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7440ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7441echo "$as_me:7441: checking how to run the C++ preprocessor" >&5
7442echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6
7443if test -z "$CXXCPP"; then
7444  if test "${ac_cv_prog_CXXCPP+set}" = set; then
7445  echo $ECHO_N "(cached) $ECHO_C" >&6
7446else
7447      # Double quotes because CXXCPP needs to be expanded
7448    for CXXCPP in "$CXX -E" "/lib/cpp"
7449    do
7450      ac_preproc_ok=false
7451for ac_cxx_preproc_warn_flag in '' yes
7452do
7453  # Use a header file that comes with gcc, so configuring glibc
7454  # with a fresh cross-compiler works.
7455  # On the NeXT, cc -E runs the code through the compiler's parser,
7456  # not just through cpp. "Syntax error" is here to catch this case.
7457  cat >conftest.$ac_ext <<_ACEOF
7458#line 7458 "configure"
7459#include "confdefs.h"
7460#include <assert.h>
7461                     Syntax error
7462_ACEOF
7463if { (eval echo "$as_me:7463: \"$ac_cpp conftest.$ac_ext\"") >&5
7464  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7465  ac_status=$?
7466  egrep -v '^ *\+' conftest.er1 >conftest.err
7467  rm -f conftest.er1
7468  cat conftest.err >&5
7469  echo "$as_me:7469: \$? = $ac_status" >&5
7470  (exit $ac_status); } >/dev/null; then
7471  if test -s conftest.err; then
7472    ac_cpp_err=$ac_cxx_preproc_warn_flag
7473  else
7474    ac_cpp_err=
7475  fi
7476else
7477  ac_cpp_err=yes
7478fi
7479if test -z "$ac_cpp_err"; then
7480  :
7481else
7482  echo "$as_me: failed program was:" >&5
7483  cat conftest.$ac_ext >&5
7484  # Broken: fails on valid input.
7485continue
7486fi
7487rm -f conftest.err conftest.$ac_ext
7488
7489  # OK, works on sane cases.  Now check whether non-existent headers
7490  # can be detected and how.
7491  cat >conftest.$ac_ext <<_ACEOF
7492#line 7492 "configure"
7493#include "confdefs.h"
7494#include <ac_nonexistent.h>
7495_ACEOF
7496if { (eval echo "$as_me:7496: \"$ac_cpp conftest.$ac_ext\"") >&5
7497  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7498  ac_status=$?
7499  egrep -v '^ *\+' conftest.er1 >conftest.err
7500  rm -f conftest.er1
7501  cat conftest.err >&5
7502  echo "$as_me:7502: \$? = $ac_status" >&5
7503  (exit $ac_status); } >/dev/null; then
7504  if test -s conftest.err; then
7505    ac_cpp_err=$ac_cxx_preproc_warn_flag
7506  else
7507    ac_cpp_err=
7508  fi
7509else
7510  ac_cpp_err=yes
7511fi
7512if test -z "$ac_cpp_err"; then
7513  # Broken: success on invalid input.
7514continue
7515else
7516  echo "$as_me: failed program was:" >&5
7517  cat conftest.$ac_ext >&5
7518  # Passes both tests.
7519ac_preproc_ok=:
7520break
7521fi
7522rm -f conftest.err conftest.$ac_ext
7523
7524done
7525# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7526rm -f conftest.err conftest.$ac_ext
7527if $ac_preproc_ok; then
7528  break
7529fi
7530
7531    done
7532    ac_cv_prog_CXXCPP=$CXXCPP
7533
7534fi
7535  CXXCPP=$ac_cv_prog_CXXCPP
7536else
7537  ac_cv_prog_CXXCPP=$CXXCPP
7538fi
7539echo "$as_me:7539: result: $CXXCPP" >&5
7540echo "${ECHO_T}$CXXCPP" >&6
7541ac_preproc_ok=false
7542for ac_cxx_preproc_warn_flag in '' yes
7543do
7544  # Use a header file that comes with gcc, so configuring glibc
7545  # with a fresh cross-compiler works.
7546  # On the NeXT, cc -E runs the code through the compiler's parser,
7547  # not just through cpp. "Syntax error" is here to catch this case.
7548  cat >conftest.$ac_ext <<_ACEOF
7549#line 7549 "configure"
7550#include "confdefs.h"
7551#include <assert.h>
7552                     Syntax error
7553_ACEOF
7554if { (eval echo "$as_me:7554: \"$ac_cpp conftest.$ac_ext\"") >&5
7555  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7556  ac_status=$?
7557  egrep -v '^ *\+' conftest.er1 >conftest.err
7558  rm -f conftest.er1
7559  cat conftest.err >&5
7560  echo "$as_me:7560: \$? = $ac_status" >&5
7561  (exit $ac_status); } >/dev/null; then
7562  if test -s conftest.err; then
7563    ac_cpp_err=$ac_cxx_preproc_warn_flag
7564  else
7565    ac_cpp_err=
7566  fi
7567else
7568  ac_cpp_err=yes
7569fi
7570if test -z "$ac_cpp_err"; then
7571  :
7572else
7573  echo "$as_me: failed program was:" >&5
7574  cat conftest.$ac_ext >&5
7575  # Broken: fails on valid input.
7576continue
7577fi
7578rm -f conftest.err conftest.$ac_ext
7579
7580  # OK, works on sane cases.  Now check whether non-existent headers
7581  # can be detected and how.
7582  cat >conftest.$ac_ext <<_ACEOF
7583#line 7583 "configure"
7584#include "confdefs.h"
7585#include <ac_nonexistent.h>
7586_ACEOF
7587if { (eval echo "$as_me:7587: \"$ac_cpp conftest.$ac_ext\"") >&5
7588  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7589  ac_status=$?
7590  egrep -v '^ *\+' conftest.er1 >conftest.err
7591  rm -f conftest.er1
7592  cat conftest.err >&5
7593  echo "$as_me:7593: \$? = $ac_status" >&5
7594  (exit $ac_status); } >/dev/null; then
7595  if test -s conftest.err; then
7596    ac_cpp_err=$ac_cxx_preproc_warn_flag
7597  else
7598    ac_cpp_err=
7599  fi
7600else
7601  ac_cpp_err=yes
7602fi
7603if test -z "$ac_cpp_err"; then
7604  # Broken: success on invalid input.
7605continue
7606else
7607  echo "$as_me: failed program was:" >&5
7608  cat conftest.$ac_ext >&5
7609  # Passes both tests.
7610ac_preproc_ok=:
7611break
7612fi
7613rm -f conftest.err conftest.$ac_ext
7614
7615done
7616# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7617rm -f conftest.err conftest.$ac_ext
7618if $ac_preproc_ok; then
7619  :
7620else
7621  { { echo "$as_me:7621: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&5
7622echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&2;}
7623   { (exit 1); exit 1; }; }
7624fi
7625
7626ac_ext=cc
7627ac_cpp='$CXXCPP $CPPFLAGS'
7628ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7629ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7630ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
7631
7632echo "$as_me:7632: checking for X" >&5
7633echo $ECHO_N "checking for X... $ECHO_C" >&6
7634
7635# Check whether --with-x or --without-x was given.
7636if test "${with_x+set}" = set; then
7637  withval="$with_x"
7638
7639fi;
7640# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
7641if test "x$with_x" = xno; then
7642  # The user explicitly disabled X.
7643  have_x=disabled
7644else
7645  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
7646    # Both variables are already set.
7647    have_x=yes
7648  else
7649    if test "${ac_cv_have_x+set}" = set; then
7650  echo $ECHO_N "(cached) $ECHO_C" >&6
7651else
7652  # One or both of the vars are not set, and there is no cached value.
7653ac_x_includes=no ac_x_libraries=no
7654rm -fr conftest.dir
7655if mkdir conftest.dir; then
7656  cd conftest.dir
7657  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
7658  cat >Imakefile <<'EOF'
7659acfindx:
7660	@echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
7661EOF
7662  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
7663    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
7664    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
7665    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
7666    for ac_extension in a so sl; do
7667      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
7668         test -f $ac_im_libdir/libX11.$ac_extension; then
7669        ac_im_usrlibdir=$ac_im_libdir; break
7670      fi
7671    done
7672    # Screen out bogus values from the imake configuration.  They are
7673    # bogus both because they are the default anyway, and because
7674    # using them would break gcc on systems where it needs fixed includes.
7675    case $ac_im_incroot in
7676	/usr/include) ;;
7677	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
7678    esac
7679    case $ac_im_usrlibdir in
7680	/usr/lib | /lib) ;;
7681	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
7682    esac
7683  fi
7684  cd ..
7685  rm -fr conftest.dir
7686fi
7687
7688# Standard set of common directories for X headers.
7689# Check X11 before X11Rn because it is often a symlink to the current release.
7690ac_x_header_dirs='
7691/usr/X11/include
7692/usr/X11R6/include
7693/usr/X11R5/include
7694/usr/X11R4/include
7695
7696/usr/include/X11
7697/usr/include/X11R6
7698/usr/include/X11R5
7699/usr/include/X11R4
7700
7701/usr/local/X11/include
7702/usr/local/X11R6/include
7703/usr/local/X11R5/include
7704/usr/local/X11R4/include
7705
7706/usr/local/include/X11
7707/usr/local/include/X11R6
7708/usr/local/include/X11R5
7709/usr/local/include/X11R4
7710
7711/usr/X386/include
7712/usr/x386/include
7713/usr/XFree86/include/X11
7714
7715/usr/include
7716/usr/local/include
7717/usr/unsupported/include
7718/usr/athena/include
7719/usr/local/x11r5/include
7720/usr/lpp/Xamples/include
7721
7722/usr/openwin/include
7723/usr/openwin/share/include'
7724
7725if test "$ac_x_includes" = no; then
7726  # Guess where to find include files, by looking for Intrinsic.h.
7727  # First, try using that file with no special directory specified.
7728  cat >conftest.$ac_ext <<_ACEOF
7729#line 7729 "configure"
7730#include "confdefs.h"
7731#include <X11/Intrinsic.h>
7732_ACEOF
7733if { (eval echo "$as_me:7733: \"$ac_cpp conftest.$ac_ext\"") >&5
7734  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7735  ac_status=$?
7736  egrep -v '^ *\+' conftest.er1 >conftest.err
7737  rm -f conftest.er1
7738  cat conftest.err >&5
7739  echo "$as_me:7739: \$? = $ac_status" >&5
7740  (exit $ac_status); } >/dev/null; then
7741  if test -s conftest.err; then
7742    ac_cpp_err=$ac_cxx_preproc_warn_flag
7743  else
7744    ac_cpp_err=
7745  fi
7746else
7747  ac_cpp_err=yes
7748fi
7749if test -z "$ac_cpp_err"; then
7750  # We can compile using X headers with no special include directory.
7751ac_x_includes=
7752else
7753  echo "$as_me: failed program was:" >&5
7754  cat conftest.$ac_ext >&5
7755  for ac_dir in $ac_x_header_dirs; do
7756  if test -r "$ac_dir/X11/Intrinsic.h"; then
7757    ac_x_includes=$ac_dir
7758    break
7759  fi
7760done
7761fi
7762rm -f conftest.err conftest.$ac_ext
7763fi # $ac_x_includes = no
7764
7765if test "$ac_x_libraries" = no; then
7766  # Check for the libraries.
7767  # See if we find them without any special options.
7768  # Don't add to $LIBS permanently.
7769  ac_save_LIBS=$LIBS
7770  LIBS="-lXt $LIBS"
7771  cat >conftest.$ac_ext <<_ACEOF
7772#line 7772 "configure"
7773#include "confdefs.h"
7774#include <X11/Intrinsic.h>
7775int
7776main ()
7777{
7778XtMalloc (0)
7779  ;
7780  return 0;
7781}
7782_ACEOF
7783rm -f conftest.$ac_objext conftest$ac_exeext
7784if { (eval echo "$as_me:7784: \"$ac_link\"") >&5
7785  (eval $ac_link) 2>&5
7786  ac_status=$?
7787  echo "$as_me:7787: \$? = $ac_status" >&5
7788  (exit $ac_status); } &&
7789         { ac_try='test -s conftest$ac_exeext'
7790  { (eval echo "$as_me:7790: \"$ac_try\"") >&5
7791  (eval $ac_try) 2>&5
7792  ac_status=$?
7793  echo "$as_me:7793: \$? = $ac_status" >&5
7794  (exit $ac_status); }; }; then
7795  LIBS=$ac_save_LIBS
7796# We can link X programs with no special library path.
7797ac_x_libraries=
7798else
7799  echo "$as_me: failed program was:" >&5
7800cat conftest.$ac_ext >&5
7801LIBS=$ac_save_LIBS
7802for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
7803do
7804  # Don't even attempt the hair of trying to link an X program!
7805  for ac_extension in a so sl; do
7806    if test -r $ac_dir/libXt.$ac_extension; then
7807      ac_x_libraries=$ac_dir
7808      break 2
7809    fi
7810  done
7811done
7812fi
7813rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7814fi # $ac_x_libraries = no
7815
7816if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
7817  # Didn't find X anywhere.  Cache the known absence of X.
7818  ac_cv_have_x="have_x=no"
7819else
7820  # Record where we found X for the cache.
7821  ac_cv_have_x="have_x=yes \
7822	        ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
7823fi
7824fi
7825
7826  fi
7827  eval "$ac_cv_have_x"
7828fi # $with_x != no
7829
7830if test "$have_x" != yes; then
7831  echo "$as_me:7831: result: $have_x" >&5
7832echo "${ECHO_T}$have_x" >&6
7833  no_x=yes
7834else
7835  # If each of the values was on the command line, it overrides each guess.
7836  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
7837  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
7838  # Update the cache value to reflect the command line values.
7839  ac_cv_have_x="have_x=yes \
7840		ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
7841  echo "$as_me:7841: result: libraries $x_libraries, headers $x_includes" >&5
7842echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
7843fi
7844
7845if test "$no_x" = yes; then
7846  # Not all programs may use this symbol, but it does not hurt to define it.
7847
7848cat >>confdefs.h <<\EOF
7849#define X_DISPLAY_MISSING 1
7850EOF
7851
7852  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
7853else
7854  if test -n "$x_includes"; then
7855    X_CFLAGS="$X_CFLAGS -I$x_includes"
7856  fi
7857
7858  # It would also be nice to do this for all -L options, not just this one.
7859  if test -n "$x_libraries"; then
7860    X_LIBS="$X_LIBS -L$x_libraries"
7861    # For Solaris; some versions of Sun CC require a space after -R and
7862    # others require no space.  Words are not sufficient . . . .
7863    case `(uname -sr) 2>/dev/null` in
7864    "SunOS 5"*)
7865      echo "$as_me:7865: checking whether -R must be followed by a space" >&5
7866echo $ECHO_N "checking whether -R must be followed by a space... $ECHO_C" >&6
7867      ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries"
7868      cat >conftest.$ac_ext <<_ACEOF
7869#line 7869 "configure"
7870#include "confdefs.h"
7871
7872int
7873main ()
7874{
7875
7876  ;
7877  return 0;
7878}
7879_ACEOF
7880rm -f conftest.$ac_objext conftest$ac_exeext
7881if { (eval echo "$as_me:7881: \"$ac_link\"") >&5
7882  (eval $ac_link) 2>&5
7883  ac_status=$?
7884  echo "$as_me:7884: \$? = $ac_status" >&5
7885  (exit $ac_status); } &&
7886         { ac_try='test -s conftest$ac_exeext'
7887  { (eval echo "$as_me:7887: \"$ac_try\"") >&5
7888  (eval $ac_try) 2>&5
7889  ac_status=$?
7890  echo "$as_me:7890: \$? = $ac_status" >&5
7891  (exit $ac_status); }; }; then
7892  ac_R_nospace=yes
7893else
7894  echo "$as_me: failed program was:" >&5
7895cat conftest.$ac_ext >&5
7896ac_R_nospace=no
7897fi
7898rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7899      if test $ac_R_nospace = yes; then
7900	echo "$as_me:7900: result: no" >&5
7901echo "${ECHO_T}no" >&6
7902	X_LIBS="$X_LIBS -R$x_libraries"
7903      else
7904	LIBS="$ac_xsave_LIBS -R $x_libraries"
7905	cat >conftest.$ac_ext <<_ACEOF
7906#line 7906 "configure"
7907#include "confdefs.h"
7908
7909int
7910main ()
7911{
7912
7913  ;
7914  return 0;
7915}
7916_ACEOF
7917rm -f conftest.$ac_objext conftest$ac_exeext
7918if { (eval echo "$as_me:7918: \"$ac_link\"") >&5
7919  (eval $ac_link) 2>&5
7920  ac_status=$?
7921  echo "$as_me:7921: \$? = $ac_status" >&5
7922  (exit $ac_status); } &&
7923         { ac_try='test -s conftest$ac_exeext'
7924  { (eval echo "$as_me:7924: \"$ac_try\"") >&5
7925  (eval $ac_try) 2>&5
7926  ac_status=$?
7927  echo "$as_me:7927: \$? = $ac_status" >&5
7928  (exit $ac_status); }; }; then
7929  ac_R_space=yes
7930else
7931  echo "$as_me: failed program was:" >&5
7932cat conftest.$ac_ext >&5
7933ac_R_space=no
7934fi
7935rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7936	if test $ac_R_space = yes; then
7937	  echo "$as_me:7937: result: yes" >&5
7938echo "${ECHO_T}yes" >&6
7939	  X_LIBS="$X_LIBS -R $x_libraries"
7940	else
7941	  echo "$as_me:7941: result: neither works" >&5
7942echo "${ECHO_T}neither works" >&6
7943	fi
7944      fi
7945      LIBS=$ac_xsave_LIBS
7946    esac
7947  fi
7948
7949  # Check for system-dependent libraries X programs must link with.
7950  # Do this before checking for the system-independent R6 libraries
7951  # (-lICE), since we may need -lsocket or whatever for X linking.
7952
7953  if test "$ISC" = yes; then
7954    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
7955  else
7956    # Martyn Johnson says this is needed for Ultrix, if the X
7957    # libraries were built with DECnet support.  And Karl Berry says
7958    # the Alpha needs dnet_stub (dnet does not exist).
7959    ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11"
7960    cat >conftest.$ac_ext <<_ACEOF
7961#line 7961 "configure"
7962#include "confdefs.h"
7963
7964/* Override any gcc2 internal prototype to avoid an error.  */
7965#ifdef __cplusplus
7966extern "C"
7967#endif
7968/* We use char because int might match the return type of a gcc2
7969   builtin and then its argument prototype would still apply.  */
7970char XOpenDisplay ();
7971int
7972main ()
7973{
7974XOpenDisplay ();
7975  ;
7976  return 0;
7977}
7978_ACEOF
7979rm -f conftest.$ac_objext conftest$ac_exeext
7980if { (eval echo "$as_me:7980: \"$ac_link\"") >&5
7981  (eval $ac_link) 2>&5
7982  ac_status=$?
7983  echo "$as_me:7983: \$? = $ac_status" >&5
7984  (exit $ac_status); } &&
7985         { ac_try='test -s conftest$ac_exeext'
7986  { (eval echo "$as_me:7986: \"$ac_try\"") >&5
7987  (eval $ac_try) 2>&5
7988  ac_status=$?
7989  echo "$as_me:7989: \$? = $ac_status" >&5
7990  (exit $ac_status); }; }; then
7991  :
7992else
7993  echo "$as_me: failed program was:" >&5
7994cat conftest.$ac_ext >&5
7995echo "$as_me:7995: checking for dnet_ntoa in -ldnet" >&5
7996echo $ECHO_N "checking for dnet_ntoa in -ldnet... $ECHO_C" >&6
7997if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then
7998  echo $ECHO_N "(cached) $ECHO_C" >&6
7999else
8000  ac_check_lib_save_LIBS=$LIBS
8001LIBS="-ldnet  $LIBS"
8002cat >conftest.$ac_ext <<_ACEOF
8003#line 8003 "configure"
8004#include "confdefs.h"
8005
8006/* Override any gcc2 internal prototype to avoid an error.  */
8007#ifdef __cplusplus
8008extern "C"
8009#endif
8010/* We use char because int might match the return type of a gcc2
8011   builtin and then its argument prototype would still apply.  */
8012char dnet_ntoa ();
8013int
8014main ()
8015{
8016dnet_ntoa ();
8017  ;
8018  return 0;
8019}
8020_ACEOF
8021rm -f conftest.$ac_objext conftest$ac_exeext
8022if { (eval echo "$as_me:8022: \"$ac_link\"") >&5
8023  (eval $ac_link) 2>&5
8024  ac_status=$?
8025  echo "$as_me:8025: \$? = $ac_status" >&5
8026  (exit $ac_status); } &&
8027         { ac_try='test -s conftest$ac_exeext'
8028  { (eval echo "$as_me:8028: \"$ac_try\"") >&5
8029  (eval $ac_try) 2>&5
8030  ac_status=$?
8031  echo "$as_me:8031: \$? = $ac_status" >&5
8032  (exit $ac_status); }; }; then
8033  ac_cv_lib_dnet_dnet_ntoa=yes
8034else
8035  echo "$as_me: failed program was:" >&5
8036cat conftest.$ac_ext >&5
8037ac_cv_lib_dnet_dnet_ntoa=no
8038fi
8039rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8040LIBS=$ac_check_lib_save_LIBS
8041fi
8042echo "$as_me:8042: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
8043echo "${ECHO_T}$ac_cv_lib_dnet_dnet_ntoa" >&6
8044if test $ac_cv_lib_dnet_dnet_ntoa = yes; then
8045  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
8046fi
8047
8048    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
8049      echo "$as_me:8049: checking for dnet_ntoa in -ldnet_stub" >&5
8050echo $ECHO_N "checking for dnet_ntoa in -ldnet_stub... $ECHO_C" >&6
8051if test "${ac_cv_lib_dnet_stub_dnet_ntoa+set}" = set; then
8052  echo $ECHO_N "(cached) $ECHO_C" >&6
8053else
8054  ac_check_lib_save_LIBS=$LIBS
8055LIBS="-ldnet_stub  $LIBS"
8056cat >conftest.$ac_ext <<_ACEOF
8057#line 8057 "configure"
8058#include "confdefs.h"
8059
8060/* Override any gcc2 internal prototype to avoid an error.  */
8061#ifdef __cplusplus
8062extern "C"
8063#endif
8064/* We use char because int might match the return type of a gcc2
8065   builtin and then its argument prototype would still apply.  */
8066char dnet_ntoa ();
8067int
8068main ()
8069{
8070dnet_ntoa ();
8071  ;
8072  return 0;
8073}
8074_ACEOF
8075rm -f conftest.$ac_objext conftest$ac_exeext
8076if { (eval echo "$as_me:8076: \"$ac_link\"") >&5
8077  (eval $ac_link) 2>&5
8078  ac_status=$?
8079  echo "$as_me:8079: \$? = $ac_status" >&5
8080  (exit $ac_status); } &&
8081         { ac_try='test -s conftest$ac_exeext'
8082  { (eval echo "$as_me:8082: \"$ac_try\"") >&5
8083  (eval $ac_try) 2>&5
8084  ac_status=$?
8085  echo "$as_me:8085: \$? = $ac_status" >&5
8086  (exit $ac_status); }; }; then
8087  ac_cv_lib_dnet_stub_dnet_ntoa=yes
8088else
8089  echo "$as_me: failed program was:" >&5
8090cat conftest.$ac_ext >&5
8091ac_cv_lib_dnet_stub_dnet_ntoa=no
8092fi
8093rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8094LIBS=$ac_check_lib_save_LIBS
8095fi
8096echo "$as_me:8096: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5
8097echo "${ECHO_T}$ac_cv_lib_dnet_stub_dnet_ntoa" >&6
8098if test $ac_cv_lib_dnet_stub_dnet_ntoa = yes; then
8099  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
8100fi
8101
8102    fi
8103fi
8104rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8105    LIBS="$ac_xsave_LIBS"
8106
8107    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
8108    # to get the SysV transport functions.
8109    # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4)
8110    # needs -lnsl.
8111    # The nsl library prevents programs from opening the X display
8112    # on Irix 5.2, according to T.E. Dickey.
8113    # The functions gethostbyname, getservbyname, and inet_addr are
8114    # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking.
8115    echo "$as_me:8115: checking for gethostbyname" >&5
8116echo $ECHO_N "checking for gethostbyname... $ECHO_C" >&6
8117if test "${ac_cv_func_gethostbyname+set}" = set; then
8118  echo $ECHO_N "(cached) $ECHO_C" >&6
8119else
8120  cat >conftest.$ac_ext <<_ACEOF
8121#line 8121 "configure"
8122#include "confdefs.h"
8123/* System header to define __stub macros and hopefully few prototypes,
8124    which can conflict with char gethostbyname (); below.  */
8125#include <assert.h>
8126/* Override any gcc2 internal prototype to avoid an error.  */
8127#ifdef __cplusplus
8128extern "C"
8129#endif
8130/* We use char because int might match the return type of a gcc2
8131   builtin and then its argument prototype would still apply.  */
8132char gethostbyname ();
8133char (*f) ();
8134
8135int
8136main ()
8137{
8138/* The GNU C library defines this for functions which it implements
8139    to always fail with ENOSYS.  Some functions are actually named
8140    something starting with __ and the normal name is an alias.  */
8141#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
8142choke me
8143#else
8144f = gethostbyname;
8145#endif
8146
8147  ;
8148  return 0;
8149}
8150_ACEOF
8151rm -f conftest.$ac_objext conftest$ac_exeext
8152if { (eval echo "$as_me:8152: \"$ac_link\"") >&5
8153  (eval $ac_link) 2>&5
8154  ac_status=$?
8155  echo "$as_me:8155: \$? = $ac_status" >&5
8156  (exit $ac_status); } &&
8157         { ac_try='test -s conftest$ac_exeext'
8158  { (eval echo "$as_me:8158: \"$ac_try\"") >&5
8159  (eval $ac_try) 2>&5
8160  ac_status=$?
8161  echo "$as_me:8161: \$? = $ac_status" >&5
8162  (exit $ac_status); }; }; then
8163  ac_cv_func_gethostbyname=yes
8164else
8165  echo "$as_me: failed program was:" >&5
8166cat conftest.$ac_ext >&5
8167ac_cv_func_gethostbyname=no
8168fi
8169rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8170fi
8171echo "$as_me:8171: result: $ac_cv_func_gethostbyname" >&5
8172echo "${ECHO_T}$ac_cv_func_gethostbyname" >&6
8173
8174    if test $ac_cv_func_gethostbyname = no; then
8175      echo "$as_me:8175: checking for gethostbyname in -lnsl" >&5
8176echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6
8177if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
8178  echo $ECHO_N "(cached) $ECHO_C" >&6
8179else
8180  ac_check_lib_save_LIBS=$LIBS
8181LIBS="-lnsl  $LIBS"
8182cat >conftest.$ac_ext <<_ACEOF
8183#line 8183 "configure"
8184#include "confdefs.h"
8185
8186/* Override any gcc2 internal prototype to avoid an error.  */
8187#ifdef __cplusplus
8188extern "C"
8189#endif
8190/* We use char because int might match the return type of a gcc2
8191   builtin and then its argument prototype would still apply.  */
8192char gethostbyname ();
8193int
8194main ()
8195{
8196gethostbyname ();
8197  ;
8198  return 0;
8199}
8200_ACEOF
8201rm -f conftest.$ac_objext conftest$ac_exeext
8202if { (eval echo "$as_me:8202: \"$ac_link\"") >&5
8203  (eval $ac_link) 2>&5
8204  ac_status=$?
8205  echo "$as_me:8205: \$? = $ac_status" >&5
8206  (exit $ac_status); } &&
8207         { ac_try='test -s conftest$ac_exeext'
8208  { (eval echo "$as_me:8208: \"$ac_try\"") >&5
8209  (eval $ac_try) 2>&5
8210  ac_status=$?
8211  echo "$as_me:8211: \$? = $ac_status" >&5
8212  (exit $ac_status); }; }; then
8213  ac_cv_lib_nsl_gethostbyname=yes
8214else
8215  echo "$as_me: failed program was:" >&5
8216cat conftest.$ac_ext >&5
8217ac_cv_lib_nsl_gethostbyname=no
8218fi
8219rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8220LIBS=$ac_check_lib_save_LIBS
8221fi
8222echo "$as_me:8222: result: $ac_cv_lib_nsl_gethostbyname" >&5
8223echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6
8224if test $ac_cv_lib_nsl_gethostbyname = yes; then
8225  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
8226fi
8227
8228      if test $ac_cv_lib_nsl_gethostbyname = no; then
8229        echo "$as_me:8229: checking for gethostbyname in -lbsd" >&5
8230echo $ECHO_N "checking for gethostbyname in -lbsd... $ECHO_C" >&6
8231if test "${ac_cv_lib_bsd_gethostbyname+set}" = set; then
8232  echo $ECHO_N "(cached) $ECHO_C" >&6
8233else
8234  ac_check_lib_save_LIBS=$LIBS
8235LIBS="-lbsd  $LIBS"
8236cat >conftest.$ac_ext <<_ACEOF
8237#line 8237 "configure"
8238#include "confdefs.h"
8239
8240/* Override any gcc2 internal prototype to avoid an error.  */
8241#ifdef __cplusplus
8242extern "C"
8243#endif
8244/* We use char because int might match the return type of a gcc2
8245   builtin and then its argument prototype would still apply.  */
8246char gethostbyname ();
8247int
8248main ()
8249{
8250gethostbyname ();
8251  ;
8252  return 0;
8253}
8254_ACEOF
8255rm -f conftest.$ac_objext conftest$ac_exeext
8256if { (eval echo "$as_me:8256: \"$ac_link\"") >&5
8257  (eval $ac_link) 2>&5
8258  ac_status=$?
8259  echo "$as_me:8259: \$? = $ac_status" >&5
8260  (exit $ac_status); } &&
8261         { ac_try='test -s conftest$ac_exeext'
8262  { (eval echo "$as_me:8262: \"$ac_try\"") >&5
8263  (eval $ac_try) 2>&5
8264  ac_status=$?
8265  echo "$as_me:8265: \$? = $ac_status" >&5
8266  (exit $ac_status); }; }; then
8267  ac_cv_lib_bsd_gethostbyname=yes
8268else
8269  echo "$as_me: failed program was:" >&5
8270cat conftest.$ac_ext >&5
8271ac_cv_lib_bsd_gethostbyname=no
8272fi
8273rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8274LIBS=$ac_check_lib_save_LIBS
8275fi
8276echo "$as_me:8276: result: $ac_cv_lib_bsd_gethostbyname" >&5
8277echo "${ECHO_T}$ac_cv_lib_bsd_gethostbyname" >&6
8278if test $ac_cv_lib_bsd_gethostbyname = yes; then
8279  X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd"
8280fi
8281
8282      fi
8283    fi
8284
8285    # lieder@skyler.mavd.honeywell.com says without -lsocket,
8286    # socket/setsockopt and other routines are undefined under SCO ODT
8287    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
8288    # on later versions), says Simon Leinen: it contains gethostby*
8289    # variants that don't use the nameserver (or something).  -lsocket
8290    # must be given before -lnsl if both are needed.  We assume that
8291    # if connect needs -lnsl, so does gethostbyname.
8292    echo "$as_me:8292: checking for connect" >&5
8293echo $ECHO_N "checking for connect... $ECHO_C" >&6
8294if test "${ac_cv_func_connect+set}" = set; then
8295  echo $ECHO_N "(cached) $ECHO_C" >&6
8296else
8297  cat >conftest.$ac_ext <<_ACEOF
8298#line 8298 "configure"
8299#include "confdefs.h"
8300/* System header to define __stub macros and hopefully few prototypes,
8301    which can conflict with char connect (); below.  */
8302#include <assert.h>
8303/* Override any gcc2 internal prototype to avoid an error.  */
8304#ifdef __cplusplus
8305extern "C"
8306#endif
8307/* We use char because int might match the return type of a gcc2
8308   builtin and then its argument prototype would still apply.  */
8309char connect ();
8310char (*f) ();
8311
8312int
8313main ()
8314{
8315/* The GNU C library defines this for functions which it implements
8316    to always fail with ENOSYS.  Some functions are actually named
8317    something starting with __ and the normal name is an alias.  */
8318#if defined (__stub_connect) || defined (__stub___connect)
8319choke me
8320#else
8321f = connect;
8322#endif
8323
8324  ;
8325  return 0;
8326}
8327_ACEOF
8328rm -f conftest.$ac_objext conftest$ac_exeext
8329if { (eval echo "$as_me:8329: \"$ac_link\"") >&5
8330  (eval $ac_link) 2>&5
8331  ac_status=$?
8332  echo "$as_me:8332: \$? = $ac_status" >&5
8333  (exit $ac_status); } &&
8334         { ac_try='test -s conftest$ac_exeext'
8335  { (eval echo "$as_me:8335: \"$ac_try\"") >&5
8336  (eval $ac_try) 2>&5
8337  ac_status=$?
8338  echo "$as_me:8338: \$? = $ac_status" >&5
8339  (exit $ac_status); }; }; then
8340  ac_cv_func_connect=yes
8341else
8342  echo "$as_me: failed program was:" >&5
8343cat conftest.$ac_ext >&5
8344ac_cv_func_connect=no
8345fi
8346rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8347fi
8348echo "$as_me:8348: result: $ac_cv_func_connect" >&5
8349echo "${ECHO_T}$ac_cv_func_connect" >&6
8350
8351    if test $ac_cv_func_connect = no; then
8352      echo "$as_me:8352: checking for connect in -lsocket" >&5
8353echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6
8354if test "${ac_cv_lib_socket_connect+set}" = set; then
8355  echo $ECHO_N "(cached) $ECHO_C" >&6
8356else
8357  ac_check_lib_save_LIBS=$LIBS
8358LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
8359cat >conftest.$ac_ext <<_ACEOF
8360#line 8360 "configure"
8361#include "confdefs.h"
8362
8363/* Override any gcc2 internal prototype to avoid an error.  */
8364#ifdef __cplusplus
8365extern "C"
8366#endif
8367/* We use char because int might match the return type of a gcc2
8368   builtin and then its argument prototype would still apply.  */
8369char connect ();
8370int
8371main ()
8372{
8373connect ();
8374  ;
8375  return 0;
8376}
8377_ACEOF
8378rm -f conftest.$ac_objext conftest$ac_exeext
8379if { (eval echo "$as_me:8379: \"$ac_link\"") >&5
8380  (eval $ac_link) 2>&5
8381  ac_status=$?
8382  echo "$as_me:8382: \$? = $ac_status" >&5
8383  (exit $ac_status); } &&
8384         { ac_try='test -s conftest$ac_exeext'
8385  { (eval echo "$as_me:8385: \"$ac_try\"") >&5
8386  (eval $ac_try) 2>&5
8387  ac_status=$?
8388  echo "$as_me:8388: \$? = $ac_status" >&5
8389  (exit $ac_status); }; }; then
8390  ac_cv_lib_socket_connect=yes
8391else
8392  echo "$as_me: failed program was:" >&5
8393cat conftest.$ac_ext >&5
8394ac_cv_lib_socket_connect=no
8395fi
8396rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8397LIBS=$ac_check_lib_save_LIBS
8398fi
8399echo "$as_me:8399: result: $ac_cv_lib_socket_connect" >&5
8400echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6
8401if test $ac_cv_lib_socket_connect = yes; then
8402  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
8403fi
8404
8405    fi
8406
8407    # Guillermo Gomez says -lposix is necessary on A/UX.
8408    echo "$as_me:8408: checking for remove" >&5
8409echo $ECHO_N "checking for remove... $ECHO_C" >&6
8410if test "${ac_cv_func_remove+set}" = set; then
8411  echo $ECHO_N "(cached) $ECHO_C" >&6
8412else
8413  cat >conftest.$ac_ext <<_ACEOF
8414#line 8414 "configure"
8415#include "confdefs.h"
8416/* System header to define __stub macros and hopefully few prototypes,
8417    which can conflict with char remove (); below.  */
8418#include <assert.h>
8419/* Override any gcc2 internal prototype to avoid an error.  */
8420#ifdef __cplusplus
8421extern "C"
8422#endif
8423/* We use char because int might match the return type of a gcc2
8424   builtin and then its argument prototype would still apply.  */
8425char remove ();
8426char (*f) ();
8427
8428int
8429main ()
8430{
8431/* The GNU C library defines this for functions which it implements
8432    to always fail with ENOSYS.  Some functions are actually named
8433    something starting with __ and the normal name is an alias.  */
8434#if defined (__stub_remove) || defined (__stub___remove)
8435choke me
8436#else
8437f = remove;
8438#endif
8439
8440  ;
8441  return 0;
8442}
8443_ACEOF
8444rm -f conftest.$ac_objext conftest$ac_exeext
8445if { (eval echo "$as_me:8445: \"$ac_link\"") >&5
8446  (eval $ac_link) 2>&5
8447  ac_status=$?
8448  echo "$as_me:8448: \$? = $ac_status" >&5
8449  (exit $ac_status); } &&
8450         { ac_try='test -s conftest$ac_exeext'
8451  { (eval echo "$as_me:8451: \"$ac_try\"") >&5
8452  (eval $ac_try) 2>&5
8453  ac_status=$?
8454  echo "$as_me:8454: \$? = $ac_status" >&5
8455  (exit $ac_status); }; }; then
8456  ac_cv_func_remove=yes
8457else
8458  echo "$as_me: failed program was:" >&5
8459cat conftest.$ac_ext >&5
8460ac_cv_func_remove=no
8461fi
8462rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8463fi
8464echo "$as_me:8464: result: $ac_cv_func_remove" >&5
8465echo "${ECHO_T}$ac_cv_func_remove" >&6
8466
8467    if test $ac_cv_func_remove = no; then
8468      echo "$as_me:8468: checking for remove in -lposix" >&5
8469echo $ECHO_N "checking for remove in -lposix... $ECHO_C" >&6
8470if test "${ac_cv_lib_posix_remove+set}" = set; then
8471  echo $ECHO_N "(cached) $ECHO_C" >&6
8472else
8473  ac_check_lib_save_LIBS=$LIBS
8474LIBS="-lposix  $LIBS"
8475cat >conftest.$ac_ext <<_ACEOF
8476#line 8476 "configure"
8477#include "confdefs.h"
8478
8479/* Override any gcc2 internal prototype to avoid an error.  */
8480#ifdef __cplusplus
8481extern "C"
8482#endif
8483/* We use char because int might match the return type of a gcc2
8484   builtin and then its argument prototype would still apply.  */
8485char remove ();
8486int
8487main ()
8488{
8489remove ();
8490  ;
8491  return 0;
8492}
8493_ACEOF
8494rm -f conftest.$ac_objext conftest$ac_exeext
8495if { (eval echo "$as_me:8495: \"$ac_link\"") >&5
8496  (eval $ac_link) 2>&5
8497  ac_status=$?
8498  echo "$as_me:8498: \$? = $ac_status" >&5
8499  (exit $ac_status); } &&
8500         { ac_try='test -s conftest$ac_exeext'
8501  { (eval echo "$as_me:8501: \"$ac_try\"") >&5
8502  (eval $ac_try) 2>&5
8503  ac_status=$?
8504  echo "$as_me:8504: \$? = $ac_status" >&5
8505  (exit $ac_status); }; }; then
8506  ac_cv_lib_posix_remove=yes
8507else
8508  echo "$as_me: failed program was:" >&5
8509cat conftest.$ac_ext >&5
8510ac_cv_lib_posix_remove=no
8511fi
8512rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8513LIBS=$ac_check_lib_save_LIBS
8514fi
8515echo "$as_me:8515: result: $ac_cv_lib_posix_remove" >&5
8516echo "${ECHO_T}$ac_cv_lib_posix_remove" >&6
8517if test $ac_cv_lib_posix_remove = yes; then
8518  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
8519fi
8520
8521    fi
8522
8523    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
8524    echo "$as_me:8524: checking for shmat" >&5
8525echo $ECHO_N "checking for shmat... $ECHO_C" >&6
8526if test "${ac_cv_func_shmat+set}" = set; then
8527  echo $ECHO_N "(cached) $ECHO_C" >&6
8528else
8529  cat >conftest.$ac_ext <<_ACEOF
8530#line 8530 "configure"
8531#include "confdefs.h"
8532/* System header to define __stub macros and hopefully few prototypes,
8533    which can conflict with char shmat (); below.  */
8534#include <assert.h>
8535/* Override any gcc2 internal prototype to avoid an error.  */
8536#ifdef __cplusplus
8537extern "C"
8538#endif
8539/* We use char because int might match the return type of a gcc2
8540   builtin and then its argument prototype would still apply.  */
8541char shmat ();
8542char (*f) ();
8543
8544int
8545main ()
8546{
8547/* The GNU C library defines this for functions which it implements
8548    to always fail with ENOSYS.  Some functions are actually named
8549    something starting with __ and the normal name is an alias.  */
8550#if defined (__stub_shmat) || defined (__stub___shmat)
8551choke me
8552#else
8553f = shmat;
8554#endif
8555
8556  ;
8557  return 0;
8558}
8559_ACEOF
8560rm -f conftest.$ac_objext conftest$ac_exeext
8561if { (eval echo "$as_me:8561: \"$ac_link\"") >&5
8562  (eval $ac_link) 2>&5
8563  ac_status=$?
8564  echo "$as_me:8564: \$? = $ac_status" >&5
8565  (exit $ac_status); } &&
8566         { ac_try='test -s conftest$ac_exeext'
8567  { (eval echo "$as_me:8567: \"$ac_try\"") >&5
8568  (eval $ac_try) 2>&5
8569  ac_status=$?
8570  echo "$as_me:8570: \$? = $ac_status" >&5
8571  (exit $ac_status); }; }; then
8572  ac_cv_func_shmat=yes
8573else
8574  echo "$as_me: failed program was:" >&5
8575cat conftest.$ac_ext >&5
8576ac_cv_func_shmat=no
8577fi
8578rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8579fi
8580echo "$as_me:8580: result: $ac_cv_func_shmat" >&5
8581echo "${ECHO_T}$ac_cv_func_shmat" >&6
8582
8583    if test $ac_cv_func_shmat = no; then
8584      echo "$as_me:8584: checking for shmat in -lipc" >&5
8585echo $ECHO_N "checking for shmat in -lipc... $ECHO_C" >&6
8586if test "${ac_cv_lib_ipc_shmat+set}" = set; then
8587  echo $ECHO_N "(cached) $ECHO_C" >&6
8588else
8589  ac_check_lib_save_LIBS=$LIBS
8590LIBS="-lipc  $LIBS"
8591cat >conftest.$ac_ext <<_ACEOF
8592#line 8592 "configure"
8593#include "confdefs.h"
8594
8595/* Override any gcc2 internal prototype to avoid an error.  */
8596#ifdef __cplusplus
8597extern "C"
8598#endif
8599/* We use char because int might match the return type of a gcc2
8600   builtin and then its argument prototype would still apply.  */
8601char shmat ();
8602int
8603main ()
8604{
8605shmat ();
8606  ;
8607  return 0;
8608}
8609_ACEOF
8610rm -f conftest.$ac_objext conftest$ac_exeext
8611if { (eval echo "$as_me:8611: \"$ac_link\"") >&5
8612  (eval $ac_link) 2>&5
8613  ac_status=$?
8614  echo "$as_me:8614: \$? = $ac_status" >&5
8615  (exit $ac_status); } &&
8616         { ac_try='test -s conftest$ac_exeext'
8617  { (eval echo "$as_me:8617: \"$ac_try\"") >&5
8618  (eval $ac_try) 2>&5
8619  ac_status=$?
8620  echo "$as_me:8620: \$? = $ac_status" >&5
8621  (exit $ac_status); }; }; then
8622  ac_cv_lib_ipc_shmat=yes
8623else
8624  echo "$as_me: failed program was:" >&5
8625cat conftest.$ac_ext >&5
8626ac_cv_lib_ipc_shmat=no
8627fi
8628rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8629LIBS=$ac_check_lib_save_LIBS
8630fi
8631echo "$as_me:8631: result: $ac_cv_lib_ipc_shmat" >&5
8632echo "${ECHO_T}$ac_cv_lib_ipc_shmat" >&6
8633if test $ac_cv_lib_ipc_shmat = yes; then
8634  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
8635fi
8636
8637    fi
8638  fi
8639
8640  # Check for libraries that X11R6 Xt/Xaw programs need.
8641  ac_save_LDFLAGS=$LDFLAGS
8642  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
8643  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
8644  # check for ICE first), but we must link in the order -lSM -lICE or
8645  # we get undefined symbols.  So assume we have SM if we have ICE.
8646  # These have to be linked with before -lX11, unlike the other
8647  # libraries we check for below, so use a different variable.
8648  # John Interrante, Karl Berry
8649  echo "$as_me:8649: checking for IceConnectionNumber in -lICE" >&5
8650echo $ECHO_N "checking for IceConnectionNumber in -lICE... $ECHO_C" >&6
8651if test "${ac_cv_lib_ICE_IceConnectionNumber+set}" = set; then
8652  echo $ECHO_N "(cached) $ECHO_C" >&6
8653else
8654  ac_check_lib_save_LIBS=$LIBS
8655LIBS="-lICE $X_EXTRA_LIBS $LIBS"
8656cat >conftest.$ac_ext <<_ACEOF
8657#line 8657 "configure"
8658#include "confdefs.h"
8659
8660/* Override any gcc2 internal prototype to avoid an error.  */
8661#ifdef __cplusplus
8662extern "C"
8663#endif
8664/* We use char because int might match the return type of a gcc2
8665   builtin and then its argument prototype would still apply.  */
8666char IceConnectionNumber ();
8667int
8668main ()
8669{
8670IceConnectionNumber ();
8671  ;
8672  return 0;
8673}
8674_ACEOF
8675rm -f conftest.$ac_objext conftest$ac_exeext
8676if { (eval echo "$as_me:8676: \"$ac_link\"") >&5
8677  (eval $ac_link) 2>&5
8678  ac_status=$?
8679  echo "$as_me:8679: \$? = $ac_status" >&5
8680  (exit $ac_status); } &&
8681         { ac_try='test -s conftest$ac_exeext'
8682  { (eval echo "$as_me:8682: \"$ac_try\"") >&5
8683  (eval $ac_try) 2>&5
8684  ac_status=$?
8685  echo "$as_me:8685: \$? = $ac_status" >&5
8686  (exit $ac_status); }; }; then
8687  ac_cv_lib_ICE_IceConnectionNumber=yes
8688else
8689  echo "$as_me: failed program was:" >&5
8690cat conftest.$ac_ext >&5
8691ac_cv_lib_ICE_IceConnectionNumber=no
8692fi
8693rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8694LIBS=$ac_check_lib_save_LIBS
8695fi
8696echo "$as_me:8696: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5
8697echo "${ECHO_T}$ac_cv_lib_ICE_IceConnectionNumber" >&6
8698if test $ac_cv_lib_ICE_IceConnectionNumber = yes; then
8699  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
8700fi
8701
8702  LDFLAGS=$ac_save_LDFLAGS
8703
8704fi
8705
8706echo "$as_me:8706: checking for X" >&5
8707echo $ECHO_N "checking for X... $ECHO_C" >&6
8708if test "${ac_cv_have_x+set}" = set; then
8709  echo $ECHO_N "(cached) $ECHO_C" >&6
8710else
8711  # One or both of the vars are not set, and there is no cached value.
8712ac_x_includes=NO ac_x_libraries=NO
8713echo "$as_me:8713: checking for X" >&5
8714echo $ECHO_N "checking for X... $ECHO_C" >&6
8715
8716# Check whether --with-x or --without-x was given.
8717if test "${with_x+set}" = set; then
8718  withval="$with_x"
8719
8720fi;
8721# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
8722if test "x$with_x" = xno; then
8723  # The user explicitly disabled X.
8724  have_x=disabled
8725else
8726  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
8727    # Both variables are already set.
8728    have_x=yes
8729  else
8730    if test "${ac_cv_have_x+set}" = set; then
8731  echo $ECHO_N "(cached) $ECHO_C" >&6
8732else
8733  # One or both of the vars are not set, and there is no cached value.
8734ac_x_includes=no ac_x_libraries=no
8735rm -fr conftest.dir
8736if mkdir conftest.dir; then
8737  cd conftest.dir
8738  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
8739  cat >Imakefile <<'EOF'
8740acfindx:
8741	@echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
8742EOF
8743  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
8744    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
8745    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
8746    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
8747    for ac_extension in a so sl; do
8748      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
8749         test -f $ac_im_libdir/libX11.$ac_extension; then
8750        ac_im_usrlibdir=$ac_im_libdir; break
8751      fi
8752    done
8753    # Screen out bogus values from the imake configuration.  They are
8754    # bogus both because they are the default anyway, and because
8755    # using them would break gcc on systems where it needs fixed includes.
8756    case $ac_im_incroot in
8757	/usr/include) ;;
8758	*) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
8759    esac
8760    case $ac_im_usrlibdir in
8761	/usr/lib | /lib) ;;
8762	*) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
8763    esac
8764  fi
8765  cd ..
8766  rm -fr conftest.dir
8767fi
8768
8769# Standard set of common directories for X headers.
8770# Check X11 before X11Rn because it is often a symlink to the current release.
8771ac_x_header_dirs='
8772/usr/X11/include
8773/usr/X11R6/include
8774/usr/X11R5/include
8775/usr/X11R4/include
8776
8777/usr/include/X11
8778/usr/include/X11R6
8779/usr/include/X11R5
8780/usr/include/X11R4
8781
8782/usr/local/X11/include
8783/usr/local/X11R6/include
8784/usr/local/X11R5/include
8785/usr/local/X11R4/include
8786
8787/usr/local/include/X11
8788/usr/local/include/X11R6
8789/usr/local/include/X11R5
8790/usr/local/include/X11R4
8791
8792/usr/X386/include
8793/usr/x386/include
8794/usr/XFree86/include/X11
8795
8796/usr/include
8797/usr/local/include
8798/usr/unsupported/include
8799/usr/athena/include
8800/usr/local/x11r5/include
8801/usr/lpp/Xamples/include
8802
8803/usr/openwin/include
8804/usr/openwin/share/include'
8805
8806if test "$ac_x_includes" = no; then
8807  # Guess where to find include files, by looking for Intrinsic.h.
8808  # First, try using that file with no special directory specified.
8809  cat >conftest.$ac_ext <<_ACEOF
8810#line 8810 "configure"
8811#include "confdefs.h"
8812#include <X11/Intrinsic.h>
8813_ACEOF
8814if { (eval echo "$as_me:8814: \"$ac_cpp conftest.$ac_ext\"") >&5
8815  (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8816  ac_status=$?
8817  egrep -v '^ *\+' conftest.er1 >conftest.err
8818  rm -f conftest.er1
8819  cat conftest.err >&5
8820  echo "$as_me:8820: \$? = $ac_status" >&5
8821  (exit $ac_status); } >/dev/null; then
8822  if test -s conftest.err; then
8823    ac_cpp_err=$ac_cxx_preproc_warn_flag
8824  else
8825    ac_cpp_err=
8826  fi
8827else
8828  ac_cpp_err=yes
8829fi
8830if test -z "$ac_cpp_err"; then
8831  # We can compile using X headers with no special include directory.
8832ac_x_includes=
8833else
8834  echo "$as_me: failed program was:" >&5
8835  cat conftest.$ac_ext >&5
8836  for ac_dir in $ac_x_header_dirs; do
8837  if test -r "$ac_dir/X11/Intrinsic.h"; then
8838    ac_x_includes=$ac_dir
8839    break
8840  fi
8841done
8842fi
8843rm -f conftest.err conftest.$ac_ext
8844fi # $ac_x_includes = no
8845
8846if test "$ac_x_libraries" = no; then
8847  # Check for the libraries.
8848  # See if we find them without any special options.
8849  # Don't add to $LIBS permanently.
8850  ac_save_LIBS=$LIBS
8851  LIBS="-lXt $LIBS"
8852  cat >conftest.$ac_ext <<_ACEOF
8853#line 8853 "configure"
8854#include "confdefs.h"
8855#include <X11/Intrinsic.h>
8856int
8857main ()
8858{
8859XtMalloc (0)
8860  ;
8861  return 0;
8862}
8863_ACEOF
8864rm -f conftest.$ac_objext conftest$ac_exeext
8865if { (eval echo "$as_me:8865: \"$ac_link\"") >&5
8866  (eval $ac_link) 2>&5
8867  ac_status=$?
8868  echo "$as_me:8868: \$? = $ac_status" >&5
8869  (exit $ac_status); } &&
8870         { ac_try='test -s conftest$ac_exeext'
8871  { (eval echo "$as_me:8871: \"$ac_try\"") >&5
8872  (eval $ac_try) 2>&5
8873  ac_status=$?
8874  echo "$as_me:8874: \$? = $ac_status" >&5
8875  (exit $ac_status); }; }; then
8876  LIBS=$ac_save_LIBS
8877# We can link X programs with no special library path.
8878ac_x_libraries=
8879else
8880  echo "$as_me: failed program was:" >&5
8881cat conftest.$ac_ext >&5
8882LIBS=$ac_save_LIBS
8883for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
8884do
8885  # Don't even attempt the hair of trying to link an X program!
8886  for ac_extension in a so sl; do
8887    if test -r $ac_dir/libXt.$ac_extension; then
8888      ac_x_libraries=$ac_dir
8889      break 2
8890    fi
8891  done
8892done
8893fi
8894rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
8895fi # $ac_x_libraries = no
8896
8897if test "$ac_x_includes" = no || test "$ac_x_libraries" = no; then
8898  # Didn't find X anywhere.  Cache the known absence of X.
8899  ac_cv_have_x="have_x=no"
8900else
8901  # Record where we found X for the cache.
8902  ac_cv_have_x="have_x=yes \
8903	        ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
8904fi
8905fi
8906
8907  fi
8908  eval "$ac_cv_have_x"
8909fi # $with_x != no
8910
8911if test "$have_x" != yes; then
8912  echo "$as_me:8912: result: $have_x" >&5
8913echo "${ECHO_T}$have_x" >&6
8914  no_x=yes
8915else
8916  # If each of the values was on the command line, it overrides each guess.
8917  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8918  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8919  # Update the cache value to reflect the command line values.
8920  ac_cv_have_x="have_x=yes \
8921		ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
8922  echo "$as_me:8922: result: libraries $x_libraries, headers $x_includes" >&5
8923echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
8924fi
8925
8926if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
8927  { { echo "$as_me:8927: error: Can't find X includes. Please check your installation and add the correct paths!" >&5
8928echo "$as_me: error: Can't find X includes. Please check your installation and add the correct paths!" >&2;}
8929   { (exit 1); exit 1; }; }
8930else
8931  # Record where we found X for the cache.
8932  ac_cv_have_x="have_x=yes \
8933                ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
8934fi
8935fi
8936eval "$ac_cv_have_x"
8937
8938if test "$have_x" != yes; then
8939  echo "$as_me:8939: result: $have_x" >&5
8940echo "${ECHO_T}$have_x" >&6
8941  no_x=yes
8942else
8943  # If each of the values was on the command line, it overrides each guess.
8944  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
8945  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
8946
8947  # don't set -I/usr/X11R6/include please. It's boring. /S.Rehel
8948  # IRIX test doesn't support -ef ! Aaah GNU ... Aah linux!
8949  #
8950  if test ! -z "$x_includes" ; then
8951    xdir1=`cd $x_includes/X11 && /bin/pwd`
8952    xdir2=`cd /usr/include/X11 && /bin/pwd`
8953    if test "$xdir1" = "$xdir2" ; then
8954      x_includes=/usr/include
8955    fi
8956  fi
8957
8958  # Update the cache value to reflect the command line values.
8959  ac_cv_have_x="have_x=yes \
8960                ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
8961  echo "$as_me:8961: result: libraries $x_libraries, headers $x_includes" >&5
8962echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6
8963
8964#  CPPFLAGS="$CPPFLAGS -L$x_libraries"
8965fi
8966
8967if test -z "$x_includes" || \
8968   test "$x_includes" = "/usr/include" || \
8969   test "x$x_includes" = xNONE; then
8970  X_INCLUDES=""
8971  x_includes=".";  else
8972  X_INCLUDES="-I$x_includes"
8973fi
8974
8975if test -z "$x_libraries" || test "$x_libraries" = xNONE; then
8976  X_LDFLAGS=""
8977# It does bad things under IRIX 6.4 /SR Mar.12.1999
8978#  x_libraries="/usr/lib"; dnl better than nothing :-
8979  all_libraries=""
8980 else
8981  X_LDFLAGS="-L$x_libraries"
8982  all_libraries=$X_LDFLAGS
8983fi
8984
8985all_includes=$X_INCLUDES
8986
8987echo "$as_me:8987: checking for sin in -lm" >&5
8988echo $ECHO_N "checking for sin in -lm... $ECHO_C" >&6
8989if test "${ac_cv_lib_m_sin+set}" = set; then
8990  echo $ECHO_N "(cached) $ECHO_C" >&6
8991else
8992  ac_check_lib_save_LIBS=$LIBS
8993LIBS="-lm  $LIBS"
8994cat >conftest.$ac_ext <<_ACEOF
8995#line 8995 "configure"
8996#include "confdefs.h"
8997
8998/* Override any gcc2 internal prototype to avoid an error.  */
8999#ifdef __cplusplus
9000extern "C"
9001#endif
9002/* We use char because int might match the return type of a gcc2
9003   builtin and then its argument prototype would still apply.  */
9004char sin ();
9005int
9006main ()
9007{
9008sin ();
9009  ;
9010  return 0;
9011}
9012_ACEOF
9013rm -f conftest.$ac_objext conftest$ac_exeext
9014if { (eval echo "$as_me:9014: \"$ac_link\"") >&5
9015  (eval $ac_link) 2>&5
9016  ac_status=$?
9017  echo "$as_me:9017: \$? = $ac_status" >&5
9018  (exit $ac_status); } &&
9019         { ac_try='test -s conftest$ac_exeext'
9020  { (eval echo "$as_me:9020: \"$ac_try\"") >&5
9021  (eval $ac_try) 2>&5
9022  ac_status=$?
9023  echo "$as_me:9023: \$? = $ac_status" >&5
9024  (exit $ac_status); }; }; then
9025  ac_cv_lib_m_sin=yes
9026else
9027  echo "$as_me: failed program was:" >&5
9028cat conftest.$ac_ext >&5
9029ac_cv_lib_m_sin=no
9030fi
9031rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9032LIBS=$ac_check_lib_save_LIBS
9033fi
9034echo "$as_me:9034: result: $ac_cv_lib_m_sin" >&5
9035echo "${ECHO_T}$ac_cv_lib_m_sin" >&6
9036if test $ac_cv_lib_m_sin = yes; then
9037  cat >>confdefs.h <<EOF
9038#define HAVE_LIBM 1
9039EOF
9040
9041  LIBS="-lm $LIBS"
9042
9043fi
9044
9045echo "$as_me:9045: checking for XOpenDisplay in -lX11" >&5
9046echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6
9047if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then
9048  echo $ECHO_N "(cached) $ECHO_C" >&6
9049else
9050  ac_check_lib_save_LIBS=$LIBS
9051LIBS="-lX11  $LIBS"
9052cat >conftest.$ac_ext <<_ACEOF
9053#line 9053 "configure"
9054#include "confdefs.h"
9055
9056/* Override any gcc2 internal prototype to avoid an error.  */
9057#ifdef __cplusplus
9058extern "C"
9059#endif
9060/* We use char because int might match the return type of a gcc2
9061   builtin and then its argument prototype would still apply.  */
9062char XOpenDisplay ();
9063int
9064main ()
9065{
9066XOpenDisplay ();
9067  ;
9068  return 0;
9069}
9070_ACEOF
9071rm -f conftest.$ac_objext conftest$ac_exeext
9072if { (eval echo "$as_me:9072: \"$ac_link\"") >&5
9073  (eval $ac_link) 2>&5
9074  ac_status=$?
9075  echo "$as_me:9075: \$? = $ac_status" >&5
9076  (exit $ac_status); } &&
9077         { ac_try='test -s conftest$ac_exeext'
9078  { (eval echo "$as_me:9078: \"$ac_try\"") >&5
9079  (eval $ac_try) 2>&5
9080  ac_status=$?
9081  echo "$as_me:9081: \$? = $ac_status" >&5
9082  (exit $ac_status); }; }; then
9083  ac_cv_lib_X11_XOpenDisplay=yes
9084else
9085  echo "$as_me: failed program was:" >&5
9086cat conftest.$ac_ext >&5
9087ac_cv_lib_X11_XOpenDisplay=no
9088fi
9089rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9090LIBS=$ac_check_lib_save_LIBS
9091fi
9092echo "$as_me:9092: result: $ac_cv_lib_X11_XOpenDisplay" >&5
9093echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6
9094if test $ac_cv_lib_X11_XOpenDisplay = yes; then
9095  cat >>confdefs.h <<EOF
9096#define HAVE_LIBX11 1
9097EOF
9098
9099  LIBS="-lX11 $LIBS"
9100
9101fi
9102
9103echo "$as_me:9103: checking for XShmCreateImage in -lXext" >&5
9104echo $ECHO_N "checking for XShmCreateImage in -lXext... $ECHO_C" >&6
9105if test "${ac_cv_lib_Xext_XShmCreateImage+set}" = set; then
9106  echo $ECHO_N "(cached) $ECHO_C" >&6
9107else
9108  ac_check_lib_save_LIBS=$LIBS
9109LIBS="-lXext  $LIBS"
9110cat >conftest.$ac_ext <<_ACEOF
9111#line 9111 "configure"
9112#include "confdefs.h"
9113
9114/* Override any gcc2 internal prototype to avoid an error.  */
9115#ifdef __cplusplus
9116extern "C"
9117#endif
9118/* We use char because int might match the return type of a gcc2
9119   builtin and then its argument prototype would still apply.  */
9120char XShmCreateImage ();
9121int
9122main ()
9123{
9124XShmCreateImage ();
9125  ;
9126  return 0;
9127}
9128_ACEOF
9129rm -f conftest.$ac_objext conftest$ac_exeext
9130if { (eval echo "$as_me:9130: \"$ac_link\"") >&5
9131  (eval $ac_link) 2>&5
9132  ac_status=$?
9133  echo "$as_me:9133: \$? = $ac_status" >&5
9134  (exit $ac_status); } &&
9135         { ac_try='test -s conftest$ac_exeext'
9136  { (eval echo "$as_me:9136: \"$ac_try\"") >&5
9137  (eval $ac_try) 2>&5
9138  ac_status=$?
9139  echo "$as_me:9139: \$? = $ac_status" >&5
9140  (exit $ac_status); }; }; then
9141  ac_cv_lib_Xext_XShmCreateImage=yes
9142else
9143  echo "$as_me: failed program was:" >&5
9144cat conftest.$ac_ext >&5
9145ac_cv_lib_Xext_XShmCreateImage=no
9146fi
9147rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9148LIBS=$ac_check_lib_save_LIBS
9149fi
9150echo "$as_me:9150: result: $ac_cv_lib_Xext_XShmCreateImage" >&5
9151echo "${ECHO_T}$ac_cv_lib_Xext_XShmCreateImage" >&6
9152if test $ac_cv_lib_Xext_XShmCreateImage = yes; then
9153  cat >>confdefs.h <<EOF
9154#define HAVE_LIBXEXT 1
9155EOF
9156
9157  LIBS="-lXext $LIBS"
9158
9159fi
9160
9161echo "$as_me:9161: checking for IceSetIOErrorHandler in -lICE" >&5
9162echo $ECHO_N "checking for IceSetIOErrorHandler in -lICE... $ECHO_C" >&6
9163if test "${ac_cv_lib_ICE_IceSetIOErrorHandler+set}" = set; then
9164  echo $ECHO_N "(cached) $ECHO_C" >&6
9165else
9166  ac_check_lib_save_LIBS=$LIBS
9167LIBS="-lICE  $LIBS"
9168cat >conftest.$ac_ext <<_ACEOF
9169#line 9169 "configure"
9170#include "confdefs.h"
9171
9172/* Override any gcc2 internal prototype to avoid an error.  */
9173#ifdef __cplusplus
9174extern "C"
9175#endif
9176/* We use char because int might match the return type of a gcc2
9177   builtin and then its argument prototype would still apply.  */
9178char IceSetIOErrorHandler ();
9179int
9180main ()
9181{
9182IceSetIOErrorHandler ();
9183  ;
9184  return 0;
9185}
9186_ACEOF
9187rm -f conftest.$ac_objext conftest$ac_exeext
9188if { (eval echo "$as_me:9188: \"$ac_link\"") >&5
9189  (eval $ac_link) 2>&5
9190  ac_status=$?
9191  echo "$as_me:9191: \$? = $ac_status" >&5
9192  (exit $ac_status); } &&
9193         { ac_try='test -s conftest$ac_exeext'
9194  { (eval echo "$as_me:9194: \"$ac_try\"") >&5
9195  (eval $ac_try) 2>&5
9196  ac_status=$?
9197  echo "$as_me:9197: \$? = $ac_status" >&5
9198  (exit $ac_status); }; }; then
9199  ac_cv_lib_ICE_IceSetIOErrorHandler=yes
9200else
9201  echo "$as_me: failed program was:" >&5
9202cat conftest.$ac_ext >&5
9203ac_cv_lib_ICE_IceSetIOErrorHandler=no
9204fi
9205rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9206LIBS=$ac_check_lib_save_LIBS
9207fi
9208echo "$as_me:9208: result: $ac_cv_lib_ICE_IceSetIOErrorHandler" >&5
9209echo "${ECHO_T}$ac_cv_lib_ICE_IceSetIOErrorHandler" >&6
9210if test $ac_cv_lib_ICE_IceSetIOErrorHandler = yes; then
9211  cat >>confdefs.h <<EOF
9212#define HAVE_LIBICE 1
9213EOF
9214
9215  LIBS="-lICE $LIBS"
9216
9217fi
9218
9219#dnl Replace `main' with a function in -lMesaGL:
9220#dnl AC_CHECK_LIB(MesaGL, glEnd)
9221#dnl Replace `main' with a function in -lMesaGLU:
9222#dnl AC_CHECK_LIB(MesaGLU, gluNewNurbsRenderer)
9223
9224echo "$as_me:9224: checking for SmsSetErrorHandler in -lSM" >&5
9225echo $ECHO_N "checking for SmsSetErrorHandler in -lSM... $ECHO_C" >&6
9226if test "${ac_cv_lib_SM_SmsSetErrorHandler+set}" = set; then
9227  echo $ECHO_N "(cached) $ECHO_C" >&6
9228else
9229  ac_check_lib_save_LIBS=$LIBS
9230LIBS="-lSM  $LIBS"
9231cat >conftest.$ac_ext <<_ACEOF
9232#line 9232 "configure"
9233#include "confdefs.h"
9234
9235/* Override any gcc2 internal prototype to avoid an error.  */
9236#ifdef __cplusplus
9237extern "C"
9238#endif
9239/* We use char because int might match the return type of a gcc2
9240   builtin and then its argument prototype would still apply.  */
9241char SmsSetErrorHandler ();
9242int
9243main ()
9244{
9245SmsSetErrorHandler ();
9246  ;
9247  return 0;
9248}
9249_ACEOF
9250rm -f conftest.$ac_objext conftest$ac_exeext
9251if { (eval echo "$as_me:9251: \"$ac_link\"") >&5
9252  (eval $ac_link) 2>&5
9253  ac_status=$?
9254  echo "$as_me:9254: \$? = $ac_status" >&5
9255  (exit $ac_status); } &&
9256         { ac_try='test -s conftest$ac_exeext'
9257  { (eval echo "$as_me:9257: \"$ac_try\"") >&5
9258  (eval $ac_try) 2>&5
9259  ac_status=$?
9260  echo "$as_me:9260: \$? = $ac_status" >&5
9261  (exit $ac_status); }; }; then
9262  ac_cv_lib_SM_SmsSetErrorHandler=yes
9263else
9264  echo "$as_me: failed program was:" >&5
9265cat conftest.$ac_ext >&5
9266ac_cv_lib_SM_SmsSetErrorHandler=no
9267fi
9268rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9269LIBS=$ac_check_lib_save_LIBS
9270fi
9271echo "$as_me:9271: result: $ac_cv_lib_SM_SmsSetErrorHandler" >&5
9272echo "${ECHO_T}$ac_cv_lib_SM_SmsSetErrorHandler" >&6
9273if test $ac_cv_lib_SM_SmsSetErrorHandler = yes; then
9274  cat >>confdefs.h <<EOF
9275#define HAVE_LIBSM 1
9276EOF
9277
9278  LIBS="-lSM $LIBS"
9279
9280fi
9281
9282echo "$as_me:9282: checking for XtDisplay in -lXt" >&5
9283echo $ECHO_N "checking for XtDisplay in -lXt... $ECHO_C" >&6
9284if test "${ac_cv_lib_Xt_XtDisplay+set}" = set; then
9285  echo $ECHO_N "(cached) $ECHO_C" >&6
9286else
9287  ac_check_lib_save_LIBS=$LIBS
9288LIBS="-lXt  $LIBS"
9289cat >conftest.$ac_ext <<_ACEOF
9290#line 9290 "configure"
9291#include "confdefs.h"
9292
9293/* Override any gcc2 internal prototype to avoid an error.  */
9294#ifdef __cplusplus
9295extern "C"
9296#endif
9297/* We use char because int might match the return type of a gcc2
9298   builtin and then its argument prototype would still apply.  */
9299char XtDisplay ();
9300int
9301main ()
9302{
9303XtDisplay ();
9304  ;
9305  return 0;
9306}
9307_ACEOF
9308rm -f conftest.$ac_objext conftest$ac_exeext
9309if { (eval echo "$as_me:9309: \"$ac_link\"") >&5
9310  (eval $ac_link) 2>&5
9311  ac_status=$?
9312  echo "$as_me:9312: \$? = $ac_status" >&5
9313  (exit $ac_status); } &&
9314         { ac_try='test -s conftest$ac_exeext'
9315  { (eval echo "$as_me:9315: \"$ac_try\"") >&5
9316  (eval $ac_try) 2>&5
9317  ac_status=$?
9318  echo "$as_me:9318: \$? = $ac_status" >&5
9319  (exit $ac_status); }; }; then
9320  ac_cv_lib_Xt_XtDisplay=yes
9321else
9322  echo "$as_me: failed program was:" >&5
9323cat conftest.$ac_ext >&5
9324ac_cv_lib_Xt_XtDisplay=no
9325fi
9326rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9327LIBS=$ac_check_lib_save_LIBS
9328fi
9329echo "$as_me:9329: result: $ac_cv_lib_Xt_XtDisplay" >&5
9330echo "${ECHO_T}$ac_cv_lib_Xt_XtDisplay" >&6
9331if test $ac_cv_lib_Xt_XtDisplay = yes; then
9332  cat >>confdefs.h <<EOF
9333#define HAVE_LIBXT 1
9334EOF
9335
9336  LIBS="-lXt $LIBS"
9337
9338fi
9339
9340echo "$as_me:9340: checking for XOpenDevice in -lXi" >&5
9341echo $ECHO_N "checking for XOpenDevice in -lXi... $ECHO_C" >&6
9342if test "${ac_cv_lib_Xi_XOpenDevice+set}" = set; then
9343  echo $ECHO_N "(cached) $ECHO_C" >&6
9344else
9345  ac_check_lib_save_LIBS=$LIBS
9346LIBS="-lXi  $LIBS"
9347cat >conftest.$ac_ext <<_ACEOF
9348#line 9348 "configure"
9349#include "confdefs.h"
9350
9351/* Override any gcc2 internal prototype to avoid an error.  */
9352#ifdef __cplusplus
9353extern "C"
9354#endif
9355/* We use char because int might match the return type of a gcc2
9356   builtin and then its argument prototype would still apply.  */
9357char XOpenDevice ();
9358int
9359main ()
9360{
9361XOpenDevice ();
9362  ;
9363  return 0;
9364}
9365_ACEOF
9366rm -f conftest.$ac_objext conftest$ac_exeext
9367if { (eval echo "$as_me:9367: \"$ac_link\"") >&5
9368  (eval $ac_link) 2>&5
9369  ac_status=$?
9370  echo "$as_me:9370: \$? = $ac_status" >&5
9371  (exit $ac_status); } &&
9372         { ac_try='test -s conftest$ac_exeext'
9373  { (eval echo "$as_me:9373: \"$ac_try\"") >&5
9374  (eval $ac_try) 2>&5
9375  ac_status=$?
9376  echo "$as_me:9376: \$? = $ac_status" >&5
9377  (exit $ac_status); }; }; then
9378  ac_cv_lib_Xi_XOpenDevice=yes
9379else
9380  echo "$as_me: failed program was:" >&5
9381cat conftest.$ac_ext >&5
9382ac_cv_lib_Xi_XOpenDevice=no
9383fi
9384rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9385LIBS=$ac_check_lib_save_LIBS
9386fi
9387echo "$as_me:9387: result: $ac_cv_lib_Xi_XOpenDevice" >&5
9388echo "${ECHO_T}$ac_cv_lib_Xi_XOpenDevice" >&6
9389if test $ac_cv_lib_Xi_XOpenDevice = yes; then
9390  cat >>confdefs.h <<EOF
9391#define HAVE_LIBXI 1
9392EOF
9393
9394  LIBS="-lXi $LIBS"
9395
9396fi
9397
9398echo "$as_me:9398: checking for XmuSimpleErrorHandler in -lXmu" >&5
9399echo $ECHO_N "checking for XmuSimpleErrorHandler in -lXmu... $ECHO_C" >&6
9400if test "${ac_cv_lib_Xmu_XmuSimpleErrorHandler+set}" = set; then
9401  echo $ECHO_N "(cached) $ECHO_C" >&6
9402else
9403  ac_check_lib_save_LIBS=$LIBS
9404LIBS="-lXmu -lXt $LIBS"
9405cat >conftest.$ac_ext <<_ACEOF
9406#line 9406 "configure"
9407#include "confdefs.h"
9408
9409/* Override any gcc2 internal prototype to avoid an error.  */
9410#ifdef __cplusplus
9411extern "C"
9412#endif
9413/* We use char because int might match the return type of a gcc2
9414   builtin and then its argument prototype would still apply.  */
9415char XmuSimpleErrorHandler ();
9416int
9417main ()
9418{
9419XmuSimpleErrorHandler ();
9420  ;
9421  return 0;
9422}
9423_ACEOF
9424rm -f conftest.$ac_objext conftest$ac_exeext
9425if { (eval echo "$as_me:9425: \"$ac_link\"") >&5
9426  (eval $ac_link) 2>&5
9427  ac_status=$?
9428  echo "$as_me:9428: \$? = $ac_status" >&5
9429  (exit $ac_status); } &&
9430         { ac_try='test -s conftest$ac_exeext'
9431  { (eval echo "$as_me:9431: \"$ac_try\"") >&5
9432  (eval $ac_try) 2>&5
9433  ac_status=$?
9434  echo "$as_me:9434: \$? = $ac_status" >&5
9435  (exit $ac_status); }; }; then
9436  ac_cv_lib_Xmu_XmuSimpleErrorHandler=yes
9437else
9438  echo "$as_me: failed program was:" >&5
9439cat conftest.$ac_ext >&5
9440ac_cv_lib_Xmu_XmuSimpleErrorHandler=no
9441fi
9442rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9443LIBS=$ac_check_lib_save_LIBS
9444fi
9445echo "$as_me:9445: result: $ac_cv_lib_Xmu_XmuSimpleErrorHandler" >&5
9446echo "${ECHO_T}$ac_cv_lib_Xmu_XmuSimpleErrorHandler" >&6
9447if test $ac_cv_lib_Xmu_XmuSimpleErrorHandler = yes; then
9448  cat >>confdefs.h <<EOF
9449#define HAVE_LIBXMU 1
9450EOF
9451
9452  LIBS="-lXmu $LIBS"
9453
9454fi
9455
9456echo "$as_me:9456: checking for GL" >&5
9457echo $ECHO_N "checking for GL... $ECHO_C" >&6
9458ac_gl_includes=NO
9459ac_gl_libraries=NO
9460gl_libraries=""
9461gl_includes=""
9462
9463# Check whether --with-gl-dir or --without-gl-dir was given.
9464if test "${with_gl_dir+set}" = set; then
9465  withval="$with_gl_dir"
9466    ac_gl_includes="$withval"/include
9467       ac_gl_libraries="$withval"/lib
9468
9469fi;
9470
9471# Check whether --with-gl-includes or --without-gl-includes was given.
9472if test "${with_gl_includes+set}" = set; then
9473  withval="$with_gl_includes"
9474
9475       ac_gl_includes="$withval"
9476
9477fi;
9478
9479# Check whether --with-gl-libraries or --without-gl-libraries was given.
9480if test "${with_gl_libraries+set}" = set; then
9481  withval="$with_gl_libraries"
9482    ac_gl_libraries="$withval"
9483
9484fi;
9485
9486if test "$ac_gl_includes" = NO || test "$ac_gl_libraries" = NO; then
9487
9488if test "${ac_cv_have_gl+set}" = set; then
9489  echo $ECHO_N "(cached) $ECHO_C" >&6
9490else
9491  #try to guess gl locations
9492
9493gl_incdirs="$ac_gl_includes \
9494            /usr/include \
9495            /usr/X11R6/include \
9496            /usr/local/include \
9497            /usr/local/Mesa/include \
9498            $HOME/Mesa/include \
9499            $GL_INC"
9500test -n "$GLDIR" && gl_incdirs="$GLDIR/include $GLDIR $gl_incdirs"
9501
9502gl_incdir=NO
9503for i in $gl_incdirs;
9504do
9505  for j in GL/gl.h;
9506  do
9507    if test -r "$i/$j"; then
9508      gl_incdir=$i
9509      break 2
9510    fi
9511  done
9512done
9513
9514ac_gl_includes=$gl_incdir
9515
9516gl_libdirs="$ac_gl_libraries \
9517            /usr/lib \
9518            /usr/X11R6/lib \
9519            /usr/local/lib \
9520            /usr/local/Mesa/lib \
9521            $HOME/Mesa/lib \
9522            $GLLIB"
9523test -n "$GLDIR" && gl_libdirs="$GLDIR/lib $GLDIR $gl_libdirs"
9524
9525GL_LIBNAME=""
9526
9527gl_libdir=NO
9528for i in $gl_libdirs;
9529do
9530  for j in libGL.so libGL.a;
9531  do
9532    if test -r "$i/$j"; then
9533      gl_libdir=$i
9534      break 2
9535    fi
9536  done
9537done
9538
9539if test "$gl_libdir" = NO ; then
9540
9541gl_libdir=NO
9542for i in $gl_libdirs;
9543do
9544  for j in libMesaGL.so libMesaGL.a;
9545  do
9546    if test -r "$i/$j"; then
9547      gl_libdir=$i
9548      break 2
9549    fi
9550  done
9551done
9552
9553  ac_gl_libraries=$gl_libdir
9554  GL_LIBNAME="Mesa"
9555else
9556  ac_gl_libraries=$gl_libdir
9557  GL_LIBNAME=""
9558fi
9559
9560gl_libdir=NO
9561for i in $gl_libdirs;
9562do
9563  for j in libGL.so libMesaGL.so libGL.a libMesaGL.a;
9564  do
9565    if test -r "$i/$j"; then
9566      gl_libdir=$i
9567      break 2
9568    fi
9569  done
9570done
9571
9572ac_gl_libraries=$gl_libdir
9573
9574ac_cxxflags_safe=$CXXFLAGS
9575ac_ldflags_safe=$LDFLAGS
9576ac_libs_safe=$LIBS
9577
9578CXXFLAGS="$CXXFLAGS -I$gl_incdir"
9579LDFLAGS="-L$gl_libdir"
9580LIBS="-lGL $X_LDFLAGS $LIBS"
9581
9582ac_ext=cc
9583ac_cpp='$CXXCPP $CPPFLAGS'
9584ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9585ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9586ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9587
9588cat > conftest.$ac_ext <<EOF
9589#include "confdefs.h"
9590#include "GL/gl.h"
9591int main() {
9592  glEnd();
9593  return 0;
9594}
9595EOF
9596
9597if { (eval echo "$as_me:9597: \"$ac_link\"") >&5
9598  (eval $ac_link) 2>&5
9599  ac_status=$?
9600  echo "$as_me:9600: \$? = $ac_status" >&5
9601  (exit $ac_status); } && test -s conftest; then
9602  rm -f conftest*
9603else
9604  rm -f conftest*
9605  LIBS="$ac_libs_safe -lMesaGL $X_LDFLAGS -lX11 -lXext -lm"
9606
9607cat > conftest.$ac_ext <<EOF
9608#include "confdefs.h"
9609#include "GL/gl.h"
9610int main() {
9611  glEnd();
9612  return 0;
9613}
9614EOF
9615
9616  if { (eval echo "$as_me:9616: \"$ac_link\"") >&5
9617  (eval $ac_link) 2>&5
9618  ac_status=$?
9619  echo "$as_me:9619: \$? = $ac_status" >&5
9620  (exit $ac_status); } && test -s conftest; then
9621    rm -f conftest*
9622   else
9623    echo "configure: failed program was:" >&5
9624    cat conftest.$ac_ext >&5
9625    ac_gl_libraries="NO"
9626   fi
9627fi
9628
9629rm -f conftest*
9630CXXFLAGS=$ac_cxxflags_safe
9631LDFLAGS=$ac_ldflags_safe
9632LIBS=$ac_libs_safe
9633
9634if test "$ac_gl_includes" = NO || test "$ac_gl_libraries" = NO; then
9635  ac_cv_have_gl="have_gl=no"
9636  ac_gl_notfound=""
9637  if test "$ac_gl_includes" = NO; then
9638    if test "$ac_gl_libraries" = NO; then
9639      ac_gl_notfound="(headers and libraries)";
9640    else
9641      ac_gl_notfound="(headers)";
9642    fi
9643  else
9644    ac_gl_notfound="(libraries)";
9645  fi
9646
9647  { { echo "$as_me:9647: error: OpenGL $ac_gl_notfound not found. Please check your installation! " >&5
9648echo "$as_me: error: OpenGL $ac_gl_notfound not found. Please check your installation! " >&2;}
9649   { (exit 1); exit 1; }; };
9650else
9651  have_gl="yes"
9652fi
9653
9654fi
9655
9656else
9657  have_gl="yes"
9658fi
9659
9660eval "$ac_cv_have_gl"
9661
9662if test "$have_gl" != yes; then
9663  echo "$as_me:9663: result: $have_gl" >&5
9664echo "${ECHO_T}$have_gl" >&6;
9665else
9666  ac_cv_have_gl="have_gl=yes \
9667    ac_gl_includes=$ac_gl_includes ac_gl_libraries=$ac_gl_libraries"
9668  echo "$as_me:9668: result: libraries $ac_gl_libraries/lib${GL_LIBNAME}GL*, headers $ac_gl_includes/GL" >&5
9669echo "${ECHO_T}libraries $ac_gl_libraries/lib${GL_LIBNAME}GL*, headers $ac_gl_includes/GL" >&6
9670
9671  gl_libraries=$ac_gl_libraries
9672  gl_includes=$ac_gl_includes
9673fi
9674
9675if test "$gl_includes" = "$x_includes" || \
9676   test "$gl_includes" = "/usr/include" || \
9677   test -z "$gl_includes"; then
9678 GL_INCLUDES="";
9679else
9680 GL_INCLUDES="-I$gl_includes"
9681 all_includes="$GL_INCLUDES $all_includes"
9682fi
9683
9684if test "$gl_libraries" = "$x_libraries" || \
9685   test "$gl_libraries" = "/usr/lib" || \
9686   test "$gl_libraries" = "/usr/local/lib" || \
9687   test -z "$gl_libraries"; then
9688 GL_LDFLAGS=""
9689else
9690 GL_LDFLAGS="-L$gl_libraries"
9691 all_libraries="$GL_LDFLAGS $all_libraries"
9692fi
9693
9694echo "$as_me:9694: checking for glut" >&5
9695echo $ECHO_N "checking for glut... $ECHO_C" >&6
9696ac_glut_includes=NO ac_glut_libraries=NO
9697glut_libraries=""
9698glut_includes=""
9699
9700# Check whether --with-glut-dir or --without-glut-dir was given.
9701if test "${with_glut_dir+set}" = set; then
9702  withval="$with_glut_dir"
9703    ac_glut_includes="$withval"/include
9704       ac_glut_libraries="$withval"/lib/glut
9705
9706fi;
9707
9708# Check whether --with-glut-includes or --without-glut-includes was given.
9709if test "${with_glut_includes+set}" = set; then
9710  withval="$with_glut_includes"
9711
9712       ac_glut_includes="$withval"
9713
9714fi;
9715
9716# Check whether --with-glut-libraries or --without-glut-libraries was given.
9717if test "${with_glut_libraries+set}" = set; then
9718  withval="$with_glut_libraries"
9719
9720       ac_glut_libraries="$withval"
9721
9722fi;
9723
9724if test "$ac_glut_includes" = NO || test "$ac_glut_libraries" = NO; then
9725
9726if test "${ac_cv_have_glut+set}" = set; then
9727  echo $ECHO_N "(cached) $ECHO_C" >&6
9728else
9729  #try to guess glut locations
9730
9731GLTT_MAKE_TARGET=lib_and_demos
9732
9733glut_incdirs="$ac_glut_includes /usr/include /usr/local/include /usr/glut/include /usr/local/glut/include $HOME/glut/include $HOME/Mesa/include $GLUT_INC $gl_includes"
9734test -n "$GLUTDIR" && glut_incdirs="$GLUTDIR/include $GLUTDIR $glut_incdirs"
9735
9736glut_incdir=NO
9737for i in $glut_incdirs;
9738do
9739  for j in GL/glut.h;
9740  do
9741    if test -r "$i/$j"; then
9742      glut_incdir=$i
9743      break 2
9744    fi
9745  done
9746done
9747
9748ac_glut_includes=$glut_incdir
9749
9750glut_libdirs="$ac_glut_libraries /usr/lib /usr/local/lib /usr/glut/lib/glut /usr/local/glut/lib/glut $HOME/glut/lib/glut $HOME/Mesa/lib $GLUTLIB $gl_libraries"
9751test -n "$GLUTDIR" && glut_libdirs="$GLUTDIR/lib/glut $GLUTDIR $glut_libdirs"
9752
9753glut_libdir=NO
9754for i in $glut_libdirs;
9755do
9756  for j in libglut.so libglut.so.3.6 libglut.so.3 libglut.a libglut.sl;
9757  do
9758    if test -r "$i/$j"; then
9759      glut_libdir=$i
9760      break 2
9761    fi
9762  done
9763done
9764
9765ac_glut_libraries=$glut_libdir
9766
9767ac_cxxflags_safe=$CXXFLAGS
9768ac_ldflags_safe=$LDFLAGS
9769ac_libs_safe=$LIBS
9770
9771CXXFLAGS="$CXXFLAGS -I$glut_incdir -I$gl_includes"
9772LDFLAGS="-L$glut_libdir"
9773LIBS="-lglut -L$gl_libraries -l${GL_LIBNAME}GL -l${GL_LIBNAME}GLU $LIBSOCKET $LIBS"
9774
9775ac_ext=cc
9776ac_cpp='$CXXCPP $CPPFLAGS'
9777ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9778ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9779ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9780
9781cat > conftest.$ac_ext <<EOF
9782#include "confdefs.h"
9783#include "GL/glut.h"
9784int main( int argc, char** argv ) {
9785  glutInit(&argc, argv);
9786  return 0;
9787}
9788EOF
9789
9790if { (eval echo "$as_me:9790: \"$ac_link\"") >&5
9791  (eval $ac_link) 2>&5
9792  ac_status=$?
9793  echo "$as_me:9793: \$? = $ac_status" >&5
9794  (exit $ac_status); } && test -s conftest; then
9795  rm -f conftest*
9796else
9797  echo "configure: failed program was:" >&5
9798  cat conftest.$ac_ext >&5
9799  ac_glut_libraries="NO"
9800fi
9801rm -f conftest*
9802CXXFLAGS=$ac_cxxflags_safe
9803LDFLAGS=$ac_ldflags_safe
9804LIBS=$ac_libs_safe
9805
9806if test "$ac_glut_includes" = NO || test "$ac_glut_libraries" = NO; then
9807  ac_cv_have_glut="have_glut=no"
9808  ac_glut_notfound=""
9809  if test "$ac_glut_includes" = NO; then
9810    if test "$ac_glut_libraries" = NO; then
9811      ac_glut_notfound="(headers and libraries)";
9812    else
9813      ac_glut_notfound="(headers)";
9814    fi
9815  else
9816    ac_glut_notfound="(libraries)";
9817  fi
9818
9819  { echo "$as_me:9819: WARNING: glut $ac_glut_notfound not found. Demos won't be built! " >&5
9820echo "$as_me: WARNING: glut $ac_glut_notfound not found. Demos won't be built! " >&2;};
9821  GLTT_MAKE_TARGET=lib_only
9822else
9823  have_glut="yes"
9824fi
9825ac_make_target=$GLTT_MAKE_TARGET
9826
9827fi
9828
9829else
9830  have_glut="yes"
9831fi
9832
9833eval "$ac_cv_have_glut"
9834
9835if test "$have_glut" != yes; then
9836  echo "$as_me:9836: result: $have_glut" >&5
9837echo "${ECHO_T}$have_glut" >&6;
9838else
9839  ac_cv_have_glut="have_glut=yes \
9840    ac_glut_includes=$ac_glut_includes ac_glut_libraries=$ac_glut_libraries ac_make_target=$GLTT_MAKE_TARGET"
9841  echo "$as_me:9841: result: libraries $ac_glut_libraries, headers $ac_glut_includes" >&5
9842echo "${ECHO_T}libraries $ac_glut_libraries, headers $ac_glut_includes" >&6
9843
9844  glut_libraries=$ac_glut_libraries
9845  glut_includes=$ac_glut_includes
9846  GLTT_MAKE_TARGET=$ac_make_target
9847fi
9848
9849if test "$glut_includes" = "$x_includes" || \
9850   test "$glut_includes" = "/usr/include" || \
9851   test -z "$glut_includes"; then
9852 GLUT_INCLUDES="";
9853else
9854 GLUT_INCLUDES="-I$glut_includes"
9855 all_includes="$GLUT_INCLUDES $all_includes"
9856fi
9857
9858if test "$glut_libraries" = "$x_libraries" || \
9859   test "$glut_libraries" = "/usr/lib" || \
9860   test "$glut_libraries" = "/usr/local/lib" || \
9861   test -z "$glut_libraries"; then
9862 GLUT_LDFLAGS=""
9863else
9864 GLUT_LDFLAGS="-L$glut_libraries"
9865 all_libraries="$GLUT_LDFLAGS $all_libraries"
9866fi
9867
9868topdir=`pwd`
9869
9870ac_config_files="$ac_config_files Makefile gltt.spec"
9871cat >confcache <<\_ACEOF
9872# This file is a shell script that caches the results of configure
9873# tests run on this system so they can be shared between configure
9874# scripts and configure runs, see configure's option --config-cache.
9875# It is not useful on other systems.  If it contains results you don't
9876# want to keep, you may remove or edit it.
9877#
9878# config.status only pays attention to the cache file if you give it
9879# the --recheck option to rerun configure.
9880#
9881# `ac_cv_env_foo' variables (set or unset) will be overriden when
9882# loading this file, other *unset* `ac_cv_foo' will be assigned the
9883# following values.
9884
9885_ACEOF
9886
9887# The following way of writing the cache mishandles newlines in values,
9888# but we know of no workaround that is simple, portable, and efficient.
9889# So, don't put newlines in cache variables' values.
9890# Ultrix sh set writes to stderr and can't be redirected directly,
9891# and sets the high bit in the cache file unless we assign to the vars.
9892{
9893  (set) 2>&1 |
9894    case `(ac_space=' '; set | grep ac_space) 2>&1` in
9895    *ac_space=\ *)
9896      # `set' does not quote correctly, so add quotes (double-quote
9897      # substitution turns \\\\ into \\, and sed turns \\ into \).
9898      sed -n \
9899        "s/'/'\\\\''/g;
9900    	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
9901      ;;
9902    *)
9903      # `set' quotes correctly as required by POSIX, so do not add quotes.
9904      sed -n \
9905        "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
9906      ;;
9907    esac;
9908} |
9909  sed '
9910     t clear
9911     : clear
9912     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
9913     t end
9914     /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
9915     : end' >>confcache
9916if cmp -s $cache_file confcache; then :; else
9917  if test -w $cache_file; then
9918    test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
9919    cat confcache >$cache_file
9920  else
9921    echo "not updating unwritable cache $cache_file"
9922  fi
9923fi
9924rm -f confcache
9925
9926test "x$prefix" = xNONE && prefix=$ac_default_prefix
9927# Let make expand exec_prefix.
9928test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9929
9930# VPATH may cause trouble with some makes, so we remove $(srcdir),
9931# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
9932# trailing colons and then remove the whole line if VPATH becomes empty
9933# (actually we leave an empty line to preserve line numbers).
9934if test "x$srcdir" = x.; then
9935  ac_vpsub='/^[ 	]*VPATH[ 	]*=/{
9936s/:*\$(srcdir):*/:/;
9937s/:*\${srcdir}:*/:/;
9938s/:*@srcdir@:*/:/;
9939s/^\([^=]*=[ 	]*\):*/\1/;
9940s/:*$//;
9941s/^[^=]*=[ 	]*$//;
9942}'
9943fi
9944
9945DEFS=-DHAVE_CONFIG_H
9946
9947: ${CONFIG_STATUS=./config.status}
9948ac_clean_files_save=$ac_clean_files
9949ac_clean_files="$ac_clean_files $CONFIG_STATUS"
9950{ echo "$as_me:9950: creating $CONFIG_STATUS" >&5
9951echo "$as_me: creating $CONFIG_STATUS" >&6;}
9952cat >$CONFIG_STATUS <<_ACEOF
9953#! $SHELL
9954# Generated automatically by configure.
9955# Run this file to recreate the current configuration.
9956# Compiler output produced by configure, useful for debugging
9957# configure, is in config.log if it exists.
9958
9959debug=false
9960SHELL=\${CONFIG_SHELL-$SHELL}
9961ac_cs_invocation="\$0 \$@"
9962
9963_ACEOF
9964
9965cat >>$CONFIG_STATUS <<\_ACEOF
9966# Be Bourne compatible
9967if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
9968  emulate sh
9969  NULLCMD=:
9970elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
9971  set -o posix
9972fi
9973
9974# Name of the executable.
9975as_me=`echo "$0" |sed 's,.*[\\/],,'`
9976
9977if expr a : '\(a\)' >/dev/null 2>&1; then
9978  as_expr=expr
9979else
9980  as_expr=false
9981fi
9982
9983rm -f conf$$ conf$$.exe conf$$.file
9984echo >conf$$.file
9985if ln -s conf$$.file conf$$ 2>/dev/null; then
9986  # We could just check for DJGPP; but this test a) works b) is more generic
9987  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
9988  if test -f conf$$.exe; then
9989    # Don't use ln at all; we don't have any links
9990    as_ln_s='cp -p'
9991  else
9992    as_ln_s='ln -s'
9993  fi
9994elif ln conf$$.file conf$$ 2>/dev/null; then
9995  as_ln_s=ln
9996else
9997  as_ln_s='cp -p'
9998fi
9999rm -f conf$$ conf$$.exe conf$$.file
10000
10001as_executable_p="test -f"
10002
10003# Support unset when possible.
10004if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
10005  as_unset=unset
10006else
10007  as_unset=false
10008fi
10009
10010# NLS nuisances.
10011$as_unset LANG || test "${LANG+set}" != set || { LANG=C; export LANG; }
10012$as_unset LC_ALL || test "${LC_ALL+set}" != set || { LC_ALL=C; export LC_ALL; }
10013$as_unset LC_TIME || test "${LC_TIME+set}" != set || { LC_TIME=C; export LC_TIME; }
10014$as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set || { LC_CTYPE=C; export LC_CTYPE; }
10015$as_unset LANGUAGE || test "${LANGUAGE+set}" != set || { LANGUAGE=C; export LANGUAGE; }
10016$as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set || { LC_COLLATE=C; export LC_COLLATE; }
10017$as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set || { LC_NUMERIC=C; export LC_NUMERIC; }
10018$as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set || { LC_MESSAGES=C; export LC_MESSAGES; }
10019
10020# IFS
10021# We need space, tab and new line, in precisely that order.
10022as_nl='
10023'
10024IFS=" 	$as_nl"
10025
10026# CDPATH.
10027$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=:; export CDPATH; }
10028
10029exec 6>&1
10030
10031_ACEOF
10032
10033# Files that config.status was made for.
10034if test -n "$ac_config_files"; then
10035  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
10036fi
10037
10038if test -n "$ac_config_headers"; then
10039  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
10040fi
10041
10042if test -n "$ac_config_links"; then
10043  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
10044fi
10045
10046if test -n "$ac_config_commands"; then
10047  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
10048fi
10049
10050cat >>$CONFIG_STATUS <<\EOF
10051
10052ac_cs_usage="\
10053\`$as_me' instantiates files from templates according to the
10054current configuration.
10055
10056Usage: $0 [OPTIONS] [FILE]...
10057
10058  -h, --help       print this help, then exit
10059  -V, --version    print version number, then exit
10060  -d, --debug      don't remove temporary files
10061      --recheck    update $as_me by reconfiguring in the same conditions
10062  --file=FILE[:TEMPLATE]
10063                   instantiate the configuration file FILE
10064  --header=FILE[:TEMPLATE]
10065                   instantiate the configuration header FILE
10066
10067Configuration files:
10068$config_files
10069
10070Configuration headers:
10071$config_headers
10072
10073Configuration commands:
10074$config_commands
10075
10076Report bugs to <bug-autoconf@gnu.org>."
10077EOF
10078
10079cat >>$CONFIG_STATUS <<EOF
10080ac_cs_version="\\
10081config.status
10082configured by $0, generated by GNU Autoconf 2.52,
10083  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
10084
10085Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
10086Free Software Foundation, Inc.
10087This config.status script is free software; the Free Software Foundation
10088gives unlimited permission to copy, distribute and modify it."
10089srcdir=$srcdir
10090INSTALL="$INSTALL"
10091EOF
10092
10093cat >>$CONFIG_STATUS <<\EOF
10094# If no file are specified by the user, then we need to provide default
10095# value.  By we need to know if files were specified by the user.
10096ac_need_defaults=:
10097while test $# != 0
10098do
10099  case $1 in
10100  --*=*)
10101    ac_option=`expr "x$1" : 'x\([^=]*\)='`
10102    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
10103    shift
10104    set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
10105    shift
10106    ;;
10107  -*);;
10108  *) # This is not an option, so the user has probably given explicit
10109     # arguments.
10110     ac_need_defaults=false;;
10111  esac
10112
10113  case $1 in
10114  # Handling of the options.
10115EOF
10116cat >>$CONFIG_STATUS <<EOF
10117  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
10118    echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
10119    exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
10120EOF
10121cat >>$CONFIG_STATUS <<\EOF
10122  --version | --vers* | -V )
10123    echo "$ac_cs_version"; exit 0 ;;
10124  --he | --h)
10125    # Conflict between --help and --header
10126    { { echo "$as_me:10126: error: ambiguous option: $1
10127Try \`$0 --help' for more information." >&5
10128echo "$as_me: error: ambiguous option: $1
10129Try \`$0 --help' for more information." >&2;}
10130   { (exit 1); exit 1; }; };;
10131  --help | --hel | -h )
10132    echo "$ac_cs_usage"; exit 0 ;;
10133  --debug | --d* | -d )
10134    debug=: ;;
10135  --file | --fil | --fi | --f )
10136    shift
10137    CONFIG_FILES="$CONFIG_FILES $1"
10138    ac_need_defaults=false;;
10139  --header | --heade | --head | --hea )
10140    shift
10141    CONFIG_HEADERS="$CONFIG_HEADERS $1"
10142    ac_need_defaults=false;;
10143
10144  # This is an error.
10145  -*) { { echo "$as_me:10145: error: unrecognized option: $1
10146Try \`$0 --help' for more information." >&5
10147echo "$as_me: error: unrecognized option: $1
10148Try \`$0 --help' for more information." >&2;}
10149   { (exit 1); exit 1; }; } ;;
10150
10151  *) ac_config_targets="$ac_config_targets $1" ;;
10152
10153  esac
10154  shift
10155done
10156
10157exec 5>>config.log
10158cat >&5 << _ACEOF
10159
10160## ----------------------- ##
10161## Running config.status.  ##
10162## ----------------------- ##
10163
10164This file was extended by $as_me 2.52, executed with
10165  CONFIG_FILES    = $CONFIG_FILES
10166  CONFIG_HEADERS  = $CONFIG_HEADERS
10167  CONFIG_LINKS    = $CONFIG_LINKS
10168  CONFIG_COMMANDS = $CONFIG_COMMANDS
10169  > $ac_cs_invocation
10170on `(hostname || uname -n) 2>/dev/null | sed 1q`
10171
10172_ACEOF
10173EOF
10174
10175cat >>$CONFIG_STATUS <<EOF
10176#
10177# INIT-COMMANDS section.
10178#
10179
10180EOF
10181
10182cat >>$CONFIG_STATUS <<\EOF
10183for ac_config_target in $ac_config_targets
10184do
10185  case "$ac_config_target" in
10186  # Handling of arguments.
10187  "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
10188  "gltt.spec" ) CONFIG_FILES="$CONFIG_FILES gltt.spec" ;;
10189  "default-1" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
10190  "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
10191  *) { { echo "$as_me:10191: error: invalid argument: $ac_config_target" >&5
10192echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
10193   { (exit 1); exit 1; }; };;
10194  esac
10195done
10196
10197# If the user did not use the arguments to specify the items to instantiate,
10198# then the envvar interface is used.  Set only those that are not.
10199# We use the long form for the default assignment because of an extremely
10200# bizarre bug on SunOS 4.1.3.
10201if $ac_need_defaults; then
10202  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
10203  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
10204  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
10205fi
10206
10207# Create a temporary directory, and hook for its removal unless debugging.
10208$debug ||
10209{
10210  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
10211  trap '{ (exit 1); exit 1; }' 1 2 13 15
10212}
10213
10214# Create a (secure) tmp directory for tmp files.
10215: ${TMPDIR=/tmp}
10216{
10217  tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
10218  test -n "$tmp" && test -d "$tmp"
10219}  ||
10220{
10221  tmp=$TMPDIR/cs$$-$RANDOM
10222  (umask 077 && mkdir $tmp)
10223} ||
10224{
10225   echo "$me: cannot create a temporary directory in $TMPDIR" >&2
10226   { (exit 1); exit 1; }
10227}
10228
10229EOF
10230
10231cat >>$CONFIG_STATUS <<EOF
10232
10233#
10234# CONFIG_FILES section.
10235#
10236
10237# No need to generate the scripts if there are no CONFIG_FILES.
10238# This happens for instance when ./config.status config.h
10239if test -n "\$CONFIG_FILES"; then
10240  # Protect against being on the right side of a sed subst in config.status.
10241  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
10242   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
10243s,@SHELL@,$SHELL,;t t
10244s,@exec_prefix@,$exec_prefix,;t t
10245s,@prefix@,$prefix,;t t
10246s,@program_transform_name@,$program_transform_name,;t t
10247s,@bindir@,$bindir,;t t
10248s,@sbindir@,$sbindir,;t t
10249s,@libexecdir@,$libexecdir,;t t
10250s,@datadir@,$datadir,;t t
10251s,@sysconfdir@,$sysconfdir,;t t
10252s,@sharedstatedir@,$sharedstatedir,;t t
10253s,@localstatedir@,$localstatedir,;t t
10254s,@libdir@,$libdir,;t t
10255s,@includedir@,$includedir,;t t
10256s,@oldincludedir@,$oldincludedir,;t t
10257s,@infodir@,$infodir,;t t
10258s,@mandir@,$mandir,;t t
10259s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
10260s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
10261s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
10262s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
10263s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
10264s,@build_alias@,$build_alias,;t t
10265s,@host_alias@,$host_alias,;t t
10266s,@target_alias@,$target_alias,;t t
10267s,@ECHO_C@,$ECHO_C,;t t
10268s,@ECHO_N@,$ECHO_N,;t t
10269s,@ECHO_T@,$ECHO_T,;t t
10270s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
10271s,@DEFS@,$DEFS,;t t
10272s,@LIBS@,$LIBS,;t t
10273s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
10274s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
10275s,@INSTALL_DATA@,$INSTALL_DATA,;t t
10276s,@PACKAGE@,$PACKAGE,;t t
10277s,@VERSION@,$VERSION,;t t
10278s,@ACLOCAL@,$ACLOCAL,;t t
10279s,@AUTOCONF@,$AUTOCONF,;t t
10280s,@AUTOMAKE@,$AUTOMAKE,;t t
10281s,@AUTOHEADER@,$AUTOHEADER,;t t
10282s,@MAKEINFO@,$MAKEINFO,;t t
10283s,@SET_MAKE@,$SET_MAKE,;t t
10284s,@CC@,$CC,;t t
10285s,@CFLAGS@,$CFLAGS,;t t
10286s,@LDFLAGS@,$LDFLAGS,;t t
10287s,@CPPFLAGS@,$CPPFLAGS,;t t
10288s,@ac_ct_CC@,$ac_ct_CC,;t t
10289s,@EXEEXT@,$EXEEXT,;t t
10290s,@OBJEXT@,$OBJEXT,;t t
10291s,@CPP@,$CPP,;t t
10292s,@CXX@,$CXX,;t t
10293s,@CXXFLAGS@,$CXXFLAGS,;t t
10294s,@ac_ct_CXX@,$ac_ct_CXX,;t t
10295s,@build@,$build,;t t
10296s,@build_cpu@,$build_cpu,;t t
10297s,@build_vendor@,$build_vendor,;t t
10298s,@build_os@,$build_os,;t t
10299s,@host@,$host,;t t
10300s,@host_cpu@,$host_cpu,;t t
10301s,@host_vendor@,$host_vendor,;t t
10302s,@host_os@,$host_os,;t t
10303s,@LN_S@,$LN_S,;t t
10304s,@ECHO@,$ECHO,;t t
10305s,@RANLIB@,$RANLIB,;t t
10306s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
10307s,@STRIP@,$STRIP,;t t
10308s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
10309s,@LIBTOOL@,$LIBTOOL,;t t
10310s,@ttf_libraries@,$ttf_libraries,;t t
10311s,@ttf_includes@,$ttf_includes,;t t
10312s,@TTF_INCLUDES@,$TTF_INCLUDES,;t t
10313s,@TTF_LDFLAGS@,$TTF_LDFLAGS,;t t
10314s,@LIBSOCKET@,$LIBSOCKET,;t t
10315s,@LIBUCB@,$LIBUCB,;t t
10316s,@CXXCPP@,$CXXCPP,;t t
10317s,@X_CFLAGS@,$X_CFLAGS,;t t
10318s,@X_PRE_LIBS@,$X_PRE_LIBS,;t t
10319s,@X_LIBS@,$X_LIBS,;t t
10320s,@X_EXTRA_LIBS@,$X_EXTRA_LIBS,;t t
10321s,@X_INCLUDES@,$X_INCLUDES,;t t
10322s,@X_LDFLAGS@,$X_LDFLAGS,;t t
10323s,@gl_libraries@,$gl_libraries,;t t
10324s,@gl_includes@,$gl_includes,;t t
10325s,@GL_INCLUDES@,$GL_INCLUDES,;t t
10326s,@GL_LDFLAGS@,$GL_LDFLAGS,;t t
10327s,@GL_LIBNAME@,$GL_LIBNAME,;t t
10328s,@glut_libraries@,$glut_libraries,;t t
10329s,@glut_includes@,$glut_includes,;t t
10330s,@GLUT_INCLUDES@,$GLUT_INCLUDES,;t t
10331s,@GLUT_LDFLAGS@,$GLUT_LDFLAGS,;t t
10332s,@GLTT_MAKE_TARGET@,$GLTT_MAKE_TARGET,;t t
10333s,@topdir@,$topdir,;t t
10334CEOF
10335
10336EOF
10337
10338  cat >>$CONFIG_STATUS <<\EOF
10339  # Split the substitutions into bite-sized pieces for seds with
10340  # small command number limits, like on Digital OSF/1 and HP-UX.
10341  ac_max_sed_lines=48
10342  ac_sed_frag=1 # Number of current file.
10343  ac_beg=1 # First line for current file.
10344  ac_end=$ac_max_sed_lines # Line after last line for current file.
10345  ac_more_lines=:
10346  ac_sed_cmds=
10347  while $ac_more_lines; do
10348    if test $ac_beg -gt 1; then
10349      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
10350    else
10351      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
10352    fi
10353    if test ! -s $tmp/subs.frag; then
10354      ac_more_lines=false
10355    else
10356      # The purpose of the label and of the branching condition is to
10357      # speed up the sed processing (if there are no `@' at all, there
10358      # is no need to browse any of the substitutions).
10359      # These are the two extra sed commands mentioned above.
10360      (echo ':t
10361  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
10362      if test -z "$ac_sed_cmds"; then
10363  	ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
10364      else
10365  	ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
10366      fi
10367      ac_sed_frag=`expr $ac_sed_frag + 1`
10368      ac_beg=$ac_end
10369      ac_end=`expr $ac_end + $ac_max_sed_lines`
10370    fi
10371  done
10372  if test -z "$ac_sed_cmds"; then
10373    ac_sed_cmds=cat
10374  fi
10375fi # test -n "$CONFIG_FILES"
10376
10377EOF
10378cat >>$CONFIG_STATUS <<\EOF
10379for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
10380  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10381  case $ac_file in
10382  - | *:- | *:-:* ) # input from stdin
10383        cat >$tmp/stdin
10384        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
10385        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
10386  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
10387        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
10388  * )   ac_file_in=$ac_file.in ;;
10389  esac
10390
10391  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
10392  ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
10393         X"$ac_file" : 'X\(//\)[^/]' \| \
10394         X"$ac_file" : 'X\(//\)$' \| \
10395         X"$ac_file" : 'X\(/\)' \| \
10396         .     : '\(.\)' 2>/dev/null ||
10397echo X"$ac_file" |
10398    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
10399  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
10400  	  /^X\(\/\/\)$/{ s//\1/; q; }
10401  	  /^X\(\/\).*/{ s//\1/; q; }
10402  	  s/.*/./; q'`
10403  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10404    { case "$ac_dir" in
10405  [\\/]* | ?:[\\/]* ) as_incr_dir=;;
10406  *)                      as_incr_dir=.;;
10407esac
10408as_dummy="$ac_dir"
10409for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
10410  case $as_mkdir_dir in
10411    # Skip DOS drivespec
10412    ?:) as_incr_dir=$as_mkdir_dir ;;
10413    *)
10414      as_incr_dir=$as_incr_dir/$as_mkdir_dir
10415      test -d "$as_incr_dir" || mkdir "$as_incr_dir"
10416    ;;
10417  esac
10418done; }
10419
10420    ac_dir_suffix="/`echo $ac_dir|sed 's,^\./,,'`"
10421    # A "../" for each directory in $ac_dir_suffix.
10422    ac_dots=`echo "$ac_dir_suffix" | sed 's,/[^/]*,../,g'`
10423  else
10424    ac_dir_suffix= ac_dots=
10425  fi
10426
10427  case $srcdir in
10428  .)  ac_srcdir=.
10429      if test -z "$ac_dots"; then
10430         ac_top_srcdir=.
10431      else
10432         ac_top_srcdir=`echo $ac_dots | sed 's,/$,,'`
10433      fi ;;
10434  [\\/]* | ?:[\\/]* )
10435      ac_srcdir=$srcdir$ac_dir_suffix;
10436      ac_top_srcdir=$srcdir ;;
10437  *) # Relative path.
10438    ac_srcdir=$ac_dots$srcdir$ac_dir_suffix
10439    ac_top_srcdir=$ac_dots$srcdir ;;
10440  esac
10441
10442  case $INSTALL in
10443  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
10444  *) ac_INSTALL=$ac_dots$INSTALL ;;
10445  esac
10446
10447  if test x"$ac_file" != x-; then
10448    { echo "$as_me:10448: creating $ac_file" >&5
10449echo "$as_me: creating $ac_file" >&6;}
10450    rm -f "$ac_file"
10451  fi
10452  # Let's still pretend it is `configure' which instantiates (i.e., don't
10453  # use $as_me), people would be surprised to read:
10454  #    /* config.h.  Generated automatically by config.status.  */
10455  configure_input="Generated automatically from `echo $ac_file_in |
10456                                                 sed 's,.*/,,'` by configure."
10457
10458  # First look for the input files in the build tree, otherwise in the
10459  # src tree.
10460  ac_file_inputs=`IFS=:
10461    for f in $ac_file_in; do
10462      case $f in
10463      -) echo $tmp/stdin ;;
10464      [\\/$]*)
10465         # Absolute (can't be DOS-style, as IFS=:)
10466         test -f "$f" || { { echo "$as_me:10466: error: cannot find input file: $f" >&5
10467echo "$as_me: error: cannot find input file: $f" >&2;}
10468   { (exit 1); exit 1; }; }
10469         echo $f;;
10470      *) # Relative
10471         if test -f "$f"; then
10472           # Build tree
10473           echo $f
10474         elif test -f "$srcdir/$f"; then
10475           # Source tree
10476           echo $srcdir/$f
10477         else
10478           # /dev/null tree
10479           { { echo "$as_me:10479: error: cannot find input file: $f" >&5
10480echo "$as_me: error: cannot find input file: $f" >&2;}
10481   { (exit 1); exit 1; }; }
10482         fi;;
10483      esac
10484    done` || { (exit 1); exit 1; }
10485EOF
10486cat >>$CONFIG_STATUS <<EOF
10487  sed "$ac_vpsub
10488$extrasub
10489EOF
10490cat >>$CONFIG_STATUS <<\EOF
10491:t
10492/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
10493s,@configure_input@,$configure_input,;t t
10494s,@srcdir@,$ac_srcdir,;t t
10495s,@top_srcdir@,$ac_top_srcdir,;t t
10496s,@INSTALL@,$ac_INSTALL,;t t
10497" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
10498  rm -f $tmp/stdin
10499  if test x"$ac_file" != x-; then
10500    mv $tmp/out $ac_file
10501  else
10502    cat $tmp/out
10503    rm -f $tmp/out
10504  fi
10505
10506done
10507EOF
10508cat >>$CONFIG_STATUS <<\EOF
10509
10510#
10511# CONFIG_HEADER section.
10512#
10513
10514# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
10515# NAME is the cpp macro being defined and VALUE is the value it is being given.
10516#
10517# ac_d sets the value in "#define NAME VALUE" lines.
10518ac_dA='s,^\([ 	]*\)#\([ 	]*define[ 	][ 	]*\)'
10519ac_dB='[ 	].*$,\1#\2'
10520ac_dC=' '
10521ac_dD=',;t'
10522# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
10523ac_uA='s,^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
10524ac_uB='$,\1#\2define\3'
10525ac_uC=' '
10526ac_uD=',;t'
10527
10528for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
10529  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10530  case $ac_file in
10531  - | *:- | *:-:* ) # input from stdin
10532        cat >$tmp/stdin
10533        ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
10534        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
10535  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
10536        ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
10537  * )   ac_file_in=$ac_file.in ;;
10538  esac
10539
10540  test x"$ac_file" != x- && { echo "$as_me:10540: creating $ac_file" >&5
10541echo "$as_me: creating $ac_file" >&6;}
10542
10543  # First look for the input files in the build tree, otherwise in the
10544  # src tree.
10545  ac_file_inputs=`IFS=:
10546    for f in $ac_file_in; do
10547      case $f in
10548      -) echo $tmp/stdin ;;
10549      [\\/$]*)
10550         # Absolute (can't be DOS-style, as IFS=:)
10551         test -f "$f" || { { echo "$as_me:10551: error: cannot find input file: $f" >&5
10552echo "$as_me: error: cannot find input file: $f" >&2;}
10553   { (exit 1); exit 1; }; }
10554         echo $f;;
10555      *) # Relative
10556         if test -f "$f"; then
10557           # Build tree
10558           echo $f
10559         elif test -f "$srcdir/$f"; then
10560           # Source tree
10561           echo $srcdir/$f
10562         else
10563           # /dev/null tree
10564           { { echo "$as_me:10564: error: cannot find input file: $f" >&5
10565echo "$as_me: error: cannot find input file: $f" >&2;}
10566   { (exit 1); exit 1; }; }
10567         fi;;
10568      esac
10569    done` || { (exit 1); exit 1; }
10570  # Remove the trailing spaces.
10571  sed 's/[ 	]*$//' $ac_file_inputs >$tmp/in
10572
10573EOF
10574
10575# Transform confdefs.h into two sed scripts, `conftest.defines' and
10576# `conftest.undefs', that substitutes the proper values into
10577# config.h.in to produce config.h.  The first handles `#define'
10578# templates, and the second `#undef' templates.
10579# And first: Protect against being on the right side of a sed subst in
10580# config.status.  Protect against being in an unquoted here document
10581# in config.status.
10582rm -f conftest.defines conftest.undefs
10583# Using a here document instead of a string reduces the quoting nightmare.
10584# Putting comments in sed scripts is not portable.
10585#
10586# `end' is used to avoid that the second main sed command (meant for
10587# 0-ary CPP macros) applies to n-ary macro definitions.
10588# See the Autoconf documentation for `clear'.
10589cat >confdef2sed.sed <<\EOF
10590s/[\\&,]/\\&/g
10591s,[\\$`],\\&,g
10592t clear
10593: clear
10594s,^[ 	]*#[ 	]*define[ 	][ 	]*\(\([^ 	(][^ 	(]*\)([^)]*)\)[ 	]*\(.*\)$,${ac_dA}\2${ac_dB}\1${ac_dC}\3${ac_dD},gp
10595t end
10596s,^[ 	]*#[ 	]*define[ 	][ 	]*\([^ 	][^ 	]*\)[ 	]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
10597: end
10598EOF
10599# If some macros were called several times there might be several times
10600# the same #defines, which is useless.  Nevertheless, we may not want to
10601# sort them, since we want the *last* AC-DEFINE to be honored.
10602uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
10603sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
10604rm -f confdef2sed.sed
10605
10606# This sed command replaces #undef with comments.  This is necessary, for
10607# example, in the case of _POSIX_SOURCE, which is predefined and required
10608# on some systems where configure will not decide to define it.
10609cat >>conftest.undefs <<\EOF
10610s,^[ 	]*#[ 	]*undef[ 	][ 	]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
10611EOF
10612
10613# Break up conftest.defines because some shells have a limit on the size
10614# of here documents, and old seds have small limits too (100 cmds).
10615echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
10616echo '  if egrep "^[ 	]*#[ 	]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
10617echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
10618echo '  :' >>$CONFIG_STATUS
10619rm -f conftest.tail
10620while grep . conftest.defines >/dev/null
10621do
10622  # Write a limited-size here document to $tmp/defines.sed.
10623  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
10624  # Speed up: don't consider the non `#define' lines.
10625  echo '/^[ 	]*#[ 	]*define/!b' >>$CONFIG_STATUS
10626  # Work around the forget-to-reset-the-flag bug.
10627  echo 't clr' >>$CONFIG_STATUS
10628  echo ': clr' >>$CONFIG_STATUS
10629  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
10630  echo 'CEOF
10631  sed -f $tmp/defines.sed $tmp/in >$tmp/out
10632  rm -f $tmp/in
10633  mv $tmp/out $tmp/in
10634' >>$CONFIG_STATUS
10635  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
10636  rm -f conftest.defines
10637  mv conftest.tail conftest.defines
10638done
10639rm -f conftest.defines
10640echo '  fi # egrep' >>$CONFIG_STATUS
10641echo >>$CONFIG_STATUS
10642
10643# Break up conftest.undefs because some shells have a limit on the size
10644# of here documents, and old seds have small limits too (100 cmds).
10645echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
10646rm -f conftest.tail
10647while grep . conftest.undefs >/dev/null
10648do
10649  # Write a limited-size here document to $tmp/undefs.sed.
10650  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
10651  # Speed up: don't consider the non `#undef'
10652  echo '/^[ 	]*#[ 	]*undef/!b' >>$CONFIG_STATUS
10653  # Work around the forget-to-reset-the-flag bug.
10654  echo 't clr' >>$CONFIG_STATUS
10655  echo ': clr' >>$CONFIG_STATUS
10656  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
10657  echo 'CEOF
10658  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
10659  rm -f $tmp/in
10660  mv $tmp/out $tmp/in
10661' >>$CONFIG_STATUS
10662  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
10663  rm -f conftest.undefs
10664  mv conftest.tail conftest.undefs
10665done
10666rm -f conftest.undefs
10667
10668cat >>$CONFIG_STATUS <<\EOF
10669  # Let's still pretend it is `configure' which instantiates (i.e., don't
10670  # use $as_me), people would be surprised to read:
10671  #    /* config.h.  Generated automatically by config.status.  */
10672  if test x"$ac_file" = x-; then
10673    echo "/* Generated automatically by configure.  */" >$tmp/config.h
10674  else
10675    echo "/* $ac_file.  Generated automatically by configure.  */" >$tmp/config.h
10676  fi
10677  cat $tmp/in >>$tmp/config.h
10678  rm -f $tmp/in
10679  if test x"$ac_file" != x-; then
10680    if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
10681      { echo "$as_me:10681: $ac_file is unchanged" >&5
10682echo "$as_me: $ac_file is unchanged" >&6;}
10683    else
10684      ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
10685         X"$ac_file" : 'X\(//\)[^/]' \| \
10686         X"$ac_file" : 'X\(//\)$' \| \
10687         X"$ac_file" : 'X\(/\)' \| \
10688         .     : '\(.\)' 2>/dev/null ||
10689echo X"$ac_file" |
10690    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
10691  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
10692  	  /^X\(\/\/\)$/{ s//\1/; q; }
10693  	  /^X\(\/\).*/{ s//\1/; q; }
10694  	  s/.*/./; q'`
10695      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10696        { case "$ac_dir" in
10697  [\\/]* | ?:[\\/]* ) as_incr_dir=;;
10698  *)                      as_incr_dir=.;;
10699esac
10700as_dummy="$ac_dir"
10701for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
10702  case $as_mkdir_dir in
10703    # Skip DOS drivespec
10704    ?:) as_incr_dir=$as_mkdir_dir ;;
10705    *)
10706      as_incr_dir=$as_incr_dir/$as_mkdir_dir
10707      test -d "$as_incr_dir" || mkdir "$as_incr_dir"
10708    ;;
10709  esac
10710done; }
10711
10712      fi
10713      rm -f $ac_file
10714      mv $tmp/config.h $ac_file
10715    fi
10716  else
10717    cat $tmp/config.h
10718    rm -f $tmp/config.h
10719  fi
10720done
10721EOF
10722cat >>$CONFIG_STATUS <<\EOF
10723
10724#
10725# CONFIG_COMMANDS section.
10726#
10727for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
10728  ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
10729  ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
10730
10731  case $ac_dest in
10732    default-1 ) test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h ;;
10733  esac
10734done
10735EOF
10736
10737cat >>$CONFIG_STATUS <<\EOF
10738
10739{ (exit 0); exit 0; }
10740EOF
10741chmod +x $CONFIG_STATUS
10742ac_clean_files=$ac_clean_files_save
10743
10744# configure is writing to config.log, and then calls config.status.
10745# config.status does its own redirection, appending to config.log.
10746# Unfortunately, on DOS this fails, as config.log is still kept open
10747# by configure, so config.status won't be able to write to it; its
10748# output is simply discarded.  So we exec the FD to /dev/null,
10749# effectively closing config.log, so it can be properly (re)opened and
10750# appended to by config.status.  When coming back to configure, we
10751# need to make the FD available again.
10752if test "$no_create" != yes; then
10753  ac_cs_success=:
10754  exec 5>/dev/null
10755  $SHELL $CONFIG_STATUS || ac_cs_success=false
10756  exec 5>>config.log
10757  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
10758  # would make configure fail if this is the last instruction.
10759  $ac_cs_success || { (exit 1); exit 1; }
10760fi
10761
10762