source: abuse/tags/pd/abuse/configure @ 49

Last change on this file since 49 was 49, checked in by Sam Hocevar, 11 years ago
  • Imported original public domain release, for future reference.
  • Property svn:executable set to *
File size: 84.9 KB
Line 
1#! /bin/sh
2
3# Guess values for system-dependent variables and create Makefiles.
4# Generated automatically using autoconf version 2.12
5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6#
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9
10# Defaults:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
14ac_help="$ac_help
15  --with-x                use the X Window System"
16
17# Initialize some variables set by options.
18# The variables have the same names as the options, with
19# dashes changed to underlines.
20build=NONE
21cache_file=./config.cache
22exec_prefix=NONE
23host=NONE
24no_create=
25nonopt=NONE
26no_recursion=
27prefix=NONE
28program_prefix=NONE
29program_suffix=NONE
30program_transform_name=s,x,x,
31silent=
32site=
33srcdir=
34target=NONE
35verbose=
36x_includes=NONE
37x_libraries=NONE
38bindir='${exec_prefix}/bin'
39sbindir='${exec_prefix}/sbin'
40libexecdir='${exec_prefix}/libexec'
41datadir='${prefix}/share'
42sysconfdir='${prefix}/etc'
43sharedstatedir='${prefix}/com'
44localstatedir='${prefix}/var'
45libdir='${exec_prefix}/lib'
46includedir='${prefix}/include'
47oldincludedir='/usr/include'
48infodir='${prefix}/info'
49mandir='${prefix}/man'
50
51# Initialize some other variables.
52subdirs=
53MFLAGS= MAKEFLAGS=
54# Maximum number of lines to put in a shell here document.
55ac_max_here_lines=12
56
57ac_prev=
58for ac_option
59do
60
61  # If the previous option needs an argument, assign it.
62  if test -n "$ac_prev"; then
63    eval "$ac_prev=\$ac_option"
64    ac_prev=
65    continue
66  fi
67
68  case "$ac_option" in
69  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
70  *) ac_optarg= ;;
71  esac
72
73  # Accept the important Cygnus configure options, so we can diagnose typos.
74
75  case "$ac_option" in
76
77  -bindir | --bindir | --bindi | --bind | --bin | --bi)
78    ac_prev=bindir ;;
79  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
80    bindir="$ac_optarg" ;;
81
82  -build | --build | --buil | --bui | --bu)
83    ac_prev=build ;;
84  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
85    build="$ac_optarg" ;;
86
87  -cache-file | --cache-file | --cache-fil | --cache-fi \
88  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
89    ac_prev=cache_file ;;
90  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
91  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
92    cache_file="$ac_optarg" ;;
93
94  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
95    ac_prev=datadir ;;
96  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
97  | --da=*)
98    datadir="$ac_optarg" ;;
99
100  -disable-* | --disable-*)
101    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
102    # Reject names that are not valid shell variable names.
103    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
104      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
105    fi
106    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
107    eval "enable_${ac_feature}=no" ;;
108
109  -enable-* | --enable-*)
110    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
111    # Reject names that are not valid shell variable names.
112    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
113      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
114    fi
115    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
116    case "$ac_option" in
117      *=*) ;;
118      *) ac_optarg=yes ;;
119    esac
120    eval "enable_${ac_feature}='$ac_optarg'" ;;
121
122  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
123  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
124  | --exec | --exe | --ex)
125    ac_prev=exec_prefix ;;
126  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
127  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
128  | --exec=* | --exe=* | --ex=*)
129    exec_prefix="$ac_optarg" ;;
130
131  -gas | --gas | --ga | --g)
132    # Obsolete; use --with-gas.
133    with_gas=yes ;;
134
135  -help | --help | --hel | --he)
136    # Omit some internal or obsolete options to make the list less imposing.
137    # This message is too long to be a string in the A/UX 3.1 sh.
138    cat << EOF
139Usage: configure [options] [host]
140Options: [defaults in brackets after descriptions]
141Configuration:
142  --cache-file=FILE       cache test results in FILE
143  --help                  print this message
144  --no-create             do not create output files
145  --quiet, --silent       do not print \`checking...' messages
146  --version               print the version of autoconf that created configure
147Directory and file names:
148  --prefix=PREFIX         install architecture-independent files in PREFIX
149                          [$ac_default_prefix]
150  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
151                          [same as prefix]
152  --bindir=DIR            user executables in DIR [EPREFIX/bin]
153  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
154  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
155  --datadir=DIR           read-only architecture-independent data in DIR
156                          [PREFIX/share]
157  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
158  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
159                          [PREFIX/com]
160  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
161  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
162  --includedir=DIR        C header files in DIR [PREFIX/include]
163  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
164  --infodir=DIR           info documentation in DIR [PREFIX/info]
165  --mandir=DIR            man documentation in DIR [PREFIX/man]
166  --srcdir=DIR            find the sources in DIR [configure dir or ..]
167  --program-prefix=PREFIX prepend PREFIX to installed program names
168  --program-suffix=SUFFIX append SUFFIX to installed program names
169  --program-transform-name=PROGRAM
170                          run sed PROGRAM on installed program names
171EOF
172    cat << EOF
173Host type:
174  --build=BUILD           configure for building on BUILD [BUILD=HOST]
175  --host=HOST             configure for HOST [guessed]
176  --target=TARGET         configure for TARGET [TARGET=HOST]
177Features and packages:
178  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
179  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
180  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
181  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
182  --x-includes=DIR        X include files are in DIR
183  --x-libraries=DIR       X library files are in DIR
184EOF
185    if test -n "$ac_help"; then
186      echo "--enable and --with options recognized:$ac_help"
187    fi
188    exit 0 ;;
189
190  -host | --host | --hos | --ho)
191    ac_prev=host ;;
192  -host=* | --host=* | --hos=* | --ho=*)
193    host="$ac_optarg" ;;
194
195  -includedir | --includedir | --includedi | --included | --include \
196  | --includ | --inclu | --incl | --inc)
197    ac_prev=includedir ;;
198  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
199  | --includ=* | --inclu=* | --incl=* | --inc=*)
200    includedir="$ac_optarg" ;;
201
202  -infodir | --infodir | --infodi | --infod | --info | --inf)
203    ac_prev=infodir ;;
204  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
205    infodir="$ac_optarg" ;;
206
207  -libdir | --libdir | --libdi | --libd)
208    ac_prev=libdir ;;
209  -libdir=* | --libdir=* | --libdi=* | --libd=*)
210    libdir="$ac_optarg" ;;
211
212  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
213  | --libexe | --libex | --libe)
214    ac_prev=libexecdir ;;
215  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
216  | --libexe=* | --libex=* | --libe=*)
217    libexecdir="$ac_optarg" ;;
218
219  -localstatedir | --localstatedir | --localstatedi | --localstated \
220  | --localstate | --localstat | --localsta | --localst \
221  | --locals | --local | --loca | --loc | --lo)
222    ac_prev=localstatedir ;;
223  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
224  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
225  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
226    localstatedir="$ac_optarg" ;;
227
228  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
229    ac_prev=mandir ;;
230  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
231    mandir="$ac_optarg" ;;
232
233  -nfp | --nfp | --nf)
234    # Obsolete; use --without-fp.
235    with_fp=no ;;
236
237  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
238  | --no-cr | --no-c)
239    no_create=yes ;;
240
241  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
242  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
243    no_recursion=yes ;;
244
245  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
246  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
247  | --oldin | --oldi | --old | --ol | --o)
248    ac_prev=oldincludedir ;;
249  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
250  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
251  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
252    oldincludedir="$ac_optarg" ;;
253
254  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
255    ac_prev=prefix ;;
256  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
257    prefix="$ac_optarg" ;;
258
259  -program-prefix | --program-prefix | --program-prefi | --program-pref \
260  | --program-pre | --program-pr | --program-p)
261    ac_prev=program_prefix ;;
262  -program-prefix=* | --program-prefix=* | --program-prefi=* \
263  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
264    program_prefix="$ac_optarg" ;;
265
266  -program-suffix | --program-suffix | --program-suffi | --program-suff \
267  | --program-suf | --program-su | --program-s)
268    ac_prev=program_suffix ;;
269  -program-suffix=* | --program-suffix=* | --program-suffi=* \
270  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
271    program_suffix="$ac_optarg" ;;
272
273  -program-transform-name | --program-transform-name \
274  | --program-transform-nam | --program-transform-na \
275  | --program-transform-n | --program-transform- \
276  | --program-transform | --program-transfor \
277  | --program-transfo | --program-transf \
278  | --program-trans | --program-tran \
279  | --progr-tra | --program-tr | --program-t)
280    ac_prev=program_transform_name ;;
281  -program-transform-name=* | --program-transform-name=* \
282  | --program-transform-nam=* | --program-transform-na=* \
283  | --program-transform-n=* | --program-transform-=* \
284  | --program-transform=* | --program-transfor=* \
285  | --program-transfo=* | --program-transf=* \
286  | --program-trans=* | --program-tran=* \
287  | --progr-tra=* | --program-tr=* | --program-t=*)
288    program_transform_name="$ac_optarg" ;;
289
290  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
291  | -silent | --silent | --silen | --sile | --sil)
292    silent=yes ;;
293
294  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
295    ac_prev=sbindir ;;
296  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
297  | --sbi=* | --sb=*)
298    sbindir="$ac_optarg" ;;
299
300  -sharedstatedir | --sharedstatedir | --sharedstatedi \
301  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
302  | --sharedst | --shareds | --shared | --share | --shar \
303  | --sha | --sh)
304    ac_prev=sharedstatedir ;;
305  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
306  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
307  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
308  | --sha=* | --sh=*)
309    sharedstatedir="$ac_optarg" ;;
310
311  -site | --site | --sit)
312    ac_prev=site ;;
313  -site=* | --site=* | --sit=*)
314    site="$ac_optarg" ;;
315
316  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
317    ac_prev=srcdir ;;
318  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
319    srcdir="$ac_optarg" ;;
320
321  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
322  | --syscon | --sysco | --sysc | --sys | --sy)
323    ac_prev=sysconfdir ;;
324  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
325  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
326    sysconfdir="$ac_optarg" ;;
327
328  -target | --target | --targe | --targ | --tar | --ta | --t)
329    ac_prev=target ;;
330  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
331    target="$ac_optarg" ;;
332
333  -v | -verbose | --verbose | --verbos | --verbo | --verb)
334    verbose=yes ;;
335
336  -version | --version | --versio | --versi | --vers)
337    echo "configure generated by autoconf version 2.12"
338    exit 0 ;;
339
340  -with-* | --with-*)
341    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
342    # Reject names that are not valid shell variable names.
343    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
344      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
345    fi
346    ac_package=`echo $ac_package| sed 's/-/_/g'`
347    case "$ac_option" in
348      *=*) ;;
349      *) ac_optarg=yes ;;
350    esac
351    eval "with_${ac_package}='$ac_optarg'" ;;
352
353  -without-* | --without-*)
354    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
355    # Reject names that are not valid shell variable names.
356    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
357      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
358    fi
359    ac_package=`echo $ac_package| sed 's/-/_/g'`
360    eval "with_${ac_package}=no" ;;
361
362  --x)
363    # Obsolete; use --with-x.
364    with_x=yes ;;
365
366  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
367  | --x-incl | --x-inc | --x-in | --x-i)
368    ac_prev=x_includes ;;
369  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
370  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
371    x_includes="$ac_optarg" ;;
372
373  -x-libraries | --x-libraries | --x-librarie | --x-librari \
374  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
375    ac_prev=x_libraries ;;
376  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
377  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
378    x_libraries="$ac_optarg" ;;
379
380  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
381    ;;
382
383  *)
384    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
385      echo "configure: warning: $ac_option: invalid host type" 1>&2
386    fi
387    if test "x$nonopt" != xNONE; then
388      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
389    fi
390    nonopt="$ac_option"
391    ;;
392
393  esac
394done
395
396if test -n "$ac_prev"; then
397  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
398fi
399
400trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
401
402# File descriptor usage:
403# 0 standard input
404# 1 file creation
405# 2 errors and warnings
406# 3 some systems may open it to /dev/tty
407# 4 used on the Kubota Titan
408# 6 checking for... messages and results
409# 5 compiler messages saved in config.log
410if test "$silent" = yes; then
411  exec 6>/dev/null
412else
413  exec 6>&1
414fi
415exec 5>./config.log
416
417echo "\
418This file contains any messages produced by compilers while
419running configure, to aid debugging if configure makes a mistake.
420" 1>&5
421
422# Strip out --no-create and --no-recursion so they do not pile up.
423# Also quote any args containing shell metacharacters.
424ac_configure_args=
425for ac_arg
426do
427  case "$ac_arg" in
428  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
429  | --no-cr | --no-c) ;;
430  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
431  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
432  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
433  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
434  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
435  esac
436done
437
438# NLS nuisances.
439# Only set these to C if already set.  These must not be set unconditionally
440# because not all systems understand e.g. LANG=C (notably SCO).
441# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
442# Non-C LC_CTYPE values break the ctype check.
443if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
444if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
445if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
446if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
447
448# confdefs.h avoids OS command line length limits that DEFS can exceed.
449rm -rf conftest* confdefs.h
450# AIX cpp loses on an empty file, so make sure it contains at least a newline.
451echo > confdefs.h
452
453# A filename unique to this package, relative to the directory that
454# configure is in, which we can look for to find out if srcdir is correct.
455ac_unique_file=src/game.c
456
457# Find the source files, if location was not specified.
458if test -z "$srcdir"; then
459  ac_srcdir_defaulted=yes
460  # Try the directory containing this script, then its parent.
461  ac_prog=$0
462  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
463  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
464  srcdir=$ac_confdir
465  if test ! -r $srcdir/$ac_unique_file; then
466    srcdir=..
467  fi
468else
469  ac_srcdir_defaulted=no
470fi
471if test ! -r $srcdir/$ac_unique_file; then
472  if test "$ac_srcdir_defaulted" = yes; then
473    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
474  else
475    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
476  fi
477fi
478srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
479
480# Prefer explicitly selected file to automatically selected ones.
481if test -z "$CONFIG_SITE"; then
482  if test "x$prefix" != xNONE; then
483    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
484  else
485    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
486  fi
487fi
488for ac_site_file in $CONFIG_SITE; do
489  if test -r "$ac_site_file"; then
490    echo "loading site script $ac_site_file"
491    . "$ac_site_file"
492  fi
493done
494
495if test -r "$cache_file"; then
496  echo "loading cache $cache_file"
497  . $cache_file
498else
499  echo "creating cache $cache_file"
500  > $cache_file
501fi
502
503ac_ext=c
504# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
505ac_cpp='$CPP $CPPFLAGS'
506ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
507ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
508cross_compiling=$ac_cv_prog_cc_cross
509
510if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
511  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
512  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
513    ac_n= ac_c='
514' ac_t='        '
515  else
516    ac_n=-n ac_c= ac_t=
517  fi
518else
519  ac_n= ac_c='\c' ac_t=
520fi
521
522
523ac_aux_dir=
524for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
525  if test -f $ac_dir/install-sh; then
526    ac_aux_dir=$ac_dir
527    ac_install_sh="$ac_aux_dir/install-sh -c"
528    break
529  elif test -f $ac_dir/install.sh; then
530    ac_aux_dir=$ac_dir
531    ac_install_sh="$ac_aux_dir/install.sh -c"
532    break
533  fi
534done
535if test -z "$ac_aux_dir"; then
536  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
537fi
538ac_config_guess=$ac_aux_dir/config.guess
539ac_config_sub=$ac_aux_dir/config.sub
540ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
541
542# Find a good install program.  We prefer a C program (faster),
543# so one script is as good as another.  But avoid the broken or
544# incompatible versions:
545# SysV /etc/install, /usr/sbin/install
546# SunOS /usr/etc/install
547# IRIX /sbin/install
548# AIX /bin/install
549# AFS /usr/afsws/bin/install, which mishandles nonexistent args
550# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
551# ./install, which can be erroneously created by make from ./install.sh.
552echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
553echo "configure:554: checking for a BSD compatible install" >&5
554if test -z "$INSTALL"; then
555if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
556  echo $ac_n "(cached) $ac_c" 1>&6
557else
558    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
559  for ac_dir in $PATH; do
560    # Account for people who put trailing slashes in PATH elements.
561    case "$ac_dir/" in
562    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
563    *)
564      # OSF1 and SCO ODT 3.0 have their own names for install.
565      for ac_prog in ginstall installbsd scoinst install; do
566        if test -f $ac_dir/$ac_prog; then
567          if test $ac_prog = install &&
568            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
569            # AIX install.  It has an incompatible calling convention.
570            # OSF/1 installbsd also uses dspmsg, but is usable.
571            :
572          else
573            ac_cv_path_install="$ac_dir/$ac_prog -c"
574            break 2
575          fi
576        fi
577      done
578      ;;
579    esac
580  done
581  IFS="$ac_save_IFS"
582
583fi
584  if test "${ac_cv_path_install+set}" = set; then
585    INSTALL="$ac_cv_path_install"
586  else
587    # As a last resort, use the slow shell script.  We don't cache a
588    # path for INSTALL within a source directory, because that will
589    # break other packages using the cache if that directory is
590    # removed, or if the path is relative.
591    INSTALL="$ac_install_sh"
592  fi
593fi
594echo "$ac_t""$INSTALL" 1>&6
595
596# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
597# It thinks the first close brace ends the variable substitution.
598test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
599
600test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
601
602
603test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
604
605
606PACKAGE=abuse
607
608VERSION=2.0
609
610if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
611  { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
612fi
613cat >> confdefs.h <<EOF
614#define PACKAGE "$PACKAGE"
615EOF
616
617cat >> confdefs.h <<EOF
618#define VERSION "$VERSION"
619EOF
620
621echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
622echo "configure:623: checking whether build environment is sane" >&5
623# Just in case
624sleep 1
625echo timestamp > conftestfile
626# Do `set' in a subshell so we don't clobber the current shell's
627# arguments.  Must try -L first in case configure is actually a
628# symlink; some systems play weird games with the mod time of symlinks
629# (eg FreeBSD returns the mod time of the symlink's containing
630# directory).
631if (
632   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
633   if test "" = "X"; then
634      # -L didn't work.
635      set X `ls -t $srcdir/configure conftestfile`
636   fi
637   test "$2" = conftestfile
638   )
639then
640   # Ok.
641   :
642else
643   echo "configure: warning: newly created file is older than distributed files!
644Check your system clock" 1>&2
645fi
646rm -f conftest*
647echo "$ac_t""yes" 1>&6
648if test "$program_transform_name" = s,x,x,; then
649  program_transform_name=
650else
651  # Double any \ or $.  echo might interpret backslashes.
652  cat <<\EOF_SED > conftestsed
653s,\\,\\\\,g; s,\$,$$,g
654EOF_SED
655  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
656  rm -f conftestsed
657fi
658test "$program_prefix" != NONE &&
659  program_transform_name="s,^,${program_prefix},; $program_transform_name"
660# Use a double $ so make ignores it.
661test "$program_suffix" != NONE &&
662  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
663
664# sed with no file args requires a program.
665test "$program_transform_name" = "" && program_transform_name="s,x,x,"
666
667missing_dir=`cd $ac_aux_dir && pwd`
668echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
669echo "configure:670: checking for working aclocal" >&5
670# Run test in a subshell; some versions of sh will print an error if
671# an executable is not found, even if stderr is redirected.
672# Redirect stdin to placate older versions of autoconf.  Sigh.
673if (aclocal --version) < /dev/null > /dev/null 2>&1; then
674   ACLOCAL=aclocal
675   echo "$ac_t""found" 1>&6
676else
677   ACLOCAL="$missing_dir/missing aclocal"
678   echo "$ac_t""missing" 1>&6
679fi
680
681echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
682echo "configure:683: checking for working autoconf" >&5
683# Run test in a subshell; some versions of sh will print an error if
684# an executable is not found, even if stderr is redirected.
685# Redirect stdin to placate older versions of autoconf.  Sigh.
686if (autoconf --version) < /dev/null > /dev/null 2>&1; then
687   AUTOCONF=autoconf
688   echo "$ac_t""found" 1>&6
689else
690   AUTOCONF="$missing_dir/missing autoconf"
691   echo "$ac_t""missing" 1>&6
692fi
693
694echo $ac_n "checking for working automake""... $ac_c" 1>&6
695echo "configure:696: checking for working automake" >&5
696# Run test in a subshell; some versions of sh will print an error if
697# an executable is not found, even if stderr is redirected.
698# Redirect stdin to placate older versions of autoconf.  Sigh.
699if (automake --version) < /dev/null > /dev/null 2>&1; then
700   AUTOMAKE=automake
701   echo "$ac_t""found" 1>&6
702else
703   AUTOMAKE="$missing_dir/missing automake"
704   echo "$ac_t""missing" 1>&6
705fi
706
707echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
708echo "configure:709: checking for working autoheader" >&5
709# Run test in a subshell; some versions of sh will print an error if
710# an executable is not found, even if stderr is redirected.
711# Redirect stdin to placate older versions of autoconf.  Sigh.
712if (autoheader --version) < /dev/null > /dev/null 2>&1; then
713   AUTOHEADER=autoheader
714   echo "$ac_t""found" 1>&6
715else
716   AUTOHEADER="$missing_dir/missing autoheader"
717   echo "$ac_t""missing" 1>&6
718fi
719
720echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
721echo "configure:722: checking for working makeinfo" >&5
722# Run test in a subshell; some versions of sh will print an error if
723# an executable is not found, even if stderr is redirected.
724# Redirect stdin to placate older versions of autoconf.  Sigh.
725if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
726   MAKEINFO=makeinfo
727   echo "$ac_t""found" 1>&6
728else
729   MAKEINFO="$missing_dir/missing makeinfo"
730   echo "$ac_t""missing" 1>&6
731fi
732
733echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
734echo "configure:735: checking whether ${MAKE-make} sets \${MAKE}" >&5
735set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
736if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
737  echo $ac_n "(cached) $ac_c" 1>&6
738else
739  cat > conftestmake <<\EOF
740all:
741        @echo 'ac_maketemp="${MAKE}"'
742EOF
743# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
744eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
745if test -n "$ac_maketemp"; then
746  eval ac_cv_prog_make_${ac_make}_set=yes
747else
748  eval ac_cv_prog_make_${ac_make}_set=no
749fi
750rm -f conftestmake
751fi
752if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
753  echo "$ac_t""yes" 1>&6
754  SET_MAKE=
755else
756  echo "$ac_t""no" 1>&6
757  SET_MAKE="MAKE=${MAKE-make}"
758fi
759
760# Extract the first word of "gcc", so it can be a program name with args.
761set dummy gcc; ac_word=$2
762echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
763echo "configure:764: checking for $ac_word" >&5
764if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
765  echo $ac_n "(cached) $ac_c" 1>&6
766else
767  if test -n "$CC"; then
768  ac_cv_prog_CC="$CC" # Let the user override the test.
769else
770  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
771  for ac_dir in $PATH; do
772    test -z "$ac_dir" && ac_dir=.
773    if test -f $ac_dir/$ac_word; then
774      ac_cv_prog_CC="gcc"
775      break
776    fi
777  done
778  IFS="$ac_save_ifs"
779fi
780fi
781CC="$ac_cv_prog_CC"
782if test -n "$CC"; then
783  echo "$ac_t""$CC" 1>&6
784else
785  echo "$ac_t""no" 1>&6
786fi
787
788if test -z "$CC"; then
789  # Extract the first word of "cc", so it can be a program name with args.
790set dummy cc; ac_word=$2
791echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
792echo "configure:793: checking for $ac_word" >&5
793if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
794  echo $ac_n "(cached) $ac_c" 1>&6
795else
796  if test -n "$CC"; then
797  ac_cv_prog_CC="$CC" # Let the user override the test.
798else
799  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
800  ac_prog_rejected=no
801  for ac_dir in $PATH; do
802    test -z "$ac_dir" && ac_dir=.
803    if test -f $ac_dir/$ac_word; then
804      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
805        ac_prog_rejected=yes
806        continue
807      fi
808      ac_cv_prog_CC="cc"
809      break
810    fi
811  done
812  IFS="$ac_save_ifs"
813if test $ac_prog_rejected = yes; then
814  # We found a bogon in the path, so make sure we never use it.
815  set dummy $ac_cv_prog_CC
816  shift
817  if test $# -gt 0; then
818    # We chose a different compiler from the bogus one.
819    # However, it has the same basename, so the bogon will be chosen
820    # first if we set CC to just the basename; use the full file name.
821    shift
822    set dummy "$ac_dir/$ac_word" "$@"
823    shift
824    ac_cv_prog_CC="$@"
825  fi
826fi
827fi
828fi
829CC="$ac_cv_prog_CC"
830if test -n "$CC"; then
831  echo "$ac_t""$CC" 1>&6
832else
833  echo "$ac_t""no" 1>&6
834fi
835
836  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
837fi
838
839echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
840echo "configure:841: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
841
842ac_ext=c
843# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
844ac_cpp='$CPP $CPPFLAGS'
845ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
846ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
847cross_compiling=$ac_cv_prog_cc_cross
848
849cat > conftest.$ac_ext <<EOF
850#line 851 "configure"
851#include "confdefs.h"
852main(){return(0);}
853EOF
854if { (eval echo configure:855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
855  ac_cv_prog_cc_works=yes
856  # If we can't run a trivial program, we are probably using a cross compiler.
857  if (./conftest; exit) 2>/dev/null; then
858    ac_cv_prog_cc_cross=no
859  else
860    ac_cv_prog_cc_cross=yes
861  fi
862else
863  echo "configure: failed program was:" >&5
864  cat conftest.$ac_ext >&5
865  ac_cv_prog_cc_works=no
866fi
867rm -fr conftest*
868
869echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
870if test $ac_cv_prog_cc_works = no; then
871  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
872fi
873echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
874echo "configure:875: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
875echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
876cross_compiling=$ac_cv_prog_cc_cross
877
878echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
879echo "configure:880: checking whether we are using GNU C" >&5
880if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
881  echo $ac_n "(cached) $ac_c" 1>&6
882else
883  cat > conftest.c <<EOF
884#ifdef __GNUC__
885  yes;
886#endif
887EOF
888if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:889: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
889  ac_cv_prog_gcc=yes
890else
891  ac_cv_prog_gcc=no
892fi
893fi
894
895echo "$ac_t""$ac_cv_prog_gcc" 1>&6
896
897if test $ac_cv_prog_gcc = yes; then
898  GCC=yes
899  ac_test_CFLAGS="${CFLAGS+set}"
900  ac_save_CFLAGS="$CFLAGS"
901  CFLAGS=
902  echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
903echo "configure:904: checking whether ${CC-cc} accepts -g" >&5
904if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
905  echo $ac_n "(cached) $ac_c" 1>&6
906else
907  echo 'void f(){}' > conftest.c
908if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
909  ac_cv_prog_cc_g=yes
910else
911  ac_cv_prog_cc_g=no
912fi
913rm -f conftest*
914
915fi
916
917echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
918  if test "$ac_test_CFLAGS" = set; then
919    CFLAGS="$ac_save_CFLAGS"
920  elif test $ac_cv_prog_cc_g = yes; then
921    CFLAGS="-g -O2"
922  else
923    CFLAGS="-O2"
924  fi
925else
926  GCC=
927  test "${CFLAGS+set}" = set || CFLAGS="-g"
928fi
929
930echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
931echo "configure:932: checking how to run the C preprocessor" >&5
932# On Suns, sometimes $CPP names a directory.
933if test -n "$CPP" && test -d "$CPP"; then
934  CPP=
935fi
936if test -z "$CPP"; then
937if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
938  echo $ac_n "(cached) $ac_c" 1>&6
939else
940    # This must be in double quotes, not single quotes, because CPP may get
941  # substituted into the Makefile and "${CC-cc}" will confuse make.
942  CPP="${CC-cc} -E"
943  # On the NeXT, cc -E runs the code through the compiler's parser,
944  # not just through cpp.
945  cat > conftest.$ac_ext <<EOF
946#line 947 "configure"
947#include "confdefs.h"
948#include <assert.h>
949Syntax Error
950EOF
951ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
952{ (eval echo configure:953: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
953ac_err=`grep -v '^ *+' conftest.out`
954if test -z "$ac_err"; then
955  :
956else
957  echo "$ac_err" >&5
958  echo "configure: failed program was:" >&5
959  cat conftest.$ac_ext >&5
960  rm -rf conftest*
961  CPP="${CC-cc} -E -traditional-cpp"
962  cat > conftest.$ac_ext <<EOF
963#line 964 "configure"
964#include "confdefs.h"
965#include <assert.h>
966Syntax Error
967EOF
968ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
969{ (eval echo configure:970: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
970ac_err=`grep -v '^ *+' conftest.out`
971if test -z "$ac_err"; then
972  :
973else
974  echo "$ac_err" >&5
975  echo "configure: failed program was:" >&5
976  cat conftest.$ac_ext >&5
977  rm -rf conftest*
978  CPP=/lib/cpp
979fi
980rm -f conftest*
981fi
982rm -f conftest*
983  ac_cv_prog_CPP="$CPP"
984fi
985  CPP="$ac_cv_prog_CPP"
986else
987  ac_cv_prog_CPP="$CPP"
988fi
989echo "$ac_t""$CPP" 1>&6
990
991for ac_prog in $CCC c++ g++ gcc CC cxx cc++
992do
993# Extract the first word of "$ac_prog", so it can be a program name with args.
994set dummy $ac_prog; ac_word=$2
995echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
996echo "configure:997: checking for $ac_word" >&5
997if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
998  echo $ac_n "(cached) $ac_c" 1>&6
999else
1000  if test -n "$CXX"; then
1001  ac_cv_prog_CXX="$CXX" # Let the user override the test.
1002else
1003  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
1004  for ac_dir in $PATH; do
1005    test -z "$ac_dir" && ac_dir=.
1006    if test -f $ac_dir/$ac_word; then
1007      ac_cv_prog_CXX="$ac_prog"
1008      break
1009    fi
1010  done
1011  IFS="$ac_save_ifs"
1012fi
1013fi
1014CXX="$ac_cv_prog_CXX"
1015if test -n "$CXX"; then
1016  echo "$ac_t""$CXX" 1>&6
1017else
1018  echo "$ac_t""no" 1>&6
1019fi
1020
1021test -n "$CXX" && break
1022done
1023test -n "$CXX" || CXX="gcc"
1024
1025
1026echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1027echo "configure:1028: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
1028
1029ac_ext=C
1030# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1031ac_cpp='$CXXCPP $CPPFLAGS'
1032ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1033ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1034cross_compiling=$ac_cv_prog_cxx_cross
1035
1036cat > conftest.$ac_ext <<EOF
1037#line 1038 "configure"
1038#include "confdefs.h"
1039main(){return(0);}
1040EOF
1041if { (eval echo configure:1042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1042  ac_cv_prog_cxx_works=yes
1043  # If we can't run a trivial program, we are probably using a cross compiler.
1044  if (./conftest; exit) 2>/dev/null; then
1045    ac_cv_prog_cxx_cross=no
1046  else
1047    ac_cv_prog_cxx_cross=yes
1048  fi
1049else
1050  echo "configure: failed program was:" >&5
1051  cat conftest.$ac_ext >&5
1052  ac_cv_prog_cxx_works=no
1053fi
1054rm -fr conftest*
1055ac_ext=c
1056# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1057ac_cpp='$CPP $CPPFLAGS'
1058ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1059ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1060cross_compiling=$ac_cv_prog_cc_cross
1061
1062echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
1063if test $ac_cv_prog_cxx_works = no; then
1064  { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
1065fi
1066echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1067echo "configure:1068: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
1068echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
1069cross_compiling=$ac_cv_prog_cxx_cross
1070
1071echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
1072echo "configure:1073: checking whether we are using GNU C++" >&5
1073if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
1074  echo $ac_n "(cached) $ac_c" 1>&6
1075else
1076  cat > conftest.C <<EOF
1077#ifdef __GNUC__
1078  yes;
1079#endif
1080EOF
1081if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1082: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1082  ac_cv_prog_gxx=yes
1083else
1084  ac_cv_prog_gxx=no
1085fi
1086fi
1087
1088echo "$ac_t""$ac_cv_prog_gxx" 1>&6
1089
1090if test $ac_cv_prog_gxx = yes; then
1091  GXX=yes
1092  ac_test_CXXFLAGS="${CXXFLAGS+set}"
1093  ac_save_CXXFLAGS="$CXXFLAGS"
1094  CXXFLAGS=
1095  echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
1096echo "configure:1097: checking whether ${CXX-g++} accepts -g" >&5
1097if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
1098  echo $ac_n "(cached) $ac_c" 1>&6
1099else
1100  echo 'void f(){}' > conftest.cc
1101if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
1102  ac_cv_prog_cxx_g=yes
1103else
1104  ac_cv_prog_cxx_g=no
1105fi
1106rm -f conftest*
1107
1108fi
1109
1110echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
1111  if test "$ac_test_CXXFLAGS" = set; then
1112    CXXFLAGS="$ac_save_CXXFLAGS"
1113  elif test $ac_cv_prog_cxx_g = yes; then
1114    CXXFLAGS="-g -O2"
1115  else
1116    CXXFLAGS="-O2"
1117  fi
1118else
1119  GXX=
1120  test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
1121fi
1122
1123
1124# Make sure we can run config.sub.
1125if $ac_config_sub sun4 >/dev/null 2>&1; then :
1126else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
1127fi
1128
1129echo $ac_n "checking host system type""... $ac_c" 1>&6
1130echo "configure:1131: checking host system type" >&5
1131
1132host_alias=$host
1133case "$host_alias" in
1134NONE)
1135  case $nonopt in
1136  NONE)
1137    if host_alias=`$ac_config_guess`; then :
1138    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
1139    fi ;;
1140  *) host_alias=$nonopt ;;
1141  esac ;;
1142esac
1143
1144host=`$ac_config_sub $host_alias`
1145host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1146host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1147host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1148echo "$ac_t""$host" 1>&6
1149
1150if test "$program_transform_name" = s,x,x,; then
1151  program_transform_name=
1152else
1153  # Double any \ or $.  echo might interpret backslashes.
1154  cat <<\EOF_SED > conftestsed
1155s,\\,\\\\,g; s,\$,$$,g
1156EOF_SED
1157  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
1158  rm -f conftestsed
1159fi
1160test "$program_prefix" != NONE &&
1161  program_transform_name="s,^,${program_prefix},; $program_transform_name"
1162# Use a double $ so make ignores it.
1163test "$program_suffix" != NONE &&
1164  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
1165
1166# sed with no file args requires a program.
1167test "$program_transform_name" = "" && program_transform_name="s,x,x,"
1168
1169# Find a good install program.  We prefer a C program (faster),
1170# so one script is as good as another.  But avoid the broken or
1171# incompatible versions:
1172# SysV /etc/install, /usr/sbin/install
1173# SunOS /usr/etc/install
1174# IRIX /sbin/install
1175# AIX /bin/install
1176# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1177# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1178# ./install, which can be erroneously created by make from ./install.sh.
1179echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1180echo "configure:1181: checking for a BSD compatible install" >&5
1181if test -z "$INSTALL"; then
1182if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1183  echo $ac_n "(cached) $ac_c" 1>&6
1184else
1185    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS="${IFS}:"
1186  for ac_dir in $PATH; do
1187    # Account for people who put trailing slashes in PATH elements.
1188    case "$ac_dir/" in
1189    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1190    *)
1191      # OSF1 and SCO ODT 3.0 have their own names for install.
1192      for ac_prog in ginstall installbsd scoinst install; do
1193        if test -f $ac_dir/$ac_prog; then
1194          if test $ac_prog = install &&
1195            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1196            # AIX install.  It has an incompatible calling convention.
1197            # OSF/1 installbsd also uses dspmsg, but is usable.
1198            :
1199          else
1200            ac_cv_path_install="$ac_dir/$ac_prog -c"
1201            break 2
1202          fi
1203        fi
1204      done
1205      ;;
1206    esac
1207  done
1208  IFS="$ac_save_IFS"
1209
1210fi
1211  if test "${ac_cv_path_install+set}" = set; then
1212    INSTALL="$ac_cv_path_install"
1213  else
1214    # As a last resort, use the slow shell script.  We don't cache a
1215    # path for INSTALL within a source directory, because that will
1216    # break other packages using the cache if that directory is
1217    # removed, or if the path is relative.
1218    INSTALL="$ac_install_sh"
1219  fi
1220fi
1221echo "$ac_t""$INSTALL" 1>&6
1222
1223# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1224# It thinks the first close brace ends the variable substitution.
1225test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1226
1227test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1228
1229
1230# If we find X, set shell vars x_includes and x_libraries to the
1231# paths, otherwise set no_x=yes.
1232# Uses ac_ vars as temps to allow command line to override cache and checks.
1233# --without-x overrides everything else, but does not touch the cache.
1234echo $ac_n "checking for X""... $ac_c" 1>&6
1235echo "configure:1236: checking for X" >&5
1236
1237# Check whether --with-x or --without-x was given.
1238if test "${with_x+set}" = set; then
1239  withval="$with_x"
1240  :
1241fi
1242
1243# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
1244if test "x$with_x" = xno; then
1245  # The user explicitly disabled X.
1246  have_x=disabled
1247else
1248  if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
1249    # Both variables are already set.
1250    have_x=yes
1251  else
1252if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
1253  echo $ac_n "(cached) $ac_c" 1>&6
1254else
1255  # One or both of the vars are not set, and there is no cached value.
1256ac_x_includes=NO ac_x_libraries=NO
1257rm -fr conftestdir
1258if mkdir conftestdir; then
1259  cd conftestdir
1260  # Make sure to not put "make" in the Imakefile rules, since we grep it out.
1261  cat > Imakefile <<'EOF'
1262acfindx:
1263        @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
1264EOF
1265  if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
1266    # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1267    eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
1268    # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
1269    for ac_extension in a so sl; do
1270      if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
1271        test -f $ac_im_libdir/libX11.$ac_extension; then
1272        ac_im_usrlibdir=$ac_im_libdir; break
1273      fi
1274    done
1275    # Screen out bogus values from the imake configuration.  They are
1276    # bogus both because they are the default anyway, and because
1277    # using them would break gcc on systems where it needs fixed includes.
1278    case "$ac_im_incroot" in
1279        /usr/include) ;;
1280        *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
1281    esac
1282    case "$ac_im_usrlibdir" in
1283        /usr/lib | /lib) ;;
1284        *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
1285    esac
1286  fi
1287  cd ..
1288  rm -fr conftestdir
1289fi
1290
1291if test "$ac_x_includes" = NO; then
1292  # Guess where to find include files, by looking for this one X11 .h file.
1293  test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
1294
1295  # First, try using that file with no special directory specified.
1296cat > conftest.$ac_ext <<EOF
1297#line 1298 "configure"
1298#include "confdefs.h"
1299#include <$x_direct_test_include>
1300EOF
1301ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1302{ (eval echo configure:1303: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1303ac_err=`grep -v '^ *+' conftest.out`
1304if test -z "$ac_err"; then
1305  rm -rf conftest*
1306  # We can compile using X headers with no special include directory.
1307ac_x_includes=
1308else
1309  echo "$ac_err" >&5
1310  echo "configure: failed program was:" >&5
1311  cat conftest.$ac_ext >&5
1312  rm -rf conftest*
1313  # Look for the header file in a standard set of common directories.
1314# Check X11 before X11Rn because it is often a symlink to the current release.
1315  for ac_dir in               \
1316    /usr/X11/include          \
1317    /usr/X11R6/include        \
1318    /usr/X11R5/include        \
1319    /usr/X11R4/include        \
1320                              \
1321    /usr/include/X11          \
1322    /usr/include/X11R6        \
1323    /usr/include/X11R5        \
1324    /usr/include/X11R4        \
1325                              \
1326    /usr/local/X11/include    \
1327    /usr/local/X11R6/include  \
1328    /usr/local/X11R5/include  \
1329    /usr/local/X11R4/include  \
1330                              \
1331    /usr/local/include/X11    \
1332    /usr/local/include/X11R6  \
1333    /usr/local/include/X11R5  \
1334    /usr/local/include/X11R4  \
1335                              \
1336    /usr/X386/include         \
1337    /usr/x386/include         \
1338    /usr/XFree86/include/X11  \
1339                              \
1340    /usr/include              \
1341    /usr/local/include        \
1342    /usr/unsupported/include  \
1343    /usr/athena/include       \
1344    /usr/local/x11r5/include  \
1345    /usr/lpp/Xamples/include  \
1346                              \
1347    /usr/openwin/include      \
1348    /usr/openwin/share/include \
1349    ; \
1350  do
1351    if test -r "$ac_dir/$x_direct_test_include"; then
1352      ac_x_includes=$ac_dir
1353      break
1354    fi
1355  done
1356fi
1357rm -f conftest*
1358fi # $ac_x_includes = NO
1359
1360if test "$ac_x_libraries" = NO; then
1361  # Check for the libraries.
1362
1363  test -z "$x_direct_test_library" && x_direct_test_library=Xt
1364  test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
1365
1366  # See if we find them without any special options.
1367  # Don't add to $LIBS permanently.
1368  ac_save_LIBS="$LIBS"
1369  LIBS="-l$x_direct_test_library $LIBS"
1370cat > conftest.$ac_ext <<EOF
1371#line 1372 "configure"
1372#include "confdefs.h"
1373
1374int main() {
1375${x_direct_test_function}()
1376; return 0; }
1377EOF
1378if { (eval echo configure:1379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1379  rm -rf conftest*
1380  LIBS="$ac_save_LIBS"
1381# We can link X programs with no special library path.
1382ac_x_libraries=
1383else
1384  echo "configure: failed program was:" >&5
1385  cat conftest.$ac_ext >&5
1386  rm -rf conftest*
1387  LIBS="$ac_save_LIBS"
1388# First see if replacing the include by lib works.
1389# Check X11 before X11Rn because it is often a symlink to the current release.
1390for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
1391    /usr/X11/lib          \
1392    /usr/X11R6/lib        \
1393    /usr/X11R5/lib        \
1394    /usr/X11R4/lib        \
1395                          \
1396    /usr/lib/X11          \
1397    /usr/lib/X11R6        \
1398    /usr/lib/X11R5        \
1399    /usr/lib/X11R4        \
1400                          \
1401    /usr/local/X11/lib    \
1402    /usr/local/X11R6/lib  \
1403    /usr/local/X11R5/lib  \
1404    /usr/local/X11R4/lib  \
1405                          \
1406    /usr/local/lib/X11    \
1407    /usr/local/lib/X11R6  \
1408    /usr/local/lib/X11R5  \
1409    /usr/local/lib/X11R4  \
1410                          \
1411    /usr/X386/lib         \
1412    /usr/x386/lib         \
1413    /usr/XFree86/lib/X11  \
1414                          \
1415    /usr/lib              \
1416    /usr/local/lib        \
1417    /usr/unsupported/lib  \
1418    /usr/athena/lib       \
1419    /usr/local/x11r5/lib  \
1420    /usr/lpp/Xamples/lib  \
1421    /lib/usr/lib/X11      \
1422                          \
1423    /usr/openwin/lib      \
1424    /usr/openwin/share/lib \
1425    ; \
1426do
1427  for ac_extension in a so sl; do
1428    if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
1429      ac_x_libraries=$ac_dir
1430      break 2
1431    fi
1432  done
1433done
1434fi
1435rm -f conftest*
1436fi # $ac_x_libraries = NO
1437
1438if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
1439  # Didn't find X anywhere.  Cache the known absence of X.
1440  ac_cv_have_x="have_x=no"
1441else
1442  # Record where we found X for the cache.
1443  ac_cv_have_x="have_x=yes \
1444                ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
1445fi
1446fi
1447  fi
1448  eval "$ac_cv_have_x"
1449fi # $with_x != no
1450
1451if test "$have_x" != yes; then
1452  echo "$ac_t""$have_x" 1>&6
1453  no_x=yes
1454else
1455  # If each of the values was on the command line, it overrides each guess.
1456  test "x$x_includes" = xNONE && x_includes=$ac_x_includes
1457  test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
1458  # Update the cache value to reflect the command line values.
1459  ac_cv_have_x="have_x=yes \
1460                ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
1461  echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
1462fi
1463
1464if test "$no_x" = yes; then
1465  # Not all programs may use this symbol, but it does not hurt to define it.
1466  cat >> confdefs.h <<\EOF
1467#define X_DISPLAY_MISSING 1
1468EOF
1469
1470  X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
1471else
1472  if test -n "$x_includes"; then
1473    X_CFLAGS="$X_CFLAGS -I$x_includes"
1474  fi
1475
1476  # It would also be nice to do this for all -L options, not just this one.
1477  if test -n "$x_libraries"; then
1478    X_LIBS="$X_LIBS -L$x_libraries"
1479    # For Solaris; some versions of Sun CC require a space after -R and
1480    # others require no space.  Words are not sufficient . . . .
1481    case "`(uname -sr) 2>/dev/null`" in
1482    "SunOS 5"*)
1483      echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
1484echo "configure:1485: checking whether -R must be followed by a space" >&5
1485      ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
1486      cat > conftest.$ac_ext <<EOF
1487#line 1488 "configure"
1488#include "confdefs.h"
1489
1490int main() {
1491
1492; return 0; }
1493EOF
1494if { (eval echo configure:1495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1495  rm -rf conftest*
1496  ac_R_nospace=yes
1497else
1498  echo "configure: failed program was:" >&5
1499  cat conftest.$ac_ext >&5
1500  rm -rf conftest*
1501  ac_R_nospace=no
1502fi
1503rm -f conftest*
1504      if test $ac_R_nospace = yes; then
1505        echo "$ac_t""no" 1>&6
1506        X_LIBS="$X_LIBS -R$x_libraries"
1507      else
1508        LIBS="$ac_xsave_LIBS -R $x_libraries"
1509        cat > conftest.$ac_ext <<EOF
1510#line 1511 "configure"
1511#include "confdefs.h"
1512
1513int main() {
1514
1515; return 0; }
1516EOF
1517if { (eval echo configure:1518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1518  rm -rf conftest*
1519  ac_R_space=yes
1520else
1521  echo "configure: failed program was:" >&5
1522  cat conftest.$ac_ext >&5
1523  rm -rf conftest*
1524  ac_R_space=no
1525fi
1526rm -f conftest*
1527        if test $ac_R_space = yes; then
1528          echo "$ac_t""yes" 1>&6
1529          X_LIBS="$X_LIBS -R $x_libraries"
1530        else
1531          echo "$ac_t""neither works" 1>&6
1532        fi
1533      fi
1534      LIBS="$ac_xsave_LIBS"
1535    esac
1536  fi
1537
1538  # Check for system-dependent libraries X programs must link with.
1539  # Do this before checking for the system-independent R6 libraries
1540  # (-lICE), since we may need -lsocket or whatever for X linking.
1541
1542  if test "$ISC" = yes; then
1543    X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
1544  else
1545    # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
1546    # libraries were built with DECnet support.  And karl@cs.umb.edu says
1547    # the Alpha needs dnet_stub (dnet does not exist).
1548    echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
1549echo "configure:1550: checking for dnet_ntoa in -ldnet" >&5
1550ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
1551if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1552  echo $ac_n "(cached) $ac_c" 1>&6
1553else
1554  ac_save_LIBS="$LIBS"
1555LIBS="-ldnet  $LIBS"
1556cat > conftest.$ac_ext <<EOF
1557#line 1558 "configure"
1558#include "confdefs.h"
1559/* Override any gcc2 internal prototype to avoid an error.  */
1560/* We use char because int might match the return type of a gcc2
1561    builtin and then its argument prototype would still apply.  */
1562char dnet_ntoa();
1563
1564int main() {
1565dnet_ntoa()
1566; return 0; }
1567EOF
1568if { (eval echo configure:1569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1569  rm -rf conftest*
1570  eval "ac_cv_lib_$ac_lib_var=yes"
1571else
1572  echo "configure: failed program was:" >&5
1573  cat conftest.$ac_ext >&5
1574  rm -rf conftest*
1575  eval "ac_cv_lib_$ac_lib_var=no"
1576fi
1577rm -f conftest*
1578LIBS="$ac_save_LIBS"
1579
1580fi
1581if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1582  echo "$ac_t""yes" 1>&6
1583  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
1584else
1585  echo "$ac_t""no" 1>&6
1586fi
1587
1588    if test $ac_cv_lib_dnet_dnet_ntoa = no; then
1589      echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
1590echo "configure:1591: checking for dnet_ntoa in -ldnet_stub" >&5
1591ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
1592if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1593  echo $ac_n "(cached) $ac_c" 1>&6
1594else
1595  ac_save_LIBS="$LIBS"
1596LIBS="-ldnet_stub  $LIBS"
1597cat > conftest.$ac_ext <<EOF
1598#line 1599 "configure"
1599#include "confdefs.h"
1600/* Override any gcc2 internal prototype to avoid an error.  */
1601/* We use char because int might match the return type of a gcc2
1602    builtin and then its argument prototype would still apply.  */
1603char dnet_ntoa();
1604
1605int main() {
1606dnet_ntoa()
1607; return 0; }
1608EOF
1609if { (eval echo configure:1610: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1610  rm -rf conftest*
1611  eval "ac_cv_lib_$ac_lib_var=yes"
1612else
1613  echo "configure: failed program was:" >&5
1614  cat conftest.$ac_ext >&5
1615  rm -rf conftest*
1616  eval "ac_cv_lib_$ac_lib_var=no"
1617fi
1618rm -f conftest*
1619LIBS="$ac_save_LIBS"
1620
1621fi
1622if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1623  echo "$ac_t""yes" 1>&6
1624  X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
1625else
1626  echo "$ac_t""no" 1>&6
1627fi
1628
1629    fi
1630
1631    # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
1632    # to get the SysV transport functions.
1633    # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
1634    # needs -lnsl.
1635    # The nsl library prevents programs from opening the X display
1636    # on Irix 5.2, according to dickey@clark.net.
1637    echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
1638echo "configure:1639: checking for gethostbyname" >&5
1639if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
1640  echo $ac_n "(cached) $ac_c" 1>&6
1641else
1642  cat > conftest.$ac_ext <<EOF
1643#line 1644 "configure"
1644#include "confdefs.h"
1645/* System header to define __stub macros and hopefully few prototypes,
1646    which can conflict with char gethostbyname(); below.  */
1647#include <assert.h>
1648/* Override any gcc2 internal prototype to avoid an error.  */
1649/* We use char because int might match the return type of a gcc2
1650    builtin and then its argument prototype would still apply.  */
1651char gethostbyname();
1652
1653int main() {
1654
1655/* The GNU C library defines this for functions which it implements
1656    to always fail with ENOSYS.  Some functions are actually named
1657    something starting with __ and the normal name is an alias.  */
1658#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
1659choke me
1660#else
1661gethostbyname();
1662#endif
1663
1664; return 0; }
1665EOF
1666if { (eval echo configure:1667: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1667  rm -rf conftest*
1668  eval "ac_cv_func_gethostbyname=yes"
1669else
1670  echo "configure: failed program was:" >&5
1671  cat conftest.$ac_ext >&5
1672  rm -rf conftest*
1673  eval "ac_cv_func_gethostbyname=no"
1674fi
1675rm -f conftest*
1676fi
1677
1678if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
1679  echo "$ac_t""yes" 1>&6
1680  :
1681else
1682  echo "$ac_t""no" 1>&6
1683fi
1684
1685    if test $ac_cv_func_gethostbyname = no; then
1686      echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
1687echo "configure:1688: checking for gethostbyname in -lnsl" >&5
1688ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
1689if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1690  echo $ac_n "(cached) $ac_c" 1>&6
1691else
1692  ac_save_LIBS="$LIBS"
1693LIBS="-lnsl  $LIBS"
1694cat > conftest.$ac_ext <<EOF
1695#line 1696 "configure"
1696#include "confdefs.h"
1697/* Override any gcc2 internal prototype to avoid an error.  */
1698/* We use char because int might match the return type of a gcc2
1699    builtin and then its argument prototype would still apply.  */
1700char gethostbyname();
1701
1702int main() {
1703gethostbyname()
1704; return 0; }
1705EOF
1706if { (eval echo configure:1707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1707  rm -rf conftest*
1708  eval "ac_cv_lib_$ac_lib_var=yes"
1709else
1710  echo "configure: failed program was:" >&5
1711  cat conftest.$ac_ext >&5
1712  rm -rf conftest*
1713  eval "ac_cv_lib_$ac_lib_var=no"
1714fi
1715rm -f conftest*
1716LIBS="$ac_save_LIBS"
1717
1718fi
1719if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1720  echo "$ac_t""yes" 1>&6
1721  X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
1722else
1723  echo "$ac_t""no" 1>&6
1724fi
1725
1726    fi
1727
1728    # lieder@skyler.mavd.honeywell.com says without -lsocket,
1729    # socket/setsockopt and other routines are undefined under SCO ODT
1730    # 2.0.  But -lsocket is broken on IRIX 5.2 (and is not necessary
1731    # on later versions), says simon@lia.di.epfl.ch: it contains
1732    # gethostby* variants that don't use the nameserver (or something).
1733    # -lsocket must be given before -lnsl if both are needed.
1734    # We assume that if connect needs -lnsl, so does gethostbyname.
1735    echo $ac_n "checking for connect""... $ac_c" 1>&6
1736echo "configure:1737: checking for connect" >&5
1737if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
1738  echo $ac_n "(cached) $ac_c" 1>&6
1739else
1740  cat > conftest.$ac_ext <<EOF
1741#line 1742 "configure"
1742#include "confdefs.h"
1743/* System header to define __stub macros and hopefully few prototypes,
1744    which can conflict with char connect(); below.  */
1745#include <assert.h>
1746/* Override any gcc2 internal prototype to avoid an error.  */
1747/* We use char because int might match the return type of a gcc2
1748    builtin and then its argument prototype would still apply.  */
1749char connect();
1750
1751int main() {
1752
1753/* The GNU C library defines this for functions which it implements
1754    to always fail with ENOSYS.  Some functions are actually named
1755    something starting with __ and the normal name is an alias.  */
1756#if defined (__stub_connect) || defined (__stub___connect)
1757choke me
1758#else
1759connect();
1760#endif
1761
1762; return 0; }
1763EOF
1764if { (eval echo configure:1765: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1765  rm -rf conftest*
1766  eval "ac_cv_func_connect=yes"
1767else
1768  echo "configure: failed program was:" >&5
1769  cat conftest.$ac_ext >&5
1770  rm -rf conftest*
1771  eval "ac_cv_func_connect=no"
1772fi
1773rm -f conftest*
1774fi
1775
1776if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
1777  echo "$ac_t""yes" 1>&6
1778  :
1779else
1780  echo "$ac_t""no" 1>&6
1781fi
1782
1783    if test $ac_cv_func_connect = no; then
1784      echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
1785echo "configure:1786: checking for connect in -lsocket" >&5
1786ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
1787if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1788  echo $ac_n "(cached) $ac_c" 1>&6
1789else
1790  ac_save_LIBS="$LIBS"
1791LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
1792cat > conftest.$ac_ext <<EOF
1793#line 1794 "configure"
1794#include "confdefs.h"
1795/* Override any gcc2 internal prototype to avoid an error.  */
1796/* We use char because int might match the return type of a gcc2
1797    builtin and then its argument prototype would still apply.  */
1798char connect();
1799
1800int main() {
1801connect()
1802; return 0; }
1803EOF
1804if { (eval echo configure:1805: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1805  rm -rf conftest*
1806  eval "ac_cv_lib_$ac_lib_var=yes"
1807else
1808  echo "configure: failed program was:" >&5
1809  cat conftest.$ac_ext >&5
1810  rm -rf conftest*
1811  eval "ac_cv_lib_$ac_lib_var=no"
1812fi
1813rm -f conftest*
1814LIBS="$ac_save_LIBS"
1815
1816fi
1817if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1818  echo "$ac_t""yes" 1>&6
1819  X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
1820else
1821  echo "$ac_t""no" 1>&6
1822fi
1823
1824    fi
1825
1826    # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
1827    echo $ac_n "checking for remove""... $ac_c" 1>&6
1828echo "configure:1829: checking for remove" >&5
1829if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
1830  echo $ac_n "(cached) $ac_c" 1>&6
1831else
1832  cat > conftest.$ac_ext <<EOF
1833#line 1834 "configure"
1834#include "confdefs.h"
1835/* System header to define __stub macros and hopefully few prototypes,
1836    which can conflict with char remove(); below.  */
1837#include <assert.h>
1838/* Override any gcc2 internal prototype to avoid an error.  */
1839/* We use char because int might match the return type of a gcc2
1840    builtin and then its argument prototype would still apply.  */
1841char remove();
1842
1843int main() {
1844
1845/* The GNU C library defines this for functions which it implements
1846    to always fail with ENOSYS.  Some functions are actually named
1847    something starting with __ and the normal name is an alias.  */
1848#if defined (__stub_remove) || defined (__stub___remove)
1849choke me
1850#else
1851remove();
1852#endif
1853
1854; return 0; }
1855EOF
1856if { (eval echo configure:1857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1857  rm -rf conftest*
1858  eval "ac_cv_func_remove=yes"
1859else
1860  echo "configure: failed program was:" >&5
1861  cat conftest.$ac_ext >&5
1862  rm -rf conftest*
1863  eval "ac_cv_func_remove=no"
1864fi
1865rm -f conftest*
1866fi
1867
1868if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
1869  echo "$ac_t""yes" 1>&6
1870  :
1871else
1872  echo "$ac_t""no" 1>&6
1873fi
1874
1875    if test $ac_cv_func_remove = no; then
1876      echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
1877echo "configure:1878: checking for remove in -lposix" >&5
1878ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
1879if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1880  echo $ac_n "(cached) $ac_c" 1>&6
1881else
1882  ac_save_LIBS="$LIBS"
1883LIBS="-lposix  $LIBS"
1884cat > conftest.$ac_ext <<EOF
1885#line 1886 "configure"
1886#include "confdefs.h"
1887/* Override any gcc2 internal prototype to avoid an error.  */
1888/* We use char because int might match the return type of a gcc2
1889    builtin and then its argument prototype would still apply.  */
1890char remove();
1891
1892int main() {
1893remove()
1894; return 0; }
1895EOF
1896if { (eval echo configure:1897: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1897  rm -rf conftest*
1898  eval "ac_cv_lib_$ac_lib_var=yes"
1899else
1900  echo "configure: failed program was:" >&5
1901  cat conftest.$ac_ext >&5
1902  rm -rf conftest*
1903  eval "ac_cv_lib_$ac_lib_var=no"
1904fi
1905rm -f conftest*
1906LIBS="$ac_save_LIBS"
1907
1908fi
1909if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1910  echo "$ac_t""yes" 1>&6
1911  X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
1912else
1913  echo "$ac_t""no" 1>&6
1914fi
1915
1916    fi
1917
1918    # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
1919    echo $ac_n "checking for shmat""... $ac_c" 1>&6
1920echo "configure:1921: checking for shmat" >&5
1921if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
1922  echo $ac_n "(cached) $ac_c" 1>&6
1923else
1924  cat > conftest.$ac_ext <<EOF
1925#line 1926 "configure"
1926#include "confdefs.h"
1927/* System header to define __stub macros and hopefully few prototypes,
1928    which can conflict with char shmat(); below.  */
1929#include <assert.h>
1930/* Override any gcc2 internal prototype to avoid an error.  */
1931/* We use char because int might match the return type of a gcc2
1932    builtin and then its argument prototype would still apply.  */
1933char shmat();
1934
1935int main() {
1936
1937/* The GNU C library defines this for functions which it implements
1938    to always fail with ENOSYS.  Some functions are actually named
1939    something starting with __ and the normal name is an alias.  */
1940#if defined (__stub_shmat) || defined (__stub___shmat)
1941choke me
1942#else
1943shmat();
1944#endif
1945
1946; return 0; }
1947EOF
1948if { (eval echo configure:1949: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1949  rm -rf conftest*
1950  eval "ac_cv_func_shmat=yes"
1951else
1952  echo "configure: failed program was:" >&5
1953  cat conftest.$ac_ext >&5
1954  rm -rf conftest*
1955  eval "ac_cv_func_shmat=no"
1956fi
1957rm -f conftest*
1958fi
1959
1960if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
1961  echo "$ac_t""yes" 1>&6
1962  :
1963else
1964  echo "$ac_t""no" 1>&6
1965fi
1966
1967    if test $ac_cv_func_shmat = no; then
1968      echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
1969echo "configure:1970: checking for shmat in -lipc" >&5
1970ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
1971if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1972  echo $ac_n "(cached) $ac_c" 1>&6
1973else
1974  ac_save_LIBS="$LIBS"
1975LIBS="-lipc  $LIBS"
1976cat > conftest.$ac_ext <<EOF
1977#line 1978 "configure"
1978#include "confdefs.h"
1979/* Override any gcc2 internal prototype to avoid an error.  */
1980/* We use char because int might match the return type of a gcc2
1981    builtin and then its argument prototype would still apply.  */
1982char shmat();
1983
1984int main() {
1985shmat()
1986; return 0; }
1987EOF
1988if { (eval echo configure:1989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1989  rm -rf conftest*
1990  eval "ac_cv_lib_$ac_lib_var=yes"
1991else
1992  echo "configure: failed program was:" >&5
1993  cat conftest.$ac_ext >&5
1994  rm -rf conftest*
1995  eval "ac_cv_lib_$ac_lib_var=no"
1996fi
1997rm -f conftest*
1998LIBS="$ac_save_LIBS"
1999
2000fi
2001if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2002  echo "$ac_t""yes" 1>&6
2003  X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
2004else
2005  echo "$ac_t""no" 1>&6
2006fi
2007
2008    fi
2009  fi
2010
2011  # Check for libraries that X11R6 Xt/Xaw programs need.
2012  ac_save_LDFLAGS="$LDFLAGS"
2013  test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
2014  # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
2015  # check for ICE first), but we must link in the order -lSM -lICE or
2016  # we get undefined symbols.  So assume we have SM if we have ICE.
2017  # These have to be linked with before -lX11, unlike the other
2018  # libraries we check for below, so use a different variable.
2019  #  --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
2020  echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
2021echo "configure:2022: checking for IceConnectionNumber in -lICE" >&5
2022ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
2023if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2024  echo $ac_n "(cached) $ac_c" 1>&6
2025else
2026  ac_save_LIBS="$LIBS"
2027LIBS="-lICE  $LIBS"
2028cat > conftest.$ac_ext <<EOF
2029#line 2030 "configure"
2030#include "confdefs.h"
2031/* Override any gcc2 internal prototype to avoid an error.  */
2032/* We use char because int might match the return type of a gcc2
2033    builtin and then its argument prototype would still apply.  */
2034char IceConnectionNumber();
2035
2036int main() {
2037IceConnectionNumber()
2038; return 0; }
2039EOF
2040if { (eval echo configure:2041: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2041  rm -rf conftest*
2042  eval "ac_cv_lib_$ac_lib_var=yes"
2043else
2044  echo "configure: failed program was:" >&5
2045  cat conftest.$ac_ext >&5
2046  rm -rf conftest*
2047  eval "ac_cv_lib_$ac_lib_var=no"
2048fi
2049rm -f conftest*
2050LIBS="$ac_save_LIBS"
2051
2052fi
2053if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2054  echo "$ac_t""yes" 1>&6
2055  X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
2056else
2057  echo "$ac_t""no" 1>&6
2058fi
2059
2060  LDFLAGS="$ac_save_LDFLAGS"
2061
2062fi
2063
2064
2065# Do we need to link against something for X shared memory support?
2066echo $ac_n "checking for XShmAttach in -lXext""... $ac_c" 1>&6
2067echo "configure:2068: checking for XShmAttach in -lXext" >&5
2068ac_lib_var=`echo Xext'_'XShmAttach | sed 'y%./+-%__p_%'`
2069if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2070  echo $ac_n "(cached) $ac_c" 1>&6
2071else
2072  ac_save_LIBS="$LIBS"
2073LIBS="-lXext $X_LIBS -lX11 $LIBS"
2074cat > conftest.$ac_ext <<EOF
2075#line 2076 "configure"
2076#include "confdefs.h"
2077/* Override any gcc2 internal prototype to avoid an error.  */
2078/* We use char because int might match the return type of a gcc2
2079    builtin and then its argument prototype would still apply.  */
2080char XShmAttach();
2081
2082int main() {
2083XShmAttach()
2084; return 0; }
2085EOF
2086if { (eval echo configure:2087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2087  rm -rf conftest*
2088  eval "ac_cv_lib_$ac_lib_var=yes"
2089else
2090  echo "configure: failed program was:" >&5
2091  cat conftest.$ac_ext >&5
2092  rm -rf conftest*
2093  eval "ac_cv_lib_$ac_lib_var=no"
2094fi
2095rm -f conftest*
2096LIBS="$ac_save_LIBS"
2097
2098fi
2099if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2100  echo "$ac_t""yes" 1>&6
2101  :
2102else
2103  echo "$ac_t""no" 1>&6
2104
2105echo $ac_n "checking for XShmAttach in -lXextSam""... $ac_c" 1>&6
2106echo "configure:2107: checking for XShmAttach in -lXextSam" >&5
2107ac_lib_var=`echo XextSam'_'XShmAttach | sed 'y%./+-%__p_%'`
2108if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2109  echo $ac_n "(cached) $ac_c" 1>&6
2110else
2111  ac_save_LIBS="$LIBS"
2112LIBS="-lXextSam $X_LIBS -lX11 -lXext $LIBS"
2113cat > conftest.$ac_ext <<EOF
2114#line 2115 "configure"
2115#include "confdefs.h"
2116/* Override any gcc2 internal prototype to avoid an error.  */
2117/* We use char because int might match the return type of a gcc2
2118    builtin and then its argument prototype would still apply.  */
2119char XShmAttach();
2120
2121int main() {
2122XShmAttach()
2123; return 0; }
2124EOF
2125if { (eval echo configure:2126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2126  rm -rf conftest*
2127  eval "ac_cv_lib_$ac_lib_var=yes"
2128else
2129  echo "configure: failed program was:" >&5
2130  cat conftest.$ac_ext >&5
2131  rm -rf conftest*
2132  eval "ac_cv_lib_$ac_lib_var=no"
2133fi
2134rm -f conftest*
2135LIBS="$ac_save_LIBS"
2136
2137fi
2138if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2139  echo "$ac_t""yes" 1>&6
2140  LIBS="$LIBS -lXextSam"
2141else
2142  echo "$ac_t""no" 1>&6
2143fi
2144
2145
2146fi
2147
2148
2149PROGS=
2150case ${host} in
2151  *-*-linux*)
2152        ac_safe=`echo "vga.h" | sed 'y%./+-%__p_%'`
2153echo $ac_n "checking for vga.h""... $ac_c" 1>&6
2154echo "configure:2155: checking for vga.h" >&5
2155if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2156  echo $ac_n "(cached) $ac_c" 1>&6
2157else
2158  cat > conftest.$ac_ext <<EOF
2159#line 2160 "configure"
2160#include "confdefs.h"
2161#include <vga.h>
2162EOF
2163ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2164{ (eval echo configure:2165: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2165ac_err=`grep -v '^ *+' conftest.out`
2166if test -z "$ac_err"; then
2167  rm -rf conftest*
2168  eval "ac_cv_header_$ac_safe=yes"
2169else
2170  echo "$ac_err" >&5
2171  echo "configure: failed program was:" >&5
2172  cat conftest.$ac_ext >&5
2173  rm -rf conftest*
2174  eval "ac_cv_header_$ac_safe=no"
2175fi
2176rm -f conftest*
2177fi
2178if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2179  echo "$ac_t""yes" 1>&6
2180  PROGS='abuse.console keydrv'
2181else
2182  echo "$ac_t""no" 1>&6
2183fi
2184
2185        PROGS="${PROGS} lnx_sdrv"
2186        ;;
2187  mips-sgi-irix*)
2188        PROGS=sgi_sdrv
2189        ;;
2190  powerpc-*-aix4*)
2191        if test -f /usr/lpp/UMS/include/UMSAudioDevice.h &&
2192           test -f /usr/lpp/som/include/somobj.h; then
2193          PROGS=aix_sdrv
2194        fi
2195        ;;
2196  *)
2197        ;;
2198esac
2199
2200
2201for ac_hdr in bstring.h
2202do
2203ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2204echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2205echo "configure:2206: checking for $ac_hdr" >&5
2206if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2207  echo $ac_n "(cached) $ac_c" 1>&6
2208else
2209  cat > conftest.$ac_ext <<EOF
2210#line 2211 "configure"
2211#include "confdefs.h"
2212#include <$ac_hdr>
2213EOF
2214ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2215{ (eval echo configure:2216: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2216ac_err=`grep -v '^ *+' conftest.out`
2217if test -z "$ac_err"; then
2218  rm -rf conftest*
2219  eval "ac_cv_header_$ac_safe=yes"
2220else
2221  echo "$ac_err" >&5
2222  echo "configure: failed program was:" >&5
2223  cat conftest.$ac_ext >&5
2224  rm -rf conftest*
2225  eval "ac_cv_header_$ac_safe=no"
2226fi
2227rm -f conftest*
2228fi
2229if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2230  echo "$ac_t""yes" 1>&6
2231    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2232  cat >> confdefs.h <<EOF
2233#define $ac_tr_hdr 1
2234EOF
2235 
2236else
2237  echo "$ac_t""no" 1>&6
2238fi
2239done
2240
2241for ac_func in atexit on_exit
2242do
2243echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2244echo "configure:2245: checking for $ac_func" >&5
2245if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2246  echo $ac_n "(cached) $ac_c" 1>&6
2247else
2248  cat > conftest.$ac_ext <<EOF
2249#line 2250 "configure"
2250#include "confdefs.h"
2251/* System header to define __stub macros and hopefully few prototypes,
2252    which can conflict with char $ac_func(); below.  */
2253#include <assert.h>
2254/* Override any gcc2 internal prototype to avoid an error.  */
2255/* We use char because int might match the return type of a gcc2
2256    builtin and then its argument prototype would still apply.  */
2257char $ac_func();
2258
2259int main() {
2260
2261/* The GNU C library defines this for functions which it implements
2262    to always fail with ENOSYS.  Some functions are actually named
2263    something starting with __ and the normal name is an alias.  */
2264#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2265choke me
2266#else
2267$ac_func();
2268#endif
2269
2270; return 0; }
2271EOF
2272if { (eval echo configure:2273: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2273  rm -rf conftest*
2274  eval "ac_cv_func_$ac_func=yes"
2275else
2276  echo "configure: failed program was:" >&5
2277  cat conftest.$ac_ext >&5
2278  rm -rf conftest*
2279  eval "ac_cv_func_$ac_func=no"
2280fi
2281rm -f conftest*
2282fi
2283
2284if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2285  echo "$ac_t""yes" 1>&6
2286    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2287  cat >> confdefs.h <<EOF
2288#define $ac_tr_func 1
2289EOF
2290 break
2291else
2292  echo "$ac_t""no" 1>&6
2293fi
2294done
2295
2296echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
2297echo "configure:2298: checking whether byte ordering is bigendian" >&5
2298if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
2299  echo $ac_n "(cached) $ac_c" 1>&6
2300else
2301  ac_cv_c_bigendian=unknown
2302# See if we have a good endian.h.
2303cat > conftest.$ac_ext <<EOF
2304#line 2305 "configure"
2305#include "confdefs.h"
2306#include <endian.h>
2307EOF
2308ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2309{ (eval echo configure:2310: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2310ac_err=`grep -v '^ *+' conftest.out`
2311if test -z "$ac_err"; then
2312  rm -rf conftest*
2313  cat > conftest.$ac_ext <<EOF
2314#line 2315 "configure"
2315#include "confdefs.h"
2316#include <endian.h>
2317int main() {
2318
2319#if !__BYTE_ORDER || !__BIG_ENDIAN
2320  bogus endian macros
2321#endif
2322; return 0; }
2323EOF
2324if { (eval echo configure:2325: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2325  rm -rf conftest*
2326  cat > conftest.$ac_ext <<EOF
2327#line 2328 "configure"
2328#include "confdefs.h"
2329#include <endian.h>
2330int main() {
2331
2332#if __BYTE_ORDER != __BIG_ENDIAN
2333 not big endian
2334#endif
2335; return 0; }
2336EOF
2337if { (eval echo configure:2338: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2338  rm -rf conftest*
2339  ac_cv_c_bigendian=yes
2340else
2341  echo "configure: failed program was:" >&5
2342  cat conftest.$ac_ext >&5
2343  rm -rf conftest*
2344  ac_cv_c_bigendian=no
2345fi
2346rm -f conftest*
2347else
2348  echo "configure: failed program was:" >&5
2349  cat conftest.$ac_ext >&5
2350fi
2351rm -f conftest*
2352else
2353  echo "$ac_err" >&5
2354  echo "configure: failed program was:" >&5
2355  cat conftest.$ac_ext >&5
2356fi
2357rm -f conftest*
2358if test $ac_cv_c_bigendian = unknown; then
2359# See if sys/param.h defines the BYTE_ORDER macro.
2360cat > conftest.$ac_ext <<EOF
2361#line 2362 "configure"
2362#include "confdefs.h"
2363#include <sys/types.h>
2364#include <sys/param.h>
2365int main() {
2366
2367#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
2368 bogus endian macros
2369#endif
2370; return 0; }
2371EOF
2372if { (eval echo configure:2373: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2373  rm -rf conftest*
2374  # It does; now see whether it defined to BIG_ENDIAN or not.
2375cat > conftest.$ac_ext <<EOF
2376#line 2377 "configure"
2377#include "confdefs.h"
2378#include <sys/types.h>
2379#include <sys/param.h>
2380int main() {
2381
2382#if BYTE_ORDER != BIG_ENDIAN
2383 not big endian
2384#endif
2385; return 0; }
2386EOF
2387if { (eval echo configure:2388: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2388  rm -rf conftest*
2389  ac_cv_c_bigendian=yes
2390else
2391  echo "configure: failed program was:" >&5
2392  cat conftest.$ac_ext >&5
2393  rm -rf conftest*
2394  ac_cv_c_bigendian=no
2395fi
2396rm -f conftest*
2397else
2398  echo "configure: failed program was:" >&5
2399  cat conftest.$ac_ext >&5
2400fi
2401rm -f conftest*
2402fi
2403if test $ac_cv_c_bigendian = unknown; then
2404if test "$cross_compiling" = yes; then
2405    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
2406else
2407  cat > conftest.$ac_ext <<EOF
2408#line 2409 "configure"
2409#include "confdefs.h"
2410main () {
2411  /* Are we little or big endian?  From Harbison&Steele.  */
2412  union
2413  {
2414    long l;
2415    char c[sizeof (long)];
2416  } u;
2417  u.l = 1;
2418  exit (u.c[sizeof (long) - 1] == 1);
2419}
2420EOF
2421if { (eval echo configure:2422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
2422then
2423  ac_cv_c_bigendian=no
2424else
2425  echo "configure: failed program was:" >&5
2426  cat conftest.$ac_ext >&5
2427  rm -fr conftest*
2428  ac_cv_c_bigendian=yes
2429fi
2430rm -fr conftest*
2431fi
2432
2433fi
2434fi
2435
2436echo "$ac_t""$ac_cv_c_bigendian" 1>&6
2437if test $ac_cv_c_bigendian = yes; then
2438  cat >> confdefs.h <<\EOF
2439#define WORDS_BIGENDIAN 1
2440EOF
2441
2442fi
2443
2444
2445
2446
2447ac_ext=C
2448# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2449ac_cpp='$CXXCPP $CPPFLAGS'
2450ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2451ac_link='${CXX-g++} -o conftest $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2452cross_compiling=$ac_cv_prog_cxx_cross
2453
2454ab_flags=
2455for ab_flag in -fno-exceptions -fno-rtti; do
2456
2457echo $ac_n "checking whether ${CXX} supports the $ab_flag flag""... $ac_c" 1>&6
2458echo "configure:2459: checking whether ${CXX} supports the $ab_flag flag" >&5
2459ab_flag_var=`echo $ab_flag | sed 'y%./+-%__p_%'`
2460if eval "test \"`echo '$''{'ab_cv_flag_$ab_flag_var'+set}'`\" = set"; then
2461  echo $ac_n "(cached) $ac_c" 1>&6
2462else
2463 
2464
2465ab_save_flags="$CXXFLAGS"
2466CXXFLAGS="$CXXFLAGS $ab_flag"
2467cat > conftest.$ac_ext <<EOF
2468#line 2469 "configure"
2469#include "confdefs.h"
2470
2471int main() {
2472int a;
2473; return 0; }
2474EOF
2475if { (eval echo configure:2476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2476  rm -rf conftest*
2477  eval "ab_cv_flag_$ab_flag_var=yes"
2478else
2479  echo "configure: failed program was:" >&5
2480  cat conftest.$ac_ext >&5
2481  rm -rf conftest*
2482  eval "ab_cv_flag_$ab_flag_var=no"
2483fi
2484rm -f conftest*
2485CXXFLAGS="$ab_save_flags"
2486
2487fi
2488
2489if eval "test \"`echo '$ab_cv_flag_'$ab_flag_var`\" = yes"; then
2490  echo "$ac_t""yes" 1>&6
2491  ab_flags="$ab_flags $ab_flag"
2492else
2493  echo "$ac_t""no" 1>&6
2494fi
2495
2496
2497ADDCXXFLAGS="$ab_flags"
2498
2499done
2500
2501ac_ext=c
2502# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
2503ac_cpp='$CPP $CPPFLAGS'
2504ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
2505ac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
2506cross_compiling=$ac_cv_prog_cc_cross
2507
2508
2509mkdir -p src/net/unix src/net/mac
2510
2511trap '' 1 2 15
2512cat > confcache <<\EOF
2513# This file is a shell script that caches the results of configure
2514# tests run on this system so they can be shared between configure
2515# scripts and configure runs.  It is not useful on other systems.
2516# If it contains results you don't want to keep, you may remove or edit it.
2517#
2518# By default, configure uses ./config.cache as the cache file,
2519# creating it if it does not exist already.  You can give configure
2520# the --cache-file=FILE option to use a different cache file; that is
2521# what configure does when it calls configure scripts in
2522# subdirectories, so they share the cache.
2523# Giving --cache-file=/dev/null disables caching, for debugging configure.
2524# config.status only pays attention to the cache file if you give it the
2525# --recheck option to rerun configure.
2526#
2527EOF
2528# The following way of writing the cache mishandles newlines in values,
2529# but we know of no workaround that is simple, portable, and efficient.
2530# So, don't put newlines in cache variables' values.
2531# Ultrix sh set writes to stderr and can't be redirected directly,
2532# and sets the high bit in the cache file unless we assign to the vars.
2533(set) 2>&1 |
2534  case `(ac_space=' '; set) 2>&1` in
2535  *ac_space=\ *)
2536    # `set' does not quote correctly, so add quotes (double-quote substitution
2537    # turns \\\\ into \\, and sed turns \\ into \).
2538    sed -n \
2539      -e "s/'/'\\\\''/g" \
2540      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2541    ;;
2542  *)
2543    # `set' quotes correctly as required by POSIX, so do not add quotes.
2544    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2545    ;;
2546  esac >> confcache
2547if cmp -s $cache_file confcache; then
2548  :
2549else
2550  if test -w $cache_file; then
2551    echo "updating cache $cache_file"
2552    cat confcache > $cache_file
2553  else
2554    echo "not updating unwritable cache $cache_file"
2555  fi
2556fi
2557rm -f confcache
2558
2559trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2560
2561test "x$prefix" = xNONE && prefix=$ac_default_prefix
2562# Let make expand exec_prefix.
2563test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2564
2565# Any assignment to VPATH causes Sun make to only execute
2566# the first set of double-colon rules, so remove it if not needed.
2567# If there is a colon in the path, we need to keep it.
2568if test "x$srcdir" = x.; then
2569  ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
2570fi
2571
2572trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2573
2574# Transform confdefs.h into DEFS.
2575# Protect against shell expansion while executing Makefile rules.
2576# Protect against Makefile macro expansion.
2577cat > conftest.defs <<\EOF
2578s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
2579s%[     `~#$^&*(){}\\|;'"<>?]%\\&%g
2580s%\[%\\&%g
2581s%\]%\\&%g
2582s%\$%$$%g
2583EOF
2584DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
2585rm -f conftest.defs
2586
2587
2588# Without the "./", some shells look in PATH for config.status.
2589: ${CONFIG_STATUS=./config.status}
2590
2591echo creating $CONFIG_STATUS
2592rm -f $CONFIG_STATUS
2593cat > $CONFIG_STATUS <<EOF
2594#! /bin/sh
2595# Generated automatically by configure.
2596# Run this file to recreate the current configuration.
2597# This directory was configured as follows,
2598# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2599#
2600# $0 $ac_configure_args
2601#
2602# Compiler output produced by configure, useful for debugging
2603# configure, is in ./config.log if it exists.
2604
2605ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2606for ac_option
2607do
2608  case "\$ac_option" in
2609  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2610    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2611    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2612  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2613    echo "$CONFIG_STATUS generated by autoconf version 2.12"
2614    exit 0 ;;
2615  -help | --help | --hel | --he | --h)
2616    echo "\$ac_cs_usage"; exit 0 ;;
2617  *) echo "\$ac_cs_usage"; exit 1 ;;
2618  esac
2619done
2620
2621ac_given_srcdir=$srcdir
2622ac_given_INSTALL="$INSTALL"
2623
2624trap 'rm -fr `echo "Makefile abuse" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2625EOF
2626cat >> $CONFIG_STATUS <<EOF
2627
2628# Protect against being on the right side of a sed subst in config.status.
2629sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2630 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2631$ac_vpsub
2632$extrasub
2633s%@CFLAGS@%$CFLAGS%g
2634s%@CPPFLAGS@%$CPPFLAGS%g
2635s%@CXXFLAGS@%$CXXFLAGS%g
2636s%@DEFS@%$DEFS%g
2637s%@LDFLAGS@%$LDFLAGS%g
2638s%@LIBS@%$LIBS%g
2639s%@exec_prefix@%$exec_prefix%g
2640s%@prefix@%$prefix%g
2641s%@program_transform_name@%$program_transform_name%g
2642s%@bindir@%$bindir%g
2643s%@sbindir@%$sbindir%g
2644s%@libexecdir@%$libexecdir%g
2645s%@datadir@%$datadir%g
2646s%@sysconfdir@%$sysconfdir%g
2647s%@sharedstatedir@%$sharedstatedir%g
2648s%@localstatedir@%$localstatedir%g
2649s%@libdir@%$libdir%g
2650s%@includedir@%$includedir%g
2651s%@oldincludedir@%$oldincludedir%g
2652s%@infodir@%$infodir%g
2653s%@mandir@%$mandir%g
2654s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2655s%@INSTALL_DATA@%$INSTALL_DATA%g
2656s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
2657s%@PACKAGE@%$PACKAGE%g
2658s%@VERSION@%$VERSION%g
2659s%@ACLOCAL@%$ACLOCAL%g
2660s%@AUTOCONF@%$AUTOCONF%g
2661s%@AUTOMAKE@%$AUTOMAKE%g
2662s%@AUTOHEADER@%$AUTOHEADER%g
2663s%@MAKEINFO@%$MAKEINFO%g
2664s%@SET_MAKE@%$SET_MAKE%g
2665s%@CC@%$CC%g
2666s%@CPP@%$CPP%g
2667s%@CXX@%$CXX%g
2668s%@host@%$host%g
2669s%@host_alias@%$host_alias%g
2670s%@host_cpu@%$host_cpu%g
2671s%@host_vendor@%$host_vendor%g
2672s%@host_os@%$host_os%g
2673s%@X_CFLAGS@%$X_CFLAGS%g
2674s%@X_PRE_LIBS@%$X_PRE_LIBS%g
2675s%@X_LIBS@%$X_LIBS%g
2676s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
2677s%@PROGS@%$PROGS%g
2678s%@ADDCXXFLAGS@%$ADDCXXFLAGS%g
2679
2680CEOF
2681EOF
2682
2683cat >> $CONFIG_STATUS <<\EOF
2684
2685# Split the substitutions into bite-sized pieces for seds with
2686# small command number limits, like on Digital OSF/1 and HP-UX.
2687ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2688ac_file=1 # Number of current file.
2689ac_beg=1 # First line for current file.
2690ac_end=$ac_max_sed_cmds # Line after last line for current file.
2691ac_more_lines=:
2692ac_sed_cmds=""
2693while $ac_more_lines; do
2694  if test $ac_beg -gt 1; then
2695    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2696  else
2697    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2698  fi
2699  if test ! -s conftest.s$ac_file; then
2700    ac_more_lines=false
2701    rm -f conftest.s$ac_file
2702  else
2703    if test -z "$ac_sed_cmds"; then
2704      ac_sed_cmds="sed -f conftest.s$ac_file"
2705    else
2706      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2707    fi
2708    ac_file=`expr $ac_file + 1`
2709    ac_beg=$ac_end
2710    ac_end=`expr $ac_end + $ac_max_sed_cmds`
2711  fi
2712done
2713if test -z "$ac_sed_cmds"; then
2714  ac_sed_cmds=cat
2715fi
2716EOF
2717
2718cat >> $CONFIG_STATUS <<EOF
2719
2720CONFIG_FILES=\${CONFIG_FILES-"Makefile abuse"}
2721EOF
2722cat >> $CONFIG_STATUS <<\EOF
2723for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2724  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2725  case "$ac_file" in
2726  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2727       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2728  *) ac_file_in="${ac_file}.in" ;;
2729  esac
2730
2731  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2732
2733  # Remove last slash and all that follows it.  Not all systems have dirname.
2734  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2735  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2736    # The file is in a subdirectory.
2737    test ! -d "$ac_dir" && mkdir "$ac_dir"
2738    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2739    # A "../" for each directory in $ac_dir_suffix.
2740    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2741  else
2742    ac_dir_suffix= ac_dots=
2743  fi
2744
2745  case "$ac_given_srcdir" in
2746  .)  srcdir=.
2747      if test -z "$ac_dots"; then top_srcdir=.
2748      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2749  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2750  *) # Relative path.
2751    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2752    top_srcdir="$ac_dots$ac_given_srcdir" ;;
2753  esac
2754
2755  case "$ac_given_INSTALL" in
2756  [/$]*) INSTALL="$ac_given_INSTALL" ;;
2757  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2758  esac
2759
2760  echo creating "$ac_file"
2761  rm -f "$ac_file"
2762  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2763  case "$ac_file" in
2764  *Makefile*) ac_comsub="1i\\
2765# $configure_input" ;;
2766  *) ac_comsub= ;;
2767  esac
2768
2769  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2770  sed -e "$ac_comsub
2771s%@configure_input@%$configure_input%g
2772s%@srcdir@%$srcdir%g
2773s%@top_srcdir@%$top_srcdir%g
2774s%@INSTALL@%$INSTALL%g
2775" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2776fi; done
2777rm -f conftest.s*
2778
2779EOF
2780cat >> $CONFIG_STATUS <<EOF
2781
2782EOF
2783cat >> $CONFIG_STATUS <<\EOF
2784
2785exit 0
2786EOF
2787chmod +x $CONFIG_STATUS
2788rm -fr confdefs* $ac_clean_files
2789test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2790
Note: See TracBrowser for help on using the repository browser.