ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/host/c++/socket++-1.10/configure
Revision: 1.1
Committed: Mon Feb 26 15:01:39 2001 UTC (23 years, 9 months ago) by ab11
Branch: MAIN
CVS Tags: PROJECT_COMPLETION
Log Message:
Networking class. Assumed to be bug free.

File Contents

# User Rev Content
1 ab11 1.1 #!/bin/sh
2    
3     # Guess values for system-dependent variables and create Makefiles.
4     # Generated automatically using autoconf version 2.1
5     # Copyright (C) 1992, 1993, 1994 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:
11     ac_help=
12     ac_default_prefix=/usr/local
13     # Any additions from configure.in:
14    
15     # Initialize some variables set by options.
16     # The variables have the same names as the options, with
17     # dashes changed to underlines.
18     build=NONE
19     cache_file=./config.cache
20     exec_prefix=NONE
21     host=NONE
22     no_create=
23     nonopt=NONE
24     no_recursion=
25     prefix=NONE
26     program_prefix=NONE
27     program_suffix=NONE
28     program_transform_name=s,x,x,
29     silent=
30     site=
31     srcdir=
32     target=NONE
33     verbose=
34     x_includes=NONE
35     x_libraries=NONE
36    
37     # Initialize some other variables.
38     subdirs=
39    
40     ac_prev=
41     for ac_option
42     do
43    
44     # If the previous option needs an argument, assign it.
45     if test -n "$ac_prev"; then
46     eval "$ac_prev=\$ac_option"
47     ac_prev=
48     continue
49     fi
50    
51     case "$ac_option" in
52     -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
53     *) ac_optarg= ;;
54     esac
55    
56     # Accept the important Cygnus configure options, so we can diagnose typos.
57    
58     case "$ac_option" in
59    
60     -build | --build | --buil | --bui | --bu | --b)
61     ac_prev=build ;;
62     -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
63     build="$ac_optarg" ;;
64    
65     -cache-file | --cache-file | --cache-fil | --cache-fi \
66     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
67     ac_prev=cache_file ;;
68     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
69     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
70     cache_file="$ac_optarg" ;;
71    
72     -disable-* | --disable-*)
73     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
74     # Reject names that are not valid shell variable names.
75     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
76     { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
77     fi
78     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
79     eval "enable_${ac_feature}=no" ;;
80    
81     -enable-* | --enable-*)
82     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
83     # Reject names that are not valid shell variable names.
84     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
85     { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
86     fi
87     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
88     case "$ac_option" in
89     *=*) ;;
90     *) ac_optarg=yes ;;
91     esac
92     eval "enable_${ac_feature}='$ac_optarg'" ;;
93    
94     -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
95     | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
96     | --exec | --exe | --ex)
97     ac_prev=exec_prefix ;;
98     -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
99     | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
100     | --exec=* | --exe=* | --ex=*)
101     exec_prefix="$ac_optarg" ;;
102    
103     -gas | --gas | --ga | --g)
104     # Obsolete; use --with-gas.
105     with_gas=yes ;;
106    
107     -help | --help | --hel | --he)
108     # Omit some internal or obsolete options to make the list less imposing.
109     # This message is too long to be a string in the A/UX 3.1 sh.
110     cat << EOF
111     Usage: configure [options] [host]
112     Options: [defaults in brackets after descriptions]
113     Configuration:
114     --cache-file=FILE cache test results in FILE
115     --help print this message
116     --no-create do not create output files
117     --quiet, --silent do not print \`checking...' messages
118     --version print the version of autoconf that created configure
119     Directory and file names:
120     --prefix=PREFIX install architecture-independent files in PREFIX
121     [$ac_default_prefix]
122     --exec-prefix=PREFIX install architecture-dependent files in PREFIX
123     [same as prefix]
124     --srcdir=DIR find the sources in DIR [configure dir or ..]
125     --program-prefix=PREFIX prepend PREFIX to installed program names
126     --program-suffix=SUFFIX append SUFFIX to installed program names
127     --program-transform-name=PROGRAM run sed PROGRAM on installed program names
128     Host type:
129     --build=BUILD configure for building on BUILD [BUILD=HOST]
130     --host=HOST configure for HOST [guessed]
131     --target=TARGET configure for TARGET [TARGET=HOST]
132     Features and packages:
133     --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
134     --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
135     --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
136     --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
137     --x-includes=DIR X include files are in DIR
138     --x-libraries=DIR X library files are in DIR
139     --enable and --with options recognized:$ac_help
140     EOF
141     exit 0 ;;
142    
143     -host | --host | --hos | --ho)
144     ac_prev=host ;;
145     -host=* | --host=* | --hos=* | --ho=*)
146     host="$ac_optarg" ;;
147    
148     -nfp | --nfp | --nf)
149     # Obsolete; use --without-fp.
150     with_fp=no ;;
151    
152     -no-create | --no-create | --no-creat | --no-crea | --no-cre \
153     | --no-cr | --no-c)
154     no_create=yes ;;
155    
156     -no-recursion | --no-recursion | --no-recursio | --no-recursi \
157     | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
158     no_recursion=yes ;;
159    
160     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
161     ac_prev=prefix ;;
162     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
163     prefix="$ac_optarg" ;;
164    
165     -program-prefix | --program-prefix | --program-prefi | --program-pref \
166     | --program-pre | --program-pr | --program-p)
167     ac_prev=program_prefix ;;
168     -program-prefix=* | --program-prefix=* | --program-prefi=* \
169     | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
170     program_prefix="$ac_optarg" ;;
171    
172     -program-suffix | --program-suffix | --program-suffi | --program-suff \
173     | --program-suf | --program-su | --program-s)
174     ac_prev=program_suffix ;;
175     -program-suffix=* | --program-suffix=* | --program-suffi=* \
176     | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
177     program_suffix="$ac_optarg" ;;
178    
179     -program-transform-name | --program-transform-name \
180     | --program-transform-nam | --program-transform-na \
181     | --program-transform-n | --program-transform- \
182     | --program-transform | --program-transfor \
183     | --program-transfo | --program-transf \
184     | --program-trans | --program-tran \
185     | --progr-tra | --program-tr | --program-t)
186     ac_prev=program_transform_name ;;
187     -program-transform-name=* | --program-transform-name=* \
188     | --program-transform-nam=* | --program-transform-na=* \
189     | --program-transform-n=* | --program-transform-=* \
190     | --program-transform=* | --program-transfor=* \
191     | --program-transfo=* | --program-transf=* \
192     | --program-trans=* | --program-tran=* \
193     | --progr-tra=* | --program-tr=* | --program-t=*)
194     program_transform_name="$ac_optarg" ;;
195    
196     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
197     | -silent | --silent | --silen | --sile | --sil)
198     silent=yes ;;
199    
200     -site | --site | --sit)
201     ac_prev=site ;;
202     -site=* | --site=* | --sit=*)
203     site="$ac_optarg" ;;
204    
205     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
206     ac_prev=srcdir ;;
207     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
208     srcdir="$ac_optarg" ;;
209    
210     -target | --target | --targe | --targ | --tar | --ta | --t)
211     ac_prev=target ;;
212     -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
213     target="$ac_optarg" ;;
214    
215     -v | -verbose | --verbose | --verbos | --verbo | --verb)
216     verbose=yes ;;
217    
218     -version | --version | --versio | --versi | --vers)
219     echo "configure generated by autoconf version 2.1"
220     exit 0 ;;
221    
222     -with-* | --with-*)
223     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
224     # Reject names that are not valid shell variable names.
225     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
226     { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
227     fi
228     ac_package=`echo $ac_package| sed 's/-/_/g'`
229     case "$ac_option" in
230     *=*) ;;
231     *) ac_optarg=yes ;;
232     esac
233     eval "with_${ac_package}='$ac_optarg'" ;;
234    
235     -without-* | --without-*)
236     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
237     # Reject names that are not valid shell variable names.
238     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
239     { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
240     fi
241     ac_package=`echo $ac_package| sed 's/-/_/g'`
242     eval "with_${ac_package}=no" ;;
243    
244     --x)
245     # Obsolete; use --with-x.
246     with_x=yes ;;
247    
248     -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
249     | --x-incl | --x-inc | --x-in | --x-i)
250     ac_prev=x_includes ;;
251     -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
252     | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
253     x_includes="$ac_optarg" ;;
254    
255     -x-libraries | --x-libraries | --x-librarie | --x-librari \
256     | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
257     ac_prev=x_libraries ;;
258     -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
259     | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
260     x_libraries="$ac_optarg" ;;
261    
262     -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
263     ;;
264    
265     *)
266     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
267     echo "configure: warning: $ac_option: invalid host type" 1>&2
268     fi
269     if test "x$nonopt" != xNONE; then
270     { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
271     fi
272     nonopt="$ac_option"
273     ;;
274    
275     esac
276     done
277    
278     if test -n "$ac_prev"; then
279     { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
280     fi
281    
282     trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
283    
284     # File descriptor usage:
285     # 0 unused; standard input
286     # 1 file creation
287     # 2 errors and warnings
288     # 3 unused; some systems may open it to /dev/tty
289     # 4 checking for... messages and results
290     # 5 compiler messages saved in config.log
291     if test "$silent" = yes; then
292     exec 4>/dev/null
293     else
294     exec 4>&1
295     fi
296     exec 5>./config.log
297    
298     echo "\
299     This file contains any messages produced by compilers while
300     running configure, to aid debugging if configure makes a mistake.
301     " 1>&5
302    
303     # Strip out --no-create and --no-recursion so they do not pile up.
304     # Also quote any args containing shell metacharacters.
305     ac_configure_args=
306     for ac_arg
307     do
308     case "$ac_arg" in
309     -no-create | --no-create | --no-creat | --no-crea | --no-cre \
310     | --no-cr | --no-c) ;;
311     -no-recursion | --no-recursion | --no-recursio | --no-recursi \
312     | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
313     *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
314     ac_configure_args="$ac_configure_args '$ac_arg'" ;;
315     *) ac_configure_args="$ac_configure_args $ac_arg" ;;
316     esac
317     done
318    
319     # NLS nuisances.
320     # Only set LANG and LC_ALL to C if already set.
321     # These must not be set unconditionally because not all systems understand
322     # e.g. LANG=C (notably SCO).
323     if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
324     if test "${LANG+set}" = set; then LANG=C; export LANG; fi
325    
326     # confdefs.h avoids OS command line length limits that DEFS can exceed.
327     rm -rf conftest* confdefs.h
328     # AIX cpp loses on an empty file, so make sure it contains at least a newline.
329     echo > confdefs.h
330    
331     # A filename unique to this package, relative to the directory that
332     # configure is in, which we can look for to find out if srcdir is correct.
333     ac_unique_file=sockstream.h
334    
335     # Find the source files, if location was not specified.
336     if test -z "$srcdir"; then
337     ac_srcdir_defaulted=yes
338     # Try the directory containing this script, then its parent.
339     ac_prog=$0
340     ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
341     test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
342     srcdir=$ac_confdir
343     if test ! -r $srcdir/$ac_unique_file; then
344     srcdir=..
345     fi
346     else
347     ac_srcdir_defaulted=no
348     fi
349     if test ! -r $srcdir/$ac_unique_file; then
350     if test "$ac_srcdir_defaulted" = yes; then
351     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
352     else
353     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
354     fi
355     fi
356     srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
357    
358     # Prefer explicitly selected file to automatically selected ones.
359     if test -z "$CONFIG_SITE"; then
360     if test "x$prefix" != xNONE; then
361     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
362     else
363     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
364     fi
365     fi
366     for ac_site_file in $CONFIG_SITE; do
367     if test -r "$ac_site_file"; then
368     echo "loading site script $ac_site_file"
369     . "$ac_site_file"
370     fi
371     done
372    
373     if test -r "$cache_file"; then
374     echo "loading cache $cache_file"
375     . $cache_file
376     else
377     echo "creating cache $cache_file"
378     > $cache_file
379     fi
380    
381     ac_ext=c
382     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
383     ac_cpp='$CPP $CPPFLAGS'
384     ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
385     ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
386    
387     if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
388     # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
389     if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
390     ac_n= ac_c='
391     ' ac_t=' '
392     else
393     ac_n=-n ac_c= ac_t=
394     fi
395     else
396     ac_n= ac_c='\c' ac_t=
397     fi
398    
399    
400    
401     echo $ac_n "checking whether ${MAKE-make} sets \$MAKE""... $ac_c" 1>&4
402     set dummy ${MAKE-make}; ac_make=$2
403     if eval "test \"`echo '${'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
404     echo $ac_n "(cached) $ac_c" 1>&4
405     else
406     cat > conftestmake <<\EOF
407     all:
408     @echo 'ac_maketemp="${MAKE}"'
409     EOF
410     # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
411     eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
412     if test -n "$ac_maketemp"; then
413     eval ac_cv_prog_make_${ac_make}_set=yes
414     else
415     eval ac_cv_prog_make_${ac_make}_set=no
416     fi
417     rm -f conftestmake
418     fi
419     if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
420     echo "$ac_t""yes" 1>&4
421     SET_MAKE=
422     else
423     echo "$ac_t""no" 1>&4
424     SET_MAKE="MAKE=${MAKE-make}"
425     fi
426    
427     # Extract the first word of "gcc", so it can be a program name with args.
428     set dummy gcc; ac_word=$2
429     echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
430     if eval "test \"`echo '${'ac_cv_prog_CC'+set}'`\" = set"; then
431     echo $ac_n "(cached) $ac_c" 1>&4
432     else
433     if test -n "$CC"; then
434     ac_cv_prog_CC="$CC" # Let the user override the test.
435     else
436     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
437     for ac_dir in $PATH; do
438     test -z "$ac_dir" && ac_dir=.
439     if test -f $ac_dir/$ac_word; then
440     ac_cv_prog_CC="gcc"
441     break
442     fi
443     done
444     IFS="$ac_save_ifs"
445     test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="cc"
446     fi
447     fi
448     CC="$ac_cv_prog_CC"
449     if test -n "$CC"; then
450     echo "$ac_t""$CC" 1>&4
451     else
452     echo "$ac_t""no" 1>&4
453     fi
454    
455    
456     echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&4
457     if eval "test \"`echo '${'ac_cv_prog_gcc'+set}'`\" = set"; then
458     echo $ac_n "(cached) $ac_c" 1>&4
459     else
460     cat > conftest.c <<EOF
461     #ifdef __GNUC__
462     yes;
463     #endif
464     EOF
465     if ${CC-cc} -E conftest.c 2>&5 | egrep yes >/dev/null 2>&1; then
466     ac_cv_prog_gcc=yes
467     else
468     ac_cv_prog_gcc=no
469     fi
470     fi
471     echo "$ac_t""$ac_cv_prog_gcc" 1>&4
472     if test $ac_cv_prog_gcc = yes; then
473     GCC=yes
474     if test "${CFLAGS+set}" != set; then
475     echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&4
476     if eval "test \"`echo '${'ac_cv_prog_gcc_g'+set}'`\" = set"; then
477     echo $ac_n "(cached) $ac_c" 1>&4
478     else
479     echo 'void f(){}' > conftest.c
480     if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
481     ac_cv_prog_gcc_g=yes
482     else
483     ac_cv_prog_gcc_g=no
484     fi
485     rm -f conftest*
486    
487     fi
488     echo "$ac_t""$ac_cv_prog_gcc_g" 1>&4
489     if test $ac_cv_prog_gcc_g = yes; then
490     CFLAGS="-g -O"
491     else
492     CFLAGS="-O"
493     fi
494     fi
495     else
496     GCC=
497     test "${CFLAGS+set}" = set || CFLAGS="-g"
498     fi
499    
500     for ac_prog in $CCC c++ g++ gcc CC cxx
501     do
502     # Extract the first word of "$ac_prog", so it can be a program name with args.
503     set dummy $ac_prog; ac_word=$2
504     echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
505     if eval "test \"`echo '${'ac_cv_prog_CXX'+set}'`\" = set"; then
506     echo $ac_n "(cached) $ac_c" 1>&4
507     else
508     if test -n "$CXX"; then
509     ac_cv_prog_CXX="$CXX" # Let the user override the test.
510     else
511     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
512     for ac_dir in $PATH; do
513     test -z "$ac_dir" && ac_dir=.
514     if test -f $ac_dir/$ac_word; then
515     ac_cv_prog_CXX="$ac_prog"
516     break
517     fi
518     done
519     IFS="$ac_save_ifs"
520     fi
521     fi
522     CXX="$ac_cv_prog_CXX"
523     if test -n "$CXX"; then
524     echo "$ac_t""$CXX" 1>&4
525     else
526     echo "$ac_t""no" 1>&4
527     fi
528    
529     test -n "$CXX" && break
530     done
531     test -n "$CXX" || CXX="gcc"
532    
533    
534     echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&4
535     if eval "test \"`echo '${'ac_cv_prog_gxx'+set}'`\" = set"; then
536     echo $ac_n "(cached) $ac_c" 1>&4
537     else
538     cat > conftest.C <<EOF
539     #ifdef __GNUC__
540     yes;
541     #endif
542     EOF
543     if ${CXX-g++} -E conftest.C 2>&5 | egrep yes >/dev/null 2>&1; then
544     ac_cv_prog_gxx=yes
545     else
546     ac_cv_prog_gxx=no
547     fi
548     fi
549     echo "$ac_t""$ac_cv_prog_gxx" 1>&4
550     if test $ac_cv_prog_gxx = yes; then
551     GXX=yes
552     if test "${CXXFLAGS+set}" != set; then
553     echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&4
554     if eval "test \"`echo '${'ac_cv_prog_gxx_g'+set}'`\" = set"; then
555     echo $ac_n "(cached) $ac_c" 1>&4
556     else
557     echo 'void f(){}' > conftest.cc
558     if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
559     ac_cv_prog_gxx_g=yes
560     else
561     ac_cv_prog_gxx_g=no
562     fi
563     rm -f conftest*
564    
565     fi
566     echo "$ac_t""$ac_cv_prog_gxx_g" 1>&4
567     if test $ac_cv_prog_gxx_g = yes; then
568     CXXFLAGS="-g -O"
569     else
570     CXXFLAGS="-O"
571     fi
572     fi
573     else
574     GXX=
575     test "${CXXFLAGS+set}" = set || CXXFLAGS="-g"
576     fi
577    
578     # Extract the first word of "ranlib", so it can be a program name with args.
579     set dummy ranlib; ac_word=$2
580     echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
581     if eval "test \"`echo '${'ac_cv_prog_RANLIB'+set}'`\" = set"; then
582     echo $ac_n "(cached) $ac_c" 1>&4
583     else
584     if test -n "$RANLIB"; then
585     ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
586     else
587     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
588     for ac_dir in $PATH; do
589     test -z "$ac_dir" && ac_dir=.
590     if test -f $ac_dir/$ac_word; then
591     ac_cv_prog_RANLIB="ranlib"
592     break
593     fi
594     done
595     IFS="$ac_save_ifs"
596     test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
597     fi
598     fi
599     RANLIB="$ac_cv_prog_RANLIB"
600     if test -n "$RANLIB"; then
601     echo "$ac_t""$RANLIB" 1>&4
602     else
603     echo "$ac_t""no" 1>&4
604     fi
605    
606     # Extract the first word of "makedepend", so it can be a program name with args.
607     set dummy makedepend; ac_word=$2
608     echo $ac_n "checking for $ac_word""... $ac_c" 1>&4
609     if eval "test \"`echo '${'ac_cv_prog_MAKEDEPEND'+set}'`\" = set"; then
610     echo $ac_n "(cached) $ac_c" 1>&4
611     else
612     if test -n "$MAKEDEPEND"; then
613     ac_cv_prog_MAKEDEPEND="$MAKEDEPEND" # Let the user override the test.
614     else
615     IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
616     for ac_dir in $PATH; do
617     test -z "$ac_dir" && ac_dir=.
618     if test -f $ac_dir/$ac_word; then
619     ac_cv_prog_MAKEDEPEND="makedepend"
620     break
621     fi
622     done
623     IFS="$ac_save_ifs"
624     test -z "$ac_cv_prog_MAKEDEPEND" && ac_cv_prog_MAKEDEPEND=":"
625     fi
626     fi
627     MAKEDEPEND="$ac_cv_prog_MAKEDEPEND"
628     if test -n "$MAKEDEPEND"; then
629     echo "$ac_t""$MAKEDEPEND" 1>&4
630     else
631     echo "$ac_t""no" 1>&4
632     fi
633     echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&4
634     # On Suns, sometimes $CPP names a directory.
635     if test -n "$CPP" && test -d "$CPP"; then
636     CPP=
637     fi
638     if test -z "$CPP"; then
639     if eval "test \"`echo '${'ac_cv_prog_CPP'+set}'`\" = set"; then
640     echo $ac_n "(cached) $ac_c" 1>&4
641     else
642     # This must be in double quotes, not single quotes, because CPP may get
643     # substituted into the Makefile and "${CC-cc}" will confuse make.
644     CPP="${CC-cc} -E"
645     # On the NeXT, cc -E runs the code through the compiler's parser,
646     # not just through cpp.
647     cat > conftest.$ac_ext <<EOF
648     #line 649 "configure"
649     #include "confdefs.h"
650     #include <assert.h>
651     Syntax Error
652     EOF
653     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
654     ac_err=`grep -v '^ *+' conftest.out`
655     if test -z "$ac_err"; then
656     :
657     else
658     echo "$ac_err" >&5
659     rm -rf conftest*
660     CPP="${CC-cc} -E -traditional-cpp"
661     cat > conftest.$ac_ext <<EOF
662     #line 663 "configure"
663     #include "confdefs.h"
664     #include <assert.h>
665     Syntax Error
666     EOF
667     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
668     ac_err=`grep -v '^ *+' conftest.out`
669     if test -z "$ac_err"; then
670     :
671     else
672     echo "$ac_err" >&5
673     rm -rf conftest*
674     CPP=/lib/cpp
675     fi
676     rm -f conftest*
677     fi
678     rm -f conftest*
679     ac_cv_prog_CPP="$CPP"
680     fi
681     fi
682     CPP="$ac_cv_prog_CPP"
683     echo "$ac_t""$CPP" 1>&4
684     echo $ac_n "checking how to run the C++ preprocessor""... $ac_c" 1>&4
685     if test -z "$CXXCPP"; then
686     if eval "test \"`echo '${'ac_cv_prog_CXXCPP'+set}'`\" = set"; then
687     echo $ac_n "(cached) $ac_c" 1>&4
688     else
689     ac_ext=C
690     # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
691     ac_cpp='$CXXCPP $CPPFLAGS'
692     ac_compile='${CXX-g++} $CXXFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
693     ac_link='${CXX-g++} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
694     CXXCPP="${CXX-g++} -E"
695     cat > conftest.$ac_ext <<EOF
696     #line 697 "configure"
697     #include "confdefs.h"
698     #include <stdlib.h>
699     EOF
700     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
701     ac_err=`grep -v '^ *+' conftest.out`
702     if test -z "$ac_err"; then
703     :
704     else
705     echo "$ac_err" >&5
706     rm -rf conftest*
707     CXXCPP=/lib/cpp
708     fi
709     rm -f conftest*
710     ac_cv_prog_CXXCPP="$CXXCPP"
711     ac_ext=c
712     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
713     ac_cpp='$CPP $CPPFLAGS'
714     ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
715     ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
716     fi
717     fi
718     CXXCPP="$ac_cv_prog_CXXCPP"
719     echo "$ac_t""$CXXCPP" 1>&4
720     echo $ac_n "checking for AIX""... $ac_c" 1>&4
721     cat > conftest.$ac_ext <<EOF
722     #line 723 "configure"
723     #include "confdefs.h"
724     #ifdef _AIX
725     yes
726     #endif
727    
728     EOF
729     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
730     egrep "yes" >/dev/null 2>&1; then
731     rm -rf conftest*
732     echo "$ac_t""yes" 1>&4; cat >> confdefs.h <<\EOF
733     #define _ALL_SOURCE 1
734     EOF
735    
736     else
737     rm -rf conftest*
738     echo "$ac_t""no" 1>&4
739     fi
740     rm -f conftest*
741    
742    
743    
744     echo $ac_n "checking for -lnsl""... $ac_c" 1>&4
745     if eval "test \"`echo '${'ac_cv_lib_nsl'+set}'`\" = set"; then
746     echo $ac_n "(cached) $ac_c" 1>&4
747     else
748     ac_save_LIBS="$LIBS"
749     LIBS="$LIBS -lnsl "
750     cat > conftest.$ac_ext <<EOF
751     #line 752 "configure"
752     #include "confdefs.h"
753    
754     int main() { return 0; }
755     int t() {
756     t_accept()
757     ; return 0; }
758     EOF
759     if eval $ac_link; then
760     rm -rf conftest*
761     eval "ac_cv_lib_nsl=yes"
762     else
763     rm -rf conftest*
764     eval "ac_cv_lib_nsl=no"
765     fi
766     rm -f conftest*
767     LIBS="$ac_save_LIBS"
768    
769     fi
770     if eval "test \"`echo '$ac_cv_lib_'nsl`\" = yes"; then
771     echo "$ac_t""yes" 1>&4
772     NETWORK_LIBS="$NETWORK_LIBS -lnsl"
773     else
774     echo "$ac_t""no" 1>&4
775     fi
776    
777     echo $ac_n "checking for -lsocket""... $ac_c" 1>&4
778     if eval "test \"`echo '${'ac_cv_lib_socket'+set}'`\" = set"; then
779     echo $ac_n "(cached) $ac_c" 1>&4
780     else
781     ac_save_LIBS="$LIBS"
782     LIBS="$LIBS -lsocket "
783     cat > conftest.$ac_ext <<EOF
784     #line 785 "configure"
785     #include "confdefs.h"
786    
787     int main() { return 0; }
788     int t() {
789     socket()
790     ; return 0; }
791     EOF
792     if eval $ac_link; then
793     rm -rf conftest*
794     eval "ac_cv_lib_socket=yes"
795     else
796     rm -rf conftest*
797     eval "ac_cv_lib_socket=no"
798     fi
799     rm -f conftest*
800     LIBS="$ac_save_LIBS"
801    
802     fi
803     if eval "test \"`echo '$ac_cv_lib_'socket`\" = yes"; then
804     echo "$ac_t""yes" 1>&4
805     NETWORK_LIBS="$NETWORK_LIBS -lsocket"
806     else
807     echo "$ac_t""no" 1>&4
808     fi
809    
810    
811    
812    
813     ac_ext=C
814     # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
815     ac_cpp='$CXXCPP $CPPFLAGS'
816     ac_compile='${CXX-g++} $CXXFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
817     ac_link='${CXX-g++} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
818    
819     for ac_hdr in builtin.h string.h memory.h
820     do
821     ac_safe=`echo "$ac_hdr" | tr './\055' '___'`
822     echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&4
823     if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
824     echo $ac_n "(cached) $ac_c" 1>&4
825     else
826     cat > conftest.$ac_ext <<EOF
827     #line 828 "configure"
828     #include "confdefs.h"
829     #include <$ac_hdr>
830     EOF
831     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
832     ac_err=`grep -v '^ *+' conftest.out`
833     if test -z "$ac_err"; then
834     rm -rf conftest*
835     eval "ac_cv_header_$ac_safe=yes"
836     else
837     echo "$ac_err" >&5
838     rm -rf conftest*
839     eval "ac_cv_header_$ac_safe=no"
840     fi
841     rm -f conftest*
842     fi
843     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
844     echo "$ac_t""yes" 1>&4
845     ac_tr_hdr=HAVE_`echo $ac_hdr | tr '[a-z]./\055' '[A-Z]___'`
846     cat >> confdefs.h <<EOF
847     #define $ac_tr_hdr 1
848     EOF
849    
850     else
851     echo "$ac_t""no" 1>&4
852     fi
853     done
854    
855     ac_safe=`echo "_G_config.h" | tr './\055' '___'`
856     echo $ac_n "checking for _G_config.h""... $ac_c" 1>&4
857     if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
858     echo $ac_n "(cached) $ac_c" 1>&4
859     else
860     cat > conftest.$ac_ext <<EOF
861     #line 862 "configure"
862     #include "confdefs.h"
863     #include <_G_config.h>
864     EOF
865     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
866     ac_err=`grep -v '^ *+' conftest.out`
867     if test -z "$ac_err"; then
868     rm -rf conftest*
869     eval "ac_cv_header_$ac_safe=yes"
870     else
871     echo "$ac_err" >&5
872     rm -rf conftest*
873     eval "ac_cv_header_$ac_safe=no"
874     fi
875     rm -f conftest*
876     fi
877     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
878     echo "$ac_t""yes" 1>&4
879     cat >> confdefs.h <<\EOF
880     #define _S_LIBGXX 1
881     EOF
882    
883     else
884     echo "$ac_t""no" 1>&4
885     fi
886    
887     ac_ext=c
888     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
889     ac_cpp='$CPP $CPPFLAGS'
890     ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
891     ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
892    
893     echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&4
894     if eval "test \"`echo '${'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
895     echo $ac_n "(cached) $ac_c" 1>&4
896     else
897     cat > conftest.$ac_ext <<EOF
898     #line 899 "configure"
899     #include "confdefs.h"
900     #include <sys/types.h>
901     #include <sys/wait.h>
902     #ifndef WEXITSTATUS
903     #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
904     #endif
905     #ifndef WIFEXITED
906     #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
907     #endif
908     int main() { return 0; }
909     int t() {
910     int s;
911     wait (&s);
912     s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
913     ; return 0; }
914     EOF
915     if eval $ac_compile; then
916     rm -rf conftest*
917     ac_cv_header_sys_wait_h=yes
918     else
919     rm -rf conftest*
920     ac_cv_header_sys_wait_h=no
921     fi
922     rm -f conftest*
923    
924     fi
925     echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&4
926     if test $ac_cv_header_sys_wait_h = yes; then
927     cat >> confdefs.h <<\EOF
928     #define HAVE_SYS_WAIT_H 1
929     EOF
930    
931     fi
932    
933    
934     # If we cannot run a trivial program, we must be cross compiling.
935     echo $ac_n "checking whether cross-compiling""... $ac_c" 1>&4
936     if eval "test \"`echo '${'ac_cv_c_cross'+set}'`\" = set"; then
937     echo $ac_n "(cached) $ac_c" 1>&4
938     else
939     if test "$cross_compiling" = yes; then
940     ac_cv_cross=yes
941     else
942     cat > conftest.$ac_ext <<EOF
943     #line 944 "configure"
944     #include "confdefs.h"
945     main(){return(0);}
946     EOF
947     eval $ac_link
948     if test -s conftest && (./conftest; exit) 2>/dev/null; then
949     ac_cv_c_cross=no
950     else
951     ac_cv_c_cross=yes
952     fi
953     fi
954     rm -fr conftest*
955     fi
956     cross_compiling=$ac_cv_c_cross
957     echo "$ac_t""$ac_cv_c_cross" 1>&4
958    
959     echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&4
960     if eval "test \"`echo '${'ac_cv_header_stdc'+set}'`\" = set"; then
961     echo $ac_n "(cached) $ac_c" 1>&4
962     else
963     cat > conftest.$ac_ext <<EOF
964     #line 965 "configure"
965     #include "confdefs.h"
966     #include <stdlib.h>
967     #include <stdarg.h>
968     #include <string.h>
969     #include <float.h>
970     EOF
971     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
972     ac_err=`grep -v '^ *+' conftest.out`
973     if test -z "$ac_err"; then
974     rm -rf conftest*
975     ac_cv_header_stdc=yes
976     else
977     echo "$ac_err" >&5
978     rm -rf conftest*
979     ac_cv_header_stdc=no
980     fi
981     rm -f conftest*
982    
983     if test $ac_cv_header_stdc = yes; then
984     # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
985     cat > conftest.$ac_ext <<EOF
986     #line 987 "configure"
987     #include "confdefs.h"
988     #include <string.h>
989     EOF
990     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
991     egrep "memchr" >/dev/null 2>&1; then
992     :
993     else
994     rm -rf conftest*
995     ac_cv_header_stdc=no
996     fi
997     rm -f conftest*
998    
999     fi
1000    
1001     if test $ac_cv_header_stdc = yes; then
1002     # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1003     cat > conftest.$ac_ext <<EOF
1004     #line 1005 "configure"
1005     #include "confdefs.h"
1006     #include <stdlib.h>
1007     EOF
1008     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1009     egrep "free" >/dev/null 2>&1; then
1010     :
1011     else
1012     rm -rf conftest*
1013     ac_cv_header_stdc=no
1014     fi
1015     rm -f conftest*
1016    
1017     fi
1018    
1019     if test $ac_cv_header_stdc = yes; then
1020     # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1021     if test "$cross_compiling" = yes; then
1022     ac_cv_header_stdc=no
1023     else
1024     cat > conftest.$ac_ext <<EOF
1025     #line 1026 "configure"
1026     #include "confdefs.h"
1027     #include <ctype.h>
1028     #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1029     #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1030     #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1031     int main () { int i; for (i = 0; i < 256; i++)
1032     if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1033     exit (0); }
1034    
1035     EOF
1036     eval $ac_link
1037     if test -s conftest && (./conftest; exit) 2>/dev/null; then
1038     :
1039     else
1040     ac_cv_header_stdc=no
1041     fi
1042     fi
1043     rm -fr conftest*
1044     fi
1045     fi
1046     echo "$ac_t""$ac_cv_header_stdc" 1>&4
1047     if test $ac_cv_header_stdc = yes; then
1048     cat >> confdefs.h <<\EOF
1049     #define STDC_HEADERS 1
1050     EOF
1051    
1052     fi
1053    
1054     echo $ac_n "checking for pid_t""... $ac_c" 1>&4
1055     if eval "test \"`echo '${'ac_cv_type_pid_t'+set}'`\" = set"; then
1056     echo $ac_n "(cached) $ac_c" 1>&4
1057     else
1058     cat > conftest.$ac_ext <<EOF
1059     #line 1060 "configure"
1060     #include "confdefs.h"
1061     #include <sys/types.h>
1062     #if STDC_HEADERS
1063     #include <stdlib.h>
1064     #endif
1065     EOF
1066     if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1067     egrep "pid_t" >/dev/null 2>&1; then
1068     rm -rf conftest*
1069     ac_cv_type_pid_t=yes
1070     else
1071     rm -rf conftest*
1072     ac_cv_type_pid_t=no
1073     fi
1074     rm -f conftest*
1075    
1076     fi
1077     echo "$ac_t""$ac_cv_type_pid_t" 1>&4
1078     if test $ac_cv_type_pid_t = no; then
1079     cat >> confdefs.h <<\EOF
1080     #define pid_t int
1081     EOF
1082    
1083     fi
1084    
1085    
1086    
1087    
1088    
1089    
1090    
1091     echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&4
1092     if eval "test \"`echo '${'ac_cv_type_signal'+set}'`\" = set"; then
1093     echo $ac_n "(cached) $ac_c" 1>&4
1094     else
1095     cat > conftest.$ac_ext <<EOF
1096     #line 1097 "configure"
1097     #include "confdefs.h"
1098     #include <sys/types.h>
1099     #include <signal.h>
1100     #ifdef signal
1101     #undef signal
1102     #endif
1103     extern void (*signal ()) ();
1104     int main() { return 0; }
1105     int t() {
1106     int i;
1107     ; return 0; }
1108     EOF
1109     if eval $ac_compile; then
1110     rm -rf conftest*
1111     ac_cv_type_signal=void
1112     else
1113     rm -rf conftest*
1114     ac_cv_type_signal=int
1115     fi
1116     rm -f conftest*
1117    
1118     fi
1119     echo "$ac_t""$ac_cv_type_signal" 1>&4
1120     cat >> confdefs.h <<EOF
1121     #define RETSIGTYPE $ac_cv_type_signal
1122     EOF
1123    
1124    
1125     ac_safe=`echo "vfork.h" | tr './\055' '___'`
1126     echo $ac_n "checking for vfork.h""... $ac_c" 1>&4
1127     if eval "test \"`echo '${'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1128     echo $ac_n "(cached) $ac_c" 1>&4
1129     else
1130     cat > conftest.$ac_ext <<EOF
1131     #line 1132 "configure"
1132     #include "confdefs.h"
1133     #include <vfork.h>
1134     EOF
1135     eval "$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1136     ac_err=`grep -v '^ *+' conftest.out`
1137     if test -z "$ac_err"; then
1138     rm -rf conftest*
1139     eval "ac_cv_header_$ac_safe=yes"
1140     else
1141     echo "$ac_err" >&5
1142     rm -rf conftest*
1143     eval "ac_cv_header_$ac_safe=no"
1144     fi
1145     rm -f conftest*
1146     fi
1147     if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1148     echo "$ac_t""yes" 1>&4
1149     cat >> confdefs.h <<\EOF
1150     #define HAVE_VFORK_H 1
1151     EOF
1152    
1153     else
1154     echo "$ac_t""no" 1>&4
1155     fi
1156    
1157     echo $ac_n "checking for working vfork""... $ac_c" 1>&4
1158     if eval "test \"`echo '${'ac_cv_func_vfork'+set}'`\" = set"; then
1159     echo $ac_n "(cached) $ac_c" 1>&4
1160     else
1161    
1162     if test "$cross_compiling" = yes; then
1163     ac_cv_func_vfork=no
1164     else
1165     cat > conftest.$ac_ext <<EOF
1166     #line 1167 "configure"
1167     #include "confdefs.h"
1168     /* Thanks to Paul Eggert for this test. */
1169     #include <stdio.h>
1170     #include <sys/types.h>
1171     #include <sys/stat.h>
1172     #include <signal.h>
1173     #ifdef HAVE_UNISTD_H
1174     #include <unistd.h>
1175     #endif
1176     #ifdef HAVE_VFORK_H
1177     #include <vfork.h>
1178     #endif
1179     /* On sparc systems, changes by the child to local and incoming
1180     argument registers are propagated back to the parent.
1181     The compiler is told about this with #include <vfork.h>,
1182     but some compilers (e.g. gcc -O) don't grok <vfork.h>.
1183     Test for this by using a static variable whose address
1184     is put into a register that is clobbered by the vfork. */
1185     static
1186     #ifdef __cplusplus
1187     sparc_address_test (int arg)
1188     #else
1189     sparc_address_test (arg) int arg;
1190     #endif
1191     {
1192     static pid_t child;
1193     if (!child) {
1194     child = vfork ();
1195     if (child < 0)
1196     perror ("vfork");
1197     if (!child) {
1198     arg = getpid();
1199     write(-1, "", 0);
1200     _exit (arg);
1201     }
1202     }
1203     }
1204     static int signalled;
1205     static RETSIGTYPE catch (s) int s; { signalled = 1; }
1206     main() {
1207     pid_t parent = getpid ();
1208     pid_t child;
1209    
1210     sparc_address_test ();
1211    
1212     signal (SIGINT, catch);
1213    
1214     child = vfork ();
1215    
1216     if (child == 0) {
1217     /* Here is another test for sparc vfork register problems.
1218     This test uses lots of local variables, at least
1219     as many local variables as main has allocated so far
1220     including compiler temporaries. 4 locals are enough for
1221     gcc 1.40.3 on a sparc, but we use 8 to be safe.
1222     A buggy compiler should reuse the register of parent
1223     for one of the local variables, since it will think that
1224     parent can't possibly be used any more in this routine.
1225     Assigning to the local variable will thus munge parent
1226     in the parent process. */
1227     pid_t
1228     p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
1229     p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
1230     /* Convince the compiler that p..p7 are live; otherwise, it might
1231     use the same hardware register for all 8 local variables. */
1232     if (p != p1 || p != p2 || p != p3 || p != p4
1233     || p != p5 || p != p6 || p != p7)
1234     _exit(1);
1235    
1236     /* On some systems (e.g. SunOS 5.2), if the parent is catching
1237     a signal, the child ignores the signal before execing,
1238     and the parent later receives that signal, the parent dumps core.
1239     Test for this by ignoring SIGINT in the child. */
1240     signal (SIGINT, SIG_IGN);
1241    
1242     /* On some systems (e.g. IRIX 3.3),
1243     vfork doesn't separate parent from child file descriptors.
1244     If the child closes a descriptor before it execs or exits,
1245     this munges the parent's descriptor as well.
1246     Test for this by closing stdout in the child. */
1247     _exit(close(fileno(stdout)) != 0);
1248     } else {
1249     int status;
1250     struct stat st;
1251    
1252     while (wait(&status) != child)
1253     ;
1254     exit(
1255     /* Was there some problem with vforking? */
1256     child < 0
1257    
1258     /* Did the child fail? (This shouldn't happen.) */
1259     || status
1260    
1261     /* Did the vfork/compiler bug occur? */
1262     || parent != getpid()
1263    
1264     /* Did the signal handling bug occur? */
1265     || kill(parent, SIGINT) != 0
1266     || signalled != 1
1267    
1268     /* Did the file descriptor bug occur? */
1269     || fstat(fileno(stdout), &st) != 0
1270     );
1271     }
1272     }
1273     EOF
1274     eval $ac_link
1275     if test -s conftest && (./conftest; exit) 2>/dev/null; then
1276     ac_cv_func_vfork=yes
1277     else
1278     ac_cv_func_vfork=no
1279     fi
1280     fi
1281     rm -fr conftest*
1282     fi
1283     echo "$ac_t""$ac_cv_func_vfork" 1>&4
1284     if test $ac_cv_func_vfork = no; then
1285     cat >> confdefs.h <<\EOF
1286     #define vfork fork
1287     EOF
1288    
1289     fi
1290    
1291     for ac_func in select
1292     do
1293     echo $ac_n "checking for $ac_func""... $ac_c" 1>&4
1294     if eval "test \"`echo '${'ac_cv_func_$ac_func'+set}'`\" = set"; then
1295     echo $ac_n "(cached) $ac_c" 1>&4
1296     else
1297     cat > conftest.$ac_ext <<EOF
1298     #line 1299 "configure"
1299     #include "confdefs.h"
1300     #include <ctype.h> /* Arbitrary system header to define __stub macros. */
1301     /* Override any gcc2 internal prototype to avoid an error. */
1302     char $ac_func();
1303    
1304     int main() { return 0; }
1305     int t() {
1306    
1307     /* The GNU C library defines this for functions which it implements
1308     to always fail with ENOSYS. Some functions are actually named
1309     something starting with __ and the normal name is an alias. */
1310     #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1311     choke me
1312     #else
1313     $ac_func();
1314     #endif
1315    
1316     ; return 0; }
1317     EOF
1318     if eval $ac_link; then
1319     rm -rf conftest*
1320     eval "ac_cv_func_$ac_func=yes"
1321     else
1322     rm -rf conftest*
1323     eval "ac_cv_func_$ac_func=no"
1324     fi
1325     rm -f conftest*
1326    
1327     fi
1328     if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1329     echo "$ac_t""yes" 1>&4
1330     ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'`
1331     cat >> confdefs.h <<EOF
1332     #define $ac_tr_func 1
1333     EOF
1334    
1335     else
1336     echo "$ac_t""no" 1>&4
1337     fi
1338     done
1339    
1340    
1341     echo $ac_n "checking for sys_siglist""... $ac_c" 1>&4
1342     if eval "test \"`echo '${'socketxx_cv_siglist'+set}'`\" = set"; then
1343     echo $ac_n "(cached) $ac_c" 1>&4
1344     else
1345    
1346     cat > conftest.$ac_ext <<EOF
1347     #line 1348 "configure"
1348     #include "confdefs.h"
1349    
1350     # include <unistd.h>
1351     # include <sys/signal.h>
1352    
1353     int main() { return 0; }
1354     int t() {
1355    
1356     #ifndef _sys_siglist
1357     extern char* _sys_siglist[];
1358     #endif
1359     puts(*_sys_siglist);
1360    
1361     ; return 0; }
1362     EOF
1363     if eval $ac_link; then
1364     rm -rf conftest*
1365     socketxx_cv_siglist=_sys_siglist
1366     else
1367     rm -rf conftest*
1368     socketxx_cv_siglist=sys_siglist
1369     fi
1370     rm -f conftest*
1371    
1372     fi
1373    
1374    
1375     cat >> confdefs.h <<EOF
1376     #define SYS_SIGLIST $socketxx_cv_siglist
1377     EOF
1378    
1379     echo "$ac_t""$socketxx_cv_siglist" 1>&4
1380    
1381     echo $ac_n "checking if extern \"C\" wrappers are needed""... $ac_c" 1>&4
1382     if eval "test \"`echo '${'bz_cv_cplusplus_needexternCwrapper'+set}'`\" = set"; then
1383     echo $ac_n "(cached) $ac_c" 1>&4
1384     else
1385    
1386    
1387     ac_ext=C
1388     # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1389     ac_cpp='$CXXCPP $CPPFLAGS'
1390     ac_compile='${CXX-g++} $CXXFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
1391     ac_link='${CXX-g++} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
1392    
1393     cat > conftest.$ac_ext <<EOF
1394     #line 1395 "configure"
1395     #include "confdefs.h"
1396    
1397     # include <string.h>
1398     # include <stdio.h>
1399    
1400     int main() { return 0; }
1401     int t() {
1402    
1403     char buf[100];
1404     strcpy(buf, "Hello world\n");
1405    
1406     ; return 0; }
1407     EOF
1408     if eval $ac_link; then
1409     rm -rf conftest*
1410     bz_cv_cplusplus_needexternCwrapper=no
1411     else
1412     rm -rf conftest*
1413     bz_cv_cplusplus_needexternCwrapper=yes
1414     fi
1415     rm -f conftest*
1416    
1417    
1418     fi
1419    
1420     ac_ext=c
1421     # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1422     ac_cpp='$CPP $CPPFLAGS'
1423     ac_compile='${CC-cc} $CFLAGS $CPPFLAGS conftest.$ac_ext -c 1>&5 2>&5'
1424     ac_link='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext -o conftest $LIBS 1>&5 2>&5'
1425    
1426    
1427     if test $bz_cv_cplusplus_needexternCwrapper = no; then
1428     cat >> confdefs.h <<\EOF
1429     #define EXTERN_C_BEGIN
1430     EOF
1431    
1432     cat >> confdefs.h <<\EOF
1433     #define EXTERN_C_END
1434     EOF
1435    
1436     else
1437     cat >> confdefs.h <<\EOF
1438     #define EXTERN_C_BEGIN extern "C" {
1439     EOF
1440    
1441     cat >> confdefs.h <<\EOF
1442     #define EXTERN_C_END }
1443     EOF
1444    
1445     fi
1446     echo "$ac_t""$bz_cv_cplusplus_needexternCwrapper" 1>&4
1447    
1448    
1449     trap '' 1 2 15
1450     if test -w $cache_file; then
1451     echo "updating cache $cache_file"
1452     cat > $cache_file <<\EOF
1453     # This file is a shell script that caches the results of configure
1454     # tests run on this system so they can be shared between configure
1455     # scripts and configure runs. It is not useful on other systems.
1456     # If it contains results you don't want to keep, you may remove or edit it.
1457     #
1458     # By default, configure uses ./config.cache as the cache file,
1459     # creating it if it does not exist already. You can give configure
1460     # the --cache-file=FILE option to use a different cache file; that is
1461     # what configure does when it calls configure scripts in
1462     # subdirectories, so they share the cache.
1463     # Giving --cache-file=/dev/null disables caching, for debugging configure.
1464     # config.status only pays attention to the cache file if you give it the
1465     # --recheck option to rerun configure.
1466     #
1467     EOF
1468     # Ultrix sh set writes to stderr and can't be redirected directly.
1469     (set) 2>&1 |
1470     sed -n "s/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/: \${\1='\2'}/p" \
1471     >> $cache_file
1472     else
1473     echo "not updating unwritable cache $cache_file"
1474     fi
1475    
1476     trap 'rm -fr conftest* confdefs* core $ac_clean_files; exit 1' 1 2 15
1477    
1478     test "x$prefix" = xNONE && prefix=$ac_default_prefix
1479     # Let make expand exec_prefix.
1480     test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1481    
1482     # Any assignment to VPATH causes Sun make to only execute
1483     # the first set of double-colon rules, so remove it if not needed.
1484     # If there is a colon in the path, we need to keep it.
1485     if test "x$srcdir" = x.; then
1486     ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
1487     fi
1488    
1489     trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1490    
1491     DEFS=-DHAVE_CONFIG_H
1492    
1493     # Without the "./", some shells look in PATH for config.status.
1494     : ${CONFIG_STATUS=./config.status}
1495    
1496     echo creating $CONFIG_STATUS
1497     rm -f $CONFIG_STATUS
1498     cat > $CONFIG_STATUS <<EOF
1499     #!/bin/sh
1500     # Generated automatically by configure.
1501     # Run this file to recreate the current configuration.
1502     # This directory was configured as follows,
1503     # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1504     #
1505     # $0 $ac_configure_args
1506     #
1507     # Compiler output produced by configure, useful for debugging
1508     # configure, is in ./config.log if it exists.
1509    
1510     ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1511     for ac_option
1512     do
1513     case "\$ac_option" in
1514     -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1515     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1516     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1517     -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1518     echo "$CONFIG_STATUS generated by autoconf version 2.1"
1519     exit 0 ;;
1520     -help | --help | --hel | --he | --h)
1521     echo "\$ac_cs_usage"; exit 0 ;;
1522     *) echo "\$ac_cs_usage"; exit 1 ;;
1523     esac
1524     done
1525    
1526     ac_given_srcdir=$srcdir
1527    
1528     trap 'rm -fr Makefile test/Makefile config.h conftest*; exit 1' 1 2 15
1529    
1530     # Protect against being on the right side of a sed subst in config.status.
1531     sed 's/%@/@@/; s/@%/@@/; s/%g$/@g/; /@g$/s/[\\\\&%]/\\\\&/g;
1532     s/@@/%@/; s/@@/@%/; s/@g$/%g/' > conftest.subs <<\CEOF
1533     $ac_vpsub
1534     $extrasub
1535     s%@CFLAGS@%$CFLAGS%g
1536     s%@CPPFLAGS@%$CPPFLAGS%g
1537     s%@CXXFLAGS@%$CXXFLAGS%g
1538     s%@DEFS@%$DEFS%g
1539     s%@LDFLAGS@%$LDFLAGS%g
1540     s%@LIBS@%$LIBS%g
1541     s%@exec_prefix@%$exec_prefix%g
1542     s%@prefix@%$prefix%g
1543     s%@program_transform_name@%$program_transform_name%g
1544     s%@SET_MAKE@%$SET_MAKE%g
1545     s%@CC@%$CC%g
1546     s%@CXX@%$CXX%g
1547     s%@RANLIB@%$RANLIB%g
1548     s%@MAKEDEPEND@%$MAKEDEPEND%g
1549     s%@CPP@%$CPP%g
1550     s%@CXXCPP@%$CXXCPP%g
1551     s%@NETWORK_LIBS@%$NETWORK_LIBS%g
1552    
1553     CEOF
1554     EOF
1555     cat >> $CONFIG_STATUS <<EOF
1556    
1557     CONFIG_FILES=\${CONFIG_FILES-"Makefile test/Makefile"}
1558     EOF
1559     cat >> $CONFIG_STATUS <<\EOF
1560     for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1561     # Support "outfile[:infile]", defaulting infile="outfile.in".
1562     case "$ac_file" in
1563     *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1564     ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1565     *) ac_file_in="${ac_file}.in" ;;
1566     esac
1567    
1568     # Adjust relative srcdir, etc. for subdirectories.
1569    
1570     # Remove last slash and all that follows it. Not all systems have dirname.
1571     ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1572     if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1573     # The file is in a subdirectory.
1574     test ! -d "$ac_dir" && mkdir "$ac_dir"
1575     ac_dir_suffix="/$ac_dir"
1576     # A "../" for each directory in $ac_dir_suffix.
1577     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1578     else
1579     ac_dir_suffix= ac_dots=
1580     fi
1581    
1582     case "$ac_given_srcdir" in
1583     .) srcdir=.
1584     if test -z "$ac_dots"; then top_srcdir=.
1585     else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1586     /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1587     *) # Relative path.
1588     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1589     top_srcdir="$ac_dots$ac_given_srcdir" ;;
1590     esac
1591    
1592     echo creating "$ac_file"
1593     rm -f "$ac_file"
1594     configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1595     case "$ac_file" in
1596     *Makefile*) ac_comsub="1i\\
1597     # $configure_input" ;;
1598     *) ac_comsub= ;;
1599     esac
1600     sed -e "$ac_comsub
1601     s%@configure_input@%$configure_input%g
1602     s%@srcdir@%$srcdir%g
1603     s%@top_srcdir@%$top_srcdir%g
1604     " -f conftest.subs $ac_given_srcdir/$ac_file_in > $ac_file
1605     fi; done
1606     rm -f conftest.subs
1607    
1608     # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1609     # NAME is the cpp macro being defined and VALUE is the value it is being given.
1610     #
1611     # ac_d sets the value in "#define NAME VALUE" lines.
1612     ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
1613     ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
1614     ac_dC='\3'
1615     ac_dD='%g'
1616     # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1617     ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1618     ac_uB='\([ ]\)%\1#\2define\3'
1619     ac_uC=' '
1620     ac_uD='\4%g'
1621     # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1622     ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
1623     ac_eB='$%\1#\2define\3'
1624     ac_eC=' '
1625     ac_eD='%g'
1626    
1627     CONFIG_HEADERS=${CONFIG_HEADERS-"config.h"}
1628     for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1629     # Support "outfile[:infile]", defaulting infile="outfile.in".
1630     case "$ac_file" in
1631     *:*) ac_file_in=`echo "$ac_file"|sed 's%.*:%%'`
1632     ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1633     *) ac_file_in="${ac_file}.in" ;;
1634     esac
1635    
1636     echo creating $ac_file
1637    
1638     rm -f conftest.frag conftest.in conftest.out
1639     cp $ac_given_srcdir/$ac_file_in conftest.in
1640    
1641     EOF
1642    
1643     # Transform confdefs.h into a sed script conftest.vals that substitutes
1644     # the proper values into config.h.in to produce config.h. And first:
1645     # Protect against being on the right side of a sed subst in config.status.
1646     # Protect against being in an unquoted here document in config.status.
1647     rm -f conftest.vals
1648     cat > conftest.hdr <<\EOF
1649     s/[\\&%]/\\&/g
1650     s%[\\$`]%\\&%g
1651     s%#define \([A-Za-z_][A-Za-z0-9_]*\) \(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
1652     s%ac_d%ac_u%gp
1653     s%ac_u%ac_e%gp
1654     EOF
1655     sed -n -f conftest.hdr confdefs.h > conftest.vals
1656     rm -f conftest.hdr
1657    
1658     # This sed command replaces #undef with comments. This is necessary, for
1659     # example, in the case of _POSIX_SOURCE, which is predefined and required
1660     # on some systems where configure will not decide to define it.
1661     cat >> conftest.vals <<\EOF
1662     s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1663     EOF
1664    
1665     # Break up conftest.vals because some shells have a limit on
1666     # the size of here documents, and old seds have small limits too.
1667     # Maximum number of lines to put in a single here document.
1668     ac_max_here_lines=12
1669    
1670     rm -f conftest.tail
1671     while :
1672     do
1673     ac_lines=`grep -c . conftest.vals`
1674     # grep -c gives empty output for an empty file on some AIX systems.
1675     if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1676     # Write a limited-size here document to conftest.frag.
1677     echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1678     sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1679     echo 'CEOF
1680     sed -f conftest.frag conftest.in > conftest.out
1681     rm -f conftest.in
1682     mv conftest.out conftest.in
1683     ' >> $CONFIG_STATUS
1684     sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1685     rm -f conftest.vals
1686     mv conftest.tail conftest.vals
1687     done
1688     rm -f conftest.vals
1689    
1690     cat >> $CONFIG_STATUS <<\EOF
1691     rm -f conftest.frag conftest.h
1692     echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
1693     cat conftest.in >> conftest.h
1694     rm -f conftest.in
1695     if cmp -s $ac_file conftest.h 2>/dev/null; then
1696     echo "$ac_file is unchanged"
1697     rm -f conftest.h
1698     else
1699     rm -f $ac_file
1700     mv conftest.h $ac_file
1701     fi
1702     fi; done
1703    
1704    
1705    
1706     exit 0
1707     EOF
1708     chmod +x $CONFIG_STATUS
1709     rm -fr confdefs* $ac_clean_files
1710     test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS
1711