blob: 4a0b5caa201b4f38ab997f138ab17cfafd09a0b9 [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Skip Montanarod8d39a02003-07-10 20:44:10 +00002# From configure.in Revision: 1.423 .
Guido van Rossum627b2d71993-12-24 10:39:16 +00003# Guess values for system-dependent variables and create Makefiles.
Skip Montanarod8d39a02003-07-10 20:44:10 +00004# Generated by GNU Autoconf 2.57 for python 2.3.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005#
Martin v. Löwis11437992002-04-12 09:54:03 +00006# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
7# Free Software Foundation, Inc.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00008# This configure script is free software; the Free Software Foundation
9# gives unlimited permission to copy, distribute and modify it.
Martin v. Löwis11437992002-04-12 09:54:03 +000010## --------------------- ##
11## M4sh Initialization. ##
12## --------------------- ##
13
14# Be Bourne compatible
15if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16 emulate sh
17 NULLCMD=:
Skip Montanarod8d39a02003-07-10 20:44:10 +000018 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
19 # is contrary to our usage. Disable this feature.
20 alias -g '${1+"$@"}'='"$@"'
Martin v. Löwis11437992002-04-12 09:54:03 +000021elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22 set -o posix
23fi
24
Martin v. Löwis11437992002-04-12 09:54:03 +000025# Support unset when possible.
26if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
27 as_unset=unset
28else
29 as_unset=false
30fi
31
Skip Montanarod8d39a02003-07-10 20:44:10 +000032
33# Work around bugs in pre-3.0 UWIN ksh.
34$as_unset ENV MAIL MAILPATH
35PS1='$ '
36PS2='> '
37PS4='+ '
38
39# NLS nuisances.
40for as_var in \
41 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
42 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
43 LC_TELEPHONE LC_TIME
44do
45 if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
46 eval $as_var=C; export $as_var
47 else
48 $as_unset $as_var
49 fi
50done
51
52# Required to use basename.
53if expr a : '\(a\)' >/dev/null 2>&1; then
54 as_expr=expr
55else
56 as_expr=false
57fi
58
59if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
60 as_basename=basename
61else
62 as_basename=false
63fi
Martin v. Löwis11437992002-04-12 09:54:03 +000064
65
66# Name of the executable.
Skip Montanarod8d39a02003-07-10 20:44:10 +000067as_me=`$as_basename "$0" ||
Martin v. Löwis11437992002-04-12 09:54:03 +000068$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
69 X"$0" : 'X\(//\)$' \| \
70 X"$0" : 'X\(/\)$' \| \
71 . : '\(.\)' 2>/dev/null ||
72echo X/"$0" |
73 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
74 /^X\/\(\/\/\)$/{ s//\1/; q; }
75 /^X\/\(\/\).*/{ s//\1/; q; }
76 s/.*/./; q'`
77
Skip Montanarod8d39a02003-07-10 20:44:10 +000078
Martin v. Löwis11437992002-04-12 09:54:03 +000079# PATH needs CR, and LINENO needs CR and PATH.
80# Avoid depending upon Character Ranges.
81as_cr_letters='abcdefghijklmnopqrstuvwxyz'
82as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
83as_cr_Letters=$as_cr_letters$as_cr_LETTERS
84as_cr_digits='0123456789'
85as_cr_alnum=$as_cr_Letters$as_cr_digits
86
87# The user is always right.
88if test "${PATH_SEPARATOR+set}" != set; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000089 echo "#! /bin/sh" >conf$$.sh
90 echo "exit 0" >>conf$$.sh
91 chmod +x conf$$.sh
92 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +000093 PATH_SEPARATOR=';'
94 else
95 PATH_SEPARATOR=:
96 fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000097 rm -f conf$$.sh
Martin v. Löwis11437992002-04-12 09:54:03 +000098fi
99
100
101 as_lineno_1=$LINENO
102 as_lineno_2=$LINENO
103 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
104 test "x$as_lineno_1" != "x$as_lineno_2" &&
105 test "x$as_lineno_3" = "x$as_lineno_2" || {
106 # Find who we are. Look in the path if we contain no path at all
107 # relative or not.
108 case $0 in
109 *[\\/]* ) as_myself=$0 ;;
110 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
111for as_dir in $PATH
112do
113 IFS=$as_save_IFS
114 test -z "$as_dir" && as_dir=.
115 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
116done
117
118 ;;
119 esac
120 # We did not find ourselves, most probably we were run as `sh COMMAND'
121 # in which case we are not to be found in the path.
122 if test "x$as_myself" = x; then
123 as_myself=$0
124 fi
125 if test ! -f "$as_myself"; then
126 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
127 { (exit 1); exit 1; }; }
128 fi
129 case $CONFIG_SHELL in
130 '')
131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
132for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
133do
134 IFS=$as_save_IFS
135 test -z "$as_dir" && as_dir=.
136 for as_base in sh bash ksh sh5; do
137 case $as_dir in
138 /*)
139 if ("$as_dir/$as_base" -c '
140 as_lineno_1=$LINENO
141 as_lineno_2=$LINENO
142 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
143 test "x$as_lineno_1" != "x$as_lineno_2" &&
144 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
Skip Montanarod8d39a02003-07-10 20:44:10 +0000145 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
146 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
Martin v. Löwis11437992002-04-12 09:54:03 +0000147 CONFIG_SHELL=$as_dir/$as_base
148 export CONFIG_SHELL
149 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
150 fi;;
151 esac
152 done
153done
154;;
155 esac
156
157 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
158 # uniformly replaced by the line number. The first 'sed' inserts a
159 # line-number line before each line; the second 'sed' does the real
160 # work. The second script uses 'N' to pair each line-number line
161 # with the numbered line, and appends trailing '-' during
162 # substitution so that $LINENO is not a special case at line end.
163 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
164 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
165 sed '=' <$as_myself |
166 sed '
167 N
168 s,$,-,
169 : loop
170 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
171 t loop
172 s,-$,,
173 s,^['$as_cr_digits']*\n,,
174 ' >$as_me.lineno &&
175 chmod +x $as_me.lineno ||
176 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
177 { (exit 1); exit 1; }; }
178
179 # Don't try to exec as it changes $[0], causing all sort of problems
180 # (the dirname of $[0] is not the place where we might find the
181 # original and so on. Autoconf is especially sensible to this).
182 . ./$as_me.lineno
183 # Exit status is that of the last command.
184 exit
185}
186
187
188case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
189 *c*,-n*) ECHO_N= ECHO_C='
190' ECHO_T=' ' ;;
191 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
192 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
193esac
194
195if expr a : '\(a\)' >/dev/null 2>&1; then
196 as_expr=expr
197else
198 as_expr=false
199fi
200
201rm -f conf$$ conf$$.exe conf$$.file
202echo >conf$$.file
203if ln -s conf$$.file conf$$ 2>/dev/null; then
204 # We could just check for DJGPP; but this test a) works b) is more generic
205 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
206 if test -f conf$$.exe; then
207 # Don't use ln at all; we don't have any links
208 as_ln_s='cp -p'
209 else
210 as_ln_s='ln -s'
211 fi
212elif ln conf$$.file conf$$ 2>/dev/null; then
213 as_ln_s=ln
214else
215 as_ln_s='cp -p'
216fi
217rm -f conf$$ conf$$.exe conf$$.file
218
Skip Montanarod8d39a02003-07-10 20:44:10 +0000219if mkdir -p . 2>/dev/null; then
220 as_mkdir_p=:
221else
222 as_mkdir_p=false
223fi
224
Martin v. Löwis11437992002-04-12 09:54:03 +0000225as_executable_p="test -f"
226
227# Sed expression to map a string onto a valid CPP name.
228as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
229
230# Sed expression to map a string onto a valid variable name.
231as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
232
233
234# IFS
235# We need space, tab and new line, in precisely that order.
236as_nl='
237'
238IFS=" $as_nl"
239
240# CDPATH.
Skip Montanarod8d39a02003-07-10 20:44:10 +0000241$as_unset CDPATH
Martin v. Löwis11437992002-04-12 09:54:03 +0000242
243
244# Name of the host.
245# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
246# so uname gets run too.
247ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
248
249exec 6>&1
250
251#
252# Initializations.
253#
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000254ac_default_prefix=/usr/local
Skip Montanarod8d39a02003-07-10 20:44:10 +0000255ac_config_libobj_dir=.
Martin v. Löwis11437992002-04-12 09:54:03 +0000256cross_compiling=no
257subdirs=
258MFLAGS=
259MAKEFLAGS=
260SHELL=${CONFIG_SHELL-/bin/sh}
261
262# Maximum number of lines to put in a shell here document.
263# This variable seems obsolete. It should probably be removed, and
264# only ac_max_sed_lines should be used.
265: ${ac_max_here_lines=38}
266
267# Identity of this package.
Martin v. Löwis88afe662002-10-26 13:47:44 +0000268PACKAGE_NAME='python'
269PACKAGE_TARNAME='python'
270PACKAGE_VERSION='2.3'
271PACKAGE_STRING='python 2.3'
272PACKAGE_BUGREPORT=''
Martin v. Löwis11437992002-04-12 09:54:03 +0000273
274ac_unique_file="Include/object.h"
275# Factoring default headers for most tests.
276ac_includes_default="\
277#include <stdio.h>
278#if HAVE_SYS_TYPES_H
279# include <sys/types.h>
280#endif
281#if HAVE_SYS_STAT_H
282# include <sys/stat.h>
283#endif
284#if STDC_HEADERS
285# include <stdlib.h>
286# include <stddef.h>
287#else
288# if HAVE_STDLIB_H
289# include <stdlib.h>
290# endif
291#endif
292#if HAVE_STRING_H
293# if !STDC_HEADERS && HAVE_MEMORY_H
294# include <memory.h>
295# endif
296# include <string.h>
297#endif
298#if HAVE_STRINGS_H
299# include <strings.h>
300#endif
301#if HAVE_INTTYPES_H
302# include <inttypes.h>
303#else
304# if HAVE_STDINT_H
305# include <stdint.h>
306# endif
307#endif
308#if HAVE_UNISTD_H
309# include <unistd.h>
310#endif"
311
Skip Montanarod8d39a02003-07-10 20:44:10 +0000312ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS VERSION SOVERSION CONFIG_ARGS PYTHONFRAMEWORK PYTHONFRAMEWORKDIR PYTHONFRAMEWORKPREFIX PYTHONFRAMEWORKINSTALLDIR MACHDEP SGI_ABI EXTRAPLATDIR EXTRAMACHDEPPATH CXX MAINOBJ EXEEXT CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC OBJEXT CPP EGREP BUILDEXEEXT LIBRARY LDLIBRARY DLLLIBRARY BLDLIBRARY LDLIBRARYDIR INSTSONAME RUNSHARED LINKCC RANLIB ac_ct_RANLIB AR INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LN OPT BASECFLAGS LIBTOOL_CRUFT SO LDSHARED BLDSHARED CCSHARED LINKFORSHARED CFLAGSFORSHARED SHLIBS USE_SIGNAL_MODULE SIGNAL_OBJS USE_THREAD_MODULE LDLAST THREADOBJ DLINCLDIR DYNLOADFILE MACHDEP_OBJS TRUE LIBOBJS HAVE_GETHOSTBYNAME_R_6_ARG HAVE_GETHOSTBYNAME_R_5_ARG HAVE_GETHOSTBYNAME_R_3_ARG HAVE_GETHOSTBYNAME_R HAVE_GETHOSTBYNAME LIBM LIBC UNICODE_OBJS THREADHEADERS SRCDIRS LTLIBOBJS'
313ac_subst_files=''
Guido van Rossum627b2d71993-12-24 10:39:16 +0000314
Guido van Rossum7f43da71994-08-01 12:15:30 +0000315# Initialize some variables set by options.
Martin v. Löwis11437992002-04-12 09:54:03 +0000316ac_init_help=
317ac_init_version=false
Guido van Rossum7f43da71994-08-01 12:15:30 +0000318# The variables have the same names as the options, with
319# dashes changed to underlines.
Martin v. Löwis11437992002-04-12 09:54:03 +0000320cache_file=/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000321exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +0000322no_create=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000323no_recursion=
324prefix=NONE
325program_prefix=NONE
326program_suffix=NONE
327program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +0000328silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000329site=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000330srcdir=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000331verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000332x_includes=NONE
333x_libraries=NONE
Martin v. Löwis11437992002-04-12 09:54:03 +0000334
335# Installation directory options.
336# These are left unexpanded so users can "make install exec_prefix=/foo"
337# and all the variables that are supposed to be based on exec_prefix
338# by default will actually change.
339# Use braces instead of parens because sh, perl, etc. also accept them.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000340bindir='${exec_prefix}/bin'
341sbindir='${exec_prefix}/sbin'
342libexecdir='${exec_prefix}/libexec'
343datadir='${prefix}/share'
344sysconfdir='${prefix}/etc'
345sharedstatedir='${prefix}/com'
346localstatedir='${prefix}/var'
347libdir='${exec_prefix}/lib'
348includedir='${prefix}/include'
349oldincludedir='/usr/include'
350infodir='${prefix}/info'
351mandir='${prefix}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000352
Guido van Rossum7f43da71994-08-01 12:15:30 +0000353ac_prev=
354for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +0000355do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000356 # If the previous option needs an argument, assign it.
357 if test -n "$ac_prev"; then
358 eval "$ac_prev=\$ac_option"
359 ac_prev=
360 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +0000361 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000362
Martin v. Löwis11437992002-04-12 09:54:03 +0000363 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000364
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000365 # Accept the important Cygnus configure options, so we can diagnose typos.
366
Martin v. Löwis11437992002-04-12 09:54:03 +0000367 case $ac_option in
Guido van Rossum7f43da71994-08-01 12:15:30 +0000368
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000369 -bindir | --bindir | --bindi | --bind | --bin | --bi)
370 ac_prev=bindir ;;
371 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000372 bindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000373
374 -build | --build | --buil | --bui | --bu)
Martin v. Löwis11437992002-04-12 09:54:03 +0000375 ac_prev=build_alias ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000376 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000377 build_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000378
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000379 -cache-file | --cache-file | --cache-fil | --cache-fi \
380 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
381 ac_prev=cache_file ;;
382 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
383 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000384 cache_file=$ac_optarg ;;
385
386 --config-cache | -C)
387 cache_file=config.cache ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000388
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000389 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
390 ac_prev=datadir ;;
391 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
392 | --da=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000393 datadir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000394
Guido van Rossum7f43da71994-08-01 12:15:30 +0000395 -disable-* | --disable-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000396 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000397 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000398 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
399 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
400 { (exit 1); exit 1; }; }
401 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
402 eval "enable_$ac_feature=no" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000403
404 -enable-* | --enable-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000405 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000406 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000407 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
408 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
409 { (exit 1); exit 1; }; }
410 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
411 case $ac_option in
412 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000413 *) ac_optarg=yes ;;
414 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000415 eval "enable_$ac_feature='$ac_optarg'" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000416
Guido van Rossum7f43da71994-08-01 12:15:30 +0000417 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
418 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
419 | --exec | --exe | --ex)
420 ac_prev=exec_prefix ;;
421 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
422 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
423 | --exec=* | --exe=* | --ex=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000424 exec_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000425
426 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000427 # Obsolete; use --with-gas.
428 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000429
Martin v. Löwis11437992002-04-12 09:54:03 +0000430 -help | --help | --hel | --he | -h)
431 ac_init_help=long ;;
432 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
433 ac_init_help=recursive ;;
434 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
435 ac_init_help=short ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000436
437 -host | --host | --hos | --ho)
Martin v. Löwis11437992002-04-12 09:54:03 +0000438 ac_prev=host_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000439 -host=* | --host=* | --hos=* | --ho=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000440 host_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000441
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000442 -includedir | --includedir | --includedi | --included | --include \
443 | --includ | --inclu | --incl | --inc)
444 ac_prev=includedir ;;
445 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
446 | --includ=* | --inclu=* | --incl=* | --inc=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000447 includedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000448
449 -infodir | --infodir | --infodi | --infod | --info | --inf)
450 ac_prev=infodir ;;
451 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000452 infodir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000453
454 -libdir | --libdir | --libdi | --libd)
455 ac_prev=libdir ;;
456 -libdir=* | --libdir=* | --libdi=* | --libd=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000457 libdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000458
459 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
460 | --libexe | --libex | --libe)
461 ac_prev=libexecdir ;;
462 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
463 | --libexe=* | --libex=* | --libe=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000464 libexecdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000465
466 -localstatedir | --localstatedir | --localstatedi | --localstated \
467 | --localstate | --localstat | --localsta | --localst \
468 | --locals | --local | --loca | --loc | --lo)
469 ac_prev=localstatedir ;;
470 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
471 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
472 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000473 localstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000474
475 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
476 ac_prev=mandir ;;
477 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000478 mandir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000479
Guido van Rossum7f43da71994-08-01 12:15:30 +0000480 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000481 # Obsolete; use --without-fp.
482 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000483
484 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
Martin v. Löwis11437992002-04-12 09:54:03 +0000485 | --no-cr | --no-c | -n)
Guido van Rossum7f43da71994-08-01 12:15:30 +0000486 no_create=yes ;;
487
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000488 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
489 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
490 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000491
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000492 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
493 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
494 | --oldin | --oldi | --old | --ol | --o)
495 ac_prev=oldincludedir ;;
496 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
497 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
498 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000499 oldincludedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000500
Guido van Rossum7f43da71994-08-01 12:15:30 +0000501 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
502 ac_prev=prefix ;;
503 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000504 prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000505
506 -program-prefix | --program-prefix | --program-prefi | --program-pref \
507 | --program-pre | --program-pr | --program-p)
508 ac_prev=program_prefix ;;
509 -program-prefix=* | --program-prefix=* | --program-prefi=* \
510 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000511 program_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000512
513 -program-suffix | --program-suffix | --program-suffi | --program-suff \
514 | --program-suf | --program-su | --program-s)
515 ac_prev=program_suffix ;;
516 -program-suffix=* | --program-suffix=* | --program-suffi=* \
517 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000518 program_suffix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000519
520 -program-transform-name | --program-transform-name \
521 | --program-transform-nam | --program-transform-na \
522 | --program-transform-n | --program-transform- \
523 | --program-transform | --program-transfor \
524 | --program-transfo | --program-transf \
525 | --program-trans | --program-tran \
526 | --progr-tra | --program-tr | --program-t)
527 ac_prev=program_transform_name ;;
528 -program-transform-name=* | --program-transform-name=* \
529 | --program-transform-nam=* | --program-transform-na=* \
530 | --program-transform-n=* | --program-transform-=* \
531 | --program-transform=* | --program-transfor=* \
532 | --program-transfo=* | --program-transf=* \
533 | --program-trans=* | --program-tran=* \
534 | --progr-tra=* | --program-tr=* | --program-t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000535 program_transform_name=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000536
537 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
538 | -silent | --silent | --silen | --sile | --sil)
539 silent=yes ;;
540
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000541 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
542 ac_prev=sbindir ;;
543 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
544 | --sbi=* | --sb=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000545 sbindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000546
547 -sharedstatedir | --sharedstatedir | --sharedstatedi \
548 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
549 | --sharedst | --shareds | --shared | --share | --shar \
550 | --sha | --sh)
551 ac_prev=sharedstatedir ;;
552 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
553 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
554 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
555 | --sha=* | --sh=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000556 sharedstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000557
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000558 -site | --site | --sit)
559 ac_prev=site ;;
560 -site=* | --site=* | --sit=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000561 site=$ac_optarg ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000562
Guido van Rossum7f43da71994-08-01 12:15:30 +0000563 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
564 ac_prev=srcdir ;;
565 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000566 srcdir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000567
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000568 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
569 | --syscon | --sysco | --sysc | --sys | --sy)
570 ac_prev=sysconfdir ;;
571 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
572 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000573 sysconfdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000574
Guido van Rossum7f43da71994-08-01 12:15:30 +0000575 -target | --target | --targe | --targ | --tar | --ta | --t)
Martin v. Löwis11437992002-04-12 09:54:03 +0000576 ac_prev=target_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000577 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000578 target_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000579
580 -v | -verbose | --verbose | --verbos | --verbo | --verb)
581 verbose=yes ;;
582
Martin v. Löwis11437992002-04-12 09:54:03 +0000583 -version | --version | --versio | --versi | --vers | -V)
584 ac_init_version=: ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000585
586 -with-* | --with-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000587 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000588 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000589 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
590 { echo "$as_me: error: invalid package name: $ac_package" >&2
591 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000592 ac_package=`echo $ac_package| sed 's/-/_/g'`
Martin v. Löwis11437992002-04-12 09:54:03 +0000593 case $ac_option in
594 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000595 *) ac_optarg=yes ;;
596 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000597 eval "with_$ac_package='$ac_optarg'" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000598
599 -without-* | --without-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000600 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000601 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000602 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
603 { echo "$as_me: error: invalid package name: $ac_package" >&2
604 { (exit 1); exit 1; }; }
605 ac_package=`echo $ac_package | sed 's/-/_/g'`
606 eval "with_$ac_package=no" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000607
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000608 --x)
609 # Obsolete; use --with-x.
610 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000611
612 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
613 | --x-incl | --x-inc | --x-in | --x-i)
614 ac_prev=x_includes ;;
615 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
616 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000617 x_includes=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000618
619 -x-libraries | --x-libraries | --x-librarie | --x-librari \
620 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
621 ac_prev=x_libraries ;;
622 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
623 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000624 x_libraries=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000625
Martin v. Löwis11437992002-04-12 09:54:03 +0000626 -*) { echo "$as_me: error: unrecognized option: $ac_option
627Try \`$0 --help' for more information." >&2
628 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000629 ;;
630
Martin v. Löwis11437992002-04-12 09:54:03 +0000631 *=*)
632 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
633 # Reject names that are not valid shell variable names.
634 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
635 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
636 { (exit 1); exit 1; }; }
637 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
638 eval "$ac_envvar='$ac_optarg'"
639 export $ac_envvar ;;
640
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000641 *)
Martin v. Löwis11437992002-04-12 09:54:03 +0000642 # FIXME: should be removed in autoconf 3.0.
643 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
644 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
645 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
646 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
Guido van Rossum7f43da71994-08-01 12:15:30 +0000647 ;;
648
649 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +0000650done
651
Guido van Rossum7f43da71994-08-01 12:15:30 +0000652if test -n "$ac_prev"; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000653 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
654 { echo "$as_me: error: missing argument to $ac_option" >&2
655 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000656fi
657
Martin v. Löwis11437992002-04-12 09:54:03 +0000658# Be sure to have absolute paths.
659for ac_var in exec_prefix prefix
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000660do
Martin v. Löwis11437992002-04-12 09:54:03 +0000661 eval ac_val=$`echo $ac_var`
662 case $ac_val in
663 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
664 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
665 { (exit 1); exit 1; }; };;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000666 esac
667done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000668
Martin v. Löwis11437992002-04-12 09:54:03 +0000669# Be sure to have absolute paths.
670for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
671 localstatedir libdir includedir oldincludedir infodir mandir
672do
673 eval ac_val=$`echo $ac_var`
674 case $ac_val in
675 [\\/$]* | ?:[\\/]* ) ;;
676 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
677 { (exit 1); exit 1; }; };;
678 esac
679done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000680
Martin v. Löwis11437992002-04-12 09:54:03 +0000681# There might be people who depend on the old broken behavior: `$host'
682# used to hold the argument of --host etc.
683# FIXME: To remove some day.
684build=$build_alias
685host=$host_alias
686target=$target_alias
Guido van Rossum627b2d71993-12-24 10:39:16 +0000687
Martin v. Löwis11437992002-04-12 09:54:03 +0000688# FIXME: To remove some day.
689if test "x$host_alias" != x; then
690 if test "x$build_alias" = x; then
691 cross_compiling=maybe
692 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
693 If a cross compiler is detected then cross compile mode will be used." >&2
694 elif test "x$build_alias" != "x$host_alias"; then
695 cross_compiling=yes
696 fi
697fi
698
699ac_tool_prefix=
700test -n "$host_alias" && ac_tool_prefix=$host_alias-
701
702test "$silent" = yes && exec 6>/dev/null
703
Guido van Rossum627b2d71993-12-24 10:39:16 +0000704
705# Find the source files, if location was not specified.
706if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +0000707 ac_srcdir_defaulted=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000708 # Try the directory containing this script, then its parent.
Martin v. Löwis11437992002-04-12 09:54:03 +0000709 ac_confdir=`(dirname "$0") 2>/dev/null ||
710$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
711 X"$0" : 'X\(//\)[^/]' \| \
712 X"$0" : 'X\(//\)$' \| \
713 X"$0" : 'X\(/\)' \| \
714 . : '\(.\)' 2>/dev/null ||
715echo X"$0" |
716 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
717 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
718 /^X\(\/\/\)$/{ s//\1/; q; }
719 /^X\(\/\).*/{ s//\1/; q; }
720 s/.*/./; q'`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000721 srcdir=$ac_confdir
722 if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum627b2d71993-12-24 10:39:16 +0000723 srcdir=..
724 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000725else
726 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +0000727fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000728if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000729 if test "$ac_srcdir_defaulted" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000730 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
731 { (exit 1); exit 1; }; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000732 else
Martin v. Löwis11437992002-04-12 09:54:03 +0000733 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
734 { (exit 1); exit 1; }; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000735 fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000736fi
Skip Montanarod8d39a02003-07-10 20:44:10 +0000737(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
738 { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
739 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +0000740srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
741ac_env_build_alias_set=${build_alias+set}
742ac_env_build_alias_value=$build_alias
743ac_cv_env_build_alias_set=${build_alias+set}
744ac_cv_env_build_alias_value=$build_alias
745ac_env_host_alias_set=${host_alias+set}
746ac_env_host_alias_value=$host_alias
747ac_cv_env_host_alias_set=${host_alias+set}
748ac_cv_env_host_alias_value=$host_alias
749ac_env_target_alias_set=${target_alias+set}
750ac_env_target_alias_value=$target_alias
751ac_cv_env_target_alias_set=${target_alias+set}
752ac_cv_env_target_alias_value=$target_alias
753ac_env_CC_set=${CC+set}
754ac_env_CC_value=$CC
755ac_cv_env_CC_set=${CC+set}
756ac_cv_env_CC_value=$CC
757ac_env_CFLAGS_set=${CFLAGS+set}
758ac_env_CFLAGS_value=$CFLAGS
759ac_cv_env_CFLAGS_set=${CFLAGS+set}
760ac_cv_env_CFLAGS_value=$CFLAGS
761ac_env_LDFLAGS_set=${LDFLAGS+set}
762ac_env_LDFLAGS_value=$LDFLAGS
763ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
764ac_cv_env_LDFLAGS_value=$LDFLAGS
765ac_env_CPPFLAGS_set=${CPPFLAGS+set}
766ac_env_CPPFLAGS_value=$CPPFLAGS
767ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
768ac_cv_env_CPPFLAGS_value=$CPPFLAGS
769ac_env_CPP_set=${CPP+set}
770ac_env_CPP_value=$CPP
771ac_cv_env_CPP_set=${CPP+set}
772ac_cv_env_CPP_value=$CPP
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000773
Martin v. Löwis11437992002-04-12 09:54:03 +0000774#
775# Report the --help message.
776#
777if test "$ac_init_help" = "long"; then
778 # Omit some internal or obsolete options to make the list less imposing.
779 # This message is too long to be a string in the A/UX 3.1 sh.
780 cat <<_ACEOF
Martin v. Löwis88afe662002-10-26 13:47:44 +0000781\`configure' configures python 2.3 to adapt to many kinds of systems.
Martin v. Löwis11437992002-04-12 09:54:03 +0000782
783Usage: $0 [OPTION]... [VAR=VALUE]...
784
785To assign environment variables (e.g., CC, CFLAGS...), specify them as
786VAR=VALUE. See below for descriptions of some of the useful variables.
787
788Defaults for the options are specified in brackets.
789
790Configuration:
791 -h, --help display this help and exit
792 --help=short display options specific to this package
793 --help=recursive display the short help of all the included packages
794 -V, --version display version information and exit
795 -q, --quiet, --silent do not print \`checking...' messages
796 --cache-file=FILE cache test results in FILE [disabled]
797 -C, --config-cache alias for \`--cache-file=config.cache'
798 -n, --no-create do not create output files
799 --srcdir=DIR find the sources in DIR [configure dir or \`..']
800
801_ACEOF
802
803 cat <<_ACEOF
804Installation directories:
805 --prefix=PREFIX install architecture-independent files in PREFIX
806 [$ac_default_prefix]
807 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
808 [PREFIX]
809
810By default, \`make install' will install all the files in
811\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
812an installation prefix other than \`$ac_default_prefix' using \`--prefix',
813for instance \`--prefix=\$HOME'.
814
815For better control, use the options below.
816
817Fine tuning of the installation directories:
818 --bindir=DIR user executables [EPREFIX/bin]
819 --sbindir=DIR system admin executables [EPREFIX/sbin]
820 --libexecdir=DIR program executables [EPREFIX/libexec]
821 --datadir=DIR read-only architecture-independent data [PREFIX/share]
822 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
823 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
824 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
825 --libdir=DIR object code libraries [EPREFIX/lib]
826 --includedir=DIR C header files [PREFIX/include]
827 --oldincludedir=DIR C header files for non-gcc [/usr/include]
828 --infodir=DIR info documentation [PREFIX/info]
829 --mandir=DIR man documentation [PREFIX/man]
830_ACEOF
831
832 cat <<\_ACEOF
833_ACEOF
834fi
835
836if test -n "$ac_init_help"; then
Martin v. Löwis88afe662002-10-26 13:47:44 +0000837 case $ac_init_help in
838 short | recursive ) echo "Configuration of python 2.3:";;
839 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000840 cat <<\_ACEOF
841
842Optional Features:
843 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
844 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
Martin v. Löwis3e2c6322002-10-29 10:07:43 +0000845 --enable-framework[=INSTALLDIR]
846 Build (MacOSX|Darwin) framework
847 --enable-shared disable/enable building shared python library
848 --enable-toolbox-glue disable/enable MacOSX glue code for extensions
849 --enable-ipv6 Enable ipv6 (with ipv4) support
850 --disable-ipv6 Disable ipv6 support
851 --enable-unicode[=ucs[24]]
852 Enable Unicode strings (default is yes)
Martin v. Löwis11437992002-04-12 09:54:03 +0000853
854Optional Packages:
855 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
856 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Martin v. Löwis3e2c6322002-10-29 10:07:43 +0000857 --without-gcc never use gcc
858 --with-cxx=<compiler> enable C++ support
859 --with-suffix=.exe set executable suffix
860 --with-pydebug build with Py_DEBUG defined
861 --with-libs='lib1 ...' link against additional libs
862 --with-signal-module disable/enable signal module
863 --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries
864 --with(out)-threads[=DIRECTORY]
865 disable/enable thread support
866 --with(out)-thread[=DIRECTORY]
867 deprecated; use --with(out)-threads
868 --with-pth use GNU pth threading libraries
869 --with(out)-universal-newlines
870 disable/enable foreign newlines
871 --with(out)-doc-strings disable/enable documentation strings
872 --with(out)-pymalloc disable/enable specialized mallocs
873 --with-wctype-functions use wctype.h functions
874 --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking
875 --with-dl-dld=DL_DIR GNU dynamic linking
876 --with-fpectl enable SIGFPE catching
877 --with-libm=STRING math library
878 --with-libc=STRING C library
Martin v. Löwis11437992002-04-12 09:54:03 +0000879
880Some influential environment variables:
881 CC C compiler command
882 CFLAGS C compiler flags
883 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
884 nonstandard directory <lib dir>
885 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
886 headers in a nonstandard directory <include dir>
887 CPP C preprocessor
888
889Use these variables to override the choices made by `configure' or to help
890it to find libraries and programs with nonstandard names/locations.
891
892_ACEOF
893fi
894
895if test "$ac_init_help" = "recursive"; then
896 # If there are subdirs, report their specific --help.
897 ac_popdir=`pwd`
898 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
899 test -d $ac_dir || continue
900 ac_builddir=.
901
902if test "$ac_dir" != .; then
903 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
904 # A "../" for each directory in $ac_dir_suffix.
905 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
906else
907 ac_dir_suffix= ac_top_builddir=
908fi
909
910case $srcdir in
911 .) # No --srcdir option. We are building in place.
912 ac_srcdir=.
913 if test -z "$ac_top_builddir"; then
914 ac_top_srcdir=.
915 else
916 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
917 fi ;;
918 [\\/]* | ?:[\\/]* ) # Absolute path.
919 ac_srcdir=$srcdir$ac_dir_suffix;
920 ac_top_srcdir=$srcdir ;;
921 *) # Relative path.
922 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
923 ac_top_srcdir=$ac_top_builddir$srcdir ;;
924esac
925# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
926# absolute.
927ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwisd6640d42003-07-06 09:29:52 +0000928ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +0000929ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
930ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
931
932 cd $ac_dir
933 # Check for guested configure; otherwise get Cygnus style configure.
934 if test -f $ac_srcdir/configure.gnu; then
935 echo
936 $SHELL $ac_srcdir/configure.gnu --help=recursive
937 elif test -f $ac_srcdir/configure; then
938 echo
939 $SHELL $ac_srcdir/configure --help=recursive
940 elif test -f $ac_srcdir/configure.ac ||
941 test -f $ac_srcdir/configure.in; then
942 echo
943 $ac_configure --help
944 else
945 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
946 fi
947 cd $ac_popdir
948 done
949fi
950
951test -n "$ac_init_help" && exit 0
952if $ac_init_version; then
953 cat <<\_ACEOF
Martin v. Löwis88afe662002-10-26 13:47:44 +0000954python configure 2.3
Skip Montanarod8d39a02003-07-10 20:44:10 +0000955generated by GNU Autoconf 2.57
Martin v. Löwis11437992002-04-12 09:54:03 +0000956
957Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
958Free Software Foundation, Inc.
959This configure script is free software; the Free Software Foundation
960gives unlimited permission to copy, distribute and modify it.
961_ACEOF
962 exit 0
963fi
964exec 5>config.log
965cat >&5 <<_ACEOF
966This file contains any messages produced by compilers while
967running configure, to aid debugging if configure makes a mistake.
968
Martin v. Löwis88afe662002-10-26 13:47:44 +0000969It was created by python $as_me 2.3, which was
Skip Montanarod8d39a02003-07-10 20:44:10 +0000970generated by GNU Autoconf 2.57. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +0000971
972 $ $0 $@
973
974_ACEOF
975{
976cat <<_ASUNAME
977## --------- ##
978## Platform. ##
979## --------- ##
980
981hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
982uname -m = `(uname -m) 2>/dev/null || echo unknown`
983uname -r = `(uname -r) 2>/dev/null || echo unknown`
984uname -s = `(uname -s) 2>/dev/null || echo unknown`
985uname -v = `(uname -v) 2>/dev/null || echo unknown`
986
987/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
988/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
989
990/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
991/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
992/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
993hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
994/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
995/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
996/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
997
998_ASUNAME
999
1000as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1001for as_dir in $PATH
1002do
1003 IFS=$as_save_IFS
1004 test -z "$as_dir" && as_dir=.
1005 echo "PATH: $as_dir"
1006done
1007
1008} >&5
1009
1010cat >&5 <<_ACEOF
1011
1012
1013## ----------- ##
1014## Core tests. ##
1015## ----------- ##
1016
1017_ACEOF
1018
1019
1020# Keep a trace of the command line.
1021# Strip out --no-create and --no-recursion so they do not pile up.
Skip Montanarod8d39a02003-07-10 20:44:10 +00001022# Strip out --silent because we don't want to record it for future runs.
Martin v. Löwis11437992002-04-12 09:54:03 +00001023# Also quote any args containing shell meta-characters.
Skip Montanarod8d39a02003-07-10 20:44:10 +00001024# Make two passes to allow for proper duplicate-argument suppression.
Martin v. Löwis11437992002-04-12 09:54:03 +00001025ac_configure_args=
Skip Montanarod8d39a02003-07-10 20:44:10 +00001026ac_configure_args0=
1027ac_configure_args1=
Martin v. Löwis11437992002-04-12 09:54:03 +00001028ac_sep=
Skip Montanarod8d39a02003-07-10 20:44:10 +00001029ac_must_keep_next=false
1030for ac_pass in 1 2
Martin v. Löwis11437992002-04-12 09:54:03 +00001031do
Skip Montanarod8d39a02003-07-10 20:44:10 +00001032 for ac_arg
1033 do
1034 case $ac_arg in
1035 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1036 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1037 | -silent | --silent | --silen | --sile | --sil)
1038 continue ;;
1039 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1040 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1041 esac
1042 case $ac_pass in
1043 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1044 2)
1045 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1046 if test $ac_must_keep_next = true; then
1047 ac_must_keep_next=false # Got value, back to normal.
1048 else
1049 case $ac_arg in
1050 *=* | --config-cache | -C | -disable-* | --disable-* \
1051 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1052 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1053 | -with-* | --with-* | -without-* | --without-* | --x)
1054 case "$ac_configure_args0 " in
1055 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1056 esac
1057 ;;
1058 -* ) ac_must_keep_next=true ;;
1059 esac
1060 fi
1061 ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1062 # Get rid of the leading space.
1063 ac_sep=" "
1064 ;;
1065 esac
1066 done
Martin v. Löwis11437992002-04-12 09:54:03 +00001067done
Skip Montanarod8d39a02003-07-10 20:44:10 +00001068$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1069$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001070
1071# When interrupted or exit'd, cleanup temporary files, and complete
1072# config.log. We remove comments because anyway the quotes in there
1073# would cause problems or look ugly.
1074# WARNING: Be sure not to use single quotes in there, as some shells,
1075# such as our DU 5.0 friend, will then `close' the trap.
1076trap 'exit_status=$?
1077 # Save into config.log some information that might help in debugging.
1078 {
1079 echo
Skip Montanarod8d39a02003-07-10 20:44:10 +00001080
Martin v. Löwis11437992002-04-12 09:54:03 +00001081 cat <<\_ASBOX
1082## ---------------- ##
1083## Cache variables. ##
1084## ---------------- ##
1085_ASBOX
1086 echo
1087 # The following way of writing the cache mishandles newlines in values,
1088{
1089 (set) 2>&1 |
1090 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1091 *ac_space=\ *)
1092 sed -n \
1093 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1094 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1095 ;;
1096 *)
1097 sed -n \
1098 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1099 ;;
1100 esac;
1101}
1102 echo
Skip Montanarod8d39a02003-07-10 20:44:10 +00001103
1104 cat <<\_ASBOX
1105## ----------------- ##
1106## Output variables. ##
1107## ----------------- ##
1108_ASBOX
1109 echo
1110 for ac_var in $ac_subst_vars
1111 do
1112 eval ac_val=$`echo $ac_var`
1113 echo "$ac_var='"'"'$ac_val'"'"'"
1114 done | sort
1115 echo
1116
1117 if test -n "$ac_subst_files"; then
1118 cat <<\_ASBOX
1119## ------------- ##
1120## Output files. ##
1121## ------------- ##
1122_ASBOX
1123 echo
1124 for ac_var in $ac_subst_files
1125 do
1126 eval ac_val=$`echo $ac_var`
1127 echo "$ac_var='"'"'$ac_val'"'"'"
1128 done | sort
1129 echo
1130 fi
1131
Martin v. Löwis11437992002-04-12 09:54:03 +00001132 if test -s confdefs.h; then
1133 cat <<\_ASBOX
1134## ----------- ##
1135## confdefs.h. ##
1136## ----------- ##
1137_ASBOX
1138 echo
Skip Montanarod8d39a02003-07-10 20:44:10 +00001139 sed "/^$/d" confdefs.h | sort
Martin v. Löwis11437992002-04-12 09:54:03 +00001140 echo
1141 fi
1142 test "$ac_signal" != 0 &&
1143 echo "$as_me: caught signal $ac_signal"
1144 echo "$as_me: exit $exit_status"
1145 } >&5
1146 rm -f core core.* *.core &&
1147 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1148 exit $exit_status
1149 ' 0
1150for ac_signal in 1 2 13 15; do
1151 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1152done
1153ac_signal=0
1154
1155# confdefs.h avoids OS command line length limits that DEFS can exceed.
1156rm -rf conftest* confdefs.h
1157# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1158echo >confdefs.h
1159
1160# Predefined preprocessor variables.
1161
1162cat >>confdefs.h <<_ACEOF
1163#define PACKAGE_NAME "$PACKAGE_NAME"
1164_ACEOF
1165
1166
1167cat >>confdefs.h <<_ACEOF
1168#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1169_ACEOF
1170
1171
1172cat >>confdefs.h <<_ACEOF
1173#define PACKAGE_VERSION "$PACKAGE_VERSION"
1174_ACEOF
1175
1176
1177cat >>confdefs.h <<_ACEOF
1178#define PACKAGE_STRING "$PACKAGE_STRING"
1179_ACEOF
1180
1181
1182cat >>confdefs.h <<_ACEOF
1183#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1184_ACEOF
1185
1186
1187# Let the site file select an alternate cache file if it wants to.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001188# Prefer explicitly selected file to automatically selected ones.
1189if test -z "$CONFIG_SITE"; then
1190 if test "x$prefix" != xNONE; then
1191 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1192 else
1193 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1194 fi
1195fi
1196for ac_site_file in $CONFIG_SITE; do
1197 if test -r "$ac_site_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001198 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1199echo "$as_me: loading site script $ac_site_file" >&6;}
1200 sed 's/^/| /' "$ac_site_file" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001201 . "$ac_site_file"
1202 fi
1203done
1204
1205if test -r "$cache_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001206 # Some versions of bash will fail to source /dev/null (special
1207 # files actually), so we avoid doing that.
1208 if test -f "$cache_file"; then
1209 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1210echo "$as_me: loading cache $cache_file" >&6;}
1211 case $cache_file in
1212 [\\/]* | ?:[\\/]* ) . $cache_file;;
1213 *) . ./$cache_file;;
1214 esac
1215 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001216else
Martin v. Löwis11437992002-04-12 09:54:03 +00001217 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1218echo "$as_me: creating cache $cache_file" >&6;}
1219 >$cache_file
1220fi
1221
1222# Check that the precious variables saved in the cache have kept the same
1223# value.
1224ac_cache_corrupted=false
1225for ac_var in `(set) 2>&1 |
1226 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1227 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1228 eval ac_new_set=\$ac_env_${ac_var}_set
1229 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1230 eval ac_new_val="\$ac_env_${ac_var}_value"
1231 case $ac_old_set,$ac_new_set in
1232 set,)
1233 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1234echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1235 ac_cache_corrupted=: ;;
1236 ,set)
1237 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1238echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1239 ac_cache_corrupted=: ;;
1240 ,);;
1241 *)
1242 if test "x$ac_old_val" != "x$ac_new_val"; then
1243 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1244echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1245 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
1246echo "$as_me: former value: $ac_old_val" >&2;}
1247 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
1248echo "$as_me: current value: $ac_new_val" >&2;}
1249 ac_cache_corrupted=:
1250 fi;;
1251 esac
1252 # Pass precious variables to config.status.
1253 if test "$ac_new_set" = set; then
1254 case $ac_new_val in
1255 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1256 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1257 *) ac_arg=$ac_var=$ac_new_val ;;
1258 esac
1259 case " $ac_configure_args " in
1260 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1261 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1262 esac
1263 fi
1264done
1265if $ac_cache_corrupted; then
1266 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1267echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1268 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1269echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1270 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001271fi
1272
Guido van Rossum7f43da71994-08-01 12:15:30 +00001273ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001274ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001275ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1276ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1277ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001278
Guido van Rossum627b2d71993-12-24 10:39:16 +00001279
Michael W. Hudson54241132001-12-07 15:38:26 +00001280
1281
Guido van Rossum627b2d71993-12-24 10:39:16 +00001282
Martin v. Löwis11437992002-04-12 09:54:03 +00001283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
Martin v. Löwis88afe662002-10-26 13:47:44 +00001296
1297
1298
1299
1300
1301
1302
1303
1304
Skip Montanarod8d39a02003-07-10 20:44:10 +00001305
1306 ac_config_headers="$ac_config_headers pyconfig.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00001307
1308
Martin v. Löwis11437992002-04-12 09:54:03 +00001309
1310
1311
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001312
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001313
Martin v. Löwis8316feb2003-06-14 07:48:07 +00001314# We don't use PACKAGE_ variables, and they cause conflicts
1315# with other autoconf-based packages that include Python.h
1316grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new
1317rm confdefs.h
1318mv confdefs.h.new confdefs.h
1319
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001320
Andrew M. Kuchlingf2f219d2002-02-11 16:31:10 +00001321VERSION=2.3
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001322
Martin v. Löwis1142de32002-03-29 16:28:31 +00001323
1324SOVERSION=1.0
1325
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001326# The later defininition of _XOPEN_SOURCE disables certain features
1327# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1328
1329cat >>confdefs.h <<\_ACEOF
1330#define _GNU_SOURCE 1
1331_ACEOF
1332
1333
Martin v. Löwisbcd93962003-05-03 10:32:18 +00001334# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1335# certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable
1336# them.
1337
1338cat >>confdefs.h <<\_ACEOF
1339#define _NETBSD_SOURCE 1
1340_ACEOF
1341
1342
Andrew MacIntyreabccf412003-07-02 13:53:25 +00001343# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1344# certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable
1345# them.
1346
1347cat >>confdefs.h <<\_ACEOF
1348#define __BSD_VISIBLE 1
1349_ACEOF
1350
1351
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001352define_xopen_source=yes
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001353
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00001354# Arguments passed to configure.
1355
1356CONFIG_ARGS="$ac_configure_args"
1357
Jack Jansene578a632001-08-15 01:27:14 +00001358# Check whether --enable-framework or --disable-framework was given.
1359if test "${enable_framework+set}" = set; then
1360 enableval="$enable_framework"
Martin v. Löwis11437992002-04-12 09:54:03 +00001361
Jack Jansene578a632001-08-15 01:27:14 +00001362 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00001363 yes)
Jack Jansene578a632001-08-15 01:27:14 +00001364 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00001365 esac
1366 case $enableval in
1367 no)
1368 PYTHONFRAMEWORK=
1369 PYTHONFRAMEWORKDIR=no-framework
1370 PYTHONFRAMEWORKPREFIX=
1371 PYTHONFRAMEWORKINSTALLDIR=
1372 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00001373 ;;
1374 *)
Jack Jansen127e56e2001-09-11 14:41:54 +00001375 PYTHONFRAMEWORK=Python
1376 PYTHONFRAMEWORKDIR=Python.framework
Jack Jansene578a632001-08-15 01:27:14 +00001377 PYTHONFRAMEWORKPREFIX=$enableval
Jack Jansen127e56e2001-09-11 14:41:54 +00001378 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
1379 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Jack Jansene578a632001-08-15 01:27:14 +00001380 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001381
Guido van Rossum563e7081996-09-10 18:20:48 +00001382else
Martin v. Löwis11437992002-04-12 09:54:03 +00001383
Jack Jansene578a632001-08-15 01:27:14 +00001384 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00001385 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00001386 PYTHONFRAMEWORKPREFIX=
1387 PYTHONFRAMEWORKINSTALLDIR=
1388 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001389
Martin v. Löwis11437992002-04-12 09:54:03 +00001390fi;
Michael W. Hudson54241132001-12-07 15:38:26 +00001391
1392
1393
1394
Jack Jansene578a632001-08-15 01:27:14 +00001395
1396##AC_ARG_WITH(dyld,
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001397## AC_HELP_STRING(--with-dyld,
1398## Use (OpenStep|Rhapsody) dynamic linker))
Jack Jansene578a632001-08-15 01:27:14 +00001399##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001400# Set name for machine-dependent library files
1401
Martin v. Löwis11437992002-04-12 09:54:03 +00001402echo "$as_me:$LINENO: checking MACHDEP" >&5
1403echo $ECHO_N "checking MACHDEP... $ECHO_C" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001404if test -z "$MACHDEP"
1405then
Guido van Rossum563e7081996-09-10 18:20:48 +00001406 ac_sys_system=`uname -s`
Martin v. Löwis21ee4092002-09-30 16:19:48 +00001407 if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64" \
1408 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00001409 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001410 else
Guido van Rossum563e7081996-09-10 18:20:48 +00001411 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001412 fi
Guido van Rossum563e7081996-09-10 18:20:48 +00001413 ac_md_system=`echo $ac_sys_system |
1414 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
1415 ac_md_release=`echo $ac_sys_release |
Guido van Rossum67b26592001-10-20 14:21:45 +00001416 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +00001417 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00001418
Guido van Rossum07397971997-04-29 21:49:50 +00001419 case $MACHDEP in
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00001420 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00001421 darwin*) MACHDEP="darwin";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00001422 atheos*) MACHDEP="atheos";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00001423 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001424 esac
1425fi
Guido van Rossum91922671997-10-09 20:24:13 +00001426
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001427# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
1428# disable features if it is defined, without any means to access these
1429# features as extensions. For these systems, we skip the definition of
1430# _XOPEN_SOURCE. Before adding a system to the list to gain access to
1431# some feature, make sure there is no alternative way to access this
1432# feature. Also, when using wildcards, make sure you have verified the
1433# need for not defining _XOPEN_SOURCE on all systems matching the
1434# wildcard, and that the wildcard does not include future systems
1435# (which may remove their limitations).
1436case $ac_sys_system/$ac_sys_release in
1437 # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
1438 # even though select is a POSIX function. Reported by J. Ribbens.
Martin v. Löwis858f8172003-05-24 12:35:47 +00001439 # Reconfirmed for OpenBSD 3.3 by Zachary Hamm.
1440 OpenBSD/2.* | OpenBSD/3.[0123])
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001441 define_xopen_source=no;;
Martin v. Löwisa9d71422003-03-28 18:43:31 +00001442 # On Solaris 2.6, sys/wait.h is inconsistent in the usage
1443 # of union __?sigval. Reported by Stuart Bishop.
1444 SunOS/5.6)
1445 define_xopen_source=no;;
Martin v. Löwisc2409b42003-05-11 05:53:41 +00001446 # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
1447 # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
1448 OpenUNIX/8.0.0| UnixWare/7.1.[0-3])
1449 define_xopen_source=no;;
1450 # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
Martin v. Löwis53e73c32003-05-05 05:13:18 +00001451 # but used in struct sockaddr.sa_family. Reported by Tim Rice.
Martin v. Löwisc2409b42003-05-11 05:53:41 +00001452 SCO_SV/3.2)
Martin v. Löwis53e73c32003-05-05 05:13:18 +00001453 define_xopen_source=no;;
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001454esac
1455
1456if test $define_xopen_source = yes
1457then
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00001458
1459cat >>confdefs.h <<\_ACEOF
1460#define _XOPEN_SOURCE 600
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001461_ACEOF
1462
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00001463
1464 # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
1465 # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
1466 # several APIs are not declared. Since this is also needed in some
1467 # cases for HP-UX, we define it globally.
1468
1469
1470cat >>confdefs.h <<\_ACEOF
1471#define _XOPEN_SOURCE_EXTENDED 1
1472_ACEOF
1473
1474
1475cat >>confdefs.h <<\_ACEOF
1476#define _POSIX_C_SOURCE 200112L
1477_ACEOF
1478
1479
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001480fi
1481
Guido van Rossum91922671997-10-09 20:24:13 +00001482#
1483# SGI compilers allow the specification of the both the ABI and the
1484# ISA on the command line. Depending on the values of these switches,
1485# different and often incompatable code will be generated.
1486#
1487# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
1488# thus supply support for various ABI/ISA combinations. The MACHDEP
1489# variable is also adjusted.
1490#
1491
1492if test ! -z "$SGI_ABI"
1493then
1494 CC="cc $SGI_ABI"
1495 LDFLAGS="$SGI_ABI $LDFLAGS"
1496 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
1497fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001498echo "$as_me:$LINENO: result: $MACHDEP" >&5
1499echo "${ECHO_T}$MACHDEP" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001500
Jack Jansen83f898c2002-12-30 22:23:40 +00001501# And add extra plat-mac for darwin
1502
Jack Jansen7b59b422003-03-17 15:44:10 +00001503
Jack Jansen83f898c2002-12-30 22:23:40 +00001504echo "$as_me:$LINENO: checking EXTRAPLATDIR" >&5
1505echo $ECHO_N "checking EXTRAPLATDIR... $ECHO_C" >&6
1506if test -z "$EXTRAPLATDIR"
1507then
1508 case $MACHDEP in
Jack Jansen7b59b422003-03-17 15:44:10 +00001509 darwin)
1510 EXTRAPLATDIR="\$(PLATMACDIRS)"
1511 EXTRAMACHDEPPATH="\$(PLATMACPATH)"
1512 ;;
1513 *)
1514 EXTRAPLATDIR=""
1515 EXTRAMACHDEPPATH=""
1516 ;;
Jack Jansen83f898c2002-12-30 22:23:40 +00001517 esac
1518fi
1519echo "$as_me:$LINENO: result: $EXTRAPLATDIR" >&5
1520echo "${ECHO_T}$EXTRAPLATDIR" >&6
1521
Guido van Rossum627b2d71993-12-24 10:39:16 +00001522# checks for alternative programs
Skip Montanarodecc6a42003-01-01 20:07:49 +00001523
1524# compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just
1525# for debug/optimization stuff. BASECFLAGS is for flags that are required
1526# just to get things to compile and link. Users are free to override OPT
1527# when running configure or make. The build should not break if they do.
1528# BASECFLAGS should generally not be messed with, however.
1529
1530# XXX shouldn't some/most/all of this code be merged with the stuff later
1531# on that fiddles with OPT and BASECFLAGS?
Martin v. Löwis11437992002-04-12 09:54:03 +00001532echo "$as_me:$LINENO: checking for --without-gcc" >&5
1533echo $ECHO_N "checking for --without-gcc... $ECHO_C" >&6
1534
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001535# Check whether --with-gcc or --without-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001536if test "${with_gcc+set}" = set; then
1537 withval="$with_gcc"
Martin v. Löwis11437992002-04-12 09:54:03 +00001538
Guido van Rossum7f43da71994-08-01 12:15:30 +00001539 case $withval in
Guido van Rossumda88dad1995-01-26 00:46:29 +00001540 no) CC=cc
1541 without_gcc=yes;;
1542 yes) CC=gcc
1543 without_gcc=no;;
1544 *) CC=$withval
1545 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001546 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +00001547else
Martin v. Löwis11437992002-04-12 09:54:03 +00001548
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001549 case $ac_sys_system in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001550 AIX*) CC=cc_r
1551 without_gcc=;;
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001552 BeOS*)
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001553 case $BE_HOST_CPU in
1554 ppc)
Fred Drake5790be12000-10-09 17:06:13 +00001555 CC=mwcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001556 without_gcc=yes
Skip Montanarodecc6a42003-01-01 20:07:49 +00001557 BASECFLAGS="$BASECFLAGS -export pragma"
1558 OPT="$OPT -O"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001559 LDFLAGS="$LDFLAGS -nodup"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001560 ;;
1561 x86)
Fred Drake5790be12000-10-09 17:06:13 +00001562 CC=gcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001563 without_gcc=no
Skip Montanarodecc6a42003-01-01 20:07:49 +00001564 OPT="$OPT -O"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001565 ;;
1566 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001567 { { echo "$as_me:$LINENO: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&5
1568echo "$as_me: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&2;}
1569 { (exit 1); exit 1; }; }
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001570 ;;
1571 esac
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001572 AR="\$(srcdir)/Modules/ar_beos"
1573 RANLIB=:
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001574 ;;
Trent Mick635f6fb2000-08-23 21:33:05 +00001575 Monterey*)
1576 RANLIB=:
Martin v. Löwis130fb172001-07-19 11:00:41 +00001577 without_gcc=;;
1578 *) without_gcc=no;;
Guido van Rossume77438c1995-09-13 18:59:59 +00001579 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001580fi;
1581echo "$as_me:$LINENO: result: $without_gcc" >&5
1582echo "${ECHO_T}$without_gcc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001583
1584
Guido van Rossum95012191999-12-16 17:50:52 +00001585
Fred Drakea1a84e72001-03-06 05:52:16 +00001586MAINOBJ=python.o
Martin v. Löwis11437992002-04-12 09:54:03 +00001587echo "$as_me:$LINENO: checking for --with-cxx=<compiler>" >&5
1588echo $ECHO_N "checking for --with-cxx=<compiler>... $ECHO_C" >&6
1589
Guido van Rossum95012191999-12-16 17:50:52 +00001590# Check whether --with-cxx or --without-cxx was given.
1591if test "${with_cxx+set}" = set; then
1592 withval="$with_cxx"
Martin v. Löwis11437992002-04-12 09:54:03 +00001593
Martin v. Löwis22352952000-12-13 17:37:02 +00001594 check_cxx=no
Guido van Rossum95012191999-12-16 17:50:52 +00001595 case $withval in
1596 no) CXX=
1597 with_cxx=no;;
1598 *) CXX=$withval
Fred Drakea1a84e72001-03-06 05:52:16 +00001599 MAINOBJ=ccpython.o
Guido van Rossum95012191999-12-16 17:50:52 +00001600 with_cxx=$withval;;
1601 esac
1602else
Martin v. Löwis11437992002-04-12 09:54:03 +00001603
Guido van Rossum95012191999-12-16 17:50:52 +00001604 with_cxx=no
Martin v. Löwis22352952000-12-13 17:37:02 +00001605 check_cxx=yes
Guido van Rossum95012191999-12-16 17:50:52 +00001606
Martin v. Löwis11437992002-04-12 09:54:03 +00001607fi;
1608echo "$as_me:$LINENO: result: $with_cxx" >&5
1609echo "${ECHO_T}$with_cxx" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001610
1611if test "$with_cxx" = "yes"
1612then
Martin v. Löwis11437992002-04-12 09:54:03 +00001613 { { echo "$as_me:$LINENO: error: must supply a compiler when using --with-cxx" >&5
1614echo "$as_me: error: must supply a compiler when using --with-cxx" >&2;}
1615 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001616fi
1617
1618
1619
1620
Martin v. Löwis11437992002-04-12 09:54:03 +00001621if test "$check_cxx" = "yes"
Martin v. Löwis22352952000-12-13 17:37:02 +00001622then
1623 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
1624do
Martin v. Löwis11437992002-04-12 09:54:03 +00001625 # Extract the first word of "$ac_prog", so it can be a program name with args.
Martin v. Löwis22352952000-12-13 17:37:02 +00001626set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00001627echo "$as_me:$LINENO: checking for $ac_word" >&5
1628echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1629if test "${ac_cv_prog_CXX+set}" = set; then
1630 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001631else
1632 if test -n "$CXX"; then
1633 ac_cv_prog_CXX="$CXX" # Let the user override the test.
1634else
Martin v. Löwis11437992002-04-12 09:54:03 +00001635as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1636for as_dir in $PATH
1637do
1638 IFS=$as_save_IFS
1639 test -z "$as_dir" && as_dir=.
1640 for ac_exec_ext in '' $ac_executable_extensions; do
1641 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1642 ac_cv_prog_CXX="$ac_prog"
1643 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1644 break 2
1645 fi
1646done
1647done
1648
Martin v. Löwis22352952000-12-13 17:37:02 +00001649fi
1650fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001651CXX=$ac_cv_prog_CXX
Martin v. Löwis22352952000-12-13 17:37:02 +00001652if test -n "$CXX"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001653 echo "$as_me:$LINENO: result: $CXX" >&5
1654echo "${ECHO_T}$CXX" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001655else
Martin v. Löwis11437992002-04-12 09:54:03 +00001656 echo "$as_me:$LINENO: result: no" >&5
1657echo "${ECHO_T}no" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001658fi
1659
Martin v. Löwis11437992002-04-12 09:54:03 +00001660 test -n "$CXX" && break
Martin v. Löwis22352952000-12-13 17:37:02 +00001661done
1662test -n "$CXX" || CXX="notfound"
1663
1664 if test "$CXX" = "notfound"
1665 then
1666 CXX=
1667 else
Martin v. Löwis11437992002-04-12 09:54:03 +00001668 ac_ext=cc
Martin v. Löwis22352952000-12-13 17:37:02 +00001669ac_cpp='$CXXCPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001670ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1671ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1672ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
1673 cat >conftest.$ac_ext <<_ACEOF
1674#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00001675/* confdefs.h. */
1676_ACEOF
1677cat confdefs.h >>conftest.$ac_ext
1678cat >>conftest.$ac_ext <<_ACEOF
1679/* end confdefs.h. */
Martin v. Löwis22352952000-12-13 17:37:02 +00001680
Martin v. Löwis11437992002-04-12 09:54:03 +00001681int
1682main ()
1683{
Michael W. Hudson54241132001-12-07 15:38:26 +00001684
Martin v. Löwis11437992002-04-12 09:54:03 +00001685 ;
1686 return 0;
1687}
1688_ACEOF
1689ac_clean_files_save=$ac_clean_files
Skip Montanarod8d39a02003-07-10 20:44:10 +00001690ac_clean_files="$ac_clean_files a.out a.exe b.out"
Martin v. Löwis11437992002-04-12 09:54:03 +00001691# Try to create an executable without -o first, disregard a.out.
1692# It will help us diagnose broken compilers, and finding out an intuition
1693# of exeext.
1694echo "$as_me:$LINENO: checking for C++ compiler default output" >&5
1695echo $ECHO_N "checking for C++ compiler default output... $ECHO_C" >&6
1696ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1697if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1698 (eval $ac_link_default) 2>&5
1699 ac_status=$?
1700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1701 (exit $ac_status); }; then
1702 # Find the output, starting from the most likely. This scheme is
1703# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1704# resort.
1705
1706# Be careful to initialize this variable, since it used to be cached.
1707# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1708ac_cv_exeext=
Skip Montanarod8d39a02003-07-10 20:44:10 +00001709# b.out is created by i960 compilers.
1710for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
1711do
1712 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00001713 case $ac_file in
Skip Montanarod8d39a02003-07-10 20:44:10 +00001714 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
1715 ;;
1716 conftest.$ac_ext )
1717 # This is the source file.
1718 ;;
1719 [ab].out )
1720 # We found the default executable, but exeext='' is most
1721 # certainly right.
1722 break;;
1723 *.* )
1724 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1725 # FIXME: I believe we export ac_cv_exeext for Libtool,
1726 # but it would be cool to find out if it's true. Does anybody
1727 # maintain Libtool? --akim.
1728 export ac_cv_exeext
1729 break;;
1730 * )
1731 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001732 esac
1733done
1734else
1735 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00001736sed 's/^/| /' conftest.$ac_ext >&5
1737
1738{ { echo "$as_me:$LINENO: error: C++ compiler cannot create executables
1739See \`config.log' for more details." >&5
1740echo "$as_me: error: C++ compiler cannot create executables
1741See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001742 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001743fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001744
1745ac_exeext=$ac_cv_exeext
1746echo "$as_me:$LINENO: result: $ac_file" >&5
1747echo "${ECHO_T}$ac_file" >&6
1748
1749# Check the compiler produces executables we can run. If not, either
1750# the compiler is broken, or we cross compile.
1751echo "$as_me:$LINENO: checking whether the C++ compiler works" >&5
1752echo $ECHO_N "checking whether the C++ compiler works... $ECHO_C" >&6
1753# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1754# If not cross compiling, check that we can run a simple program.
1755if test "$cross_compiling" != yes; then
1756 if { ac_try='./$ac_file'
1757 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1758 (eval $ac_try) 2>&5
1759 ac_status=$?
1760 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1761 (exit $ac_status); }; }; then
1762 cross_compiling=no
1763 else
1764 if test "$cross_compiling" = maybe; then
1765 cross_compiling=yes
1766 else
1767 { { echo "$as_me:$LINENO: error: cannot run C++ compiled programs.
Skip Montanarod8d39a02003-07-10 20:44:10 +00001768If you meant to cross compile, use \`--host'.
1769See \`config.log' for more details." >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00001770echo "$as_me: error: cannot run C++ compiled programs.
Skip Montanarod8d39a02003-07-10 20:44:10 +00001771If you meant to cross compile, use \`--host'.
1772See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001773 { (exit 1); exit 1; }; }
1774 fi
1775 fi
1776fi
1777echo "$as_me:$LINENO: result: yes" >&5
1778echo "${ECHO_T}yes" >&6
1779
Skip Montanarod8d39a02003-07-10 20:44:10 +00001780rm -f a.out a.exe conftest$ac_cv_exeext b.out
Martin v. Löwis11437992002-04-12 09:54:03 +00001781ac_clean_files=$ac_clean_files_save
1782# Check the compiler produces executables we can run. If not, either
1783# the compiler is broken, or we cross compile.
1784echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1785echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1786echo "$as_me:$LINENO: result: $cross_compiling" >&5
1787echo "${ECHO_T}$cross_compiling" >&6
1788
1789echo "$as_me:$LINENO: checking for suffix of executables" >&5
1790echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1791if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1792 (eval $ac_link) 2>&5
1793 ac_status=$?
1794 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1795 (exit $ac_status); }; then
1796 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1797# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1798# work properly (i.e., refer to `conftest.exe'), while it won't with
1799# `rm'.
Skip Montanarod8d39a02003-07-10 20:44:10 +00001800for ac_file in conftest.exe conftest conftest.*; do
1801 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00001802 case $ac_file in
Skip Montanarod8d39a02003-07-10 20:44:10 +00001803 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001804 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1805 export ac_cv_exeext
1806 break;;
1807 * ) break;;
1808 esac
1809done
1810else
Skip Montanarod8d39a02003-07-10 20:44:10 +00001811 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
1812See \`config.log' for more details." >&5
1813echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
1814See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001815 { (exit 1); exit 1; }; }
1816fi
1817
1818rm -f conftest$ac_cv_exeext
1819echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1820echo "${ECHO_T}$ac_cv_exeext" >&6
1821
1822rm -f conftest.$ac_ext
1823EXEEXT=$ac_cv_exeext
1824ac_exeext=$EXEEXT
1825
1826 ac_ext=c
1827ac_cpp='$CPP $CPPFLAGS'
1828ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1829ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1830ac_compiler_gnu=$ac_cv_c_compiler_gnu
1831
1832
Martin v. Löwis22352952000-12-13 17:37:02 +00001833
1834 fi
1835fi
1836
Guido van Rossum8b131c51995-03-09 14:10:13 +00001837# If the user switches compilers, we can't believe the cache
1838if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
1839then
Martin v. Löwis11437992002-04-12 09:54:03 +00001840 { { echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file
1841(it is also a good idea to do 'make clean' before compiling)" >&5
1842echo "$as_me: error: cached CC is different -- throw away $cache_file
1843(it is also a good idea to do 'make clean' before compiling)" >&2;}
1844 { (exit 1); exit 1; }; }
Guido van Rossum8b131c51995-03-09 14:10:13 +00001845fi
1846
Martin v. Löwis11437992002-04-12 09:54:03 +00001847ac_ext=c
1848ac_cpp='$CPP $CPPFLAGS'
1849ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1850ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1851ac_compiler_gnu=$ac_cv_c_compiler_gnu
1852if test -n "$ac_tool_prefix"; then
1853 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1854set dummy ${ac_tool_prefix}gcc; ac_word=$2
1855echo "$as_me:$LINENO: checking for $ac_word" >&5
1856echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1857if test "${ac_cv_prog_CC+set}" = set; then
1858 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001859else
1860 if test -n "$CC"; then
1861 ac_cv_prog_CC="$CC" # Let the user override the test.
1862else
Martin v. Löwis11437992002-04-12 09:54:03 +00001863as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1864for as_dir in $PATH
1865do
1866 IFS=$as_save_IFS
1867 test -z "$as_dir" && as_dir=.
1868 for ac_exec_ext in '' $ac_executable_extensions; do
1869 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1870 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1871 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1872 break 2
1873 fi
1874done
1875done
1876
Jack Jansendd19cf82001-12-06 22:36:17 +00001877fi
1878fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001879CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00001880if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001881 echo "$as_me:$LINENO: result: $CC" >&5
1882echo "${ECHO_T}$CC" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001883else
Martin v. Löwis11437992002-04-12 09:54:03 +00001884 echo "$as_me:$LINENO: result: no" >&5
1885echo "${ECHO_T}no" >&6
1886fi
1887
1888fi
1889if test -z "$ac_cv_prog_CC"; then
1890 ac_ct_CC=$CC
1891 # Extract the first word of "gcc", so it can be a program name with args.
1892set dummy gcc; ac_word=$2
1893echo "$as_me:$LINENO: checking for $ac_word" >&5
1894echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1895if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1896 echo $ECHO_N "(cached) $ECHO_C" >&6
1897else
1898 if test -n "$ac_ct_CC"; then
1899 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1900else
1901as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1902for as_dir in $PATH
1903do
1904 IFS=$as_save_IFS
1905 test -z "$as_dir" && as_dir=.
1906 for ac_exec_ext in '' $ac_executable_extensions; do
1907 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1908 ac_cv_prog_ac_ct_CC="gcc"
1909 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1910 break 2
1911 fi
1912done
1913done
1914
1915fi
1916fi
1917ac_ct_CC=$ac_cv_prog_ac_ct_CC
1918if test -n "$ac_ct_CC"; then
1919 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1920echo "${ECHO_T}$ac_ct_CC" >&6
1921else
1922 echo "$as_me:$LINENO: result: no" >&5
1923echo "${ECHO_T}no" >&6
1924fi
1925
1926 CC=$ac_ct_CC
1927else
1928 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00001929fi
1930
Jack Jansendd19cf82001-12-06 22:36:17 +00001931if test -z "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001932 if test -n "$ac_tool_prefix"; then
1933 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1934set dummy ${ac_tool_prefix}cc; ac_word=$2
1935echo "$as_me:$LINENO: checking for $ac_word" >&5
1936echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1937if test "${ac_cv_prog_CC+set}" = set; then
1938 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001939else
1940 if test -n "$CC"; then
1941 ac_cv_prog_CC="$CC" # Let the user override the test.
1942else
Martin v. Löwis11437992002-04-12 09:54:03 +00001943as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1944for as_dir in $PATH
1945do
1946 IFS=$as_save_IFS
1947 test -z "$as_dir" && as_dir=.
1948 for ac_exec_ext in '' $ac_executable_extensions; do
1949 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1950 ac_cv_prog_CC="${ac_tool_prefix}cc"
1951 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1952 break 2
1953 fi
1954done
1955done
1956
1957fi
1958fi
1959CC=$ac_cv_prog_CC
1960if test -n "$CC"; then
1961 echo "$as_me:$LINENO: result: $CC" >&5
1962echo "${ECHO_T}$CC" >&6
1963else
1964 echo "$as_me:$LINENO: result: no" >&5
1965echo "${ECHO_T}no" >&6
1966fi
1967
1968fi
1969if test -z "$ac_cv_prog_CC"; then
1970 ac_ct_CC=$CC
1971 # Extract the first word of "cc", so it can be a program name with args.
1972set dummy cc; ac_word=$2
1973echo "$as_me:$LINENO: checking for $ac_word" >&5
1974echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1975if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1976 echo $ECHO_N "(cached) $ECHO_C" >&6
1977else
1978 if test -n "$ac_ct_CC"; then
1979 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1980else
1981as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1982for as_dir in $PATH
1983do
1984 IFS=$as_save_IFS
1985 test -z "$as_dir" && as_dir=.
1986 for ac_exec_ext in '' $ac_executable_extensions; do
1987 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1988 ac_cv_prog_ac_ct_CC="cc"
1989 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1990 break 2
1991 fi
1992done
1993done
1994
1995fi
1996fi
1997ac_ct_CC=$ac_cv_prog_ac_ct_CC
1998if test -n "$ac_ct_CC"; then
1999 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2000echo "${ECHO_T}$ac_ct_CC" >&6
2001else
2002 echo "$as_me:$LINENO: result: no" >&5
2003echo "${ECHO_T}no" >&6
2004fi
2005
2006 CC=$ac_ct_CC
2007else
2008 CC="$ac_cv_prog_CC"
2009fi
2010
2011fi
2012if test -z "$CC"; then
2013 # Extract the first word of "cc", so it can be a program name with args.
2014set dummy cc; ac_word=$2
2015echo "$as_me:$LINENO: checking for $ac_word" >&5
2016echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2017if test "${ac_cv_prog_CC+set}" = set; then
2018 echo $ECHO_N "(cached) $ECHO_C" >&6
2019else
2020 if test -n "$CC"; then
2021 ac_cv_prog_CC="$CC" # Let the user override the test.
2022else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002023 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00002024as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2025for as_dir in $PATH
2026do
2027 IFS=$as_save_IFS
2028 test -z "$as_dir" && as_dir=.
2029 for ac_exec_ext in '' $ac_executable_extensions; do
2030 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2031 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2032 ac_prog_rejected=yes
2033 continue
2034 fi
2035 ac_cv_prog_CC="cc"
2036 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2037 break 2
2038 fi
2039done
2040done
2041
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002042if test $ac_prog_rejected = yes; then
2043 # We found a bogon in the path, so make sure we never use it.
2044 set dummy $ac_cv_prog_CC
2045 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00002046 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002047 # We chose a different compiler from the bogus one.
2048 # However, it has the same basename, so the bogon will be chosen
2049 # first if we set CC to just the basename; use the full file name.
2050 shift
Skip Montanarod8d39a02003-07-10 20:44:10 +00002051 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002052 fi
2053fi
2054fi
2055fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002056CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002057if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002058 echo "$as_me:$LINENO: result: $CC" >&5
2059echo "${ECHO_T}$CC" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002060else
Martin v. Löwis11437992002-04-12 09:54:03 +00002061 echo "$as_me:$LINENO: result: no" >&5
2062echo "${ECHO_T}no" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002063fi
2064
Martin v. Löwis11437992002-04-12 09:54:03 +00002065fi
2066if test -z "$CC"; then
2067 if test -n "$ac_tool_prefix"; then
2068 for ac_prog in cl
2069 do
2070 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2071set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2072echo "$as_me:$LINENO: checking for $ac_word" >&5
2073echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2074if test "${ac_cv_prog_CC+set}" = set; then
2075 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002076else
2077 if test -n "$CC"; then
2078 ac_cv_prog_CC="$CC" # Let the user override the test.
2079else
Martin v. Löwis11437992002-04-12 09:54:03 +00002080as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2081for as_dir in $PATH
2082do
2083 IFS=$as_save_IFS
2084 test -z "$as_dir" && as_dir=.
2085 for ac_exec_ext in '' $ac_executable_extensions; do
2086 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2087 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2088 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2089 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00002090 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002091done
2092done
2093
2094fi
2095fi
2096CC=$ac_cv_prog_CC
2097if test -n "$CC"; then
2098 echo "$as_me:$LINENO: result: $CC" >&5
2099echo "${ECHO_T}$CC" >&6
2100else
2101 echo "$as_me:$LINENO: result: no" >&5
2102echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00002103fi
2104
Martin v. Löwis11437992002-04-12 09:54:03 +00002105 test -n "$CC" && break
2106 done
2107fi
2108if test -z "$CC"; then
2109 ac_ct_CC=$CC
2110 for ac_prog in cl
2111do
2112 # Extract the first word of "$ac_prog", so it can be a program name with args.
2113set dummy $ac_prog; ac_word=$2
2114echo "$as_me:$LINENO: checking for $ac_word" >&5
2115echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2116if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2117 echo $ECHO_N "(cached) $ECHO_C" >&6
2118else
2119 if test -n "$ac_ct_CC"; then
2120 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2121else
2122as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2123for as_dir in $PATH
2124do
2125 IFS=$as_save_IFS
2126 test -z "$as_dir" && as_dir=.
2127 for ac_exec_ext in '' $ac_executable_extensions; do
2128 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2129 ac_cv_prog_ac_ct_CC="$ac_prog"
2130 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2131 break 2
2132 fi
2133done
2134done
Jack Jansendd19cf82001-12-06 22:36:17 +00002135
Martin v. Löwis11437992002-04-12 09:54:03 +00002136fi
2137fi
2138ac_ct_CC=$ac_cv_prog_ac_ct_CC
2139if test -n "$ac_ct_CC"; then
2140 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2141echo "${ECHO_T}$ac_ct_CC" >&6
2142else
2143 echo "$as_me:$LINENO: result: no" >&5
2144echo "${ECHO_T}no" >&6
2145fi
Michael W. Hudson54241132001-12-07 15:38:26 +00002146
Martin v. Löwis11437992002-04-12 09:54:03 +00002147 test -n "$ac_ct_CC" && break
2148done
Michael W. Hudson54241132001-12-07 15:38:26 +00002149
Martin v. Löwis11437992002-04-12 09:54:03 +00002150 CC=$ac_ct_CC
2151fi
2152
2153fi
2154
2155
Skip Montanarod8d39a02003-07-10 20:44:10 +00002156test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2157See \`config.log' for more details." >&5
2158echo "$as_me: error: no acceptable C compiler found in \$PATH
2159See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002160 { (exit 1); exit 1; }; }
2161
2162# Provide some information about the compiler.
2163echo "$as_me:$LINENO:" \
2164 "checking for C compiler version" >&5
2165ac_compiler=`set X $ac_compile; echo $2`
2166{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2167 (eval $ac_compiler --version </dev/null >&5) 2>&5
2168 ac_status=$?
2169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2170 (exit $ac_status); }
2171{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2172 (eval $ac_compiler -v </dev/null >&5) 2>&5
2173 ac_status=$?
2174 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2175 (exit $ac_status); }
2176{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2177 (eval $ac_compiler -V </dev/null >&5) 2>&5
2178 ac_status=$?
2179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2180 (exit $ac_status); }
2181
2182cat >conftest.$ac_ext <<_ACEOF
2183#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002184/* confdefs.h. */
2185_ACEOF
2186cat confdefs.h >>conftest.$ac_ext
2187cat >>conftest.$ac_ext <<_ACEOF
2188/* end confdefs.h. */
Jack Jansendd19cf82001-12-06 22:36:17 +00002189
Martin v. Löwis11437992002-04-12 09:54:03 +00002190int
2191main ()
2192{
2193
2194 ;
2195 return 0;
2196}
2197_ACEOF
2198ac_clean_files_save=$ac_clean_files
Skip Montanarod8d39a02003-07-10 20:44:10 +00002199ac_clean_files="$ac_clean_files a.out a.exe b.out"
Martin v. Löwis11437992002-04-12 09:54:03 +00002200# Try to create an executable without -o first, disregard a.out.
2201# It will help us diagnose broken compilers, and finding out an intuition
2202# of exeext.
2203echo "$as_me:$LINENO: checking for C compiler default output" >&5
2204echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2205ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2206if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2207 (eval $ac_link_default) 2>&5
2208 ac_status=$?
2209 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2210 (exit $ac_status); }; then
2211 # Find the output, starting from the most likely. This scheme is
2212# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2213# resort.
2214
2215# Be careful to initialize this variable, since it used to be cached.
2216# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2217ac_cv_exeext=
Skip Montanarod8d39a02003-07-10 20:44:10 +00002218# b.out is created by i960 compilers.
2219for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
2220do
2221 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00002222 case $ac_file in
Skip Montanarod8d39a02003-07-10 20:44:10 +00002223 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
2224 ;;
2225 conftest.$ac_ext )
2226 # This is the source file.
2227 ;;
2228 [ab].out )
2229 # We found the default executable, but exeext='' is most
2230 # certainly right.
2231 break;;
2232 *.* )
2233 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2234 # FIXME: I believe we export ac_cv_exeext for Libtool,
2235 # but it would be cool to find out if it's true. Does anybody
2236 # maintain Libtool? --akim.
2237 export ac_cv_exeext
2238 break;;
2239 * )
2240 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002241 esac
2242done
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002243else
Martin v. Löwis11437992002-04-12 09:54:03 +00002244 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002245sed 's/^/| /' conftest.$ac_ext >&5
2246
2247{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
2248See \`config.log' for more details." >&5
2249echo "$as_me: error: C compiler cannot create executables
2250See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002251 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002252fi
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002253
Martin v. Löwis11437992002-04-12 09:54:03 +00002254ac_exeext=$ac_cv_exeext
2255echo "$as_me:$LINENO: result: $ac_file" >&5
2256echo "${ECHO_T}$ac_file" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002257
Martin v. Löwis11437992002-04-12 09:54:03 +00002258# Check the compiler produces executables we can run. If not, either
2259# the compiler is broken, or we cross compile.
2260echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2261echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2262# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2263# If not cross compiling, check that we can run a simple program.
2264if test "$cross_compiling" != yes; then
2265 if { ac_try='./$ac_file'
2266 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2267 (eval $ac_try) 2>&5
2268 ac_status=$?
2269 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2270 (exit $ac_status); }; }; then
2271 cross_compiling=no
2272 else
2273 if test "$cross_compiling" = maybe; then
2274 cross_compiling=yes
2275 else
2276 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
Skip Montanarod8d39a02003-07-10 20:44:10 +00002277If you meant to cross compile, use \`--host'.
2278See \`config.log' for more details." >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002279echo "$as_me: error: cannot run C compiled programs.
Skip Montanarod8d39a02003-07-10 20:44:10 +00002280If you meant to cross compile, use \`--host'.
2281See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002282 { (exit 1); exit 1; }; }
2283 fi
2284 fi
2285fi
2286echo "$as_me:$LINENO: result: yes" >&5
2287echo "${ECHO_T}yes" >&6
2288
Skip Montanarod8d39a02003-07-10 20:44:10 +00002289rm -f a.out a.exe conftest$ac_cv_exeext b.out
Martin v. Löwis11437992002-04-12 09:54:03 +00002290ac_clean_files=$ac_clean_files_save
2291# Check the compiler produces executables we can run. If not, either
2292# the compiler is broken, or we cross compile.
2293echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2294echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2295echo "$as_me:$LINENO: result: $cross_compiling" >&5
2296echo "${ECHO_T}$cross_compiling" >&6
2297
2298echo "$as_me:$LINENO: checking for suffix of executables" >&5
2299echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2300if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2301 (eval $ac_link) 2>&5
2302 ac_status=$?
2303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2304 (exit $ac_status); }; then
2305 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2306# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2307# work properly (i.e., refer to `conftest.exe'), while it won't with
2308# `rm'.
Skip Montanarod8d39a02003-07-10 20:44:10 +00002309for ac_file in conftest.exe conftest conftest.*; do
2310 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00002311 case $ac_file in
Skip Montanarod8d39a02003-07-10 20:44:10 +00002312 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002313 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2314 export ac_cv_exeext
2315 break;;
2316 * ) break;;
2317 esac
2318done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002319else
Skip Montanarod8d39a02003-07-10 20:44:10 +00002320 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2321See \`config.log' for more details." >&5
2322echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2323See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002324 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002325fi
Jack Jansendd19cf82001-12-06 22:36:17 +00002326
Martin v. Löwis11437992002-04-12 09:54:03 +00002327rm -f conftest$ac_cv_exeext
2328echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2329echo "${ECHO_T}$ac_cv_exeext" >&6
2330
2331rm -f conftest.$ac_ext
2332EXEEXT=$ac_cv_exeext
2333ac_exeext=$EXEEXT
2334echo "$as_me:$LINENO: checking for suffix of object files" >&5
2335echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2336if test "${ac_cv_objext+set}" = set; then
2337 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002338else
Martin v. Löwis11437992002-04-12 09:54:03 +00002339 cat >conftest.$ac_ext <<_ACEOF
2340#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002341/* confdefs.h. */
2342_ACEOF
2343cat confdefs.h >>conftest.$ac_ext
2344cat >>conftest.$ac_ext <<_ACEOF
2345/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002346
Martin v. Löwis11437992002-04-12 09:54:03 +00002347int
2348main ()
2349{
2350
2351 ;
2352 return 0;
2353}
2354_ACEOF
2355rm -f conftest.o conftest.obj
2356if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2357 (eval $ac_compile) 2>&5
2358 ac_status=$?
2359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2360 (exit $ac_status); }; then
2361 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2362 case $ac_file in
Skip Montanarod8d39a02003-07-10 20:44:10 +00002363 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002364 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2365 break;;
2366 esac
2367done
2368else
2369 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002370sed 's/^/| /' conftest.$ac_ext >&5
2371
2372{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2373See \`config.log' for more details." >&5
2374echo "$as_me: error: cannot compute suffix of object files: cannot compile
2375See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002376 { (exit 1); exit 1; }; }
2377fi
2378
2379rm -f conftest.$ac_cv_objext conftest.$ac_ext
2380fi
2381echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2382echo "${ECHO_T}$ac_cv_objext" >&6
2383OBJEXT=$ac_cv_objext
2384ac_objext=$OBJEXT
2385echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2386echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2387if test "${ac_cv_c_compiler_gnu+set}" = set; then
2388 echo $ECHO_N "(cached) $ECHO_C" >&6
2389else
2390 cat >conftest.$ac_ext <<_ACEOF
2391#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002392/* confdefs.h. */
2393_ACEOF
2394cat confdefs.h >>conftest.$ac_ext
2395cat >>conftest.$ac_ext <<_ACEOF
2396/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002397
Martin v. Löwis11437992002-04-12 09:54:03 +00002398int
2399main ()
2400{
2401#ifndef __GNUC__
2402 choke me
2403#endif
2404
2405 ;
2406 return 0;
2407}
2408_ACEOF
2409rm -f conftest.$ac_objext
2410if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2411 (eval $ac_compile) 2>&5
2412 ac_status=$?
2413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2414 (exit $ac_status); } &&
2415 { ac_try='test -s conftest.$ac_objext'
2416 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2417 (eval $ac_try) 2>&5
2418 ac_status=$?
2419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2420 (exit $ac_status); }; }; then
2421 ac_compiler_gnu=yes
2422else
2423 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002424sed 's/^/| /' conftest.$ac_ext >&5
2425
Martin v. Löwis11437992002-04-12 09:54:03 +00002426ac_compiler_gnu=no
2427fi
2428rm -f conftest.$ac_objext conftest.$ac_ext
2429ac_cv_c_compiler_gnu=$ac_compiler_gnu
2430
2431fi
2432echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2433echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2434GCC=`test $ac_compiler_gnu = yes && echo yes`
2435ac_test_CFLAGS=${CFLAGS+set}
2436ac_save_CFLAGS=$CFLAGS
2437CFLAGS="-g"
2438echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2439echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2440if test "${ac_cv_prog_cc_g+set}" = set; then
2441 echo $ECHO_N "(cached) $ECHO_C" >&6
2442else
2443 cat >conftest.$ac_ext <<_ACEOF
2444#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002445/* confdefs.h. */
2446_ACEOF
2447cat confdefs.h >>conftest.$ac_ext
2448cat >>conftest.$ac_ext <<_ACEOF
2449/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002450
Martin v. Löwis11437992002-04-12 09:54:03 +00002451int
2452main ()
2453{
2454
2455 ;
2456 return 0;
2457}
2458_ACEOF
2459rm -f conftest.$ac_objext
2460if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2461 (eval $ac_compile) 2>&5
2462 ac_status=$?
2463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2464 (exit $ac_status); } &&
2465 { ac_try='test -s conftest.$ac_objext'
2466 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2467 (eval $ac_try) 2>&5
2468 ac_status=$?
2469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2470 (exit $ac_status); }; }; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002471 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002472else
Martin v. Löwis11437992002-04-12 09:54:03 +00002473 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002474sed 's/^/| /' conftest.$ac_ext >&5
2475
Martin v. Löwis11437992002-04-12 09:54:03 +00002476ac_cv_prog_cc_g=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002477fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002478rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002479fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002480echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2481echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002482if test "$ac_test_CFLAGS" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002483 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002484elif test $ac_cv_prog_cc_g = yes; then
2485 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002486 CFLAGS="-g -O2"
2487 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002488 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002489 fi
2490else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002491 if test "$GCC" = yes; then
2492 CFLAGS="-O2"
2493 else
2494 CFLAGS=
2495 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002496fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00002497echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2498echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2499if test "${ac_cv_prog_cc_stdc+set}" = set; then
2500 echo $ECHO_N "(cached) $ECHO_C" >&6
2501else
2502 ac_cv_prog_cc_stdc=no
2503ac_save_CC=$CC
2504cat >conftest.$ac_ext <<_ACEOF
2505#line $LINENO "configure"
2506/* confdefs.h. */
2507_ACEOF
2508cat confdefs.h >>conftest.$ac_ext
2509cat >>conftest.$ac_ext <<_ACEOF
2510/* end confdefs.h. */
2511#include <stdarg.h>
2512#include <stdio.h>
2513#include <sys/types.h>
2514#include <sys/stat.h>
2515/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
2516struct buf { int x; };
2517FILE * (*rcsopen) (struct buf *, struct stat *, int);
2518static char *e (p, i)
2519 char **p;
2520 int i;
2521{
2522 return p[i];
2523}
2524static char *f (char * (*g) (char **, int), char **p, ...)
2525{
2526 char *s;
2527 va_list v;
2528 va_start (v,p);
2529 s = g (p, va_arg (v,int));
2530 va_end (v);
2531 return s;
2532}
2533int test (int i, double x);
2534struct s1 {int (*f) (int a);};
2535struct s2 {int (*f) (double a);};
2536int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2537int argc;
2538char **argv;
2539int
2540main ()
2541{
2542return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
2543 ;
2544 return 0;
2545}
2546_ACEOF
2547# Don't try gcc -ansi; that turns off useful extensions and
2548# breaks some systems' header files.
2549# AIX -qlanglvl=ansi
2550# Ultrix and OSF/1 -std1
2551# HP-UX 10.20 and later -Ae
2552# HP-UX older versions -Aa -D_HPUX_SOURCE
2553# SVR4 -Xc -D__EXTENSIONS__
2554for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2555do
2556 CC="$ac_save_CC $ac_arg"
2557 rm -f conftest.$ac_objext
2558if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2559 (eval $ac_compile) 2>&5
2560 ac_status=$?
2561 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2562 (exit $ac_status); } &&
2563 { ac_try='test -s conftest.$ac_objext'
2564 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2565 (eval $ac_try) 2>&5
2566 ac_status=$?
2567 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2568 (exit $ac_status); }; }; then
2569 ac_cv_prog_cc_stdc=$ac_arg
2570break
2571else
2572 echo "$as_me: failed program was:" >&5
2573sed 's/^/| /' conftest.$ac_ext >&5
2574
2575fi
2576rm -f conftest.$ac_objext
2577done
2578rm -f conftest.$ac_ext conftest.$ac_objext
2579CC=$ac_save_CC
2580
2581fi
2582
2583case "x$ac_cv_prog_cc_stdc" in
2584 x|xno)
2585 echo "$as_me:$LINENO: result: none needed" >&5
2586echo "${ECHO_T}none needed" >&6 ;;
2587 *)
2588 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2589echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2590 CC="$CC $ac_cv_prog_cc_stdc" ;;
2591esac
2592
Martin v. Löwis11437992002-04-12 09:54:03 +00002593# Some people use a C++ compiler to compile C. Since we use `exit',
2594# in C++ we need to declare it. In case someone uses the same compiler
2595# for both compiling C and C++ we need to have the C++ compiler decide
2596# the declaration of exit, since it's the most demanding environment.
2597cat >conftest.$ac_ext <<_ACEOF
2598#ifndef __cplusplus
2599 choke me
2600#endif
2601_ACEOF
2602rm -f conftest.$ac_objext
2603if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2604 (eval $ac_compile) 2>&5
2605 ac_status=$?
2606 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2607 (exit $ac_status); } &&
2608 { ac_try='test -s conftest.$ac_objext'
2609 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2610 (eval $ac_try) 2>&5
2611 ac_status=$?
2612 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2613 (exit $ac_status); }; }; then
2614 for ac_declaration in \
2615 ''\
2616 '#include <stdlib.h>' \
2617 'extern "C" void std::exit (int) throw (); using std::exit;' \
2618 'extern "C" void std::exit (int); using std::exit;' \
2619 'extern "C" void exit (int) throw ();' \
2620 'extern "C" void exit (int);' \
2621 'void exit (int);'
2622do
2623 cat >conftest.$ac_ext <<_ACEOF
2624#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002625/* confdefs.h. */
2626_ACEOF
2627cat confdefs.h >>conftest.$ac_ext
2628cat >>conftest.$ac_ext <<_ACEOF
2629/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002630#include <stdlib.h>
2631$ac_declaration
Martin v. Löwis11437992002-04-12 09:54:03 +00002632int
2633main ()
2634{
2635exit (42);
2636 ;
2637 return 0;
2638}
2639_ACEOF
2640rm -f conftest.$ac_objext
2641if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2642 (eval $ac_compile) 2>&5
2643 ac_status=$?
2644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2645 (exit $ac_status); } &&
2646 { ac_try='test -s conftest.$ac_objext'
2647 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2648 (eval $ac_try) 2>&5
2649 ac_status=$?
2650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2651 (exit $ac_status); }; }; then
2652 :
2653else
2654 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002655sed 's/^/| /' conftest.$ac_ext >&5
2656
Martin v. Löwis11437992002-04-12 09:54:03 +00002657continue
2658fi
2659rm -f conftest.$ac_objext conftest.$ac_ext
2660 cat >conftest.$ac_ext <<_ACEOF
2661#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002662/* confdefs.h. */
2663_ACEOF
2664cat confdefs.h >>conftest.$ac_ext
2665cat >>conftest.$ac_ext <<_ACEOF
2666/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002667$ac_declaration
Martin v. Löwis11437992002-04-12 09:54:03 +00002668int
2669main ()
2670{
2671exit (42);
2672 ;
2673 return 0;
2674}
2675_ACEOF
2676rm -f conftest.$ac_objext
2677if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2678 (eval $ac_compile) 2>&5
2679 ac_status=$?
2680 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2681 (exit $ac_status); } &&
2682 { ac_try='test -s conftest.$ac_objext'
2683 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2684 (eval $ac_try) 2>&5
2685 ac_status=$?
2686 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2687 (exit $ac_status); }; }; then
2688 break
2689else
2690 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002691sed 's/^/| /' conftest.$ac_ext >&5
2692
Martin v. Löwis11437992002-04-12 09:54:03 +00002693fi
2694rm -f conftest.$ac_objext conftest.$ac_ext
2695done
2696rm -f conftest*
2697if test -n "$ac_declaration"; then
2698 echo '#ifdef __cplusplus' >>confdefs.h
2699 echo $ac_declaration >>confdefs.h
2700 echo '#endif' >>confdefs.h
2701fi
2702
2703else
2704 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002705sed 's/^/| /' conftest.$ac_ext >&5
2706
Martin v. Löwis11437992002-04-12 09:54:03 +00002707fi
2708rm -f conftest.$ac_objext conftest.$ac_ext
2709ac_ext=c
2710ac_cpp='$CPP $CPPFLAGS'
2711ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2712ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2713ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002714
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002715
2716# checks for UNIX variants that set C preprocessor variables
Martin v. Löwis11437992002-04-12 09:54:03 +00002717
2718ac_ext=c
2719ac_cpp='$CPP $CPPFLAGS'
2720ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2721ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2722ac_compiler_gnu=$ac_cv_c_compiler_gnu
2723echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2724echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002725# On Suns, sometimes $CPP names a directory.
2726if test -n "$CPP" && test -d "$CPP"; then
2727 CPP=
2728fi
2729if test -z "$CPP"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002730 if test "${ac_cv_prog_CPP+set}" = set; then
2731 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002732else
Martin v. Löwis11437992002-04-12 09:54:03 +00002733 # Double quotes because CPP needs to be expanded
2734 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2735 do
2736 ac_preproc_ok=false
2737for ac_c_preproc_warn_flag in '' yes
2738do
2739 # Use a header file that comes with gcc, so configuring glibc
2740 # with a fresh cross-compiler works.
Skip Montanarod8d39a02003-07-10 20:44:10 +00002741 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2742 # <limits.h> exists even on freestanding compilers.
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002743 # On the NeXT, cc -E runs the code through the compiler's parser,
Martin v. Löwis11437992002-04-12 09:54:03 +00002744 # not just through cpp. "Syntax error" is here to catch this case.
2745 cat >conftest.$ac_ext <<_ACEOF
2746#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002747/* confdefs.h. */
2748_ACEOF
2749cat confdefs.h >>conftest.$ac_ext
2750cat >>conftest.$ac_ext <<_ACEOF
2751/* end confdefs.h. */
2752#ifdef __STDC__
2753# include <limits.h>
2754#else
2755# include <assert.h>
2756#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00002757 Syntax error
2758_ACEOF
2759if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2760 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2761 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00002762 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00002763 rm -f conftest.er1
2764 cat conftest.err >&5
2765 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2766 (exit $ac_status); } >/dev/null; then
2767 if test -s conftest.err; then
2768 ac_cpp_err=$ac_c_preproc_warn_flag
2769 else
2770 ac_cpp_err=
2771 fi
2772else
2773 ac_cpp_err=yes
2774fi
2775if test -z "$ac_cpp_err"; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002776 :
2777else
Martin v. Löwis11437992002-04-12 09:54:03 +00002778 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002779sed 's/^/| /' conftest.$ac_ext >&5
2780
Martin v. Löwis11437992002-04-12 09:54:03 +00002781 # Broken: fails on valid input.
2782continue
Jack Jansendd19cf82001-12-06 22:36:17 +00002783fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002784rm -f conftest.err conftest.$ac_ext
Jack Jansendd19cf82001-12-06 22:36:17 +00002785
Martin v. Löwis11437992002-04-12 09:54:03 +00002786 # OK, works on sane cases. Now check whether non-existent headers
2787 # can be detected and how.
2788 cat >conftest.$ac_ext <<_ACEOF
2789#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002790/* confdefs.h. */
2791_ACEOF
2792cat confdefs.h >>conftest.$ac_ext
2793cat >>conftest.$ac_ext <<_ACEOF
2794/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002795#include <ac_nonexistent.h>
2796_ACEOF
2797if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2798 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2799 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00002800 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00002801 rm -f conftest.er1
2802 cat conftest.err >&5
2803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2804 (exit $ac_status); } >/dev/null; then
2805 if test -s conftest.err; then
2806 ac_cpp_err=$ac_c_preproc_warn_flag
2807 else
2808 ac_cpp_err=
2809 fi
2810else
2811 ac_cpp_err=yes
2812fi
2813if test -z "$ac_cpp_err"; then
2814 # Broken: success on invalid input.
2815continue
2816else
2817 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002818sed 's/^/| /' conftest.$ac_ext >&5
2819
Martin v. Löwis11437992002-04-12 09:54:03 +00002820 # Passes both tests.
2821ac_preproc_ok=:
2822break
2823fi
2824rm -f conftest.err conftest.$ac_ext
2825
2826done
2827# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2828rm -f conftest.err conftest.$ac_ext
2829if $ac_preproc_ok; then
2830 break
2831fi
2832
2833 done
2834 ac_cv_prog_CPP=$CPP
2835
2836fi
2837 CPP=$ac_cv_prog_CPP
2838else
2839 ac_cv_prog_CPP=$CPP
2840fi
2841echo "$as_me:$LINENO: result: $CPP" >&5
2842echo "${ECHO_T}$CPP" >&6
2843ac_preproc_ok=false
2844for ac_c_preproc_warn_flag in '' yes
2845do
2846 # Use a header file that comes with gcc, so configuring glibc
2847 # with a fresh cross-compiler works.
Skip Montanarod8d39a02003-07-10 20:44:10 +00002848 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2849 # <limits.h> exists even on freestanding compilers.
Martin v. Löwis11437992002-04-12 09:54:03 +00002850 # On the NeXT, cc -E runs the code through the compiler's parser,
2851 # not just through cpp. "Syntax error" is here to catch this case.
2852 cat >conftest.$ac_ext <<_ACEOF
2853#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002854/* confdefs.h. */
2855_ACEOF
2856cat confdefs.h >>conftest.$ac_ext
2857cat >>conftest.$ac_ext <<_ACEOF
2858/* end confdefs.h. */
2859#ifdef __STDC__
2860# include <limits.h>
2861#else
2862# include <assert.h>
2863#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00002864 Syntax error
2865_ACEOF
2866if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2867 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2868 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00002869 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00002870 rm -f conftest.er1
2871 cat conftest.err >&5
2872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2873 (exit $ac_status); } >/dev/null; then
2874 if test -s conftest.err; then
2875 ac_cpp_err=$ac_c_preproc_warn_flag
2876 else
2877 ac_cpp_err=
2878 fi
2879else
2880 ac_cpp_err=yes
2881fi
2882if test -z "$ac_cpp_err"; then
2883 :
2884else
2885 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002886sed 's/^/| /' conftest.$ac_ext >&5
2887
Martin v. Löwis11437992002-04-12 09:54:03 +00002888 # Broken: fails on valid input.
2889continue
2890fi
2891rm -f conftest.err conftest.$ac_ext
2892
2893 # OK, works on sane cases. Now check whether non-existent headers
2894 # can be detected and how.
2895 cat >conftest.$ac_ext <<_ACEOF
2896#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002897/* confdefs.h. */
2898_ACEOF
2899cat confdefs.h >>conftest.$ac_ext
2900cat >>conftest.$ac_ext <<_ACEOF
2901/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002902#include <ac_nonexistent.h>
2903_ACEOF
2904if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2905 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2906 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00002907 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00002908 rm -f conftest.er1
2909 cat conftest.err >&5
2910 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2911 (exit $ac_status); } >/dev/null; then
2912 if test -s conftest.err; then
2913 ac_cpp_err=$ac_c_preproc_warn_flag
2914 else
2915 ac_cpp_err=
2916 fi
2917else
2918 ac_cpp_err=yes
2919fi
2920if test -z "$ac_cpp_err"; then
2921 # Broken: success on invalid input.
2922continue
2923else
2924 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00002925sed 's/^/| /' conftest.$ac_ext >&5
2926
Martin v. Löwis11437992002-04-12 09:54:03 +00002927 # Passes both tests.
2928ac_preproc_ok=:
2929break
2930fi
2931rm -f conftest.err conftest.$ac_ext
2932
2933done
2934# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2935rm -f conftest.err conftest.$ac_ext
2936if $ac_preproc_ok; then
2937 :
2938else
Skip Montanarod8d39a02003-07-10 20:44:10 +00002939 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
2940See \`config.log' for more details." >&5
2941echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
2942See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002943 { (exit 1); exit 1; }; }
2944fi
2945
2946ac_ext=c
2947ac_cpp='$CPP $CPPFLAGS'
2948ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2949ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2950ac_compiler_gnu=$ac_cv_c_compiler_gnu
2951
2952
Skip Montanarod8d39a02003-07-10 20:44:10 +00002953echo "$as_me:$LINENO: checking for egrep" >&5
2954echo $ECHO_N "checking for egrep... $ECHO_C" >&6
2955if test "${ac_cv_prog_egrep+set}" = set; then
2956 echo $ECHO_N "(cached) $ECHO_C" >&6
2957else
2958 if echo a | (grep -E '(a|b)') >/dev/null 2>&1
2959 then ac_cv_prog_egrep='grep -E'
2960 else ac_cv_prog_egrep='egrep'
2961 fi
2962fi
2963echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
2964echo "${ECHO_T}$ac_cv_prog_egrep" >&6
2965 EGREP=$ac_cv_prog_egrep
2966
2967
Martin v. Löwis11437992002-04-12 09:54:03 +00002968
2969echo "$as_me:$LINENO: checking for AIX" >&5
2970echo $ECHO_N "checking for AIX... $ECHO_C" >&6
2971cat >conftest.$ac_ext <<_ACEOF
2972#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00002973/* confdefs.h. */
2974_ACEOF
2975cat confdefs.h >>conftest.$ac_ext
2976cat >>conftest.$ac_ext <<_ACEOF
2977/* end confdefs.h. */
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002978#ifdef _AIX
2979 yes
2980#endif
2981
Martin v. Löwis11437992002-04-12 09:54:03 +00002982_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002983if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00002984 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002985 echo "$as_me:$LINENO: result: yes" >&5
2986echo "${ECHO_T}yes" >&6
2987cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002988#define _ALL_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002989_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002990
2991else
Martin v. Löwis11437992002-04-12 09:54:03 +00002992 echo "$as_me:$LINENO: result: no" >&5
2993echo "${ECHO_T}no" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002994fi
2995rm -f conftest*
2996
Michael W. Hudson54241132001-12-07 15:38:26 +00002997
Martin v. Löwis11437992002-04-12 09:54:03 +00002998echo "$as_me:$LINENO: checking for ANSI C header files" >&5
2999echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
3000if test "${ac_cv_header_stdc+set}" = set; then
3001 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003002else
Martin v. Löwis11437992002-04-12 09:54:03 +00003003 cat >conftest.$ac_ext <<_ACEOF
3004#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003005/* confdefs.h. */
3006_ACEOF
3007cat confdefs.h >>conftest.$ac_ext
3008cat >>conftest.$ac_ext <<_ACEOF
3009/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003010#include <stdlib.h>
3011#include <stdarg.h>
3012#include <string.h>
3013#include <float.h>
3014
Skip Montanarod8d39a02003-07-10 20:44:10 +00003015int
3016main ()
3017{
3018
3019 ;
3020 return 0;
3021}
Martin v. Löwis11437992002-04-12 09:54:03 +00003022_ACEOF
Skip Montanarod8d39a02003-07-10 20:44:10 +00003023rm -f conftest.$ac_objext
3024if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3025 (eval $ac_compile) 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00003026 ac_status=$?
Martin v. Löwis11437992002-04-12 09:54:03 +00003027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003028 (exit $ac_status); } &&
3029 { ac_try='test -s conftest.$ac_objext'
3030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3031 (eval $ac_try) 2>&5
3032 ac_status=$?
3033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3034 (exit $ac_status); }; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003035 ac_cv_header_stdc=yes
3036else
3037 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003038sed 's/^/| /' conftest.$ac_ext >&5
3039
3040ac_cv_header_stdc=no
Martin v. Löwis11437992002-04-12 09:54:03 +00003041fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00003042rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00003043
3044if test $ac_cv_header_stdc = yes; then
3045 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3046 cat >conftest.$ac_ext <<_ACEOF
3047#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003048/* confdefs.h. */
3049_ACEOF
3050cat confdefs.h >>conftest.$ac_ext
3051cat >>conftest.$ac_ext <<_ACEOF
3052/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003053#include <string.h>
3054
3055_ACEOF
3056if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00003057 $EGREP "memchr" >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003058 :
3059else
3060 ac_cv_header_stdc=no
3061fi
3062rm -f conftest*
3063
3064fi
3065
3066if test $ac_cv_header_stdc = yes; then
3067 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3068 cat >conftest.$ac_ext <<_ACEOF
3069#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003070/* confdefs.h. */
3071_ACEOF
3072cat confdefs.h >>conftest.$ac_ext
3073cat >>conftest.$ac_ext <<_ACEOF
3074/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003075#include <stdlib.h>
3076
3077_ACEOF
3078if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00003079 $EGREP "free" >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003080 :
3081else
3082 ac_cv_header_stdc=no
3083fi
3084rm -f conftest*
3085
3086fi
3087
3088if test $ac_cv_header_stdc = yes; then
3089 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3090 if test "$cross_compiling" = yes; then
3091 :
3092else
3093 cat >conftest.$ac_ext <<_ACEOF
3094#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003095/* confdefs.h. */
3096_ACEOF
3097cat confdefs.h >>conftest.$ac_ext
3098cat >>conftest.$ac_ext <<_ACEOF
3099/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003100#include <ctype.h>
3101#if ((' ' & 0x0FF) == 0x020)
3102# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3103# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3104#else
Skip Montanarod8d39a02003-07-10 20:44:10 +00003105# define ISLOWER(c) \
3106 (('a' <= (c) && (c) <= 'i') \
Martin v. Löwis11437992002-04-12 09:54:03 +00003107 || ('j' <= (c) && (c) <= 'r') \
3108 || ('s' <= (c) && (c) <= 'z'))
3109# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3110#endif
3111
3112#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3113int
3114main ()
3115{
3116 int i;
3117 for (i = 0; i < 256; i++)
3118 if (XOR (islower (i), ISLOWER (i))
3119 || toupper (i) != TOUPPER (i))
3120 exit(2);
3121 exit (0);
3122}
3123_ACEOF
3124rm -f conftest$ac_exeext
3125if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3126 (eval $ac_link) 2>&5
3127 ac_status=$?
3128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3129 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3131 (eval $ac_try) 2>&5
3132 ac_status=$?
3133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3134 (exit $ac_status); }; }; then
3135 :
3136else
3137 echo "$as_me: program exited with status $ac_status" >&5
3138echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003139sed 's/^/| /' conftest.$ac_ext >&5
3140
Martin v. Löwis11437992002-04-12 09:54:03 +00003141( exit $ac_status )
3142ac_cv_header_stdc=no
3143fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00003144rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00003145fi
3146fi
3147fi
3148echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3149echo "${ECHO_T}$ac_cv_header_stdc" >&6
3150if test $ac_cv_header_stdc = yes; then
3151
3152cat >>confdefs.h <<\_ACEOF
3153#define STDC_HEADERS 1
3154_ACEOF
3155
3156fi
3157
3158# On IRIX 5.3, sys/types and inttypes.h are conflicting.
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3169 inttypes.h stdint.h unistd.h
3170do
3171as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3172echo "$as_me:$LINENO: checking for $ac_header" >&5
3173echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3174if eval "test \"\${$as_ac_Header+set}\" = set"; then
3175 echo $ECHO_N "(cached) $ECHO_C" >&6
3176else
3177 cat >conftest.$ac_ext <<_ACEOF
3178#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003179/* confdefs.h. */
3180_ACEOF
3181cat confdefs.h >>conftest.$ac_ext
3182cat >>conftest.$ac_ext <<_ACEOF
3183/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003184$ac_includes_default
3185
3186#include <$ac_header>
3187_ACEOF
3188rm -f conftest.$ac_objext
3189if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3190 (eval $ac_compile) 2>&5
3191 ac_status=$?
3192 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3193 (exit $ac_status); } &&
3194 { ac_try='test -s conftest.$ac_objext'
3195 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3196 (eval $ac_try) 2>&5
3197 ac_status=$?
3198 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3199 (exit $ac_status); }; }; then
3200 eval "$as_ac_Header=yes"
3201else
3202 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003203sed 's/^/| /' conftest.$ac_ext >&5
3204
Martin v. Löwis11437992002-04-12 09:54:03 +00003205eval "$as_ac_Header=no"
3206fi
3207rm -f conftest.$ac_objext conftest.$ac_ext
3208fi
3209echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3210echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
3211if test `eval echo '${'$as_ac_Header'}'` = yes; then
3212 cat >>confdefs.h <<_ACEOF
3213#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3214_ACEOF
3215
3216fi
3217
3218done
3219
3220
3221if test "${ac_cv_header_minix_config_h+set}" = set; then
3222 echo "$as_me:$LINENO: checking for minix/config.h" >&5
3223echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
3224if test "${ac_cv_header_minix_config_h+set}" = set; then
3225 echo $ECHO_N "(cached) $ECHO_C" >&6
3226fi
3227echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
3228echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
3229else
3230 # Is the header compilable?
3231echo "$as_me:$LINENO: checking minix/config.h usability" >&5
3232echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6
3233cat >conftest.$ac_ext <<_ACEOF
3234#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003235/* confdefs.h. */
3236_ACEOF
3237cat confdefs.h >>conftest.$ac_ext
3238cat >>conftest.$ac_ext <<_ACEOF
3239/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003240$ac_includes_default
3241#include <minix/config.h>
3242_ACEOF
3243rm -f conftest.$ac_objext
3244if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3245 (eval $ac_compile) 2>&5
3246 ac_status=$?
3247 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3248 (exit $ac_status); } &&
3249 { ac_try='test -s conftest.$ac_objext'
3250 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3251 (eval $ac_try) 2>&5
3252 ac_status=$?
3253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3254 (exit $ac_status); }; }; then
3255 ac_header_compiler=yes
3256else
3257 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003258sed 's/^/| /' conftest.$ac_ext >&5
3259
Martin v. Löwis11437992002-04-12 09:54:03 +00003260ac_header_compiler=no
3261fi
3262rm -f conftest.$ac_objext conftest.$ac_ext
3263echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
3264echo "${ECHO_T}$ac_header_compiler" >&6
3265
3266# Is the header present?
3267echo "$as_me:$LINENO: checking minix/config.h presence" >&5
3268echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6
3269cat >conftest.$ac_ext <<_ACEOF
3270#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003271/* confdefs.h. */
3272_ACEOF
3273cat confdefs.h >>conftest.$ac_ext
3274cat >>conftest.$ac_ext <<_ACEOF
3275/* end confdefs.h. */
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003276#include <minix/config.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003277_ACEOF
3278if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3279 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3280 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00003281 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003282 rm -f conftest.er1
3283 cat conftest.err >&5
3284 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3285 (exit $ac_status); } >/dev/null; then
3286 if test -s conftest.err; then
3287 ac_cpp_err=$ac_c_preproc_warn_flag
3288 else
3289 ac_cpp_err=
3290 fi
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003291else
Martin v. Löwis11437992002-04-12 09:54:03 +00003292 ac_cpp_err=yes
3293fi
3294if test -z "$ac_cpp_err"; then
3295 ac_header_preproc=yes
3296else
3297 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003298sed 's/^/| /' conftest.$ac_ext >&5
3299
Martin v. Löwis11437992002-04-12 09:54:03 +00003300 ac_header_preproc=no
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003301fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003302rm -f conftest.err conftest.$ac_ext
3303echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
3304echo "${ECHO_T}$ac_header_preproc" >&6
3305
3306# So? What about this header?
3307case $ac_header_compiler:$ac_header_preproc in
3308 yes:no )
3309 { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
3310echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
3311 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003312echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;}
3313 (
3314 cat <<\_ASBOX
3315## ------------------------------------ ##
3316## Report this to bug-autoconf@gnu.org. ##
3317## ------------------------------------ ##
3318_ASBOX
3319 ) |
3320 sed "s/^/$as_me: WARNING: /" >&2
3321 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00003322 no:yes )
3323 { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
3324echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
3325 { echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5
3326echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;}
3327 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003328echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;}
3329 (
3330 cat <<\_ASBOX
3331## ------------------------------------ ##
3332## Report this to bug-autoconf@gnu.org. ##
3333## ------------------------------------ ##
3334_ASBOX
3335 ) |
3336 sed "s/^/$as_me: WARNING: /" >&2
3337 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00003338esac
3339echo "$as_me:$LINENO: checking for minix/config.h" >&5
3340echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
3341if test "${ac_cv_header_minix_config_h+set}" = set; then
3342 echo $ECHO_N "(cached) $ECHO_C" >&6
3343else
3344 ac_cv_header_minix_config_h=$ac_header_preproc
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003345fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003346echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
3347echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
3348
3349fi
3350if test $ac_cv_header_minix_config_h = yes; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003351 MINIX=yes
3352else
Martin v. Löwis11437992002-04-12 09:54:03 +00003353 MINIX=
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003354fi
3355
Martin v. Löwis11437992002-04-12 09:54:03 +00003356
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003357if test "$MINIX" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003358
3359cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003360#define _POSIX_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003361_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003362
Martin v. Löwis11437992002-04-12 09:54:03 +00003363
3364cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003365#define _POSIX_1_SOURCE 2
Martin v. Löwis11437992002-04-12 09:54:03 +00003366_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003367
Martin v. Löwis11437992002-04-12 09:54:03 +00003368
3369cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003370#define _MINIX 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003371_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003372
3373fi
3374
3375
Martin v. Löwis779ffc02002-12-02 22:17:01 +00003376# Check for unsupported systems
3377case $ac_sys_system/$ac_sys_release in
3378SunOS/4*|DYNIX/*|dgux*/*|IRIX/4*|Linux*/1*)
3379 echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
3380 echo See README for details.
3381 exit 1;;
3382esac
3383
3384if test "$MINIX" = yes; then
3385 echo This system \(MINIX\) is no longer supported.
3386 echo Read README for details.
3387 exit 1
3388fi
3389
Michael W. Hudson54241132001-12-07 15:38:26 +00003390
Martin v. Löwis11437992002-04-12 09:54:03 +00003391echo "$as_me:$LINENO: checking for --with-suffix" >&5
3392echo $ECHO_N "checking for --with-suffix... $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00003393
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00003394# Check whether --with-suffix or --without-suffix was given.
3395if test "${with_suffix+set}" = set; then
3396 withval="$with_suffix"
Martin v. Löwis11437992002-04-12 09:54:03 +00003397
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00003398 case $withval in
3399 no) EXEEXT=;;
3400 yes) EXEEXT=.exe;;
3401 *) EXEEXT=$withval;;
3402 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00003403fi;
3404echo "$as_me:$LINENO: result: $EXEEXT" >&5
3405echo "${ECHO_T}$EXEEXT" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00003406
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003407# Test whether we're running on a non-case-sensitive system, in which
3408# case we give a warning if no ext is given
Jack Jansen1999ef42001-12-06 21:47:20 +00003409
Martin v. Löwis11437992002-04-12 09:54:03 +00003410echo "$as_me:$LINENO: checking for case-insensitive build directory" >&5
3411echo $ECHO_N "checking for case-insensitive build directory... $ECHO_C" >&6
Jack Jansen3c2c4332002-11-06 13:33:32 +00003412if test ! -d CaseSensitiveTestDir; then
3413mkdir CaseSensitiveTestDir
3414fi
3415
3416if test -d casesensitivetestdir
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003417then
Martin v. Löwis11437992002-04-12 09:54:03 +00003418 echo "$as_me:$LINENO: result: yes" >&5
3419echo "${ECHO_T}yes" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00003420 BUILDEXEEXT=.exe
3421else
Martin v. Löwis11437992002-04-12 09:54:03 +00003422 echo "$as_me:$LINENO: result: no" >&5
3423echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00003424 BUILDEXEEXT=$EXEEXT
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003425fi
Jack Jansen3c2c4332002-11-06 13:33:32 +00003426rmdir CaseSensitiveTestDir
Guido van Rossumff555e32000-09-22 15:38:21 +00003427
Guido van Rossumdd997f71998-10-07 19:58:26 +00003428case $MACHDEP in
3429bsdos*)
3430 case $CC in
3431 gcc) CC="$CC -D_HAVE_BSDI";;
3432 esac;;
3433esac
3434
Guido van Rossum24b1e751997-08-21 02:29:16 +00003435case $ac_sys_system in
3436hp*|HP*)
3437 case $CC in
Guido van Rossumcd5ff9f2000-09-22 16:15:54 +00003438 cc|*/cc) CC="$CC -Ae";;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003439 esac;;
Trent Mick635f6fb2000-08-23 21:33:05 +00003440Monterey*)
3441 case $CC in
3442 cc) CC="$CC -Wl,-Bexport";;
3443 esac;;
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003444SunOS*)
3445 # Some functions have a prototype only with that define, e.g. confstr
Martin v. Löwis11437992002-04-12 09:54:03 +00003446
3447cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003448#define __EXTENSIONS__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003449_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003450
3451 ;;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003452esac
3453
Michael W. Hudson54241132001-12-07 15:38:26 +00003454
3455
Martin v. Löwis11437992002-04-12 09:54:03 +00003456echo "$as_me:$LINENO: checking LIBRARY" >&5
3457echo $ECHO_N "checking LIBRARY... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003458if test -z "$LIBRARY"
3459then
3460 LIBRARY='libpython$(VERSION).a'
3461fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003462echo "$as_me:$LINENO: result: $LIBRARY" >&5
3463echo "${ECHO_T}$LIBRARY" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003464
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003465# LDLIBRARY is the name of the library to link against (as opposed to the
Jack Jansene578a632001-08-15 01:27:14 +00003466# name of the library into which to insert object files). BLDLIBRARY is also
3467# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
3468# is blank as the main program is not linked directly against LDLIBRARY.
3469# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
3470# systems without shared libraries, LDLIBRARY is the same as LIBRARY
3471# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
3472# DLLLIBRARY is the shared (i.e., DLL) library.
Martin v. Löwis11437992002-04-12 09:54:03 +00003473#
Martin v. Löwis1142de32002-03-29 16:28:31 +00003474# RUNSHARED is used to run shared python without installed libraries
3475#
3476# INSTSONAME is the name of the shared library that will be use to install
3477# on the system - some systems like version suffix, others don't
3478
3479
Michael W. Hudson54241132001-12-07 15:38:26 +00003480
3481
3482
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003483
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003484LDLIBRARY="$LIBRARY"
Jack Jansene578a632001-08-15 01:27:14 +00003485BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis09bdf722002-05-08 08:51:29 +00003486INSTSONAME='$(LDLIBRARY)'
Guido van Rossumca563f22001-01-23 01:52:44 +00003487DLLLIBRARY=''
Jack Jansene578a632001-08-15 01:27:14 +00003488LDLIBRARYDIR=''
Martin v. Löwis1142de32002-03-29 16:28:31 +00003489RUNSHARED=''
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003490
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003491# LINKCC is the command that links the python executable -- default is $(CC).
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003492# If CXX is set, and if it is needed to link a main function that was
3493# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
3494# python might then depend on the C++ runtime
Martin v. Löwis11437992002-04-12 09:54:03 +00003495# This is altered for AIX in order to build the export list before
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003496# linking.
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003497
Martin v. Löwis11437992002-04-12 09:54:03 +00003498echo "$as_me:$LINENO: checking LINKCC" >&5
3499echo $ECHO_N "checking LINKCC... $ECHO_C" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003500if test -z "$LINKCC"
3501then
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003502 if test -z "$CXX"; then
3503 LINKCC="\$(PURIFY) \$(CC)"
3504 else
Martin v. Löwis1931ca72002-06-01 21:39:58 +00003505 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003506 $CXX -c conftest.$ac_ext 2>&5
3507 if $CC -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
3508 && test -s conftest$ac_exeext && ./conftest$ac_exeext
3509 then
3510 LINKCC="\$(PURIFY) \$(CC)"
3511 else
3512 LINKCC="\$(PURIFY) \$(CXX)"
3513 fi
3514 rm -fr conftest*
3515 fi
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003516 case $ac_sys_system in
3517 AIX*)
Neal Norwitz0b27ff92003-03-31 15:53:49 +00003518 exp_extra="\"\""
3519 if test $ac_sys_release -ge 5 -o \
3520 $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then
3521 exp_extra="."
3522 fi
3523 LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00003524 dgux*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003525 LINKCC="LD_RUN_PATH=$libdir $LINKCC";;
Trent Mick635f6fb2000-08-23 21:33:05 +00003526 Monterey64*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003527 LINKCC="$LINKCC -L/usr/lib/ia64l64";;
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003528 esac
3529fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003530echo "$as_me:$LINENO: result: $LINKCC" >&5
3531echo "${ECHO_T}$LINKCC" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003532
Martin v. Löwis11437992002-04-12 09:54:03 +00003533echo "$as_me:$LINENO: checking for --enable-shared" >&5
3534echo $ECHO_N "checking for --enable-shared... $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003535# Check whether --enable-shared or --disable-shared was given.
3536if test "${enable_shared+set}" = set; then
3537 enableval="$enable_shared"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003538
Martin v. Löwis11437992002-04-12 09:54:03 +00003539fi;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003540
3541if test -z "$enable_shared"
Martin v. Löwis11437992002-04-12 09:54:03 +00003542then
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003543 case $ac_sys_system in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003544 CYGWIN* | atheos*)
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003545 enable_shared="yes";;
3546 *)
3547 enable_shared="no";;
3548 esac
Martin v. Löwis1142de32002-03-29 16:28:31 +00003549fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003550echo "$as_me:$LINENO: result: $enable_shared" >&5
3551echo "${ECHO_T}$enable_shared" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003552
3553
Martin v. Löwis11437992002-04-12 09:54:03 +00003554echo "$as_me:$LINENO: checking LDLIBRARY" >&5
3555echo $ECHO_N "checking LDLIBRARY... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00003556
Guido van Rossumb8552162001-09-05 14:58:11 +00003557# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
3558# library that we build, but we do not want to link against it (we
3559# will find it with a -framework option). For this reason there is an
3560# extra variable BLDLIBRARY against which Python and the extension
3561# modules are linked, BLDLIBRARY. This is normally the same as
3562# LDLIBRARY, but empty for MacOSX framework builds.
Jack Jansene578a632001-08-15 01:27:14 +00003563if test "$enable_framework"
3564then
3565 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansen66b84832003-07-04 12:14:39 +00003566 RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH"
Jack Jansene578a632001-08-15 01:27:14 +00003567 BLDLIBRARY=''
3568else
3569 BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis11437992002-04-12 09:54:03 +00003570fi
Jack Jansene578a632001-08-15 01:27:14 +00003571
Martin v. Löwis1142de32002-03-29 16:28:31 +00003572# Other platforms follow
3573if test $enable_shared = "yes"; then
Mark Hammond8235ea12002-07-19 06:55:41 +00003574
3575cat >>confdefs.h <<\_ACEOF
3576#define Py_ENABLE_SHARED 1
3577_ACEOF
3578
Martin v. Löwis1142de32002-03-29 16:28:31 +00003579 case $ac_sys_system in
3580 BeOS*)
3581 LDLIBRARY='libpython$(VERSION).so'
3582 ;;
3583 CYGWIN*)
3584 LDLIBRARY='libpython$(VERSION).dll.a'
3585 DLLLIBRARY='libpython$(VERSION).dll'
3586 ;;
3587 SunOS*)
3588 LDLIBRARY='libpython$(VERSION).so'
Martin v. Löwisd141a8c2003-06-14 15:20:28 +00003589 BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)'
Martin v. Löwis1142de32002-03-29 16:28:31 +00003590 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3591 ;;
Martin v. Löwis96ce8052003-05-31 07:58:45 +00003592 Linux*|GNU*|NetBSD*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00003593 LDLIBRARY='libpython$(VERSION).so'
3594 BLDLIBRARY='-L. -lpython$(VERSION)'
3595 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3596 INSTSONAME="$LDLIBRARY".$SOVERSION
3597 ;;
3598 hp*|HP*)
3599 LDLIBRARY='libpython$(VERSION).sl'
3600 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
3601 RUNSHARED=SHLIB_PATH=`pwd`:$SHLIB_PATH
3602 ;;
3603 OSF*)
3604 LDLIBRARY='libpython$(VERSION).so'
3605 BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
3606 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3607 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003608 atheos*)
3609 LDLIBRARY='libpython$(VERSION).so'
3610 BLDLIBRARY='-L. -lpython$(VERSION)'
3611 RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
3612 ;;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003613 esac
3614 # DG/UX requires some fancy ld contortions to produce a .so from an .a
3615 case $MACHDEP in
3616 dguxR4)
3617 LDLIBRARY='libpython$(VERSION).so'
Skip Montanarodecc6a42003-01-01 20:07:49 +00003618 BASECFLAGS="$BASECFLAGS -pic"
Martin v. Löwis1142de32002-03-29 16:28:31 +00003619 ;;
3620 esac
3621fi
3622
Martin v. Löwis11437992002-04-12 09:54:03 +00003623echo "$as_me:$LINENO: result: $LDLIBRARY" >&5
3624echo "${ECHO_T}$LDLIBRARY" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003625
Martin v. Löwis11437992002-04-12 09:54:03 +00003626if test -n "$ac_tool_prefix"; then
3627 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3628set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3629echo "$as_me:$LINENO: checking for $ac_word" >&5
3630echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3631if test "${ac_cv_prog_RANLIB+set}" = set; then
3632 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003633else
3634 if test -n "$RANLIB"; then
3635 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3636else
Martin v. Löwis11437992002-04-12 09:54:03 +00003637as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3638for as_dir in $PATH
3639do
3640 IFS=$as_save_IFS
3641 test -z "$as_dir" && as_dir=.
3642 for ac_exec_ext in '' $ac_executable_extensions; do
3643 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3644 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3645 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3646 break 2
3647 fi
3648done
3649done
3650
Guido van Rossum627b2d71993-12-24 10:39:16 +00003651fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003652fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003653RANLIB=$ac_cv_prog_RANLIB
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003654if test -n "$RANLIB"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003655 echo "$as_me:$LINENO: result: $RANLIB" >&5
3656echo "${ECHO_T}$RANLIB" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003657else
Martin v. Löwis11437992002-04-12 09:54:03 +00003658 echo "$as_me:$LINENO: result: no" >&5
3659echo "${ECHO_T}no" >&6
3660fi
3661
3662fi
3663if test -z "$ac_cv_prog_RANLIB"; then
3664 ac_ct_RANLIB=$RANLIB
3665 # Extract the first word of "ranlib", so it can be a program name with args.
3666set dummy ranlib; ac_word=$2
3667echo "$as_me:$LINENO: checking for $ac_word" >&5
3668echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3669if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3670 echo $ECHO_N "(cached) $ECHO_C" >&6
3671else
3672 if test -n "$ac_ct_RANLIB"; then
3673 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3674else
3675as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3676for as_dir in $PATH
3677do
3678 IFS=$as_save_IFS
3679 test -z "$as_dir" && as_dir=.
3680 for ac_exec_ext in '' $ac_executable_extensions; do
3681 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3682 ac_cv_prog_ac_ct_RANLIB="ranlib"
3683 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3684 break 2
3685 fi
3686done
3687done
3688
3689 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3690fi
3691fi
3692ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3693if test -n "$ac_ct_RANLIB"; then
3694 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3695echo "${ECHO_T}$ac_ct_RANLIB" >&6
3696else
3697 echo "$as_me:$LINENO: result: no" >&5
3698echo "${ECHO_T}no" >&6
3699fi
3700
3701 RANLIB=$ac_ct_RANLIB
3702else
3703 RANLIB="$ac_cv_prog_RANLIB"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003704fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003705
3706
Guido van Rossum7f43da71994-08-01 12:15:30 +00003707for ac_prog in ar aal
3708do
Martin v. Löwis11437992002-04-12 09:54:03 +00003709 # Extract the first word of "$ac_prog", so it can be a program name with args.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003710set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00003711echo "$as_me:$LINENO: checking for $ac_word" >&5
3712echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3713if test "${ac_cv_prog_AR+set}" = set; then
3714 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003715else
3716 if test -n "$AR"; then
3717 ac_cv_prog_AR="$AR" # Let the user override the test.
3718else
Martin v. Löwis11437992002-04-12 09:54:03 +00003719as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3720for as_dir in $PATH
3721do
3722 IFS=$as_save_IFS
3723 test -z "$as_dir" && as_dir=.
3724 for ac_exec_ext in '' $ac_executable_extensions; do
3725 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3726 ac_cv_prog_AR="$ac_prog"
3727 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3728 break 2
3729 fi
3730done
3731done
3732
Guido van Rossum7f43da71994-08-01 12:15:30 +00003733fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003734fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003735AR=$ac_cv_prog_AR
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003736if test -n "$AR"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003737 echo "$as_me:$LINENO: result: $AR" >&5
3738echo "${ECHO_T}$AR" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003739else
Martin v. Löwis11437992002-04-12 09:54:03 +00003740 echo "$as_me:$LINENO: result: no" >&5
3741echo "${ECHO_T}no" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003742fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003743
Martin v. Löwis11437992002-04-12 09:54:03 +00003744 test -n "$AR" && break
Guido van Rossum7f43da71994-08-01 12:15:30 +00003745done
3746test -n "$AR" || AR="ar"
3747
Michael W. Hudson54241132001-12-07 15:38:26 +00003748
Neil Schemenauera42c8272001-03-31 00:01:55 +00003749case $MACHDEP in
Neil Schemenaueraf5567f2001-10-21 22:32:04 +00003750bsdos*|hp*|HP*)
3751 # install -d does not work on BSDI or HP-UX
Neil Schemenauera42c8272001-03-31 00:01:55 +00003752 if test -z "$INSTALL"
3753 then
3754 INSTALL="${srcdir}/install-sh -c"
3755 fi
3756esac
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003757ac_aux_dir=
3758for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
3759 if test -f $ac_dir/install-sh; then
3760 ac_aux_dir=$ac_dir
3761 ac_install_sh="$ac_aux_dir/install-sh -c"
3762 break
3763 elif test -f $ac_dir/install.sh; then
3764 ac_aux_dir=$ac_dir
3765 ac_install_sh="$ac_aux_dir/install.sh -c"
3766 break
Martin v. Löwis11437992002-04-12 09:54:03 +00003767 elif test -f $ac_dir/shtool; then
3768 ac_aux_dir=$ac_dir
3769 ac_install_sh="$ac_aux_dir/shtool install -c"
3770 break
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003771 fi
3772done
3773if test -z "$ac_aux_dir"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003774 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
3775echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
3776 { (exit 1); exit 1; }; }
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003777fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003778ac_config_guess="$SHELL $ac_aux_dir/config.guess"
3779ac_config_sub="$SHELL $ac_aux_dir/config.sub"
3780ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003781
3782# Find a good install program. We prefer a C program (faster),
3783# so one script is as good as another. But avoid the broken or
3784# incompatible versions:
3785# SysV /etc/install, /usr/sbin/install
3786# SunOS /usr/etc/install
3787# IRIX /sbin/install
3788# AIX /bin/install
Martin v. Löwis11437992002-04-12 09:54:03 +00003789# AmigaOS /C/install, which installs bootblocks on floppy discs
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003790# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3791# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3792# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3793# ./install, which can be erroneously created by make from ./install.sh.
Martin v. Löwis11437992002-04-12 09:54:03 +00003794echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3795echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003796if test -z "$INSTALL"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003797if test "${ac_cv_path_install+set}" = set; then
3798 echo $ECHO_N "(cached) $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003799else
Martin v. Löwis11437992002-04-12 09:54:03 +00003800 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3801for as_dir in $PATH
3802do
3803 IFS=$as_save_IFS
3804 test -z "$as_dir" && as_dir=.
3805 # Account for people who put trailing slashes in PATH elements.
3806case $as_dir/ in
3807 ./ | .// | /cC/* | \
3808 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3809 /usr/ucb/* ) ;;
3810 *)
3811 # OSF1 and SCO ODT 3.0 have their own names for install.
3812 # Don't use installbsd from OSF since it installs stuff as root
3813 # by default.
3814 for ac_prog in ginstall scoinst install; do
3815 for ac_exec_ext in '' $ac_executable_extensions; do
3816 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3817 if test $ac_prog = install &&
3818 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3819 # AIX install. It has an incompatible calling convention.
3820 :
3821 elif test $ac_prog = install &&
3822 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3823 # program-specific install script used by HP pwplus--don't use.
3824 :
3825 else
3826 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3827 break 3
3828 fi
3829 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003830 done
Martin v. Löwis11437992002-04-12 09:54:03 +00003831 done
3832 ;;
3833esac
3834done
3835
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003836
3837fi
3838 if test "${ac_cv_path_install+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003839 INSTALL=$ac_cv_path_install
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003840 else
3841 # As a last resort, use the slow shell script. We don't cache a
3842 # path for INSTALL within a source directory, because that will
3843 # break other packages using the cache if that directory is
3844 # removed, or if the path is relative.
Martin v. Löwis11437992002-04-12 09:54:03 +00003845 INSTALL=$ac_install_sh
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003846 fi
3847fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003848echo "$as_me:$LINENO: result: $INSTALL" >&5
3849echo "${ECHO_T}$INSTALL" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003850
3851# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3852# It thinks the first close brace ends the variable substitution.
3853test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3854
Martin v. Löwis11437992002-04-12 09:54:03 +00003855test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003856
3857test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3858
Michael W. Hudson54241132001-12-07 15:38:26 +00003859
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003860# Not every filesystem supports hard links
3861
3862if test -z "$LN" ; then
3863 case $ac_sys_system in
3864 BeOS*) LN="ln -s";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00003865 CYGWIN*) LN="ln -s";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003866 atheos*) LN="ln -s";;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003867 *) LN=ln;;
3868 esac
3869fi
3870
Fred Drake109d9862001-07-11 06:27:56 +00003871# Check for --with-pydebug
Martin v. Löwis11437992002-04-12 09:54:03 +00003872echo "$as_me:$LINENO: checking for --with-pydebug" >&5
3873echo $ECHO_N "checking for --with-pydebug... $ECHO_C" >&6
3874
Fred Drake109d9862001-07-11 06:27:56 +00003875# Check whether --with-pydebug or --without-pydebug was given.
3876if test "${with_pydebug+set}" = set; then
3877 withval="$with_pydebug"
Martin v. Löwis11437992002-04-12 09:54:03 +00003878
Fred Drake109d9862001-07-11 06:27:56 +00003879if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +00003880then
3881
3882cat >>confdefs.h <<\_ACEOF
Fred Drake109d9862001-07-11 06:27:56 +00003883#define Py_DEBUG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003884_ACEOF
3885
3886 echo "$as_me:$LINENO: result: yes" >&5
3887echo "${ECHO_T}yes" >&6;
Martin v. Löwisc45929e2002-04-06 10:10:49 +00003888 Py_DEBUG='true'
Martin v. Löwis11437992002-04-12 09:54:03 +00003889else echo "$as_me:$LINENO: result: no" >&5
3890echo "${ECHO_T}no" >&6; Py_DEBUG='false'
Fred Drake109d9862001-07-11 06:27:56 +00003891fi
3892else
Martin v. Löwis11437992002-04-12 09:54:03 +00003893 echo "$as_me:$LINENO: result: no" >&5
3894echo "${ECHO_T}no" >&6
3895fi;
Fred Drake109d9862001-07-11 06:27:56 +00003896
Skip Montanarodecc6a42003-01-01 20:07:49 +00003897# XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be
3898# merged with this chunk of code?
3899
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003900# Optimizer/debugger flags
Skip Montanarodecc6a42003-01-01 20:07:49 +00003901# ------------------------
3902# (The following bit of code is complicated enough - please keep things
3903# indented properly. Just pretend you're editing Python code. ;-)
3904
3905# There are two parallel sets of case statements below, one that checks to
3906# see if OPT was set and one that does BASECFLAGS setting based upon
3907# compiler and platform. BASECFLAGS tweaks need to be made even if the
3908# user set OPT.
3909
3910# tweak OPT based on compiler and platform, only if the user didn't set
3911# it on the command line
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003912
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003913if test -z "$OPT"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003914then
Skip Montanarodecc6a42003-01-01 20:07:49 +00003915 case $GCC in
3916 yes)
3917 case $ac_cv_prog_cc_g in
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003918 yes)
Fred Drake109d9862001-07-11 06:27:56 +00003919 if test "$Py_DEBUG" = 'true' ; then
3920 # Optimization messes up debuggers, so turn it off for
3921 # debug builds.
3922 OPT="-g -Wall -Wstrict-prototypes"
3923 else
3924 OPT="-g -O3 -Wall -Wstrict-prototypes"
Skip Montanarodecc6a42003-01-01 20:07:49 +00003925 fi
3926 ;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003927 *)
Skip Montanarodecc6a42003-01-01 20:07:49 +00003928 OPT="-O3 -Wall -Wstrict-prototypes"
3929 ;;
Fred Drake109d9862001-07-11 06:27:56 +00003930 esac
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003931 case $ac_sys_system in
Skip Montanarodecc6a42003-01-01 20:07:49 +00003932 SCO_SV*) OPT="$OPT -m486 -DSCO5"
3933 ;;
3934 esac
Fred Drake109d9862001-07-11 06:27:56 +00003935 ;;
Skip Montanarodecc6a42003-01-01 20:07:49 +00003936
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003937 *)
Skip Montanarodecc6a42003-01-01 20:07:49 +00003938 OPT="-O"
3939 ;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003940 esac
Skip Montanarodecc6a42003-01-01 20:07:49 +00003941
3942 # The current (beta) Monterey compiler dies with optimizations
3943 # XXX what is Monterey? Does it still die w/ -O? Can we get rid of this?
Jack Jansenca06bc62001-08-03 15:32:23 +00003944 case $ac_sys_system in
Skip Montanarodecc6a42003-01-01 20:07:49 +00003945 Monterey*)
3946 OPT=""
3947 ;;
Jack Jansenca06bc62001-08-03 15:32:23 +00003948 esac
Skip Montanarodecc6a42003-01-01 20:07:49 +00003949
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003950fi
3951
Skip Montanarodecc6a42003-01-01 20:07:49 +00003952
3953# tweak BASECFLAGS based on compiler and platform
3954case $GCC in
3955yes)
Martin v. Löwis70fedcd2003-07-07 21:26:19 +00003956 # Python violates C99 rules, by casting between incompatible
3957 # pointer types. GCC may generate bad code as a result of that,
3958 # so use -fno-strict-aliasing if supported.
3959 echo "$as_me:$LINENO: checking whether $CC accepts -fno-strict-aliasing" >&5
3960echo $ECHO_N "checking whether $CC accepts -fno-strict-aliasing... $ECHO_C" >&6
3961 ac_save_cc="$CC"
3962 CC="$CC -fno-strict-aliasing"
3963 if test "$cross_compiling" = yes; then
3964 ac_cv_no_strict_aliasing_ok=no
3965else
3966 cat >conftest.$ac_ext <<_ACEOF
3967#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00003968/* confdefs.h. */
3969_ACEOF
3970cat confdefs.h >>conftest.$ac_ext
3971cat >>conftest.$ac_ext <<_ACEOF
3972/* end confdefs.h. */
Martin v. Löwis70fedcd2003-07-07 21:26:19 +00003973int main() { return 0; }
3974_ACEOF
3975rm -f conftest$ac_exeext
3976if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3977 (eval $ac_link) 2>&5
3978 ac_status=$?
3979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3980 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3981 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3982 (eval $ac_try) 2>&5
3983 ac_status=$?
3984 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3985 (exit $ac_status); }; }; then
3986 ac_cv_no_strict_aliasing_ok=yes
3987else
3988 echo "$as_me: program exited with status $ac_status" >&5
3989echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00003990sed 's/^/| /' conftest.$ac_ext >&5
3991
Martin v. Löwis70fedcd2003-07-07 21:26:19 +00003992( exit $ac_status )
3993ac_cv_no_strict_aliasing_ok=no
3994fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00003995rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis70fedcd2003-07-07 21:26:19 +00003996fi
3997 CC="$ac_save_cc"
3998 echo "$as_me:$LINENO: result: $ac_cv_no_strict_aliasing_ok" >&5
3999echo "${ECHO_T}$ac_cv_no_strict_aliasing_ok" >&6
4000 if test $ac_cv_no_strict_aliasing_ok = yes
4001 then
4002 BASECFLAGS="$BASECFLAGS -fno-strict-aliasing"
4003 fi
Skip Montanarodecc6a42003-01-01 20:07:49 +00004004 case $ac_sys_system in
4005 SCO_SV*)
4006 BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
4007 ;;
4008 # is there any other compiler on Darwin besides gcc?
4009 Darwin*)
4010 BASECFLAGS="$BASECFLAGS -Wno-long-double -no-cpp-precomp"
4011 ;;
4012 esac
4013 ;;
4014
4015*)
4016 case $ac_sys_system in
4017 OpenUNIX*|UnixWare*)
4018 BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
4019 ;;
Neal Norwitzb44f1652003-05-26 14:11:55 +00004020 OSF*)
4021 BASECFLAGS="$BASECFLAGS -ieee -std"
4022 ;;
Skip Montanarodecc6a42003-01-01 20:07:49 +00004023 SCO_SV*)
4024 BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
4025 ;;
4026 esac
4027 ;;
4028esac
4029
Fred Drakee1ceaa02001-12-04 20:55:47 +00004030if test "$Py_DEBUG" = 'true'; then
4031 :
4032else
4033 OPT="-DNDEBUG $OPT"
4034fi
4035
Guido van Rossum563e7081996-09-10 18:20:48 +00004036if test "$ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +00004037then
Skip Montanarodecc6a42003-01-01 20:07:49 +00004038 BASECFLAGS="$BASECFLAGS $ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +00004039fi
Guido van Rossumda88dad1995-01-26 00:46:29 +00004040
Martin v. Löwis11437992002-04-12 09:54:03 +00004041echo "$as_me:$LINENO: checking whether $CC accepts -OPT:Olimit=0" >&5
4042echo $ECHO_N "checking whether $CC accepts -OPT:Olimit=0... $ECHO_C" >&6
4043if test "${ac_cv_opt_olimit_ok+set}" = set; then
4044 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum91922671997-10-09 20:24:13 +00004045else
4046 ac_save_cc="$CC"
4047CC="$CC -OPT:Olimit=0"
4048if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00004049 ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00004050else
Martin v. Löwis11437992002-04-12 09:54:03 +00004051 cat >conftest.$ac_ext <<_ACEOF
4052#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004053/* confdefs.h. */
4054_ACEOF
4055cat confdefs.h >>conftest.$ac_ext
4056cat >>conftest.$ac_ext <<_ACEOF
4057/* end confdefs.h. */
Guido van Rossum91922671997-10-09 20:24:13 +00004058int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004059_ACEOF
4060rm -f conftest$ac_exeext
4061if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4062 (eval $ac_link) 2>&5
4063 ac_status=$?
4064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4065 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4067 (eval $ac_try) 2>&5
4068 ac_status=$?
4069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4070 (exit $ac_status); }; }; then
Guido van Rossum91922671997-10-09 20:24:13 +00004071 ac_cv_opt_olimit_ok=yes
4072else
Martin v. Löwis11437992002-04-12 09:54:03 +00004073 echo "$as_me: program exited with status $ac_status" >&5
4074echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004075sed 's/^/| /' conftest.$ac_ext >&5
4076
Martin v. Löwis11437992002-04-12 09:54:03 +00004077( exit $ac_status )
4078ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00004079fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004080rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum91922671997-10-09 20:24:13 +00004081fi
Guido van Rossum91922671997-10-09 20:24:13 +00004082CC="$ac_save_cc"
4083fi
4084
Martin v. Löwis11437992002-04-12 09:54:03 +00004085echo "$as_me:$LINENO: result: $ac_cv_opt_olimit_ok" >&5
4086echo "${ECHO_T}$ac_cv_opt_olimit_ok" >&6
Guido van Rossum2efa34b1997-10-23 17:43:11 +00004087if test $ac_cv_opt_olimit_ok = yes; then
Guido van Rossum5839e582000-10-09 19:52:35 +00004088 case $ac_sys_system in
Skip Montanarodecc6a42003-01-01 20:07:49 +00004089 # XXX is this branch needed? On MacOSX 10.2.2 the result of the
4090 # olimit_ok test is "no". Is it "yes" in some other Darwin-esque
4091 # environment?
4092 Darwin*)
4093 ;;
4094 *)
4095 BASECFLAGS="$BASECFLAGS -OPT:Olimit=0"
4096 ;;
Guido van Rossum5839e582000-10-09 19:52:35 +00004097 esac
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004098else
Martin v. Löwis11437992002-04-12 09:54:03 +00004099 echo "$as_me:$LINENO: checking whether $CC accepts -Olimit 1500" >&5
4100echo $ECHO_N "checking whether $CC accepts -Olimit 1500... $ECHO_C" >&6
4101 if test "${ac_cv_olimit_ok+set}" = set; then
4102 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004103else
4104 ac_save_cc="$CC"
4105 CC="$CC -Olimit 1500"
4106 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00004107 ac_cv_olimit_ok=no
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004108else
Martin v. Löwis11437992002-04-12 09:54:03 +00004109 cat >conftest.$ac_ext <<_ACEOF
4110#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004111/* confdefs.h. */
4112_ACEOF
4113cat confdefs.h >>conftest.$ac_ext
4114cat >>conftest.$ac_ext <<_ACEOF
4115/* end confdefs.h. */
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004116int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00004117_ACEOF
4118rm -f conftest$ac_exeext
4119if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4120 (eval $ac_link) 2>&5
4121 ac_status=$?
4122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4123 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4124 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4125 (eval $ac_try) 2>&5
4126 ac_status=$?
4127 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4128 (exit $ac_status); }; }; then
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004129 ac_cv_olimit_ok=yes
4130else
Martin v. Löwis11437992002-04-12 09:54:03 +00004131 echo "$as_me: program exited with status $ac_status" >&5
4132echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004133sed 's/^/| /' conftest.$ac_ext >&5
4134
Martin v. Löwis11437992002-04-12 09:54:03 +00004135( exit $ac_status )
4136ac_cv_olimit_ok=no
Guido van Rossum201afe51997-05-14 21:14:44 +00004137fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004138rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004139fi
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004140 CC="$ac_save_cc"
4141fi
4142
Martin v. Löwis11437992002-04-12 09:54:03 +00004143 echo "$as_me:$LINENO: result: $ac_cv_olimit_ok" >&5
4144echo "${ECHO_T}$ac_cv_olimit_ok" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004145 if test $ac_cv_olimit_ok = yes; then
Skip Montanarodecc6a42003-01-01 20:07:49 +00004146 BASECFLAGS="$BASECFLAGS -Olimit 1500"
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00004147 fi
4148fi
4149
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004150# On some compilers, pthreads are available without further options
4151# (e.g. MacOS X). On some of these systems, the compiler will not
4152# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
4153# So we have to see first whether pthreads are available without
4154# options before we can check whether -Kpthread improves anything.
Martin v. Löwis11437992002-04-12 09:54:03 +00004155echo "$as_me:$LINENO: checking whether pthreads are available without options" >&5
4156echo $ECHO_N "checking whether pthreads are available without options... $ECHO_C" >&6
4157if test "${ac_cv_pthread_is_default+set}" = set; then
4158 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis130fb172001-07-19 11:00:41 +00004159else
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004160 if test "$cross_compiling" = yes; then
4161 ac_cv_pthread_is_default=no
Martin v. Löwis260aecc2001-10-07 08:14:41 +00004162else
Martin v. Löwis11437992002-04-12 09:54:03 +00004163 cat >conftest.$ac_ext <<_ACEOF
4164#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004165/* confdefs.h. */
4166_ACEOF
4167cat confdefs.h >>conftest.$ac_ext
4168cat >>conftest.$ac_ext <<_ACEOF
4169/* end confdefs.h. */
Martin v. Löwis260aecc2001-10-07 08:14:41 +00004170
Martin v. Löwis130fb172001-07-19 11:00:41 +00004171#include <pthread.h>
Martin v. Löwis260aecc2001-10-07 08:14:41 +00004172
4173void* routine(void* p){return NULL;}
4174
4175int main(){
4176 pthread_t p;
4177 if(pthread_create(&p,NULL,routine,NULL)!=0)
4178 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00004179 (void)pthread_detach(p);
Martin v. Löwis260aecc2001-10-07 08:14:41 +00004180 return 0;
4181}
4182
Martin v. Löwis11437992002-04-12 09:54:03 +00004183_ACEOF
4184rm -f conftest$ac_exeext
4185if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4186 (eval $ac_link) 2>&5
4187 ac_status=$?
4188 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4189 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4190 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4191 (eval $ac_try) 2>&5
4192 ac_status=$?
4193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4194 (exit $ac_status); }; }; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00004195
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004196 ac_cv_pthread_is_default=yes
Skip Montanarod8d39a02003-07-10 20:44:10 +00004197 ac_cv_kthread=no
4198 ac_cv_pthread=no
4199
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004200else
Martin v. Löwis11437992002-04-12 09:54:03 +00004201 echo "$as_me: program exited with status $ac_status" >&5
4202echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004203sed 's/^/| /' conftest.$ac_ext >&5
4204
Martin v. Löwis11437992002-04-12 09:54:03 +00004205( exit $ac_status )
4206ac_cv_pthread_is_default=no
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004207fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004208rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004209fi
4210
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004211fi
4212
Martin v. Löwis11437992002-04-12 09:54:03 +00004213echo "$as_me:$LINENO: result: $ac_cv_pthread_is_default" >&5
4214echo "${ECHO_T}$ac_cv_pthread_is_default" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004215
Michael W. Hudson54241132001-12-07 15:38:26 +00004216
Martin v. Löwis11437992002-04-12 09:54:03 +00004217if test $ac_cv_pthread_is_default = yes
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004218then
4219 ac_cv_kpthread=no
4220else
4221# -Kpthread, if available, provides the right #defines
4222# and linker options to make pthread_create available
4223# Some compilers won't report that they do not support -Kpthread,
4224# so we need to run a program to see whether it really made the
4225# function available.
Martin v. Löwis11437992002-04-12 09:54:03 +00004226echo "$as_me:$LINENO: checking whether $CC accepts -Kpthread" >&5
4227echo $ECHO_N "checking whether $CC accepts -Kpthread... $ECHO_C" >&6
4228if test "${ac_cv_kpthread+set}" = set; then
4229 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004230else
4231 ac_save_cc="$CC"
4232CC="$CC -Kpthread"
4233if test "$cross_compiling" = yes; then
4234 ac_cv_kpthread=no
4235else
Martin v. Löwis11437992002-04-12 09:54:03 +00004236 cat >conftest.$ac_ext <<_ACEOF
4237#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004238/* confdefs.h. */
4239_ACEOF
4240cat confdefs.h >>conftest.$ac_ext
4241cat >>conftest.$ac_ext <<_ACEOF
4242/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004243
4244#include <pthread.h>
4245
4246void* routine(void* p){return NULL;}
4247
4248int main(){
4249 pthread_t p;
4250 if(pthread_create(&p,NULL,routine,NULL)!=0)
4251 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00004252 (void)pthread_detach(p);
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004253 return 0;
4254}
4255
Martin v. Löwis11437992002-04-12 09:54:03 +00004256_ACEOF
4257rm -f conftest$ac_exeext
4258if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4259 (eval $ac_link) 2>&5
4260 ac_status=$?
4261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4262 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4263 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4264 (eval $ac_try) 2>&5
4265 ac_status=$?
4266 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4267 (exit $ac_status); }; }; then
Martin v. Löwis130fb172001-07-19 11:00:41 +00004268 ac_cv_kpthread=yes
4269else
Martin v. Löwis11437992002-04-12 09:54:03 +00004270 echo "$as_me: program exited with status $ac_status" >&5
4271echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004272sed 's/^/| /' conftest.$ac_ext >&5
4273
Martin v. Löwis11437992002-04-12 09:54:03 +00004274( exit $ac_status )
4275ac_cv_kpthread=no
Martin v. Löwis130fb172001-07-19 11:00:41 +00004276fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004277rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis260aecc2001-10-07 08:14:41 +00004278fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00004279CC="$ac_save_cc"
4280fi
4281
Martin v. Löwis11437992002-04-12 09:54:03 +00004282echo "$as_me:$LINENO: result: $ac_cv_kpthread" >&5
4283echo "${ECHO_T}$ac_cv_kpthread" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00004284fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00004285
Skip Montanarod8d39a02003-07-10 20:44:10 +00004286if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no
Martin v. Löwis5f433f02003-05-05 05:05:30 +00004287then
4288# -Kthread, if available, provides the right #defines
4289# and linker options to make pthread_create available
4290# Some compilers won't report that they do not support -Kthread,
4291# so we need to run a program to see whether it really made the
4292# function available.
4293echo "$as_me:$LINENO: checking whether $CC accepts -Kthread" >&5
4294echo $ECHO_N "checking whether $CC accepts -Kthread... $ECHO_C" >&6
4295if test "${ac_cv_kthread+set}" = set; then
4296 echo $ECHO_N "(cached) $ECHO_C" >&6
4297else
4298 ac_save_cc="$CC"
4299CC="$CC -Kthread"
4300if test "$cross_compiling" = yes; then
4301 ac_cv_kthread=no
4302else
4303 cat >conftest.$ac_ext <<_ACEOF
4304#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004305/* confdefs.h. */
4306_ACEOF
4307cat confdefs.h >>conftest.$ac_ext
4308cat >>conftest.$ac_ext <<_ACEOF
4309/* end confdefs.h. */
Martin v. Löwis5f433f02003-05-05 05:05:30 +00004310
4311#include <pthread.h>
4312
4313void* routine(void* p){return NULL;}
4314
4315int main(){
4316 pthread_t p;
4317 if(pthread_create(&p,NULL,routine,NULL)!=0)
4318 return 1;
4319 (void)pthread_detach(p);
4320 return 0;
4321}
4322
4323_ACEOF
4324rm -f conftest$ac_exeext
4325if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4326 (eval $ac_link) 2>&5
4327 ac_status=$?
4328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4329 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4330 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4331 (eval $ac_try) 2>&5
4332 ac_status=$?
4333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4334 (exit $ac_status); }; }; then
4335 ac_cv_kthread=yes
4336else
4337 echo "$as_me: program exited with status $ac_status" >&5
4338echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004339sed 's/^/| /' conftest.$ac_ext >&5
4340
Martin v. Löwis5f433f02003-05-05 05:05:30 +00004341( exit $ac_status )
4342ac_cv_kthread=no
4343fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004344rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis5f433f02003-05-05 05:05:30 +00004345fi
4346CC="$ac_save_cc"
4347fi
4348
4349echo "$as_me:$LINENO: result: $ac_cv_kthread" >&5
4350echo "${ECHO_T}$ac_cv_kthread" >&6
4351fi
4352
Skip Montanarod8d39a02003-07-10 20:44:10 +00004353if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +00004354then
4355# -pthread, if available, provides the right #defines
4356# and linker options to make pthread_create available
4357# Some compilers won't report that they do not support -pthread,
4358# so we need to run a program to see whether it really made the
4359# function available.
4360echo "$as_me:$LINENO: checking whether $CC accepts -pthread" >&5
4361echo $ECHO_N "checking whether $CC accepts -pthread... $ECHO_C" >&6
4362if test "${ac_cv_thread+set}" = set; then
4363 echo $ECHO_N "(cached) $ECHO_C" >&6
4364else
4365 ac_save_cc="$CC"
4366CC="$CC -pthread"
4367if test "$cross_compiling" = yes; then
4368 ac_cv_pthread=no
4369else
4370 cat >conftest.$ac_ext <<_ACEOF
4371#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004372/* confdefs.h. */
4373_ACEOF
4374cat confdefs.h >>conftest.$ac_ext
4375cat >>conftest.$ac_ext <<_ACEOF
4376/* end confdefs.h. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +00004377
4378#include <pthread.h>
4379
4380void* routine(void* p){return NULL;}
4381
4382int main(){
4383 pthread_t p;
4384 if(pthread_create(&p,NULL,routine,NULL)!=0)
4385 return 1;
4386 (void)pthread_detach(p);
4387 return 0;
4388}
4389
4390_ACEOF
4391rm -f conftest$ac_exeext
4392if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4393 (eval $ac_link) 2>&5
4394 ac_status=$?
4395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4396 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4397 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4398 (eval $ac_try) 2>&5
4399 ac_status=$?
4400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4401 (exit $ac_status); }; }; then
4402 ac_cv_pthread=yes
4403else
4404 echo "$as_me: program exited with status $ac_status" >&5
4405echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004406sed 's/^/| /' conftest.$ac_ext >&5
4407
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +00004408( exit $ac_status )
4409ac_cv_pthread=no
4410fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004411rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +00004412fi
4413CC="$ac_save_cc"
4414fi
4415
4416echo "$as_me:$LINENO: result: $ac_cv_pthread" >&5
4417echo "${ECHO_T}$ac_cv_pthread" >&6
4418fi
4419
Martin v. Löwisab1e5852003-06-28 07:46:38 +00004420# If we have set a CC compiler flag for thread support then
4421# check if it works for CXX, too.
4422ac_cv_cxx_thread=no
4423if test ! -z "$CXX"
4424then
4425echo "$as_me:$LINENO: checking whether $CXX also accepts flags for thread support" >&5
4426echo $ECHO_N "checking whether $CXX also accepts flags for thread support... $ECHO_C" >&6
4427ac_save_cxx="$CXX"
4428
4429if test "$ac_cv_kpthread" = "yes"
4430then
4431 CXX="$CXX -Kpthread"
4432 ac_cv_cxx_thread=yes
4433elif test "$ac_cv_kthread" = "yes"
4434then
4435 CXX="$CXX -Kthread"
4436 ac_cv_cxx_thread=yes
4437elif test "$ac_cv_pthread" = "yes"
4438then
4439 CXX="$CXX -pthread"
4440 ac_cv_cxx_thread=yes
4441fi
4442
4443if test $ac_cv_cxx_thread = yes
4444then
4445 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
4446 $CXX -c conftest.$ac_ext 2>&5
4447 if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
4448 && test -s conftest$ac_exeext && ./conftest$ac_exeext
4449 then
4450 ac_cv_cxx_thread=yes
4451 else
4452 ac_cv_cxx_thread=no
4453 CXX="$ac_save_cxx"
4454 fi
4455 rm -fr conftest*
4456else
4457 CXX="$ac_save_cxx"
4458fi
4459fi
4460echo "$as_me:$LINENO: result: $ac_cv_cxx_thread" >&5
4461echo "${ECHO_T}$ac_cv_cxx_thread" >&6
4462
Michael W. Hudson54241132001-12-07 15:38:26 +00004463
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00004464# checks for header files
Martin v. Löwis11437992002-04-12 09:54:03 +00004465echo "$as_me:$LINENO: checking for ANSI C header files" >&5
4466echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
4467if test "${ac_cv_header_stdc+set}" = set; then
4468 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004469else
Martin v. Löwis11437992002-04-12 09:54:03 +00004470 cat >conftest.$ac_ext <<_ACEOF
4471#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004472/* confdefs.h. */
4473_ACEOF
4474cat confdefs.h >>conftest.$ac_ext
4475cat >>conftest.$ac_ext <<_ACEOF
4476/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00004477#include <stdlib.h>
4478#include <stdarg.h>
4479#include <string.h>
4480#include <float.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004481
Skip Montanarod8d39a02003-07-10 20:44:10 +00004482int
4483main ()
4484{
4485
4486 ;
4487 return 0;
4488}
Martin v. Löwis11437992002-04-12 09:54:03 +00004489_ACEOF
Skip Montanarod8d39a02003-07-10 20:44:10 +00004490rm -f conftest.$ac_objext
4491if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4492 (eval $ac_compile) 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004493 ac_status=$?
Martin v. Löwis11437992002-04-12 09:54:03 +00004494 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004495 (exit $ac_status); } &&
4496 { ac_try='test -s conftest.$ac_objext'
4497 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4498 (eval $ac_try) 2>&5
4499 ac_status=$?
4500 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4501 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004502 ac_cv_header_stdc=yes
4503else
Martin v. Löwis11437992002-04-12 09:54:03 +00004504 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004505sed 's/^/| /' conftest.$ac_ext >&5
4506
4507ac_cv_header_stdc=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004508fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004509rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004510
4511if test $ac_cv_header_stdc = yes; then
4512 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00004513 cat >conftest.$ac_ext <<_ACEOF
4514#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004515/* confdefs.h. */
4516_ACEOF
4517cat confdefs.h >>conftest.$ac_ext
4518cat >>conftest.$ac_ext <<_ACEOF
4519/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004520#include <string.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004521
4522_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004523if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00004524 $EGREP "memchr" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004525 :
4526else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004527 ac_cv_header_stdc=no
4528fi
4529rm -f conftest*
4530
4531fi
4532
4533if test $ac_cv_header_stdc = yes; then
4534 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00004535 cat >conftest.$ac_ext <<_ACEOF
4536#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004537/* confdefs.h. */
4538_ACEOF
4539cat confdefs.h >>conftest.$ac_ext
4540cat >>conftest.$ac_ext <<_ACEOF
4541/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004542#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004543
4544_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004545if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00004546 $EGREP "free" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004547 :
4548else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004549 ac_cv_header_stdc=no
4550fi
4551rm -f conftest*
4552
4553fi
4554
4555if test $ac_cv_header_stdc = yes; then
4556 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
Martin v. Löwis11437992002-04-12 09:54:03 +00004557 if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004558 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004559else
Martin v. Löwis11437992002-04-12 09:54:03 +00004560 cat >conftest.$ac_ext <<_ACEOF
4561#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004562/* confdefs.h. */
4563_ACEOF
4564cat confdefs.h >>conftest.$ac_ext
4565cat >>conftest.$ac_ext <<_ACEOF
4566/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00004567#include <ctype.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004568#if ((' ' & 0x0FF) == 0x020)
4569# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4570# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4571#else
Skip Montanarod8d39a02003-07-10 20:44:10 +00004572# define ISLOWER(c) \
4573 (('a' <= (c) && (c) <= 'i') \
Martin v. Löwis11437992002-04-12 09:54:03 +00004574 || ('j' <= (c) && (c) <= 'r') \
4575 || ('s' <= (c) && (c) <= 'z'))
4576# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4577#endif
Michael W. Hudson54241132001-12-07 15:38:26 +00004578
Martin v. Löwis11437992002-04-12 09:54:03 +00004579#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4580int
4581main ()
4582{
4583 int i;
4584 for (i = 0; i < 256; i++)
4585 if (XOR (islower (i), ISLOWER (i))
4586 || toupper (i) != TOUPPER (i))
4587 exit(2);
4588 exit (0);
4589}
4590_ACEOF
4591rm -f conftest$ac_exeext
4592if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4593 (eval $ac_link) 2>&5
4594 ac_status=$?
4595 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4596 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4597 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4598 (eval $ac_try) 2>&5
4599 ac_status=$?
4600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4601 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004602 :
4603else
Martin v. Löwis11437992002-04-12 09:54:03 +00004604 echo "$as_me: program exited with status $ac_status" >&5
4605echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004606sed 's/^/| /' conftest.$ac_ext >&5
4607
Martin v. Löwis11437992002-04-12 09:54:03 +00004608( exit $ac_status )
4609ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004610fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00004611rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004612fi
4613fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004614fi
4615echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
4616echo "${ECHO_T}$ac_cv_header_stdc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00004617if test $ac_cv_header_stdc = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004618
4619cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004620#define STDC_HEADERS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00004621_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004622
4623fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00004624
Martin v. Löwis11437992002-04-12 09:54:03 +00004625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
Martin v. Löwis14e73b12003-01-01 09:51:12 +00004662
Barry Warsawfe33b792003-01-07 22:42:49 +00004663
Neal Norwitz82251032003-05-23 14:35:24 +00004664
Martin v. Löwis11437992002-04-12 09:54:03 +00004665for ac_header in dlfcn.h fcntl.h grp.h limits.h langinfo.h \
Martin v. Löwis2e64c342002-03-27 18:49:02 +00004666libintl.h locale.h ncurses.h poll.h pthread.h \
Martin v. Löwis14e73b12003-01-01 09:51:12 +00004667signal.h stdarg.h stddef.h stdlib.h stropts.h termios.h thread.h \
4668unistd.h utime.h \
Neal Norwitz82251032003-05-23 14:35:24 +00004669sys/audioio.h sys/bsdtty.h sys/file.h sys/lock.h sys/mkdev.h sys/modem.h \
Andrew M. Kuchling881fd902001-07-14 20:55:52 +00004670sys/param.h sys/poll.h sys/select.h sys/socket.h sys/time.h sys/times.h \
Martin v. Löwisa5f09072002-10-11 05:37:59 +00004671sys/un.h sys/utsname.h sys/wait.h pty.h term.h libutil.h \
Barry Warsawfe33b792003-01-07 22:42:49 +00004672sys/resource.h netpacket/packet.h sysexits.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00004673do
Martin v. Löwis11437992002-04-12 09:54:03 +00004674as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
4675if eval "test \"\${$as_ac_Header+set}\" = set"; then
4676 echo "$as_me:$LINENO: checking for $ac_header" >&5
4677echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4678if eval "test \"\${$as_ac_Header+set}\" = set"; then
4679 echo $ECHO_N "(cached) $ECHO_C" >&6
4680fi
4681echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4682echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004683else
Martin v. Löwis11437992002-04-12 09:54:03 +00004684 # Is the header compilable?
4685echo "$as_me:$LINENO: checking $ac_header usability" >&5
4686echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
4687cat >conftest.$ac_ext <<_ACEOF
4688#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004689/* confdefs.h. */
4690_ACEOF
4691cat confdefs.h >>conftest.$ac_ext
4692cat >>conftest.$ac_ext <<_ACEOF
4693/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004694$ac_includes_default
4695#include <$ac_header>
4696_ACEOF
4697rm -f conftest.$ac_objext
4698if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4699 (eval $ac_compile) 2>&5
4700 ac_status=$?
4701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4702 (exit $ac_status); } &&
4703 { ac_try='test -s conftest.$ac_objext'
4704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4705 (eval $ac_try) 2>&5
4706 ac_status=$?
4707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4708 (exit $ac_status); }; }; then
4709 ac_header_compiler=yes
Michael W. Hudson54241132001-12-07 15:38:26 +00004710else
Martin v. Löwis11437992002-04-12 09:54:03 +00004711 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004712sed 's/^/| /' conftest.$ac_ext >&5
4713
Martin v. Löwis11437992002-04-12 09:54:03 +00004714ac_header_compiler=no
4715fi
4716rm -f conftest.$ac_objext conftest.$ac_ext
4717echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4718echo "${ECHO_T}$ac_header_compiler" >&6
4719
4720# Is the header present?
4721echo "$as_me:$LINENO: checking $ac_header presence" >&5
4722echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4723cat >conftest.$ac_ext <<_ACEOF
4724#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004725/* confdefs.h. */
4726_ACEOF
4727cat confdefs.h >>conftest.$ac_ext
4728cat >>conftest.$ac_ext <<_ACEOF
4729/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004730#include <$ac_header>
4731_ACEOF
4732if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4733 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4734 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00004735 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00004736 rm -f conftest.er1
4737 cat conftest.err >&5
4738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4739 (exit $ac_status); } >/dev/null; then
4740 if test -s conftest.err; then
4741 ac_cpp_err=$ac_c_preproc_warn_flag
4742 else
4743 ac_cpp_err=
4744 fi
4745else
4746 ac_cpp_err=yes
4747fi
4748if test -z "$ac_cpp_err"; then
4749 ac_header_preproc=yes
4750else
4751 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004752sed 's/^/| /' conftest.$ac_ext >&5
4753
Martin v. Löwis11437992002-04-12 09:54:03 +00004754 ac_header_preproc=no
Michael W. Hudson54241132001-12-07 15:38:26 +00004755fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004756rm -f conftest.err conftest.$ac_ext
4757echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4758echo "${ECHO_T}$ac_header_preproc" >&6
4759
4760# So? What about this header?
4761case $ac_header_compiler:$ac_header_preproc in
4762 yes:no )
4763 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4764echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4765 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004766echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4767 (
4768 cat <<\_ASBOX
4769## ------------------------------------ ##
4770## Report this to bug-autoconf@gnu.org. ##
4771## ------------------------------------ ##
4772_ASBOX
4773 ) |
4774 sed "s/^/$as_me: WARNING: /" >&2
4775 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00004776 no:yes )
4777 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4778echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4779 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
4780echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
4781 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004782echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
4783 (
4784 cat <<\_ASBOX
4785## ------------------------------------ ##
4786## Report this to bug-autoconf@gnu.org. ##
4787## ------------------------------------ ##
4788_ASBOX
4789 ) |
4790 sed "s/^/$as_me: WARNING: /" >&2
4791 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00004792esac
4793echo "$as_me:$LINENO: checking for $ac_header" >&5
4794echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4795if eval "test \"\${$as_ac_Header+set}\" = set"; then
4796 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00004797else
Martin v. Löwis11437992002-04-12 09:54:03 +00004798 eval "$as_ac_Header=$ac_header_preproc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004799fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004800echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4801echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4802
4803fi
4804if test `eval echo '${'$as_ac_Header'}'` = yes; then
4805 cat >>confdefs.h <<_ACEOF
4806#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4807_ACEOF
4808
4809fi
4810
Guido van Rossum627b2d71993-12-24 10:39:16 +00004811done
4812
Martin v. Löwis11437992002-04-12 09:54:03 +00004813
4814
4815
4816
4817
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004818ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004819for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
4820 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
4821echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
4822echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
4823if eval "test \"\${$as_ac_Header+set}\" = set"; then
4824 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00004825else
Martin v. Löwis11437992002-04-12 09:54:03 +00004826 cat >conftest.$ac_ext <<_ACEOF
4827#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004828/* confdefs.h. */
4829_ACEOF
4830cat confdefs.h >>conftest.$ac_ext
4831cat >>conftest.$ac_ext <<_ACEOF
4832/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004833#include <sys/types.h>
4834#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00004835
Martin v. Löwis11437992002-04-12 09:54:03 +00004836int
4837main ()
4838{
4839if ((DIR *) 0)
4840return 0;
4841 ;
4842 return 0;
4843}
4844_ACEOF
4845rm -f conftest.$ac_objext
4846if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4847 (eval $ac_compile) 2>&5
4848 ac_status=$?
4849 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4850 (exit $ac_status); } &&
4851 { ac_try='test -s conftest.$ac_objext'
4852 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4853 (eval $ac_try) 2>&5
4854 ac_status=$?
4855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4856 (exit $ac_status); }; }; then
4857 eval "$as_ac_Header=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +00004858else
Martin v. Löwis11437992002-04-12 09:54:03 +00004859 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004860sed 's/^/| /' conftest.$ac_ext >&5
4861
Martin v. Löwis11437992002-04-12 09:54:03 +00004862eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004863fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004864rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004865fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004866echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4867echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4868if test `eval echo '${'$as_ac_Header'}'` = yes; then
4869 cat >>confdefs.h <<_ACEOF
4870#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
4871_ACEOF
4872
4873ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00004874fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004875
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004876done
4877# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4878if test $ac_header_dirent = dirent.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004879 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4880echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4881if test "${ac_cv_search_opendir+set}" = set; then
4882 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004883else
Martin v. Löwis11437992002-04-12 09:54:03 +00004884 ac_func_search_save_LIBS=$LIBS
4885ac_cv_search_opendir=no
4886cat >conftest.$ac_ext <<_ACEOF
4887#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004888/* confdefs.h. */
4889_ACEOF
4890cat confdefs.h >>conftest.$ac_ext
4891cat >>conftest.$ac_ext <<_ACEOF
4892/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004893
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004894/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004895#ifdef __cplusplus
4896extern "C"
4897#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004898/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004899 builtin and then its argument prototype would still apply. */
4900char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00004901int
4902main ()
4903{
4904opendir ();
4905 ;
4906 return 0;
4907}
4908_ACEOF
4909rm -f conftest.$ac_objext conftest$ac_exeext
4910if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4911 (eval $ac_link) 2>&5
4912 ac_status=$?
4913 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4914 (exit $ac_status); } &&
4915 { ac_try='test -s conftest$ac_exeext'
4916 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4917 (eval $ac_try) 2>&5
4918 ac_status=$?
4919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4920 (exit $ac_status); }; }; then
4921 ac_cv_search_opendir="none required"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004922else
Martin v. Löwis11437992002-04-12 09:54:03 +00004923 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004924sed 's/^/| /' conftest.$ac_ext >&5
4925
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004926fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004927rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4928if test "$ac_cv_search_opendir" = no; then
4929 for ac_lib in dir; do
4930 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4931 cat >conftest.$ac_ext <<_ACEOF
4932#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004933/* confdefs.h. */
4934_ACEOF
4935cat confdefs.h >>conftest.$ac_ext
4936cat >>conftest.$ac_ext <<_ACEOF
4937/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004938
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004939/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004940#ifdef __cplusplus
4941extern "C"
4942#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004943/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004944 builtin and then its argument prototype would still apply. */
4945char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00004946int
4947main ()
4948{
4949opendir ();
4950 ;
4951 return 0;
4952}
4953_ACEOF
4954rm -f conftest.$ac_objext conftest$ac_exeext
4955if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4956 (eval $ac_link) 2>&5
4957 ac_status=$?
4958 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4959 (exit $ac_status); } &&
4960 { ac_try='test -s conftest$ac_exeext'
4961 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4962 (eval $ac_try) 2>&5
4963 ac_status=$?
4964 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4965 (exit $ac_status); }; }; then
4966 ac_cv_search_opendir="-l$ac_lib"
4967break
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004968else
Martin v. Löwis11437992002-04-12 09:54:03 +00004969 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00004970sed 's/^/| /' conftest.$ac_ext >&5
4971
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004972fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004973rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4974 done
4975fi
4976LIBS=$ac_func_search_save_LIBS
4977fi
4978echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4979echo "${ECHO_T}$ac_cv_search_opendir" >&6
4980if test "$ac_cv_search_opendir" != no; then
4981 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00004982
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004983fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004984
Michael W. Hudson54241132001-12-07 15:38:26 +00004985else
Martin v. Löwis11437992002-04-12 09:54:03 +00004986 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4987echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4988if test "${ac_cv_search_opendir+set}" = set; then
4989 echo $ECHO_N "(cached) $ECHO_C" >&6
4990else
4991 ac_func_search_save_LIBS=$LIBS
4992ac_cv_search_opendir=no
4993cat >conftest.$ac_ext <<_ACEOF
4994#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00004995/* confdefs.h. */
4996_ACEOF
4997cat confdefs.h >>conftest.$ac_ext
4998cat >>conftest.$ac_ext <<_ACEOF
4999/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005000
5001/* Override any gcc2 internal prototype to avoid an error. */
5002#ifdef __cplusplus
5003extern "C"
5004#endif
5005/* We use char because int might match the return type of a gcc2
5006 builtin and then its argument prototype would still apply. */
5007char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00005008int
5009main ()
5010{
5011opendir ();
5012 ;
5013 return 0;
5014}
5015_ACEOF
5016rm -f conftest.$ac_objext conftest$ac_exeext
5017if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5018 (eval $ac_link) 2>&5
5019 ac_status=$?
5020 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5021 (exit $ac_status); } &&
5022 { ac_try='test -s conftest$ac_exeext'
5023 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5024 (eval $ac_try) 2>&5
5025 ac_status=$?
5026 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5027 (exit $ac_status); }; }; then
5028 ac_cv_search_opendir="none required"
5029else
5030 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005031sed 's/^/| /' conftest.$ac_ext >&5
5032
Martin v. Löwis11437992002-04-12 09:54:03 +00005033fi
5034rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5035if test "$ac_cv_search_opendir" = no; then
5036 for ac_lib in x; do
5037 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
5038 cat >conftest.$ac_ext <<_ACEOF
5039#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005040/* confdefs.h. */
5041_ACEOF
5042cat confdefs.h >>conftest.$ac_ext
5043cat >>conftest.$ac_ext <<_ACEOF
5044/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005045
5046/* Override any gcc2 internal prototype to avoid an error. */
5047#ifdef __cplusplus
5048extern "C"
5049#endif
5050/* We use char because int might match the return type of a gcc2
5051 builtin and then its argument prototype would still apply. */
5052char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00005053int
5054main ()
5055{
5056opendir ();
5057 ;
5058 return 0;
5059}
5060_ACEOF
5061rm -f conftest.$ac_objext conftest$ac_exeext
5062if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5063 (eval $ac_link) 2>&5
5064 ac_status=$?
5065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5066 (exit $ac_status); } &&
5067 { ac_try='test -s conftest$ac_exeext'
5068 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5069 (eval $ac_try) 2>&5
5070 ac_status=$?
5071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5072 (exit $ac_status); }; }; then
5073 ac_cv_search_opendir="-l$ac_lib"
5074break
5075else
5076 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005077sed 's/^/| /' conftest.$ac_ext >&5
5078
Martin v. Löwis11437992002-04-12 09:54:03 +00005079fi
5080rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5081 done
5082fi
5083LIBS=$ac_func_search_save_LIBS
5084fi
5085echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
5086echo "${ECHO_T}$ac_cv_search_opendir" >&6
5087if test "$ac_cv_search_opendir" != no; then
5088 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
5089
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005090fi
5091
5092fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00005093
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005094echo "$as_me:$LINENO: checking whether sys/types.h defines makedev" >&5
5095echo $ECHO_N "checking whether sys/types.h defines makedev... $ECHO_C" >&6
5096if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then
5097 echo $ECHO_N "(cached) $ECHO_C" >&6
5098else
5099 cat >conftest.$ac_ext <<_ACEOF
5100#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005101/* confdefs.h. */
5102_ACEOF
5103cat confdefs.h >>conftest.$ac_ext
5104cat >>conftest.$ac_ext <<_ACEOF
5105/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005106#include <sys/types.h>
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005107int
5108main ()
5109{
5110return makedev(0, 0);
5111 ;
5112 return 0;
5113}
5114_ACEOF
5115rm -f conftest.$ac_objext conftest$ac_exeext
5116if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5117 (eval $ac_link) 2>&5
5118 ac_status=$?
5119 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5120 (exit $ac_status); } &&
5121 { ac_try='test -s conftest$ac_exeext'
5122 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5123 (eval $ac_try) 2>&5
5124 ac_status=$?
5125 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5126 (exit $ac_status); }; }; then
5127 ac_cv_header_sys_types_h_makedev=yes
5128else
5129 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005130sed 's/^/| /' conftest.$ac_ext >&5
5131
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005132ac_cv_header_sys_types_h_makedev=no
5133fi
5134rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5135
5136fi
5137echo "$as_me:$LINENO: result: $ac_cv_header_sys_types_h_makedev" >&5
5138echo "${ECHO_T}$ac_cv_header_sys_types_h_makedev" >&6
5139
5140if test $ac_cv_header_sys_types_h_makedev = no; then
5141if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
5142 echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
5143echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6
5144if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
5145 echo $ECHO_N "(cached) $ECHO_C" >&6
5146fi
5147echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
5148echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6
5149else
5150 # Is the header compilable?
5151echo "$as_me:$LINENO: checking sys/mkdev.h usability" >&5
5152echo $ECHO_N "checking sys/mkdev.h usability... $ECHO_C" >&6
5153cat >conftest.$ac_ext <<_ACEOF
5154#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005155/* confdefs.h. */
5156_ACEOF
5157cat confdefs.h >>conftest.$ac_ext
5158cat >>conftest.$ac_ext <<_ACEOF
5159/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005160$ac_includes_default
5161#include <sys/mkdev.h>
5162_ACEOF
5163rm -f conftest.$ac_objext
5164if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5165 (eval $ac_compile) 2>&5
5166 ac_status=$?
5167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5168 (exit $ac_status); } &&
5169 { ac_try='test -s conftest.$ac_objext'
5170 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5171 (eval $ac_try) 2>&5
5172 ac_status=$?
5173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5174 (exit $ac_status); }; }; then
5175 ac_header_compiler=yes
5176else
5177 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005178sed 's/^/| /' conftest.$ac_ext >&5
5179
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005180ac_header_compiler=no
5181fi
5182rm -f conftest.$ac_objext conftest.$ac_ext
5183echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5184echo "${ECHO_T}$ac_header_compiler" >&6
5185
5186# Is the header present?
5187echo "$as_me:$LINENO: checking sys/mkdev.h presence" >&5
5188echo $ECHO_N "checking sys/mkdev.h presence... $ECHO_C" >&6
5189cat >conftest.$ac_ext <<_ACEOF
5190#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005191/* confdefs.h. */
5192_ACEOF
5193cat confdefs.h >>conftest.$ac_ext
5194cat >>conftest.$ac_ext <<_ACEOF
5195/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005196#include <sys/mkdev.h>
5197_ACEOF
5198if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5199 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5200 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00005201 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005202 rm -f conftest.er1
5203 cat conftest.err >&5
5204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5205 (exit $ac_status); } >/dev/null; then
5206 if test -s conftest.err; then
5207 ac_cpp_err=$ac_c_preproc_warn_flag
5208 else
5209 ac_cpp_err=
5210 fi
5211else
5212 ac_cpp_err=yes
5213fi
5214if test -z "$ac_cpp_err"; then
5215 ac_header_preproc=yes
5216else
5217 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005218sed 's/^/| /' conftest.$ac_ext >&5
5219
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005220 ac_header_preproc=no
5221fi
5222rm -f conftest.err conftest.$ac_ext
5223echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5224echo "${ECHO_T}$ac_header_preproc" >&6
5225
5226# So? What about this header?
5227case $ac_header_compiler:$ac_header_preproc in
5228 yes:no )
5229 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&5
5230echo "$as_me: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
5231 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005232echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;}
5233 (
5234 cat <<\_ASBOX
5235## ------------------------------------ ##
5236## Report this to bug-autoconf@gnu.org. ##
5237## ------------------------------------ ##
5238_ASBOX
5239 ) |
5240 sed "s/^/$as_me: WARNING: /" >&2
5241 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005242 no:yes )
5243 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: present but cannot be compiled" >&5
5244echo "$as_me: WARNING: sys/mkdev.h: present but cannot be compiled" >&2;}
5245 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&5
5246echo "$as_me: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&2;}
5247 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005248echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;}
5249 (
5250 cat <<\_ASBOX
5251## ------------------------------------ ##
5252## Report this to bug-autoconf@gnu.org. ##
5253## ------------------------------------ ##
5254_ASBOX
5255 ) |
5256 sed "s/^/$as_me: WARNING: /" >&2
5257 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005258esac
5259echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
5260echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6
5261if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
5262 echo $ECHO_N "(cached) $ECHO_C" >&6
5263else
5264 ac_cv_header_sys_mkdev_h=$ac_header_preproc
5265fi
5266echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
5267echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6
5268
5269fi
5270if test $ac_cv_header_sys_mkdev_h = yes; then
5271
5272cat >>confdefs.h <<\_ACEOF
5273#define MAJOR_IN_MKDEV 1
5274_ACEOF
5275
5276fi
5277
5278
5279
5280 if test $ac_cv_header_sys_mkdev_h = no; then
5281 if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
5282 echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
5283echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6
5284if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
5285 echo $ECHO_N "(cached) $ECHO_C" >&6
5286fi
5287echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
5288echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6
5289else
5290 # Is the header compilable?
5291echo "$as_me:$LINENO: checking sys/sysmacros.h usability" >&5
5292echo $ECHO_N "checking sys/sysmacros.h usability... $ECHO_C" >&6
5293cat >conftest.$ac_ext <<_ACEOF
5294#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005295/* confdefs.h. */
5296_ACEOF
5297cat confdefs.h >>conftest.$ac_ext
5298cat >>conftest.$ac_ext <<_ACEOF
5299/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005300$ac_includes_default
5301#include <sys/sysmacros.h>
5302_ACEOF
5303rm -f conftest.$ac_objext
5304if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5305 (eval $ac_compile) 2>&5
5306 ac_status=$?
5307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5308 (exit $ac_status); } &&
5309 { ac_try='test -s conftest.$ac_objext'
5310 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5311 (eval $ac_try) 2>&5
5312 ac_status=$?
5313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5314 (exit $ac_status); }; }; then
5315 ac_header_compiler=yes
5316else
5317 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005318sed 's/^/| /' conftest.$ac_ext >&5
5319
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005320ac_header_compiler=no
5321fi
5322rm -f conftest.$ac_objext conftest.$ac_ext
5323echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5324echo "${ECHO_T}$ac_header_compiler" >&6
5325
5326# Is the header present?
5327echo "$as_me:$LINENO: checking sys/sysmacros.h presence" >&5
5328echo $ECHO_N "checking sys/sysmacros.h presence... $ECHO_C" >&6
5329cat >conftest.$ac_ext <<_ACEOF
5330#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005331/* confdefs.h. */
5332_ACEOF
5333cat confdefs.h >>conftest.$ac_ext
5334cat >>conftest.$ac_ext <<_ACEOF
5335/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005336#include <sys/sysmacros.h>
5337_ACEOF
5338if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
5339 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
5340 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +00005341 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005342 rm -f conftest.er1
5343 cat conftest.err >&5
5344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5345 (exit $ac_status); } >/dev/null; then
5346 if test -s conftest.err; then
5347 ac_cpp_err=$ac_c_preproc_warn_flag
5348 else
5349 ac_cpp_err=
5350 fi
5351else
5352 ac_cpp_err=yes
5353fi
5354if test -z "$ac_cpp_err"; then
5355 ac_header_preproc=yes
5356else
5357 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005358sed 's/^/| /' conftest.$ac_ext >&5
5359
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005360 ac_header_preproc=no
5361fi
5362rm -f conftest.err conftest.$ac_ext
5363echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5364echo "${ECHO_T}$ac_header_preproc" >&6
5365
5366# So? What about this header?
5367case $ac_header_compiler:$ac_header_preproc in
5368 yes:no )
5369 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&5
5370echo "$as_me: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
5371 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005372echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;}
5373 (
5374 cat <<\_ASBOX
5375## ------------------------------------ ##
5376## Report this to bug-autoconf@gnu.org. ##
5377## ------------------------------------ ##
5378_ASBOX
5379 ) |
5380 sed "s/^/$as_me: WARNING: /" >&2
5381 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005382 no:yes )
5383 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: present but cannot be compiled" >&5
5384echo "$as_me: WARNING: sys/sysmacros.h: present but cannot be compiled" >&2;}
5385 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&5
5386echo "$as_me: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&2;}
5387 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005388echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;}
5389 (
5390 cat <<\_ASBOX
5391## ------------------------------------ ##
5392## Report this to bug-autoconf@gnu.org. ##
5393## ------------------------------------ ##
5394_ASBOX
5395 ) |
5396 sed "s/^/$as_me: WARNING: /" >&2
5397 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00005398esac
5399echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
5400echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6
5401if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
5402 echo $ECHO_N "(cached) $ECHO_C" >&6
5403else
5404 ac_cv_header_sys_sysmacros_h=$ac_header_preproc
5405fi
5406echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
5407echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6
5408
5409fi
5410if test $ac_cv_header_sys_sysmacros_h = yes; then
5411
5412cat >>confdefs.h <<\_ACEOF
5413#define MAJOR_IN_SYSMACROS 1
5414_ACEOF
5415
5416fi
5417
5418
5419 fi
5420fi
5421
Michael W. Hudson54241132001-12-07 15:38:26 +00005422
Guido van Rossum627b2d71993-12-24 10:39:16 +00005423# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00005424was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +00005425echo "$as_me:$LINENO: checking for clock_t in time.h" >&5
5426echo $ECHO_N "checking for clock_t in time.h... $ECHO_C" >&6
5427cat >conftest.$ac_ext <<_ACEOF
5428#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005429/* confdefs.h. */
5430_ACEOF
5431cat confdefs.h >>conftest.$ac_ext
5432cat >>conftest.$ac_ext <<_ACEOF
5433/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005434#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005435
5436_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005437if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00005438 $EGREP "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00005439 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005440else
Martin v. Löwis11437992002-04-12 09:54:03 +00005441
5442
5443cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005444#define clock_t long
Martin v. Löwis11437992002-04-12 09:54:03 +00005445_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00005446
Martin v. Löwisc45929e2002-04-06 10:10:49 +00005447
Guido van Rossum627b2d71993-12-24 10:39:16 +00005448fi
5449rm -f conftest*
5450
Martin v. Löwis11437992002-04-12 09:54:03 +00005451echo "$as_me:$LINENO: result: $was_it_defined" >&5
5452echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00005453
Neal Norwitz11690112002-07-30 01:08:28 +00005454# Check whether using makedev requires defining _OSF_SOURCE
5455echo "$as_me:$LINENO: checking for makedev" >&5
5456echo $ECHO_N "checking for makedev... $ECHO_C" >&6
5457cat >conftest.$ac_ext <<_ACEOF
5458#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005459/* confdefs.h. */
5460_ACEOF
5461cat confdefs.h >>conftest.$ac_ext
5462cat >>conftest.$ac_ext <<_ACEOF
5463/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +00005464#include <sys/types.h>
Neal Norwitz11690112002-07-30 01:08:28 +00005465int
5466main ()
5467{
5468 makedev(0, 0)
5469 ;
5470 return 0;
5471}
5472_ACEOF
5473rm -f conftest.$ac_objext conftest$ac_exeext
5474if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5475 (eval $ac_link) 2>&5
5476 ac_status=$?
5477 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5478 (exit $ac_status); } &&
5479 { ac_try='test -s conftest$ac_exeext'
5480 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5481 (eval $ac_try) 2>&5
5482 ac_status=$?
5483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5484 (exit $ac_status); }; }; then
5485 ac_cv_has_makedev=yes
5486else
5487 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005488sed 's/^/| /' conftest.$ac_ext >&5
5489
Neal Norwitz11690112002-07-30 01:08:28 +00005490ac_cv_has_makedev=no
5491fi
5492rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5493if test "$ac_cv_has_makedev" = "no"; then
5494 # we didn't link, try if _OSF_SOURCE will allow us to link
5495 cat >conftest.$ac_ext <<_ACEOF
5496#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005497/* confdefs.h. */
5498_ACEOF
5499cat confdefs.h >>conftest.$ac_ext
5500cat >>conftest.$ac_ext <<_ACEOF
5501/* end confdefs.h. */
Neal Norwitz11690112002-07-30 01:08:28 +00005502
Neal Norwitz6eb37f02003-02-23 23:28:15 +00005503#define _OSF_SOURCE 1
5504#include <sys/types.h>
Neal Norwitz11690112002-07-30 01:08:28 +00005505
Neal Norwitz11690112002-07-30 01:08:28 +00005506int
5507main ()
5508{
5509 makedev(0, 0)
5510 ;
5511 return 0;
5512}
5513_ACEOF
5514rm -f conftest.$ac_objext conftest$ac_exeext
5515if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5516 (eval $ac_link) 2>&5
5517 ac_status=$?
5518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5519 (exit $ac_status); } &&
5520 { ac_try='test -s conftest$ac_exeext'
5521 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5522 (eval $ac_try) 2>&5
5523 ac_status=$?
5524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5525 (exit $ac_status); }; }; then
5526 ac_cv_has_makedev=yes
5527else
5528 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005529sed 's/^/| /' conftest.$ac_ext >&5
5530
Neal Norwitz11690112002-07-30 01:08:28 +00005531ac_cv_has_makedev=no
5532fi
5533rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5534 if test "$ac_cv_has_makedev" = "yes"; then
5535
5536cat >>confdefs.h <<\_ACEOF
5537#define _OSF_SOURCE 1
5538_ACEOF
5539
5540 fi
5541fi
5542echo "$as_me:$LINENO: result: $ac_cv_has_makedev" >&5
5543echo "${ECHO_T}$ac_cv_has_makedev" >&6
5544if test "$ac_cv_has_makedev" = "yes"; then
5545
5546cat >>confdefs.h <<\_ACEOF
5547#define HAVE_MAKEDEV 1
5548_ACEOF
5549
5550fi
5551
Martin v. Löwis399a6892002-10-04 10:22:02 +00005552# Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in
5553# the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are
5554# defined, but the compiler does not support pragma redefine_extname,
5555# and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit
5556# structures (such as rlimit64) without declaring them. As a
5557# work-around, disable LFS on such configurations
5558
5559use_lfs=yes
5560echo "$as_me:$LINENO: checking Solaris LFS bug" >&5
5561echo $ECHO_N "checking Solaris LFS bug... $ECHO_C" >&6
5562cat >conftest.$ac_ext <<_ACEOF
5563#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005564/* confdefs.h. */
5565_ACEOF
5566cat confdefs.h >>conftest.$ac_ext
5567cat >>conftest.$ac_ext <<_ACEOF
5568/* end confdefs.h. */
Martin v. Löwis399a6892002-10-04 10:22:02 +00005569
5570#define _LARGEFILE_SOURCE 1
5571#define _FILE_OFFSET_BITS 64
5572#include <sys/resource.h>
5573
Martin v. Löwis399a6892002-10-04 10:22:02 +00005574int
5575main ()
5576{
5577struct rlimit foo;
5578 ;
5579 return 0;
5580}
5581_ACEOF
5582rm -f conftest.$ac_objext
5583if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5584 (eval $ac_compile) 2>&5
5585 ac_status=$?
5586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5587 (exit $ac_status); } &&
5588 { ac_try='test -s conftest.$ac_objext'
5589 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5590 (eval $ac_try) 2>&5
5591 ac_status=$?
5592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5593 (exit $ac_status); }; }; then
5594 sol_lfs_bug=no
5595else
5596 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005597sed 's/^/| /' conftest.$ac_ext >&5
5598
Martin v. Löwis399a6892002-10-04 10:22:02 +00005599sol_lfs_bug=yes
5600fi
5601rm -f conftest.$ac_objext conftest.$ac_ext
5602echo "$as_me:$LINENO: result: $sol_lfs_bug" >&5
5603echo "${ECHO_T}$sol_lfs_bug" >&6
5604if test "$sol_lfs_bug" = "yes"; then
5605 use_lfs=no
5606fi
5607
5608if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00005609# Two defines needed to enable largefile support on various platforms
5610# These may affect some typedefs
Guido van Rossum810cc512001-09-09 23:51:39 +00005611
Martin v. Löwis11437992002-04-12 09:54:03 +00005612cat >>confdefs.h <<\_ACEOF
5613#define _LARGEFILE_SOURCE 1
5614_ACEOF
5615
5616
5617cat >>confdefs.h <<\_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00005618#define _FILE_OFFSET_BITS 64
Martin v. Löwis11437992002-04-12 09:54:03 +00005619_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00005620
Martin v. Löwis399a6892002-10-04 10:22:02 +00005621fi
Michael W. Hudson54241132001-12-07 15:38:26 +00005622
Guido van Rossum84e7b241996-08-19 21:59:00 +00005623# Add some code to confdefs.h so that the test for off_t works on SCO
5624cat >> confdefs.h <<\EOF
5625#if defined(SCO_DS)
5626#undef _OFF_T
5627#endif
5628EOF
5629
Guido van Rossumef2255b2000-03-10 22:30:29 +00005630# Type availability checks
Martin v. Löwis11437992002-04-12 09:54:03 +00005631echo "$as_me:$LINENO: checking for mode_t" >&5
5632echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
5633if test "${ac_cv_type_mode_t+set}" = set; then
5634 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005635else
Martin v. Löwis11437992002-04-12 09:54:03 +00005636 cat >conftest.$ac_ext <<_ACEOF
5637#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005638/* confdefs.h. */
5639_ACEOF
5640cat confdefs.h >>conftest.$ac_ext
5641cat >>conftest.$ac_ext <<_ACEOF
5642/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005643$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00005644int
5645main ()
5646{
5647if ((mode_t *) 0)
5648 return 0;
5649if (sizeof (mode_t))
5650 return 0;
5651 ;
5652 return 0;
5653}
5654_ACEOF
5655rm -f conftest.$ac_objext
5656if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5657 (eval $ac_compile) 2>&5
5658 ac_status=$?
5659 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5660 (exit $ac_status); } &&
5661 { ac_try='test -s conftest.$ac_objext'
5662 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5663 (eval $ac_try) 2>&5
5664 ac_status=$?
5665 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5666 (exit $ac_status); }; }; then
Jack Jansendd19cf82001-12-06 22:36:17 +00005667 ac_cv_type_mode_t=yes
5668else
Martin v. Löwis11437992002-04-12 09:54:03 +00005669 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005670sed 's/^/| /' conftest.$ac_ext >&5
5671
Martin v. Löwis11437992002-04-12 09:54:03 +00005672ac_cv_type_mode_t=no
Jack Jansendd19cf82001-12-06 22:36:17 +00005673fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005674rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005675fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005676echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
5677echo "${ECHO_T}$ac_cv_type_mode_t" >&6
5678if test $ac_cv_type_mode_t = yes; then
5679 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005680else
Martin v. Löwis11437992002-04-12 09:54:03 +00005681
5682cat >>confdefs.h <<_ACEOF
5683#define mode_t int
5684_ACEOF
5685
5686fi
5687
5688echo "$as_me:$LINENO: checking for off_t" >&5
5689echo $ECHO_N "checking for off_t... $ECHO_C" >&6
5690if test "${ac_cv_type_off_t+set}" = set; then
5691 echo $ECHO_N "(cached) $ECHO_C" >&6
5692else
5693 cat >conftest.$ac_ext <<_ACEOF
5694#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005695/* confdefs.h. */
5696_ACEOF
5697cat confdefs.h >>conftest.$ac_ext
5698cat >>conftest.$ac_ext <<_ACEOF
5699/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005700$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00005701int
5702main ()
5703{
5704if ((off_t *) 0)
5705 return 0;
5706if (sizeof (off_t))
5707 return 0;
5708 ;
5709 return 0;
5710}
5711_ACEOF
5712rm -f conftest.$ac_objext
5713if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5714 (eval $ac_compile) 2>&5
5715 ac_status=$?
5716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5717 (exit $ac_status); } &&
5718 { ac_try='test -s conftest.$ac_objext'
5719 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5720 (eval $ac_try) 2>&5
5721 ac_status=$?
5722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5723 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00005724 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005725else
Martin v. Löwis11437992002-04-12 09:54:03 +00005726 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005727sed 's/^/| /' conftest.$ac_ext >&5
5728
Martin v. Löwis11437992002-04-12 09:54:03 +00005729ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00005730fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005731rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005732fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005733echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
5734echo "${ECHO_T}$ac_cv_type_off_t" >&6
5735if test $ac_cv_type_off_t = yes; then
5736 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005737else
Martin v. Löwis11437992002-04-12 09:54:03 +00005738
5739cat >>confdefs.h <<_ACEOF
5740#define off_t long
5741_ACEOF
5742
5743fi
5744
5745echo "$as_me:$LINENO: checking for pid_t" >&5
5746echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
5747if test "${ac_cv_type_pid_t+set}" = set; then
5748 echo $ECHO_N "(cached) $ECHO_C" >&6
5749else
5750 cat >conftest.$ac_ext <<_ACEOF
5751#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005752/* confdefs.h. */
5753_ACEOF
5754cat confdefs.h >>conftest.$ac_ext
5755cat >>conftest.$ac_ext <<_ACEOF
5756/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005757$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00005758int
5759main ()
5760{
5761if ((pid_t *) 0)
5762 return 0;
5763if (sizeof (pid_t))
5764 return 0;
5765 ;
5766 return 0;
5767}
5768_ACEOF
5769rm -f conftest.$ac_objext
5770if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5771 (eval $ac_compile) 2>&5
5772 ac_status=$?
5773 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5774 (exit $ac_status); } &&
5775 { ac_try='test -s conftest.$ac_objext'
5776 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5777 (eval $ac_try) 2>&5
5778 ac_status=$?
5779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5780 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00005781 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005782else
Martin v. Löwis11437992002-04-12 09:54:03 +00005783 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005784sed 's/^/| /' conftest.$ac_ext >&5
5785
Martin v. Löwis11437992002-04-12 09:54:03 +00005786ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00005787fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005788rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005789fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005790echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
5791echo "${ECHO_T}$ac_cv_type_pid_t" >&6
5792if test $ac_cv_type_pid_t = yes; then
5793 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005794else
Martin v. Löwis11437992002-04-12 09:54:03 +00005795
5796cat >>confdefs.h <<_ACEOF
5797#define pid_t int
5798_ACEOF
5799
5800fi
5801
5802echo "$as_me:$LINENO: checking return type of signal handlers" >&5
5803echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5804if test "${ac_cv_type_signal+set}" = set; then
5805 echo $ECHO_N "(cached) $ECHO_C" >&6
5806else
5807 cat >conftest.$ac_ext <<_ACEOF
5808#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005809/* confdefs.h. */
5810_ACEOF
5811cat confdefs.h >>conftest.$ac_ext
5812cat >>conftest.$ac_ext <<_ACEOF
5813/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00005814#include <sys/types.h>
5815#include <signal.h>
5816#ifdef signal
Martin v. Löwis11437992002-04-12 09:54:03 +00005817# undef signal
Guido van Rossum627b2d71993-12-24 10:39:16 +00005818#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00005819#ifdef __cplusplus
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005820extern "C" void (*signal (int, void (*)(int)))(int);
5821#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00005822void (*signal ()) ();
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005823#endif
5824
Martin v. Löwis11437992002-04-12 09:54:03 +00005825int
5826main ()
5827{
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005828int i;
Martin v. Löwis11437992002-04-12 09:54:03 +00005829 ;
5830 return 0;
5831}
5832_ACEOF
5833rm -f conftest.$ac_objext
5834if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5835 (eval $ac_compile) 2>&5
5836 ac_status=$?
5837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5838 (exit $ac_status); } &&
5839 { ac_try='test -s conftest.$ac_objext'
5840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5841 (eval $ac_try) 2>&5
5842 ac_status=$?
5843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5844 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005845 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00005846else
Martin v. Löwis11437992002-04-12 09:54:03 +00005847 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005848sed 's/^/| /' conftest.$ac_ext >&5
5849
Martin v. Löwis11437992002-04-12 09:54:03 +00005850ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00005851fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005852rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005853fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005854echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
5855echo "${ECHO_T}$ac_cv_type_signal" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005856
Martin v. Löwis11437992002-04-12 09:54:03 +00005857cat >>confdefs.h <<_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005858#define RETSIGTYPE $ac_cv_type_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00005859_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00005860
Michael W. Hudson54241132001-12-07 15:38:26 +00005861
Martin v. Löwis11437992002-04-12 09:54:03 +00005862echo "$as_me:$LINENO: checking for size_t" >&5
5863echo $ECHO_N "checking for size_t... $ECHO_C" >&6
5864if test "${ac_cv_type_size_t+set}" = set; then
5865 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005866else
Martin v. Löwis11437992002-04-12 09:54:03 +00005867 cat >conftest.$ac_ext <<_ACEOF
5868#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005869/* confdefs.h. */
5870_ACEOF
5871cat confdefs.h >>conftest.$ac_ext
5872cat >>conftest.$ac_ext <<_ACEOF
5873/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005874$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00005875int
5876main ()
5877{
5878if ((size_t *) 0)
5879 return 0;
5880if (sizeof (size_t))
5881 return 0;
5882 ;
5883 return 0;
5884}
5885_ACEOF
5886rm -f conftest.$ac_objext
5887if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5888 (eval $ac_compile) 2>&5
5889 ac_status=$?
5890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5891 (exit $ac_status); } &&
5892 { ac_try='test -s conftest.$ac_objext'
5893 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5894 (eval $ac_try) 2>&5
5895 ac_status=$?
5896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5897 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00005898 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005899else
Martin v. Löwis11437992002-04-12 09:54:03 +00005900 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005901sed 's/^/| /' conftest.$ac_ext >&5
5902
Martin v. Löwis11437992002-04-12 09:54:03 +00005903ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00005904fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005905rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005906fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005907echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
5908echo "${ECHO_T}$ac_cv_type_size_t" >&6
5909if test $ac_cv_type_size_t = yes; then
5910 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005911else
Martin v. Löwis11437992002-04-12 09:54:03 +00005912
5913cat >>confdefs.h <<_ACEOF
5914#define size_t unsigned
5915_ACEOF
5916
5917fi
5918
5919echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
5920echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
5921if test "${ac_cv_type_uid_t+set}" = set; then
5922 echo $ECHO_N "(cached) $ECHO_C" >&6
5923else
5924 cat >conftest.$ac_ext <<_ACEOF
5925#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005926/* confdefs.h. */
5927_ACEOF
5928cat confdefs.h >>conftest.$ac_ext
5929cat >>conftest.$ac_ext <<_ACEOF
5930/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005931#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005932
5933_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005934if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +00005935 $EGREP "uid_t" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005936 ac_cv_type_uid_t=yes
5937else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005938 ac_cv_type_uid_t=no
5939fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00005940rm -f conftest*
5941
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005942fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005943echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
5944echo "${ECHO_T}$ac_cv_type_uid_t" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00005945if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005946
Martin v. Löwis11437992002-04-12 09:54:03 +00005947cat >>confdefs.h <<\_ACEOF
5948#define uid_t int
5949_ACEOF
5950
5951
5952cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005953#define gid_t int
Martin v. Löwis11437992002-04-12 09:54:03 +00005954_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005955
5956fi
5957
Jack Jansendd19cf82001-12-06 22:36:17 +00005958
Michael W. Hudson54241132001-12-07 15:38:26 +00005959# Sizes of various common basic types
Martin v. Löwis11437992002-04-12 09:54:03 +00005960echo "$as_me:$LINENO: checking for int" >&5
5961echo $ECHO_N "checking for int... $ECHO_C" >&6
5962if test "${ac_cv_type_int+set}" = set; then
5963 echo $ECHO_N "(cached) $ECHO_C" >&6
5964else
5965 cat >conftest.$ac_ext <<_ACEOF
5966#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00005967/* confdefs.h. */
5968_ACEOF
5969cat confdefs.h >>conftest.$ac_ext
5970cat >>conftest.$ac_ext <<_ACEOF
5971/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005972$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00005973int
5974main ()
5975{
5976if ((int *) 0)
5977 return 0;
5978if (sizeof (int))
5979 return 0;
5980 ;
5981 return 0;
5982}
5983_ACEOF
5984rm -f conftest.$ac_objext
5985if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5986 (eval $ac_compile) 2>&5
5987 ac_status=$?
5988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5989 (exit $ac_status); } &&
5990 { ac_try='test -s conftest.$ac_objext'
5991 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5992 (eval $ac_try) 2>&5
5993 ac_status=$?
5994 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5995 (exit $ac_status); }; }; then
5996 ac_cv_type_int=yes
5997else
5998 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00005999sed 's/^/| /' conftest.$ac_ext >&5
6000
Martin v. Löwis11437992002-04-12 09:54:03 +00006001ac_cv_type_int=no
6002fi
6003rm -f conftest.$ac_objext conftest.$ac_ext
6004fi
6005echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
6006echo "${ECHO_T}$ac_cv_type_int" >&6
6007
6008echo "$as_me:$LINENO: checking size of int" >&5
6009echo $ECHO_N "checking size of int... $ECHO_C" >&6
6010if test "${ac_cv_sizeof_int+set}" = set; then
6011 echo $ECHO_N "(cached) $ECHO_C" >&6
6012else
6013 if test "$ac_cv_type_int" = yes; then
6014 # The cast to unsigned long works around a bug in the HP C Compiler
6015 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6016 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6017 # This bug is HP SR number 8606223364.
6018 if test "$cross_compiling" = yes; then
6019 # Depending upon the size, compute the lo and hi bounds.
6020cat >conftest.$ac_ext <<_ACEOF
6021#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006022/* confdefs.h. */
6023_ACEOF
6024cat confdefs.h >>conftest.$ac_ext
6025cat >>conftest.$ac_ext <<_ACEOF
6026/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006027$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006028int
6029main ()
6030{
6031static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
6032test_array [0] = 0
6033
6034 ;
6035 return 0;
6036}
6037_ACEOF
6038rm -f conftest.$ac_objext
6039if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6040 (eval $ac_compile) 2>&5
6041 ac_status=$?
6042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6043 (exit $ac_status); } &&
6044 { ac_try='test -s conftest.$ac_objext'
6045 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6046 (eval $ac_try) 2>&5
6047 ac_status=$?
6048 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6049 (exit $ac_status); }; }; then
6050 ac_lo=0 ac_mid=0
6051 while :; do
6052 cat >conftest.$ac_ext <<_ACEOF
6053#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006054/* confdefs.h. */
6055_ACEOF
6056cat confdefs.h >>conftest.$ac_ext
6057cat >>conftest.$ac_ext <<_ACEOF
6058/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006059$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006060int
6061main ()
6062{
6063static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
6064test_array [0] = 0
6065
6066 ;
6067 return 0;
6068}
6069_ACEOF
6070rm -f conftest.$ac_objext
6071if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6072 (eval $ac_compile) 2>&5
6073 ac_status=$?
6074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6075 (exit $ac_status); } &&
6076 { ac_try='test -s conftest.$ac_objext'
6077 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6078 (eval $ac_try) 2>&5
6079 ac_status=$?
6080 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6081 (exit $ac_status); }; }; then
6082 ac_hi=$ac_mid; break
6083else
6084 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006085sed 's/^/| /' conftest.$ac_ext >&5
6086
Martin v. Löwis11437992002-04-12 09:54:03 +00006087ac_lo=`expr $ac_mid + 1`
6088 if test $ac_lo -le $ac_mid; then
6089 ac_lo= ac_hi=
6090 break
6091 fi
6092 ac_mid=`expr 2 '*' $ac_mid + 1`
6093fi
6094rm -f conftest.$ac_objext conftest.$ac_ext
6095 done
6096else
6097 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006098sed 's/^/| /' conftest.$ac_ext >&5
6099
Martin v. Löwis11437992002-04-12 09:54:03 +00006100cat >conftest.$ac_ext <<_ACEOF
6101#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006102/* confdefs.h. */
6103_ACEOF
6104cat confdefs.h >>conftest.$ac_ext
6105cat >>conftest.$ac_ext <<_ACEOF
6106/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006107$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006108int
6109main ()
6110{
6111static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
6112test_array [0] = 0
6113
6114 ;
6115 return 0;
6116}
6117_ACEOF
6118rm -f conftest.$ac_objext
6119if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6120 (eval $ac_compile) 2>&5
6121 ac_status=$?
6122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6123 (exit $ac_status); } &&
6124 { ac_try='test -s conftest.$ac_objext'
6125 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6126 (eval $ac_try) 2>&5
6127 ac_status=$?
6128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6129 (exit $ac_status); }; }; then
6130 ac_hi=-1 ac_mid=-1
6131 while :; do
6132 cat >conftest.$ac_ext <<_ACEOF
6133#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006134/* confdefs.h. */
6135_ACEOF
6136cat confdefs.h >>conftest.$ac_ext
6137cat >>conftest.$ac_ext <<_ACEOF
6138/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006139$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006140int
6141main ()
6142{
6143static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
6144test_array [0] = 0
6145
6146 ;
6147 return 0;
6148}
6149_ACEOF
6150rm -f conftest.$ac_objext
6151if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6152 (eval $ac_compile) 2>&5
6153 ac_status=$?
6154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6155 (exit $ac_status); } &&
6156 { ac_try='test -s conftest.$ac_objext'
6157 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6158 (eval $ac_try) 2>&5
6159 ac_status=$?
6160 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6161 (exit $ac_status); }; }; then
6162 ac_lo=$ac_mid; break
6163else
6164 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006165sed 's/^/| /' conftest.$ac_ext >&5
6166
Martin v. Löwis11437992002-04-12 09:54:03 +00006167ac_hi=`expr '(' $ac_mid ')' - 1`
6168 if test $ac_mid -le $ac_hi; then
6169 ac_lo= ac_hi=
6170 break
6171 fi
6172 ac_mid=`expr 2 '*' $ac_mid`
6173fi
6174rm -f conftest.$ac_objext conftest.$ac_ext
6175 done
6176else
6177 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006178sed 's/^/| /' conftest.$ac_ext >&5
6179
Martin v. Löwis11437992002-04-12 09:54:03 +00006180ac_lo= ac_hi=
6181fi
6182rm -f conftest.$ac_objext conftest.$ac_ext
6183fi
6184rm -f conftest.$ac_objext conftest.$ac_ext
6185# Binary search between lo and hi bounds.
6186while test "x$ac_lo" != "x$ac_hi"; do
6187 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6188 cat >conftest.$ac_ext <<_ACEOF
6189#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006190/* confdefs.h. */
6191_ACEOF
6192cat confdefs.h >>conftest.$ac_ext
6193cat >>conftest.$ac_ext <<_ACEOF
6194/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006195$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006196int
6197main ()
6198{
6199static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
6200test_array [0] = 0
6201
6202 ;
6203 return 0;
6204}
6205_ACEOF
6206rm -f conftest.$ac_objext
6207if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6208 (eval $ac_compile) 2>&5
6209 ac_status=$?
6210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6211 (exit $ac_status); } &&
6212 { ac_try='test -s conftest.$ac_objext'
6213 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6214 (eval $ac_try) 2>&5
6215 ac_status=$?
6216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6217 (exit $ac_status); }; }; then
6218 ac_hi=$ac_mid
6219else
6220 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006221sed 's/^/| /' conftest.$ac_ext >&5
6222
Martin v. Löwis11437992002-04-12 09:54:03 +00006223ac_lo=`expr '(' $ac_mid ')' + 1`
6224fi
6225rm -f conftest.$ac_objext conftest.$ac_ext
6226done
6227case $ac_lo in
6228?*) ac_cv_sizeof_int=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00006229'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
6230See \`config.log' for more details." >&5
6231echo "$as_me: error: cannot compute sizeof (int), 77
6232See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006233 { (exit 1); exit 1; }; } ;;
6234esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006235else
6236 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00006237 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
6238See \`config.log' for more details." >&5
6239echo "$as_me: error: cannot run test program while cross compiling
6240See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006241 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006242else
Martin v. Löwis11437992002-04-12 09:54:03 +00006243 cat >conftest.$ac_ext <<_ACEOF
6244#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006245/* confdefs.h. */
6246_ACEOF
6247cat confdefs.h >>conftest.$ac_ext
6248cat >>conftest.$ac_ext <<_ACEOF
6249/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006250$ac_includes_default
6251long longval () { return (long) (sizeof (int)); }
6252unsigned long ulongval () { return (long) (sizeof (int)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006253#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006254#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006255int
6256main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006257{
Martin v. Löwis11437992002-04-12 09:54:03 +00006258
6259 FILE *f = fopen ("conftest.val", "w");
6260 if (! f)
6261 exit (1);
6262 if (((long) (sizeof (int))) < 0)
6263 {
6264 long i = longval ();
6265 if (i != ((long) (sizeof (int))))
6266 exit (1);
6267 fprintf (f, "%ld\n", i);
6268 }
6269 else
6270 {
6271 unsigned long i = ulongval ();
6272 if (i != ((long) (sizeof (int))))
6273 exit (1);
6274 fprintf (f, "%lu\n", i);
6275 }
6276 exit (ferror (f) || fclose (f) != 0);
6277
6278 ;
6279 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006280}
Martin v. Löwis11437992002-04-12 09:54:03 +00006281_ACEOF
6282rm -f conftest$ac_exeext
6283if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6284 (eval $ac_link) 2>&5
6285 ac_status=$?
6286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6287 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6288 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6289 (eval $ac_try) 2>&5
6290 ac_status=$?
6291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6292 (exit $ac_status); }; }; then
6293 ac_cv_sizeof_int=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006294else
Martin v. Löwis11437992002-04-12 09:54:03 +00006295 echo "$as_me: program exited with status $ac_status" >&5
6296echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006297sed 's/^/| /' conftest.$ac_ext >&5
6298
Martin v. Löwis11437992002-04-12 09:54:03 +00006299( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00006300{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77
6301See \`config.log' for more details." >&5
6302echo "$as_me: error: cannot compute sizeof (int), 77
6303See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006304 { (exit 1); exit 1; }; }
6305fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00006306rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00006307fi
6308fi
6309rm -f conftest.val
6310else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006311 ac_cv_sizeof_int=0
6312fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006313fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006314echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
6315echo "${ECHO_T}$ac_cv_sizeof_int" >&6
6316cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006317#define SIZEOF_INT $ac_cv_sizeof_int
Martin v. Löwis11437992002-04-12 09:54:03 +00006318_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006319
6320
Martin v. Löwis11437992002-04-12 09:54:03 +00006321echo "$as_me:$LINENO: checking for long" >&5
6322echo $ECHO_N "checking for long... $ECHO_C" >&6
6323if test "${ac_cv_type_long+set}" = set; then
6324 echo $ECHO_N "(cached) $ECHO_C" >&6
6325else
6326 cat >conftest.$ac_ext <<_ACEOF
6327#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006328/* confdefs.h. */
6329_ACEOF
6330cat confdefs.h >>conftest.$ac_ext
6331cat >>conftest.$ac_ext <<_ACEOF
6332/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006333$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006334int
6335main ()
6336{
6337if ((long *) 0)
6338 return 0;
6339if (sizeof (long))
6340 return 0;
6341 ;
6342 return 0;
6343}
6344_ACEOF
6345rm -f conftest.$ac_objext
6346if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6347 (eval $ac_compile) 2>&5
6348 ac_status=$?
6349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6350 (exit $ac_status); } &&
6351 { ac_try='test -s conftest.$ac_objext'
6352 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6353 (eval $ac_try) 2>&5
6354 ac_status=$?
6355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6356 (exit $ac_status); }; }; then
6357 ac_cv_type_long=yes
6358else
6359 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006360sed 's/^/| /' conftest.$ac_ext >&5
6361
Martin v. Löwis11437992002-04-12 09:54:03 +00006362ac_cv_type_long=no
6363fi
6364rm -f conftest.$ac_objext conftest.$ac_ext
6365fi
6366echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
6367echo "${ECHO_T}$ac_cv_type_long" >&6
6368
6369echo "$as_me:$LINENO: checking size of long" >&5
6370echo $ECHO_N "checking size of long... $ECHO_C" >&6
6371if test "${ac_cv_sizeof_long+set}" = set; then
6372 echo $ECHO_N "(cached) $ECHO_C" >&6
6373else
6374 if test "$ac_cv_type_long" = yes; then
6375 # The cast to unsigned long works around a bug in the HP C Compiler
6376 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6377 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6378 # This bug is HP SR number 8606223364.
6379 if test "$cross_compiling" = yes; then
6380 # Depending upon the size, compute the lo and hi bounds.
6381cat >conftest.$ac_ext <<_ACEOF
6382#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006383/* confdefs.h. */
6384_ACEOF
6385cat confdefs.h >>conftest.$ac_ext
6386cat >>conftest.$ac_ext <<_ACEOF
6387/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006388$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006389int
6390main ()
6391{
6392static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
6393test_array [0] = 0
6394
6395 ;
6396 return 0;
6397}
6398_ACEOF
6399rm -f conftest.$ac_objext
6400if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6401 (eval $ac_compile) 2>&5
6402 ac_status=$?
6403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6404 (exit $ac_status); } &&
6405 { ac_try='test -s conftest.$ac_objext'
6406 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6407 (eval $ac_try) 2>&5
6408 ac_status=$?
6409 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6410 (exit $ac_status); }; }; then
6411 ac_lo=0 ac_mid=0
6412 while :; do
6413 cat >conftest.$ac_ext <<_ACEOF
6414#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006415/* confdefs.h. */
6416_ACEOF
6417cat confdefs.h >>conftest.$ac_ext
6418cat >>conftest.$ac_ext <<_ACEOF
6419/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006420$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006421int
6422main ()
6423{
6424static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
6425test_array [0] = 0
6426
6427 ;
6428 return 0;
6429}
6430_ACEOF
6431rm -f conftest.$ac_objext
6432if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6433 (eval $ac_compile) 2>&5
6434 ac_status=$?
6435 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6436 (exit $ac_status); } &&
6437 { ac_try='test -s conftest.$ac_objext'
6438 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6439 (eval $ac_try) 2>&5
6440 ac_status=$?
6441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6442 (exit $ac_status); }; }; then
6443 ac_hi=$ac_mid; break
6444else
6445 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006446sed 's/^/| /' conftest.$ac_ext >&5
6447
Martin v. Löwis11437992002-04-12 09:54:03 +00006448ac_lo=`expr $ac_mid + 1`
6449 if test $ac_lo -le $ac_mid; then
6450 ac_lo= ac_hi=
6451 break
6452 fi
6453 ac_mid=`expr 2 '*' $ac_mid + 1`
6454fi
6455rm -f conftest.$ac_objext conftest.$ac_ext
6456 done
6457else
6458 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006459sed 's/^/| /' conftest.$ac_ext >&5
6460
Martin v. Löwis11437992002-04-12 09:54:03 +00006461cat >conftest.$ac_ext <<_ACEOF
6462#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006463/* confdefs.h. */
6464_ACEOF
6465cat confdefs.h >>conftest.$ac_ext
6466cat >>conftest.$ac_ext <<_ACEOF
6467/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006468$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006469int
6470main ()
6471{
6472static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
6473test_array [0] = 0
6474
6475 ;
6476 return 0;
6477}
6478_ACEOF
6479rm -f conftest.$ac_objext
6480if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6481 (eval $ac_compile) 2>&5
6482 ac_status=$?
6483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6484 (exit $ac_status); } &&
6485 { ac_try='test -s conftest.$ac_objext'
6486 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6487 (eval $ac_try) 2>&5
6488 ac_status=$?
6489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6490 (exit $ac_status); }; }; then
6491 ac_hi=-1 ac_mid=-1
6492 while :; do
6493 cat >conftest.$ac_ext <<_ACEOF
6494#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006495/* confdefs.h. */
6496_ACEOF
6497cat confdefs.h >>conftest.$ac_ext
6498cat >>conftest.$ac_ext <<_ACEOF
6499/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006500$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006501int
6502main ()
6503{
6504static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
6505test_array [0] = 0
6506
6507 ;
6508 return 0;
6509}
6510_ACEOF
6511rm -f conftest.$ac_objext
6512if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6513 (eval $ac_compile) 2>&5
6514 ac_status=$?
6515 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6516 (exit $ac_status); } &&
6517 { ac_try='test -s conftest.$ac_objext'
6518 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6519 (eval $ac_try) 2>&5
6520 ac_status=$?
6521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6522 (exit $ac_status); }; }; then
6523 ac_lo=$ac_mid; break
6524else
6525 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006526sed 's/^/| /' conftest.$ac_ext >&5
6527
Martin v. Löwis11437992002-04-12 09:54:03 +00006528ac_hi=`expr '(' $ac_mid ')' - 1`
6529 if test $ac_mid -le $ac_hi; then
6530 ac_lo= ac_hi=
6531 break
6532 fi
6533 ac_mid=`expr 2 '*' $ac_mid`
6534fi
6535rm -f conftest.$ac_objext conftest.$ac_ext
6536 done
6537else
6538 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006539sed 's/^/| /' conftest.$ac_ext >&5
6540
Martin v. Löwis11437992002-04-12 09:54:03 +00006541ac_lo= ac_hi=
6542fi
6543rm -f conftest.$ac_objext conftest.$ac_ext
6544fi
6545rm -f conftest.$ac_objext conftest.$ac_ext
6546# Binary search between lo and hi bounds.
6547while test "x$ac_lo" != "x$ac_hi"; do
6548 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6549 cat >conftest.$ac_ext <<_ACEOF
6550#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006551/* confdefs.h. */
6552_ACEOF
6553cat confdefs.h >>conftest.$ac_ext
6554cat >>conftest.$ac_ext <<_ACEOF
6555/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006556$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006557int
6558main ()
6559{
6560static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
6561test_array [0] = 0
6562
6563 ;
6564 return 0;
6565}
6566_ACEOF
6567rm -f conftest.$ac_objext
6568if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6569 (eval $ac_compile) 2>&5
6570 ac_status=$?
6571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6572 (exit $ac_status); } &&
6573 { ac_try='test -s conftest.$ac_objext'
6574 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6575 (eval $ac_try) 2>&5
6576 ac_status=$?
6577 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6578 (exit $ac_status); }; }; then
6579 ac_hi=$ac_mid
6580else
6581 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006582sed 's/^/| /' conftest.$ac_ext >&5
6583
Martin v. Löwis11437992002-04-12 09:54:03 +00006584ac_lo=`expr '(' $ac_mid ')' + 1`
6585fi
6586rm -f conftest.$ac_objext conftest.$ac_ext
6587done
6588case $ac_lo in
6589?*) ac_cv_sizeof_long=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00006590'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
6591See \`config.log' for more details." >&5
6592echo "$as_me: error: cannot compute sizeof (long), 77
6593See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006594 { (exit 1); exit 1; }; } ;;
6595esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006596else
6597 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00006598 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
6599See \`config.log' for more details." >&5
6600echo "$as_me: error: cannot run test program while cross compiling
6601See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006602 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006603else
Martin v. Löwis11437992002-04-12 09:54:03 +00006604 cat >conftest.$ac_ext <<_ACEOF
6605#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006606/* confdefs.h. */
6607_ACEOF
6608cat confdefs.h >>conftest.$ac_ext
6609cat >>conftest.$ac_ext <<_ACEOF
6610/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006611$ac_includes_default
6612long longval () { return (long) (sizeof (long)); }
6613unsigned long ulongval () { return (long) (sizeof (long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006614#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006615#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006616int
6617main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006618{
Martin v. Löwis11437992002-04-12 09:54:03 +00006619
6620 FILE *f = fopen ("conftest.val", "w");
6621 if (! f)
6622 exit (1);
6623 if (((long) (sizeof (long))) < 0)
6624 {
6625 long i = longval ();
6626 if (i != ((long) (sizeof (long))))
6627 exit (1);
6628 fprintf (f, "%ld\n", i);
6629 }
6630 else
6631 {
6632 unsigned long i = ulongval ();
6633 if (i != ((long) (sizeof (long))))
6634 exit (1);
6635 fprintf (f, "%lu\n", i);
6636 }
6637 exit (ferror (f) || fclose (f) != 0);
6638
6639 ;
6640 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006641}
Martin v. Löwis11437992002-04-12 09:54:03 +00006642_ACEOF
6643rm -f conftest$ac_exeext
6644if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6645 (eval $ac_link) 2>&5
6646 ac_status=$?
6647 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6648 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6649 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6650 (eval $ac_try) 2>&5
6651 ac_status=$?
6652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6653 (exit $ac_status); }; }; then
6654 ac_cv_sizeof_long=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006655else
Martin v. Löwis11437992002-04-12 09:54:03 +00006656 echo "$as_me: program exited with status $ac_status" >&5
6657echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006658sed 's/^/| /' conftest.$ac_ext >&5
6659
Martin v. Löwis11437992002-04-12 09:54:03 +00006660( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00006661{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77
6662See \`config.log' for more details." >&5
6663echo "$as_me: error: cannot compute sizeof (long), 77
6664See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006665 { (exit 1); exit 1; }; }
6666fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00006667rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00006668fi
6669fi
6670rm -f conftest.val
6671else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006672 ac_cv_sizeof_long=0
6673fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006674fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006675echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
6676echo "${ECHO_T}$ac_cv_sizeof_long" >&6
6677cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006678#define SIZEOF_LONG $ac_cv_sizeof_long
Martin v. Löwis11437992002-04-12 09:54:03 +00006679_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00006680
6681
Martin v. Löwis11437992002-04-12 09:54:03 +00006682echo "$as_me:$LINENO: checking for void *" >&5
6683echo $ECHO_N "checking for void *... $ECHO_C" >&6
6684if test "${ac_cv_type_void_p+set}" = set; then
6685 echo $ECHO_N "(cached) $ECHO_C" >&6
6686else
6687 cat >conftest.$ac_ext <<_ACEOF
6688#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006689/* confdefs.h. */
6690_ACEOF
6691cat confdefs.h >>conftest.$ac_ext
6692cat >>conftest.$ac_ext <<_ACEOF
6693/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006694$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006695int
6696main ()
6697{
6698if ((void * *) 0)
6699 return 0;
6700if (sizeof (void *))
6701 return 0;
6702 ;
6703 return 0;
6704}
6705_ACEOF
6706rm -f conftest.$ac_objext
6707if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6708 (eval $ac_compile) 2>&5
6709 ac_status=$?
6710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6711 (exit $ac_status); } &&
6712 { ac_try='test -s conftest.$ac_objext'
6713 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6714 (eval $ac_try) 2>&5
6715 ac_status=$?
6716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6717 (exit $ac_status); }; }; then
6718 ac_cv_type_void_p=yes
6719else
6720 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006721sed 's/^/| /' conftest.$ac_ext >&5
6722
Martin v. Löwis11437992002-04-12 09:54:03 +00006723ac_cv_type_void_p=no
6724fi
6725rm -f conftest.$ac_objext conftest.$ac_ext
6726fi
6727echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
6728echo "${ECHO_T}$ac_cv_type_void_p" >&6
6729
6730echo "$as_me:$LINENO: checking size of void *" >&5
6731echo $ECHO_N "checking size of void *... $ECHO_C" >&6
6732if test "${ac_cv_sizeof_void_p+set}" = set; then
6733 echo $ECHO_N "(cached) $ECHO_C" >&6
6734else
6735 if test "$ac_cv_type_void_p" = yes; then
6736 # The cast to unsigned long works around a bug in the HP C Compiler
6737 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6738 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6739 # This bug is HP SR number 8606223364.
6740 if test "$cross_compiling" = yes; then
6741 # Depending upon the size, compute the lo and hi bounds.
6742cat >conftest.$ac_ext <<_ACEOF
6743#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006744/* confdefs.h. */
6745_ACEOF
6746cat confdefs.h >>conftest.$ac_ext
6747cat >>conftest.$ac_ext <<_ACEOF
6748/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006749$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006750int
6751main ()
6752{
6753static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
6754test_array [0] = 0
6755
6756 ;
6757 return 0;
6758}
6759_ACEOF
6760rm -f conftest.$ac_objext
6761if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6762 (eval $ac_compile) 2>&5
6763 ac_status=$?
6764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6765 (exit $ac_status); } &&
6766 { ac_try='test -s conftest.$ac_objext'
6767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6768 (eval $ac_try) 2>&5
6769 ac_status=$?
6770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6771 (exit $ac_status); }; }; then
6772 ac_lo=0 ac_mid=0
6773 while :; do
6774 cat >conftest.$ac_ext <<_ACEOF
6775#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006776/* confdefs.h. */
6777_ACEOF
6778cat confdefs.h >>conftest.$ac_ext
6779cat >>conftest.$ac_ext <<_ACEOF
6780/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006781$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006782int
6783main ()
6784{
6785static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
6786test_array [0] = 0
6787
6788 ;
6789 return 0;
6790}
6791_ACEOF
6792rm -f conftest.$ac_objext
6793if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6794 (eval $ac_compile) 2>&5
6795 ac_status=$?
6796 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6797 (exit $ac_status); } &&
6798 { ac_try='test -s conftest.$ac_objext'
6799 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6800 (eval $ac_try) 2>&5
6801 ac_status=$?
6802 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6803 (exit $ac_status); }; }; then
6804 ac_hi=$ac_mid; break
6805else
6806 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006807sed 's/^/| /' conftest.$ac_ext >&5
6808
Martin v. Löwis11437992002-04-12 09:54:03 +00006809ac_lo=`expr $ac_mid + 1`
6810 if test $ac_lo -le $ac_mid; then
6811 ac_lo= ac_hi=
6812 break
6813 fi
6814 ac_mid=`expr 2 '*' $ac_mid + 1`
6815fi
6816rm -f conftest.$ac_objext conftest.$ac_ext
6817 done
6818else
6819 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006820sed 's/^/| /' conftest.$ac_ext >&5
6821
Martin v. Löwis11437992002-04-12 09:54:03 +00006822cat >conftest.$ac_ext <<_ACEOF
6823#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006824/* confdefs.h. */
6825_ACEOF
6826cat confdefs.h >>conftest.$ac_ext
6827cat >>conftest.$ac_ext <<_ACEOF
6828/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006829$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006830int
6831main ()
6832{
6833static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
6834test_array [0] = 0
6835
6836 ;
6837 return 0;
6838}
6839_ACEOF
6840rm -f conftest.$ac_objext
6841if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6842 (eval $ac_compile) 2>&5
6843 ac_status=$?
6844 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6845 (exit $ac_status); } &&
6846 { ac_try='test -s conftest.$ac_objext'
6847 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6848 (eval $ac_try) 2>&5
6849 ac_status=$?
6850 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6851 (exit $ac_status); }; }; then
6852 ac_hi=-1 ac_mid=-1
6853 while :; do
6854 cat >conftest.$ac_ext <<_ACEOF
6855#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006856/* confdefs.h. */
6857_ACEOF
6858cat confdefs.h >>conftest.$ac_ext
6859cat >>conftest.$ac_ext <<_ACEOF
6860/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006861$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006862int
6863main ()
6864{
6865static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
6866test_array [0] = 0
6867
6868 ;
6869 return 0;
6870}
6871_ACEOF
6872rm -f conftest.$ac_objext
6873if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6874 (eval $ac_compile) 2>&5
6875 ac_status=$?
6876 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6877 (exit $ac_status); } &&
6878 { ac_try='test -s conftest.$ac_objext'
6879 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6880 (eval $ac_try) 2>&5
6881 ac_status=$?
6882 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6883 (exit $ac_status); }; }; then
6884 ac_lo=$ac_mid; break
6885else
6886 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006887sed 's/^/| /' conftest.$ac_ext >&5
6888
Martin v. Löwis11437992002-04-12 09:54:03 +00006889ac_hi=`expr '(' $ac_mid ')' - 1`
6890 if test $ac_mid -le $ac_hi; then
6891 ac_lo= ac_hi=
6892 break
6893 fi
6894 ac_mid=`expr 2 '*' $ac_mid`
6895fi
6896rm -f conftest.$ac_objext conftest.$ac_ext
6897 done
6898else
6899 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006900sed 's/^/| /' conftest.$ac_ext >&5
6901
Martin v. Löwis11437992002-04-12 09:54:03 +00006902ac_lo= ac_hi=
6903fi
6904rm -f conftest.$ac_objext conftest.$ac_ext
6905fi
6906rm -f conftest.$ac_objext conftest.$ac_ext
6907# Binary search between lo and hi bounds.
6908while test "x$ac_lo" != "x$ac_hi"; do
6909 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6910 cat >conftest.$ac_ext <<_ACEOF
6911#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006912/* confdefs.h. */
6913_ACEOF
6914cat confdefs.h >>conftest.$ac_ext
6915cat >>conftest.$ac_ext <<_ACEOF
6916/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006917$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00006918int
6919main ()
6920{
6921static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
6922test_array [0] = 0
6923
6924 ;
6925 return 0;
6926}
6927_ACEOF
6928rm -f conftest.$ac_objext
6929if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6930 (eval $ac_compile) 2>&5
6931 ac_status=$?
6932 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6933 (exit $ac_status); } &&
6934 { ac_try='test -s conftest.$ac_objext'
6935 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6936 (eval $ac_try) 2>&5
6937 ac_status=$?
6938 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6939 (exit $ac_status); }; }; then
6940 ac_hi=$ac_mid
6941else
6942 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00006943sed 's/^/| /' conftest.$ac_ext >&5
6944
Martin v. Löwis11437992002-04-12 09:54:03 +00006945ac_lo=`expr '(' $ac_mid ')' + 1`
6946fi
6947rm -f conftest.$ac_objext conftest.$ac_ext
6948done
6949case $ac_lo in
6950?*) ac_cv_sizeof_void_p=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00006951'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
6952See \`config.log' for more details." >&5
6953echo "$as_me: error: cannot compute sizeof (void *), 77
6954See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006955 { (exit 1); exit 1; }; } ;;
6956esac
Guido van Rossumad678af1998-10-02 14:42:15 +00006957else
6958 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00006959 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
6960See \`config.log' for more details." >&5
6961echo "$as_me: error: cannot run test program while cross compiling
6962See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00006963 { (exit 1); exit 1; }; }
Guido van Rossumad678af1998-10-02 14:42:15 +00006964else
Martin v. Löwis11437992002-04-12 09:54:03 +00006965 cat >conftest.$ac_ext <<_ACEOF
6966#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00006967/* confdefs.h. */
6968_ACEOF
6969cat confdefs.h >>conftest.$ac_ext
6970cat >>conftest.$ac_ext <<_ACEOF
6971/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00006972$ac_includes_default
6973long longval () { return (long) (sizeof (void *)); }
6974unsigned long ulongval () { return (long) (sizeof (void *)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006975#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006976#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006977int
6978main ()
Guido van Rossumad678af1998-10-02 14:42:15 +00006979{
Martin v. Löwis11437992002-04-12 09:54:03 +00006980
6981 FILE *f = fopen ("conftest.val", "w");
6982 if (! f)
6983 exit (1);
6984 if (((long) (sizeof (void *))) < 0)
6985 {
6986 long i = longval ();
6987 if (i != ((long) (sizeof (void *))))
6988 exit (1);
6989 fprintf (f, "%ld\n", i);
6990 }
6991 else
6992 {
6993 unsigned long i = ulongval ();
6994 if (i != ((long) (sizeof (void *))))
6995 exit (1);
6996 fprintf (f, "%lu\n", i);
6997 }
6998 exit (ferror (f) || fclose (f) != 0);
6999
7000 ;
7001 return 0;
Guido van Rossumad678af1998-10-02 14:42:15 +00007002}
Martin v. Löwis11437992002-04-12 09:54:03 +00007003_ACEOF
7004rm -f conftest$ac_exeext
7005if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7006 (eval $ac_link) 2>&5
7007 ac_status=$?
7008 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7009 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7010 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7011 (eval $ac_try) 2>&5
7012 ac_status=$?
7013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7014 (exit $ac_status); }; }; then
7015 ac_cv_sizeof_void_p=`cat conftest.val`
Guido van Rossumad678af1998-10-02 14:42:15 +00007016else
Martin v. Löwis11437992002-04-12 09:54:03 +00007017 echo "$as_me: program exited with status $ac_status" >&5
7018echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007019sed 's/^/| /' conftest.$ac_ext >&5
7020
Martin v. Löwis11437992002-04-12 09:54:03 +00007021( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00007022{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77
7023See \`config.log' for more details." >&5
7024echo "$as_me: error: cannot compute sizeof (void *), 77
7025See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007026 { (exit 1); exit 1; }; }
7027fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00007028rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007029fi
7030fi
7031rm -f conftest.val
7032else
Guido van Rossumad678af1998-10-02 14:42:15 +00007033 ac_cv_sizeof_void_p=0
7034fi
Guido van Rossumad678af1998-10-02 14:42:15 +00007035fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007036echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
7037echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
7038cat >>confdefs.h <<_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00007039#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
Martin v. Löwis11437992002-04-12 09:54:03 +00007040_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00007041
7042
Martin v. Löwis11437992002-04-12 09:54:03 +00007043echo "$as_me:$LINENO: checking for char" >&5
7044echo $ECHO_N "checking for char... $ECHO_C" >&6
7045if test "${ac_cv_type_char+set}" = set; then
7046 echo $ECHO_N "(cached) $ECHO_C" >&6
7047else
7048 cat >conftest.$ac_ext <<_ACEOF
7049#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007050/* confdefs.h. */
7051_ACEOF
7052cat confdefs.h >>conftest.$ac_ext
7053cat >>conftest.$ac_ext <<_ACEOF
7054/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007055$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007056int
7057main ()
7058{
7059if ((char *) 0)
7060 return 0;
7061if (sizeof (char))
7062 return 0;
7063 ;
7064 return 0;
7065}
7066_ACEOF
7067rm -f conftest.$ac_objext
7068if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7069 (eval $ac_compile) 2>&5
7070 ac_status=$?
7071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7072 (exit $ac_status); } &&
7073 { ac_try='test -s conftest.$ac_objext'
7074 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7075 (eval $ac_try) 2>&5
7076 ac_status=$?
7077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7078 (exit $ac_status); }; }; then
7079 ac_cv_type_char=yes
7080else
7081 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007082sed 's/^/| /' conftest.$ac_ext >&5
7083
Martin v. Löwis11437992002-04-12 09:54:03 +00007084ac_cv_type_char=no
7085fi
7086rm -f conftest.$ac_objext conftest.$ac_ext
7087fi
7088echo "$as_me:$LINENO: result: $ac_cv_type_char" >&5
7089echo "${ECHO_T}$ac_cv_type_char" >&6
7090
7091echo "$as_me:$LINENO: checking size of char" >&5
7092echo $ECHO_N "checking size of char... $ECHO_C" >&6
7093if test "${ac_cv_sizeof_char+set}" = set; then
7094 echo $ECHO_N "(cached) $ECHO_C" >&6
7095else
7096 if test "$ac_cv_type_char" = yes; then
7097 # The cast to unsigned long works around a bug in the HP C Compiler
7098 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7099 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7100 # This bug is HP SR number 8606223364.
7101 if test "$cross_compiling" = yes; then
7102 # Depending upon the size, compute the lo and hi bounds.
7103cat >conftest.$ac_ext <<_ACEOF
7104#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007105/* confdefs.h. */
7106_ACEOF
7107cat confdefs.h >>conftest.$ac_ext
7108cat >>conftest.$ac_ext <<_ACEOF
7109/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007110$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007111int
7112main ()
7113{
7114static int test_array [1 - 2 * !(((long) (sizeof (char))) >= 0)];
7115test_array [0] = 0
7116
7117 ;
7118 return 0;
7119}
7120_ACEOF
7121rm -f conftest.$ac_objext
7122if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7123 (eval $ac_compile) 2>&5
7124 ac_status=$?
7125 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7126 (exit $ac_status); } &&
7127 { ac_try='test -s conftest.$ac_objext'
7128 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7129 (eval $ac_try) 2>&5
7130 ac_status=$?
7131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7132 (exit $ac_status); }; }; then
7133 ac_lo=0 ac_mid=0
7134 while :; do
7135 cat >conftest.$ac_ext <<_ACEOF
7136#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007137/* confdefs.h. */
7138_ACEOF
7139cat confdefs.h >>conftest.$ac_ext
7140cat >>conftest.$ac_ext <<_ACEOF
7141/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007142$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007143int
7144main ()
7145{
7146static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
7147test_array [0] = 0
7148
7149 ;
7150 return 0;
7151}
7152_ACEOF
7153rm -f conftest.$ac_objext
7154if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7155 (eval $ac_compile) 2>&5
7156 ac_status=$?
7157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7158 (exit $ac_status); } &&
7159 { ac_try='test -s conftest.$ac_objext'
7160 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7161 (eval $ac_try) 2>&5
7162 ac_status=$?
7163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7164 (exit $ac_status); }; }; then
7165 ac_hi=$ac_mid; break
7166else
7167 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007168sed 's/^/| /' conftest.$ac_ext >&5
7169
Martin v. Löwis11437992002-04-12 09:54:03 +00007170ac_lo=`expr $ac_mid + 1`
7171 if test $ac_lo -le $ac_mid; then
7172 ac_lo= ac_hi=
7173 break
7174 fi
7175 ac_mid=`expr 2 '*' $ac_mid + 1`
7176fi
7177rm -f conftest.$ac_objext conftest.$ac_ext
7178 done
7179else
7180 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007181sed 's/^/| /' conftest.$ac_ext >&5
7182
Martin v. Löwis11437992002-04-12 09:54:03 +00007183cat >conftest.$ac_ext <<_ACEOF
7184#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007185/* confdefs.h. */
7186_ACEOF
7187cat confdefs.h >>conftest.$ac_ext
7188cat >>conftest.$ac_ext <<_ACEOF
7189/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007190$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007191int
7192main ()
7193{
7194static int test_array [1 - 2 * !(((long) (sizeof (char))) < 0)];
7195test_array [0] = 0
7196
7197 ;
7198 return 0;
7199}
7200_ACEOF
7201rm -f conftest.$ac_objext
7202if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7203 (eval $ac_compile) 2>&5
7204 ac_status=$?
7205 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7206 (exit $ac_status); } &&
7207 { ac_try='test -s conftest.$ac_objext'
7208 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7209 (eval $ac_try) 2>&5
7210 ac_status=$?
7211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7212 (exit $ac_status); }; }; then
7213 ac_hi=-1 ac_mid=-1
7214 while :; do
7215 cat >conftest.$ac_ext <<_ACEOF
7216#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007217/* confdefs.h. */
7218_ACEOF
7219cat confdefs.h >>conftest.$ac_ext
7220cat >>conftest.$ac_ext <<_ACEOF
7221/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007222$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007223int
7224main ()
7225{
7226static int test_array [1 - 2 * !(((long) (sizeof (char))) >= $ac_mid)];
7227test_array [0] = 0
7228
7229 ;
7230 return 0;
7231}
7232_ACEOF
7233rm -f conftest.$ac_objext
7234if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7235 (eval $ac_compile) 2>&5
7236 ac_status=$?
7237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7238 (exit $ac_status); } &&
7239 { ac_try='test -s conftest.$ac_objext'
7240 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7241 (eval $ac_try) 2>&5
7242 ac_status=$?
7243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7244 (exit $ac_status); }; }; then
7245 ac_lo=$ac_mid; break
7246else
7247 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007248sed 's/^/| /' conftest.$ac_ext >&5
7249
Martin v. Löwis11437992002-04-12 09:54:03 +00007250ac_hi=`expr '(' $ac_mid ')' - 1`
7251 if test $ac_mid -le $ac_hi; then
7252 ac_lo= ac_hi=
7253 break
7254 fi
7255 ac_mid=`expr 2 '*' $ac_mid`
7256fi
7257rm -f conftest.$ac_objext conftest.$ac_ext
7258 done
7259else
7260 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007261sed 's/^/| /' conftest.$ac_ext >&5
7262
Martin v. Löwis11437992002-04-12 09:54:03 +00007263ac_lo= ac_hi=
7264fi
7265rm -f conftest.$ac_objext conftest.$ac_ext
7266fi
7267rm -f conftest.$ac_objext conftest.$ac_ext
7268# Binary search between lo and hi bounds.
7269while test "x$ac_lo" != "x$ac_hi"; do
7270 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7271 cat >conftest.$ac_ext <<_ACEOF
7272#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007273/* confdefs.h. */
7274_ACEOF
7275cat confdefs.h >>conftest.$ac_ext
7276cat >>conftest.$ac_ext <<_ACEOF
7277/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007278$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007279int
7280main ()
7281{
7282static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
7283test_array [0] = 0
7284
7285 ;
7286 return 0;
7287}
7288_ACEOF
7289rm -f conftest.$ac_objext
7290if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7291 (eval $ac_compile) 2>&5
7292 ac_status=$?
7293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7294 (exit $ac_status); } &&
7295 { ac_try='test -s conftest.$ac_objext'
7296 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7297 (eval $ac_try) 2>&5
7298 ac_status=$?
7299 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7300 (exit $ac_status); }; }; then
7301 ac_hi=$ac_mid
7302else
7303 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007304sed 's/^/| /' conftest.$ac_ext >&5
7305
Martin v. Löwis11437992002-04-12 09:54:03 +00007306ac_lo=`expr '(' $ac_mid ')' + 1`
7307fi
7308rm -f conftest.$ac_objext conftest.$ac_ext
7309done
7310case $ac_lo in
7311?*) ac_cv_sizeof_char=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00007312'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77
7313See \`config.log' for more details." >&5
7314echo "$as_me: error: cannot compute sizeof (char), 77
7315See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007316 { (exit 1); exit 1; }; } ;;
7317esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007318else
7319 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00007320 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
7321See \`config.log' for more details." >&5
7322echo "$as_me: error: cannot run test program while cross compiling
7323See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007324 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007325else
Martin v. Löwis11437992002-04-12 09:54:03 +00007326 cat >conftest.$ac_ext <<_ACEOF
7327#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007328/* confdefs.h. */
7329_ACEOF
7330cat confdefs.h >>conftest.$ac_ext
7331cat >>conftest.$ac_ext <<_ACEOF
7332/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007333$ac_includes_default
7334long longval () { return (long) (sizeof (char)); }
7335unsigned long ulongval () { return (long) (sizeof (char)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007336#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007337#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007338int
7339main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007340{
Martin v. Löwis11437992002-04-12 09:54:03 +00007341
7342 FILE *f = fopen ("conftest.val", "w");
7343 if (! f)
7344 exit (1);
7345 if (((long) (sizeof (char))) < 0)
7346 {
7347 long i = longval ();
7348 if (i != ((long) (sizeof (char))))
7349 exit (1);
7350 fprintf (f, "%ld\n", i);
7351 }
7352 else
7353 {
7354 unsigned long i = ulongval ();
7355 if (i != ((long) (sizeof (char))))
7356 exit (1);
7357 fprintf (f, "%lu\n", i);
7358 }
7359 exit (ferror (f) || fclose (f) != 0);
7360
7361 ;
7362 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007363}
Martin v. Löwis11437992002-04-12 09:54:03 +00007364_ACEOF
7365rm -f conftest$ac_exeext
7366if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7367 (eval $ac_link) 2>&5
7368 ac_status=$?
7369 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7370 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7371 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7372 (eval $ac_try) 2>&5
7373 ac_status=$?
7374 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7375 (exit $ac_status); }; }; then
7376 ac_cv_sizeof_char=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007377else
Martin v. Löwis11437992002-04-12 09:54:03 +00007378 echo "$as_me: program exited with status $ac_status" >&5
7379echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007380sed 's/^/| /' conftest.$ac_ext >&5
7381
Martin v. Löwis11437992002-04-12 09:54:03 +00007382( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00007383{ { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77
7384See \`config.log' for more details." >&5
7385echo "$as_me: error: cannot compute sizeof (char), 77
7386See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007387 { (exit 1); exit 1; }; }
7388fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00007389rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007390fi
7391fi
7392rm -f conftest.val
7393else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007394 ac_cv_sizeof_char=0
7395fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007396fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007397echo "$as_me:$LINENO: result: $ac_cv_sizeof_char" >&5
7398echo "${ECHO_T}$ac_cv_sizeof_char" >&6
7399cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007400#define SIZEOF_CHAR $ac_cv_sizeof_char
Martin v. Löwis11437992002-04-12 09:54:03 +00007401_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007402
7403
Martin v. Löwis11437992002-04-12 09:54:03 +00007404echo "$as_me:$LINENO: checking for short" >&5
7405echo $ECHO_N "checking for short... $ECHO_C" >&6
7406if test "${ac_cv_type_short+set}" = set; then
7407 echo $ECHO_N "(cached) $ECHO_C" >&6
7408else
7409 cat >conftest.$ac_ext <<_ACEOF
7410#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007411/* confdefs.h. */
7412_ACEOF
7413cat confdefs.h >>conftest.$ac_ext
7414cat >>conftest.$ac_ext <<_ACEOF
7415/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007416$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007417int
7418main ()
7419{
7420if ((short *) 0)
7421 return 0;
7422if (sizeof (short))
7423 return 0;
7424 ;
7425 return 0;
7426}
7427_ACEOF
7428rm -f conftest.$ac_objext
7429if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7430 (eval $ac_compile) 2>&5
7431 ac_status=$?
7432 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7433 (exit $ac_status); } &&
7434 { ac_try='test -s conftest.$ac_objext'
7435 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7436 (eval $ac_try) 2>&5
7437 ac_status=$?
7438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7439 (exit $ac_status); }; }; then
7440 ac_cv_type_short=yes
7441else
7442 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007443sed 's/^/| /' conftest.$ac_ext >&5
7444
Martin v. Löwis11437992002-04-12 09:54:03 +00007445ac_cv_type_short=no
7446fi
7447rm -f conftest.$ac_objext conftest.$ac_ext
7448fi
7449echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
7450echo "${ECHO_T}$ac_cv_type_short" >&6
7451
7452echo "$as_me:$LINENO: checking size of short" >&5
7453echo $ECHO_N "checking size of short... $ECHO_C" >&6
7454if test "${ac_cv_sizeof_short+set}" = set; then
7455 echo $ECHO_N "(cached) $ECHO_C" >&6
7456else
7457 if test "$ac_cv_type_short" = yes; then
7458 # The cast to unsigned long works around a bug in the HP C Compiler
7459 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7460 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7461 # This bug is HP SR number 8606223364.
7462 if test "$cross_compiling" = yes; then
7463 # Depending upon the size, compute the lo and hi bounds.
7464cat >conftest.$ac_ext <<_ACEOF
7465#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007466/* confdefs.h. */
7467_ACEOF
7468cat confdefs.h >>conftest.$ac_ext
7469cat >>conftest.$ac_ext <<_ACEOF
7470/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007471$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007472int
7473main ()
7474{
7475static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
7476test_array [0] = 0
7477
7478 ;
7479 return 0;
7480}
7481_ACEOF
7482rm -f conftest.$ac_objext
7483if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7484 (eval $ac_compile) 2>&5
7485 ac_status=$?
7486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7487 (exit $ac_status); } &&
7488 { ac_try='test -s conftest.$ac_objext'
7489 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7490 (eval $ac_try) 2>&5
7491 ac_status=$?
7492 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7493 (exit $ac_status); }; }; then
7494 ac_lo=0 ac_mid=0
7495 while :; do
7496 cat >conftest.$ac_ext <<_ACEOF
7497#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007498/* confdefs.h. */
7499_ACEOF
7500cat confdefs.h >>conftest.$ac_ext
7501cat >>conftest.$ac_ext <<_ACEOF
7502/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007503$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007504int
7505main ()
7506{
7507static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
7508test_array [0] = 0
7509
7510 ;
7511 return 0;
7512}
7513_ACEOF
7514rm -f conftest.$ac_objext
7515if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7516 (eval $ac_compile) 2>&5
7517 ac_status=$?
7518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7519 (exit $ac_status); } &&
7520 { ac_try='test -s conftest.$ac_objext'
7521 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7522 (eval $ac_try) 2>&5
7523 ac_status=$?
7524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7525 (exit $ac_status); }; }; then
7526 ac_hi=$ac_mid; break
7527else
7528 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007529sed 's/^/| /' conftest.$ac_ext >&5
7530
Martin v. Löwis11437992002-04-12 09:54:03 +00007531ac_lo=`expr $ac_mid + 1`
7532 if test $ac_lo -le $ac_mid; then
7533 ac_lo= ac_hi=
7534 break
7535 fi
7536 ac_mid=`expr 2 '*' $ac_mid + 1`
7537fi
7538rm -f conftest.$ac_objext conftest.$ac_ext
7539 done
7540else
7541 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007542sed 's/^/| /' conftest.$ac_ext >&5
7543
Martin v. Löwis11437992002-04-12 09:54:03 +00007544cat >conftest.$ac_ext <<_ACEOF
7545#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007546/* confdefs.h. */
7547_ACEOF
7548cat confdefs.h >>conftest.$ac_ext
7549cat >>conftest.$ac_ext <<_ACEOF
7550/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007551$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007552int
7553main ()
7554{
7555static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
7556test_array [0] = 0
7557
7558 ;
7559 return 0;
7560}
7561_ACEOF
7562rm -f conftest.$ac_objext
7563if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7564 (eval $ac_compile) 2>&5
7565 ac_status=$?
7566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7567 (exit $ac_status); } &&
7568 { ac_try='test -s conftest.$ac_objext'
7569 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7570 (eval $ac_try) 2>&5
7571 ac_status=$?
7572 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7573 (exit $ac_status); }; }; then
7574 ac_hi=-1 ac_mid=-1
7575 while :; do
7576 cat >conftest.$ac_ext <<_ACEOF
7577#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007578/* confdefs.h. */
7579_ACEOF
7580cat confdefs.h >>conftest.$ac_ext
7581cat >>conftest.$ac_ext <<_ACEOF
7582/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007583$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007584int
7585main ()
7586{
7587static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
7588test_array [0] = 0
7589
7590 ;
7591 return 0;
7592}
7593_ACEOF
7594rm -f conftest.$ac_objext
7595if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7596 (eval $ac_compile) 2>&5
7597 ac_status=$?
7598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7599 (exit $ac_status); } &&
7600 { ac_try='test -s conftest.$ac_objext'
7601 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7602 (eval $ac_try) 2>&5
7603 ac_status=$?
7604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7605 (exit $ac_status); }; }; then
7606 ac_lo=$ac_mid; break
7607else
7608 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007609sed 's/^/| /' conftest.$ac_ext >&5
7610
Martin v. Löwis11437992002-04-12 09:54:03 +00007611ac_hi=`expr '(' $ac_mid ')' - 1`
7612 if test $ac_mid -le $ac_hi; then
7613 ac_lo= ac_hi=
7614 break
7615 fi
7616 ac_mid=`expr 2 '*' $ac_mid`
7617fi
7618rm -f conftest.$ac_objext conftest.$ac_ext
7619 done
7620else
7621 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007622sed 's/^/| /' conftest.$ac_ext >&5
7623
Martin v. Löwis11437992002-04-12 09:54:03 +00007624ac_lo= ac_hi=
7625fi
7626rm -f conftest.$ac_objext conftest.$ac_ext
7627fi
7628rm -f conftest.$ac_objext conftest.$ac_ext
7629# Binary search between lo and hi bounds.
7630while test "x$ac_lo" != "x$ac_hi"; do
7631 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7632 cat >conftest.$ac_ext <<_ACEOF
7633#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007634/* confdefs.h. */
7635_ACEOF
7636cat confdefs.h >>conftest.$ac_ext
7637cat >>conftest.$ac_ext <<_ACEOF
7638/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007639$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007640int
7641main ()
7642{
7643static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
7644test_array [0] = 0
7645
7646 ;
7647 return 0;
7648}
7649_ACEOF
7650rm -f conftest.$ac_objext
7651if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7652 (eval $ac_compile) 2>&5
7653 ac_status=$?
7654 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7655 (exit $ac_status); } &&
7656 { ac_try='test -s conftest.$ac_objext'
7657 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7658 (eval $ac_try) 2>&5
7659 ac_status=$?
7660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7661 (exit $ac_status); }; }; then
7662 ac_hi=$ac_mid
7663else
7664 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007665sed 's/^/| /' conftest.$ac_ext >&5
7666
Martin v. Löwis11437992002-04-12 09:54:03 +00007667ac_lo=`expr '(' $ac_mid ')' + 1`
7668fi
7669rm -f conftest.$ac_objext conftest.$ac_ext
7670done
7671case $ac_lo in
7672?*) ac_cv_sizeof_short=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00007673'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
7674See \`config.log' for more details." >&5
7675echo "$as_me: error: cannot compute sizeof (short), 77
7676See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007677 { (exit 1); exit 1; }; } ;;
7678esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007679else
7680 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00007681 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
7682See \`config.log' for more details." >&5
7683echo "$as_me: error: cannot run test program while cross compiling
7684See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007685 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007686else
Martin v. Löwis11437992002-04-12 09:54:03 +00007687 cat >conftest.$ac_ext <<_ACEOF
7688#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007689/* confdefs.h. */
7690_ACEOF
7691cat confdefs.h >>conftest.$ac_ext
7692cat >>conftest.$ac_ext <<_ACEOF
7693/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007694$ac_includes_default
7695long longval () { return (long) (sizeof (short)); }
7696unsigned long ulongval () { return (long) (sizeof (short)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007697#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007698#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007699int
7700main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007701{
Martin v. Löwis11437992002-04-12 09:54:03 +00007702
7703 FILE *f = fopen ("conftest.val", "w");
7704 if (! f)
7705 exit (1);
7706 if (((long) (sizeof (short))) < 0)
7707 {
7708 long i = longval ();
7709 if (i != ((long) (sizeof (short))))
7710 exit (1);
7711 fprintf (f, "%ld\n", i);
7712 }
7713 else
7714 {
7715 unsigned long i = ulongval ();
7716 if (i != ((long) (sizeof (short))))
7717 exit (1);
7718 fprintf (f, "%lu\n", i);
7719 }
7720 exit (ferror (f) || fclose (f) != 0);
7721
7722 ;
7723 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007724}
Martin v. Löwis11437992002-04-12 09:54:03 +00007725_ACEOF
7726rm -f conftest$ac_exeext
7727if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7728 (eval $ac_link) 2>&5
7729 ac_status=$?
7730 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7731 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7732 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7733 (eval $ac_try) 2>&5
7734 ac_status=$?
7735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7736 (exit $ac_status); }; }; then
7737 ac_cv_sizeof_short=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007738else
Martin v. Löwis11437992002-04-12 09:54:03 +00007739 echo "$as_me: program exited with status $ac_status" >&5
7740echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007741sed 's/^/| /' conftest.$ac_ext >&5
7742
Martin v. Löwis11437992002-04-12 09:54:03 +00007743( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00007744{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77
7745See \`config.log' for more details." >&5
7746echo "$as_me: error: cannot compute sizeof (short), 77
7747See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00007748 { (exit 1); exit 1; }; }
7749fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00007750rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007751fi
7752fi
7753rm -f conftest.val
7754else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007755 ac_cv_sizeof_short=0
7756fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007757fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007758echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
7759echo "${ECHO_T}$ac_cv_sizeof_short" >&6
7760cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007761#define SIZEOF_SHORT $ac_cv_sizeof_short
Martin v. Löwis11437992002-04-12 09:54:03 +00007762_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007763
7764
Martin v. Löwis11437992002-04-12 09:54:03 +00007765echo "$as_me:$LINENO: checking for float" >&5
7766echo $ECHO_N "checking for float... $ECHO_C" >&6
7767if test "${ac_cv_type_float+set}" = set; then
7768 echo $ECHO_N "(cached) $ECHO_C" >&6
7769else
7770 cat >conftest.$ac_ext <<_ACEOF
7771#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007772/* confdefs.h. */
7773_ACEOF
7774cat confdefs.h >>conftest.$ac_ext
7775cat >>conftest.$ac_ext <<_ACEOF
7776/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007777$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007778int
7779main ()
7780{
7781if ((float *) 0)
7782 return 0;
7783if (sizeof (float))
7784 return 0;
7785 ;
7786 return 0;
7787}
7788_ACEOF
7789rm -f conftest.$ac_objext
7790if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7791 (eval $ac_compile) 2>&5
7792 ac_status=$?
7793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7794 (exit $ac_status); } &&
7795 { ac_try='test -s conftest.$ac_objext'
7796 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7797 (eval $ac_try) 2>&5
7798 ac_status=$?
7799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7800 (exit $ac_status); }; }; then
7801 ac_cv_type_float=yes
7802else
7803 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007804sed 's/^/| /' conftest.$ac_ext >&5
7805
Martin v. Löwis11437992002-04-12 09:54:03 +00007806ac_cv_type_float=no
7807fi
7808rm -f conftest.$ac_objext conftest.$ac_ext
7809fi
7810echo "$as_me:$LINENO: result: $ac_cv_type_float" >&5
7811echo "${ECHO_T}$ac_cv_type_float" >&6
7812
7813echo "$as_me:$LINENO: checking size of float" >&5
7814echo $ECHO_N "checking size of float... $ECHO_C" >&6
7815if test "${ac_cv_sizeof_float+set}" = set; then
7816 echo $ECHO_N "(cached) $ECHO_C" >&6
7817else
7818 if test "$ac_cv_type_float" = yes; then
7819 # The cast to unsigned long works around a bug in the HP C Compiler
7820 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7821 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7822 # This bug is HP SR number 8606223364.
7823 if test "$cross_compiling" = yes; then
7824 # Depending upon the size, compute the lo and hi bounds.
7825cat >conftest.$ac_ext <<_ACEOF
7826#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007827/* confdefs.h. */
7828_ACEOF
7829cat confdefs.h >>conftest.$ac_ext
7830cat >>conftest.$ac_ext <<_ACEOF
7831/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007832$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007833int
7834main ()
7835{
7836static int test_array [1 - 2 * !(((long) (sizeof (float))) >= 0)];
7837test_array [0] = 0
7838
7839 ;
7840 return 0;
7841}
7842_ACEOF
7843rm -f conftest.$ac_objext
7844if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7845 (eval $ac_compile) 2>&5
7846 ac_status=$?
7847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7848 (exit $ac_status); } &&
7849 { ac_try='test -s conftest.$ac_objext'
7850 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7851 (eval $ac_try) 2>&5
7852 ac_status=$?
7853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7854 (exit $ac_status); }; }; then
7855 ac_lo=0 ac_mid=0
7856 while :; do
7857 cat >conftest.$ac_ext <<_ACEOF
7858#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007859/* confdefs.h. */
7860_ACEOF
7861cat confdefs.h >>conftest.$ac_ext
7862cat >>conftest.$ac_ext <<_ACEOF
7863/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007864$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007865int
7866main ()
7867{
7868static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
7869test_array [0] = 0
7870
7871 ;
7872 return 0;
7873}
7874_ACEOF
7875rm -f conftest.$ac_objext
7876if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7877 (eval $ac_compile) 2>&5
7878 ac_status=$?
7879 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7880 (exit $ac_status); } &&
7881 { ac_try='test -s conftest.$ac_objext'
7882 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7883 (eval $ac_try) 2>&5
7884 ac_status=$?
7885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7886 (exit $ac_status); }; }; then
7887 ac_hi=$ac_mid; break
7888else
7889 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007890sed 's/^/| /' conftest.$ac_ext >&5
7891
Martin v. Löwis11437992002-04-12 09:54:03 +00007892ac_lo=`expr $ac_mid + 1`
7893 if test $ac_lo -le $ac_mid; then
7894 ac_lo= ac_hi=
7895 break
7896 fi
7897 ac_mid=`expr 2 '*' $ac_mid + 1`
7898fi
7899rm -f conftest.$ac_objext conftest.$ac_ext
7900 done
7901else
7902 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007903sed 's/^/| /' conftest.$ac_ext >&5
7904
Martin v. Löwis11437992002-04-12 09:54:03 +00007905cat >conftest.$ac_ext <<_ACEOF
7906#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007907/* confdefs.h. */
7908_ACEOF
7909cat confdefs.h >>conftest.$ac_ext
7910cat >>conftest.$ac_ext <<_ACEOF
7911/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007912$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007913int
7914main ()
7915{
7916static int test_array [1 - 2 * !(((long) (sizeof (float))) < 0)];
7917test_array [0] = 0
7918
7919 ;
7920 return 0;
7921}
7922_ACEOF
7923rm -f conftest.$ac_objext
7924if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7925 (eval $ac_compile) 2>&5
7926 ac_status=$?
7927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7928 (exit $ac_status); } &&
7929 { ac_try='test -s conftest.$ac_objext'
7930 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7931 (eval $ac_try) 2>&5
7932 ac_status=$?
7933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7934 (exit $ac_status); }; }; then
7935 ac_hi=-1 ac_mid=-1
7936 while :; do
7937 cat >conftest.$ac_ext <<_ACEOF
7938#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007939/* confdefs.h. */
7940_ACEOF
7941cat confdefs.h >>conftest.$ac_ext
7942cat >>conftest.$ac_ext <<_ACEOF
7943/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007944$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00007945int
7946main ()
7947{
7948static int test_array [1 - 2 * !(((long) (sizeof (float))) >= $ac_mid)];
7949test_array [0] = 0
7950
7951 ;
7952 return 0;
7953}
7954_ACEOF
7955rm -f conftest.$ac_objext
7956if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7957 (eval $ac_compile) 2>&5
7958 ac_status=$?
7959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7960 (exit $ac_status); } &&
7961 { ac_try='test -s conftest.$ac_objext'
7962 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7963 (eval $ac_try) 2>&5
7964 ac_status=$?
7965 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7966 (exit $ac_status); }; }; then
7967 ac_lo=$ac_mid; break
7968else
7969 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007970sed 's/^/| /' conftest.$ac_ext >&5
7971
Martin v. Löwis11437992002-04-12 09:54:03 +00007972ac_hi=`expr '(' $ac_mid ')' - 1`
7973 if test $ac_mid -le $ac_hi; then
7974 ac_lo= ac_hi=
7975 break
7976 fi
7977 ac_mid=`expr 2 '*' $ac_mid`
7978fi
7979rm -f conftest.$ac_objext conftest.$ac_ext
7980 done
7981else
7982 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00007983sed 's/^/| /' conftest.$ac_ext >&5
7984
Martin v. Löwis11437992002-04-12 09:54:03 +00007985ac_lo= ac_hi=
7986fi
7987rm -f conftest.$ac_objext conftest.$ac_ext
7988fi
7989rm -f conftest.$ac_objext conftest.$ac_ext
7990# Binary search between lo and hi bounds.
7991while test "x$ac_lo" != "x$ac_hi"; do
7992 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7993 cat >conftest.$ac_ext <<_ACEOF
7994#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00007995/* confdefs.h. */
7996_ACEOF
7997cat confdefs.h >>conftest.$ac_ext
7998cat >>conftest.$ac_ext <<_ACEOF
7999/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008000$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008001int
8002main ()
8003{
8004static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
8005test_array [0] = 0
8006
8007 ;
8008 return 0;
8009}
8010_ACEOF
8011rm -f conftest.$ac_objext
8012if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8013 (eval $ac_compile) 2>&5
8014 ac_status=$?
8015 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8016 (exit $ac_status); } &&
8017 { ac_try='test -s conftest.$ac_objext'
8018 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8019 (eval $ac_try) 2>&5
8020 ac_status=$?
8021 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8022 (exit $ac_status); }; }; then
8023 ac_hi=$ac_mid
8024else
8025 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008026sed 's/^/| /' conftest.$ac_ext >&5
8027
Martin v. Löwis11437992002-04-12 09:54:03 +00008028ac_lo=`expr '(' $ac_mid ')' + 1`
8029fi
8030rm -f conftest.$ac_objext conftest.$ac_ext
8031done
8032case $ac_lo in
8033?*) ac_cv_sizeof_float=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00008034'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77
8035See \`config.log' for more details." >&5
8036echo "$as_me: error: cannot compute sizeof (float), 77
8037See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008038 { (exit 1); exit 1; }; } ;;
8039esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00008040else
8041 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00008042 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
8043See \`config.log' for more details." >&5
8044echo "$as_me: error: cannot run test program while cross compiling
8045See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008046 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00008047else
Martin v. Löwis11437992002-04-12 09:54:03 +00008048 cat >conftest.$ac_ext <<_ACEOF
8049#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008050/* confdefs.h. */
8051_ACEOF
8052cat confdefs.h >>conftest.$ac_ext
8053cat >>conftest.$ac_ext <<_ACEOF
8054/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008055$ac_includes_default
8056long longval () { return (long) (sizeof (float)); }
8057unsigned long ulongval () { return (long) (sizeof (float)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008058#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008059#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008060int
8061main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00008062{
Martin v. Löwis11437992002-04-12 09:54:03 +00008063
8064 FILE *f = fopen ("conftest.val", "w");
8065 if (! f)
8066 exit (1);
8067 if (((long) (sizeof (float))) < 0)
8068 {
8069 long i = longval ();
8070 if (i != ((long) (sizeof (float))))
8071 exit (1);
8072 fprintf (f, "%ld\n", i);
8073 }
8074 else
8075 {
8076 unsigned long i = ulongval ();
8077 if (i != ((long) (sizeof (float))))
8078 exit (1);
8079 fprintf (f, "%lu\n", i);
8080 }
8081 exit (ferror (f) || fclose (f) != 0);
8082
8083 ;
8084 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00008085}
Martin v. Löwis11437992002-04-12 09:54:03 +00008086_ACEOF
8087rm -f conftest$ac_exeext
8088if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8089 (eval $ac_link) 2>&5
8090 ac_status=$?
8091 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8092 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8093 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8094 (eval $ac_try) 2>&5
8095 ac_status=$?
8096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8097 (exit $ac_status); }; }; then
8098 ac_cv_sizeof_float=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00008099else
Martin v. Löwis11437992002-04-12 09:54:03 +00008100 echo "$as_me: program exited with status $ac_status" >&5
8101echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008102sed 's/^/| /' conftest.$ac_ext >&5
8103
Martin v. Löwis11437992002-04-12 09:54:03 +00008104( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00008105{ { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77
8106See \`config.log' for more details." >&5
8107echo "$as_me: error: cannot compute sizeof (float), 77
8108See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008109 { (exit 1); exit 1; }; }
8110fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00008111rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008112fi
8113fi
8114rm -f conftest.val
8115else
Guido van Rossumef2255b2000-03-10 22:30:29 +00008116 ac_cv_sizeof_float=0
8117fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00008118fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008119echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5
8120echo "${ECHO_T}$ac_cv_sizeof_float" >&6
8121cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00008122#define SIZEOF_FLOAT $ac_cv_sizeof_float
Martin v. Löwis11437992002-04-12 09:54:03 +00008123_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00008124
8125
Martin v. Löwis11437992002-04-12 09:54:03 +00008126echo "$as_me:$LINENO: checking for double" >&5
8127echo $ECHO_N "checking for double... $ECHO_C" >&6
8128if test "${ac_cv_type_double+set}" = set; then
8129 echo $ECHO_N "(cached) $ECHO_C" >&6
8130else
8131 cat >conftest.$ac_ext <<_ACEOF
8132#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008133/* confdefs.h. */
8134_ACEOF
8135cat confdefs.h >>conftest.$ac_ext
8136cat >>conftest.$ac_ext <<_ACEOF
8137/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008138$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008139int
8140main ()
8141{
8142if ((double *) 0)
8143 return 0;
8144if (sizeof (double))
8145 return 0;
8146 ;
8147 return 0;
8148}
8149_ACEOF
8150rm -f conftest.$ac_objext
8151if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8152 (eval $ac_compile) 2>&5
8153 ac_status=$?
8154 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8155 (exit $ac_status); } &&
8156 { ac_try='test -s conftest.$ac_objext'
8157 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8158 (eval $ac_try) 2>&5
8159 ac_status=$?
8160 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8161 (exit $ac_status); }; }; then
8162 ac_cv_type_double=yes
8163else
8164 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008165sed 's/^/| /' conftest.$ac_ext >&5
8166
Martin v. Löwis11437992002-04-12 09:54:03 +00008167ac_cv_type_double=no
8168fi
8169rm -f conftest.$ac_objext conftest.$ac_ext
8170fi
8171echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
8172echo "${ECHO_T}$ac_cv_type_double" >&6
8173
8174echo "$as_me:$LINENO: checking size of double" >&5
8175echo $ECHO_N "checking size of double... $ECHO_C" >&6
8176if test "${ac_cv_sizeof_double+set}" = set; then
8177 echo $ECHO_N "(cached) $ECHO_C" >&6
8178else
8179 if test "$ac_cv_type_double" = yes; then
8180 # The cast to unsigned long works around a bug in the HP C Compiler
8181 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8182 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8183 # This bug is HP SR number 8606223364.
8184 if test "$cross_compiling" = yes; then
8185 # Depending upon the size, compute the lo and hi bounds.
8186cat >conftest.$ac_ext <<_ACEOF
8187#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008188/* confdefs.h. */
8189_ACEOF
8190cat confdefs.h >>conftest.$ac_ext
8191cat >>conftest.$ac_ext <<_ACEOF
8192/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008193$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008194int
8195main ()
8196{
8197static int test_array [1 - 2 * !(((long) (sizeof (double))) >= 0)];
8198test_array [0] = 0
8199
8200 ;
8201 return 0;
8202}
8203_ACEOF
8204rm -f conftest.$ac_objext
8205if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8206 (eval $ac_compile) 2>&5
8207 ac_status=$?
8208 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8209 (exit $ac_status); } &&
8210 { ac_try='test -s conftest.$ac_objext'
8211 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8212 (eval $ac_try) 2>&5
8213 ac_status=$?
8214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8215 (exit $ac_status); }; }; then
8216 ac_lo=0 ac_mid=0
8217 while :; do
8218 cat >conftest.$ac_ext <<_ACEOF
8219#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008220/* confdefs.h. */
8221_ACEOF
8222cat confdefs.h >>conftest.$ac_ext
8223cat >>conftest.$ac_ext <<_ACEOF
8224/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008225$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008226int
8227main ()
8228{
8229static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
8230test_array [0] = 0
8231
8232 ;
8233 return 0;
8234}
8235_ACEOF
8236rm -f conftest.$ac_objext
8237if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8238 (eval $ac_compile) 2>&5
8239 ac_status=$?
8240 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8241 (exit $ac_status); } &&
8242 { ac_try='test -s conftest.$ac_objext'
8243 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8244 (eval $ac_try) 2>&5
8245 ac_status=$?
8246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8247 (exit $ac_status); }; }; then
8248 ac_hi=$ac_mid; break
8249else
8250 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008251sed 's/^/| /' conftest.$ac_ext >&5
8252
Martin v. Löwis11437992002-04-12 09:54:03 +00008253ac_lo=`expr $ac_mid + 1`
8254 if test $ac_lo -le $ac_mid; then
8255 ac_lo= ac_hi=
8256 break
8257 fi
8258 ac_mid=`expr 2 '*' $ac_mid + 1`
8259fi
8260rm -f conftest.$ac_objext conftest.$ac_ext
8261 done
8262else
8263 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008264sed 's/^/| /' conftest.$ac_ext >&5
8265
Martin v. Löwis11437992002-04-12 09:54:03 +00008266cat >conftest.$ac_ext <<_ACEOF
8267#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008268/* confdefs.h. */
8269_ACEOF
8270cat confdefs.h >>conftest.$ac_ext
8271cat >>conftest.$ac_ext <<_ACEOF
8272/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008273$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008274int
8275main ()
8276{
8277static int test_array [1 - 2 * !(((long) (sizeof (double))) < 0)];
8278test_array [0] = 0
8279
8280 ;
8281 return 0;
8282}
8283_ACEOF
8284rm -f conftest.$ac_objext
8285if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8286 (eval $ac_compile) 2>&5
8287 ac_status=$?
8288 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8289 (exit $ac_status); } &&
8290 { ac_try='test -s conftest.$ac_objext'
8291 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8292 (eval $ac_try) 2>&5
8293 ac_status=$?
8294 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8295 (exit $ac_status); }; }; then
8296 ac_hi=-1 ac_mid=-1
8297 while :; do
8298 cat >conftest.$ac_ext <<_ACEOF
8299#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008300/* confdefs.h. */
8301_ACEOF
8302cat confdefs.h >>conftest.$ac_ext
8303cat >>conftest.$ac_ext <<_ACEOF
8304/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008305$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008306int
8307main ()
8308{
8309static int test_array [1 - 2 * !(((long) (sizeof (double))) >= $ac_mid)];
8310test_array [0] = 0
8311
8312 ;
8313 return 0;
8314}
8315_ACEOF
8316rm -f conftest.$ac_objext
8317if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8318 (eval $ac_compile) 2>&5
8319 ac_status=$?
8320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8321 (exit $ac_status); } &&
8322 { ac_try='test -s conftest.$ac_objext'
8323 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8324 (eval $ac_try) 2>&5
8325 ac_status=$?
8326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8327 (exit $ac_status); }; }; then
8328 ac_lo=$ac_mid; break
8329else
8330 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008331sed 's/^/| /' conftest.$ac_ext >&5
8332
Martin v. Löwis11437992002-04-12 09:54:03 +00008333ac_hi=`expr '(' $ac_mid ')' - 1`
8334 if test $ac_mid -le $ac_hi; then
8335 ac_lo= ac_hi=
8336 break
8337 fi
8338 ac_mid=`expr 2 '*' $ac_mid`
8339fi
8340rm -f conftest.$ac_objext conftest.$ac_ext
8341 done
8342else
8343 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008344sed 's/^/| /' conftest.$ac_ext >&5
8345
Martin v. Löwis11437992002-04-12 09:54:03 +00008346ac_lo= ac_hi=
8347fi
8348rm -f conftest.$ac_objext conftest.$ac_ext
8349fi
8350rm -f conftest.$ac_objext conftest.$ac_ext
8351# Binary search between lo and hi bounds.
8352while test "x$ac_lo" != "x$ac_hi"; do
8353 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8354 cat >conftest.$ac_ext <<_ACEOF
8355#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008356/* confdefs.h. */
8357_ACEOF
8358cat confdefs.h >>conftest.$ac_ext
8359cat >>conftest.$ac_ext <<_ACEOF
8360/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008361$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008362int
8363main ()
8364{
8365static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
8366test_array [0] = 0
8367
8368 ;
8369 return 0;
8370}
8371_ACEOF
8372rm -f conftest.$ac_objext
8373if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8374 (eval $ac_compile) 2>&5
8375 ac_status=$?
8376 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8377 (exit $ac_status); } &&
8378 { ac_try='test -s conftest.$ac_objext'
8379 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8380 (eval $ac_try) 2>&5
8381 ac_status=$?
8382 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8383 (exit $ac_status); }; }; then
8384 ac_hi=$ac_mid
8385else
8386 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008387sed 's/^/| /' conftest.$ac_ext >&5
8388
Martin v. Löwis11437992002-04-12 09:54:03 +00008389ac_lo=`expr '(' $ac_mid ')' + 1`
8390fi
8391rm -f conftest.$ac_objext conftest.$ac_ext
8392done
8393case $ac_lo in
8394?*) ac_cv_sizeof_double=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00008395'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77
8396See \`config.log' for more details." >&5
8397echo "$as_me: error: cannot compute sizeof (double), 77
8398See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008399 { (exit 1); exit 1; }; } ;;
8400esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00008401else
8402 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00008403 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
8404See \`config.log' for more details." >&5
8405echo "$as_me: error: cannot run test program while cross compiling
8406See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008407 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00008408else
Martin v. Löwis11437992002-04-12 09:54:03 +00008409 cat >conftest.$ac_ext <<_ACEOF
8410#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008411/* confdefs.h. */
8412_ACEOF
8413cat confdefs.h >>conftest.$ac_ext
8414cat >>conftest.$ac_ext <<_ACEOF
8415/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008416$ac_includes_default
8417long longval () { return (long) (sizeof (double)); }
8418unsigned long ulongval () { return (long) (sizeof (double)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008419#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008420#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008421int
8422main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00008423{
Martin v. Löwis11437992002-04-12 09:54:03 +00008424
8425 FILE *f = fopen ("conftest.val", "w");
8426 if (! f)
8427 exit (1);
8428 if (((long) (sizeof (double))) < 0)
8429 {
8430 long i = longval ();
8431 if (i != ((long) (sizeof (double))))
8432 exit (1);
8433 fprintf (f, "%ld\n", i);
8434 }
8435 else
8436 {
8437 unsigned long i = ulongval ();
8438 if (i != ((long) (sizeof (double))))
8439 exit (1);
8440 fprintf (f, "%lu\n", i);
8441 }
8442 exit (ferror (f) || fclose (f) != 0);
8443
8444 ;
8445 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00008446}
Martin v. Löwis11437992002-04-12 09:54:03 +00008447_ACEOF
8448rm -f conftest$ac_exeext
8449if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8450 (eval $ac_link) 2>&5
8451 ac_status=$?
8452 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8453 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8454 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8455 (eval $ac_try) 2>&5
8456 ac_status=$?
8457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8458 (exit $ac_status); }; }; then
8459 ac_cv_sizeof_double=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00008460else
Martin v. Löwis11437992002-04-12 09:54:03 +00008461 echo "$as_me: program exited with status $ac_status" >&5
8462echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008463sed 's/^/| /' conftest.$ac_ext >&5
8464
Martin v. Löwis11437992002-04-12 09:54:03 +00008465( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00008466{ { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77
8467See \`config.log' for more details." >&5
8468echo "$as_me: error: cannot compute sizeof (double), 77
8469See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008470 { (exit 1); exit 1; }; }
8471fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00008472rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008473fi
8474fi
8475rm -f conftest.val
8476else
Guido van Rossumef2255b2000-03-10 22:30:29 +00008477 ac_cv_sizeof_double=0
8478fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00008479fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008480echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5
8481echo "${ECHO_T}$ac_cv_sizeof_double" >&6
8482cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00008483#define SIZEOF_DOUBLE $ac_cv_sizeof_double
Martin v. Löwis11437992002-04-12 09:54:03 +00008484_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00008485
8486
Martin v. Löwis11437992002-04-12 09:54:03 +00008487echo "$as_me:$LINENO: checking for fpos_t" >&5
8488echo $ECHO_N "checking for fpos_t... $ECHO_C" >&6
8489if test "${ac_cv_type_fpos_t+set}" = set; then
8490 echo $ECHO_N "(cached) $ECHO_C" >&6
8491else
8492 cat >conftest.$ac_ext <<_ACEOF
8493#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008494/* confdefs.h. */
8495_ACEOF
8496cat confdefs.h >>conftest.$ac_ext
8497cat >>conftest.$ac_ext <<_ACEOF
8498/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008499$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008500int
8501main ()
8502{
8503if ((fpos_t *) 0)
8504 return 0;
8505if (sizeof (fpos_t))
8506 return 0;
8507 ;
8508 return 0;
8509}
8510_ACEOF
8511rm -f conftest.$ac_objext
8512if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8513 (eval $ac_compile) 2>&5
8514 ac_status=$?
8515 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8516 (exit $ac_status); } &&
8517 { ac_try='test -s conftest.$ac_objext'
8518 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8519 (eval $ac_try) 2>&5
8520 ac_status=$?
8521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8522 (exit $ac_status); }; }; then
8523 ac_cv_type_fpos_t=yes
8524else
8525 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008526sed 's/^/| /' conftest.$ac_ext >&5
8527
Martin v. Löwis11437992002-04-12 09:54:03 +00008528ac_cv_type_fpos_t=no
8529fi
8530rm -f conftest.$ac_objext conftest.$ac_ext
8531fi
8532echo "$as_me:$LINENO: result: $ac_cv_type_fpos_t" >&5
8533echo "${ECHO_T}$ac_cv_type_fpos_t" >&6
8534
8535echo "$as_me:$LINENO: checking size of fpos_t" >&5
8536echo $ECHO_N "checking size of fpos_t... $ECHO_C" >&6
8537if test "${ac_cv_sizeof_fpos_t+set}" = set; then
8538 echo $ECHO_N "(cached) $ECHO_C" >&6
8539else
8540 if test "$ac_cv_type_fpos_t" = yes; then
8541 # The cast to unsigned long works around a bug in the HP C Compiler
8542 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8543 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8544 # This bug is HP SR number 8606223364.
8545 if test "$cross_compiling" = yes; then
8546 # Depending upon the size, compute the lo and hi bounds.
8547cat >conftest.$ac_ext <<_ACEOF
8548#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008549/* confdefs.h. */
8550_ACEOF
8551cat confdefs.h >>conftest.$ac_ext
8552cat >>conftest.$ac_ext <<_ACEOF
8553/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008554$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008555int
8556main ()
8557{
8558static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= 0)];
8559test_array [0] = 0
8560
8561 ;
8562 return 0;
8563}
8564_ACEOF
8565rm -f conftest.$ac_objext
8566if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8567 (eval $ac_compile) 2>&5
8568 ac_status=$?
8569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8570 (exit $ac_status); } &&
8571 { ac_try='test -s conftest.$ac_objext'
8572 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8573 (eval $ac_try) 2>&5
8574 ac_status=$?
8575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8576 (exit $ac_status); }; }; then
8577 ac_lo=0 ac_mid=0
8578 while :; do
8579 cat >conftest.$ac_ext <<_ACEOF
8580#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008581/* confdefs.h. */
8582_ACEOF
8583cat confdefs.h >>conftest.$ac_ext
8584cat >>conftest.$ac_ext <<_ACEOF
8585/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008586$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008587int
8588main ()
8589{
8590static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
8591test_array [0] = 0
8592
8593 ;
8594 return 0;
8595}
8596_ACEOF
8597rm -f conftest.$ac_objext
8598if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8599 (eval $ac_compile) 2>&5
8600 ac_status=$?
8601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8602 (exit $ac_status); } &&
8603 { ac_try='test -s conftest.$ac_objext'
8604 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8605 (eval $ac_try) 2>&5
8606 ac_status=$?
8607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8608 (exit $ac_status); }; }; then
8609 ac_hi=$ac_mid; break
8610else
8611 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008612sed 's/^/| /' conftest.$ac_ext >&5
8613
Martin v. Löwis11437992002-04-12 09:54:03 +00008614ac_lo=`expr $ac_mid + 1`
8615 if test $ac_lo -le $ac_mid; then
8616 ac_lo= ac_hi=
8617 break
8618 fi
8619 ac_mid=`expr 2 '*' $ac_mid + 1`
8620fi
8621rm -f conftest.$ac_objext conftest.$ac_ext
8622 done
8623else
8624 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008625sed 's/^/| /' conftest.$ac_ext >&5
8626
Martin v. Löwis11437992002-04-12 09:54:03 +00008627cat >conftest.$ac_ext <<_ACEOF
8628#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008629/* confdefs.h. */
8630_ACEOF
8631cat confdefs.h >>conftest.$ac_ext
8632cat >>conftest.$ac_ext <<_ACEOF
8633/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008634$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008635int
8636main ()
8637{
8638static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) < 0)];
8639test_array [0] = 0
8640
8641 ;
8642 return 0;
8643}
8644_ACEOF
8645rm -f conftest.$ac_objext
8646if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8647 (eval $ac_compile) 2>&5
8648 ac_status=$?
8649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8650 (exit $ac_status); } &&
8651 { ac_try='test -s conftest.$ac_objext'
8652 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8653 (eval $ac_try) 2>&5
8654 ac_status=$?
8655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8656 (exit $ac_status); }; }; then
8657 ac_hi=-1 ac_mid=-1
8658 while :; do
8659 cat >conftest.$ac_ext <<_ACEOF
8660#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008661/* confdefs.h. */
8662_ACEOF
8663cat confdefs.h >>conftest.$ac_ext
8664cat >>conftest.$ac_ext <<_ACEOF
8665/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008666$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008667int
8668main ()
8669{
8670static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= $ac_mid)];
8671test_array [0] = 0
8672
8673 ;
8674 return 0;
8675}
8676_ACEOF
8677rm -f conftest.$ac_objext
8678if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8679 (eval $ac_compile) 2>&5
8680 ac_status=$?
8681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8682 (exit $ac_status); } &&
8683 { ac_try='test -s conftest.$ac_objext'
8684 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8685 (eval $ac_try) 2>&5
8686 ac_status=$?
8687 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8688 (exit $ac_status); }; }; then
8689 ac_lo=$ac_mid; break
8690else
8691 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008692sed 's/^/| /' conftest.$ac_ext >&5
8693
Martin v. Löwis11437992002-04-12 09:54:03 +00008694ac_hi=`expr '(' $ac_mid ')' - 1`
8695 if test $ac_mid -le $ac_hi; then
8696 ac_lo= ac_hi=
8697 break
8698 fi
8699 ac_mid=`expr 2 '*' $ac_mid`
8700fi
8701rm -f conftest.$ac_objext conftest.$ac_ext
8702 done
8703else
8704 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008705sed 's/^/| /' conftest.$ac_ext >&5
8706
Martin v. Löwis11437992002-04-12 09:54:03 +00008707ac_lo= ac_hi=
8708fi
8709rm -f conftest.$ac_objext conftest.$ac_ext
8710fi
8711rm -f conftest.$ac_objext conftest.$ac_ext
8712# Binary search between lo and hi bounds.
8713while test "x$ac_lo" != "x$ac_hi"; do
8714 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8715 cat >conftest.$ac_ext <<_ACEOF
8716#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008717/* confdefs.h. */
8718_ACEOF
8719cat confdefs.h >>conftest.$ac_ext
8720cat >>conftest.$ac_ext <<_ACEOF
8721/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008722$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008723int
8724main ()
8725{
8726static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
8727test_array [0] = 0
8728
8729 ;
8730 return 0;
8731}
8732_ACEOF
8733rm -f conftest.$ac_objext
8734if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8735 (eval $ac_compile) 2>&5
8736 ac_status=$?
8737 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8738 (exit $ac_status); } &&
8739 { ac_try='test -s conftest.$ac_objext'
8740 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8741 (eval $ac_try) 2>&5
8742 ac_status=$?
8743 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8744 (exit $ac_status); }; }; then
8745 ac_hi=$ac_mid
8746else
8747 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008748sed 's/^/| /' conftest.$ac_ext >&5
8749
Martin v. Löwis11437992002-04-12 09:54:03 +00008750ac_lo=`expr '(' $ac_mid ')' + 1`
8751fi
8752rm -f conftest.$ac_objext conftest.$ac_ext
8753done
8754case $ac_lo in
8755?*) ac_cv_sizeof_fpos_t=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00008756'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77
8757See \`config.log' for more details." >&5
8758echo "$as_me: error: cannot compute sizeof (fpos_t), 77
8759See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008760 { (exit 1); exit 1; }; } ;;
8761esac
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008762else
8763 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00008764 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
8765See \`config.log' for more details." >&5
8766echo "$as_me: error: cannot run test program while cross compiling
8767See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008768 { (exit 1); exit 1; }; }
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008769else
Martin v. Löwis11437992002-04-12 09:54:03 +00008770 cat >conftest.$ac_ext <<_ACEOF
8771#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008772/* confdefs.h. */
8773_ACEOF
8774cat confdefs.h >>conftest.$ac_ext
8775cat >>conftest.$ac_ext <<_ACEOF
8776/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008777$ac_includes_default
8778long longval () { return (long) (sizeof (fpos_t)); }
8779unsigned long ulongval () { return (long) (sizeof (fpos_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008780#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008781#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008782int
8783main ()
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008784{
Martin v. Löwis11437992002-04-12 09:54:03 +00008785
8786 FILE *f = fopen ("conftest.val", "w");
8787 if (! f)
8788 exit (1);
8789 if (((long) (sizeof (fpos_t))) < 0)
8790 {
8791 long i = longval ();
8792 if (i != ((long) (sizeof (fpos_t))))
8793 exit (1);
8794 fprintf (f, "%ld\n", i);
8795 }
8796 else
8797 {
8798 unsigned long i = ulongval ();
8799 if (i != ((long) (sizeof (fpos_t))))
8800 exit (1);
8801 fprintf (f, "%lu\n", i);
8802 }
8803 exit (ferror (f) || fclose (f) != 0);
8804
8805 ;
8806 return 0;
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008807}
Martin v. Löwis11437992002-04-12 09:54:03 +00008808_ACEOF
8809rm -f conftest$ac_exeext
8810if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8811 (eval $ac_link) 2>&5
8812 ac_status=$?
8813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8814 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8816 (eval $ac_try) 2>&5
8817 ac_status=$?
8818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8819 (exit $ac_status); }; }; then
8820 ac_cv_sizeof_fpos_t=`cat conftest.val`
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008821else
Martin v. Löwis11437992002-04-12 09:54:03 +00008822 echo "$as_me: program exited with status $ac_status" >&5
8823echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008824sed 's/^/| /' conftest.$ac_ext >&5
8825
Martin v. Löwis11437992002-04-12 09:54:03 +00008826( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00008827{ { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77
8828See \`config.log' for more details." >&5
8829echo "$as_me: error: cannot compute sizeof (fpos_t), 77
8830See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00008831 { (exit 1); exit 1; }; }
8832fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00008833rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008834fi
8835fi
8836rm -f conftest.val
8837else
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008838 ac_cv_sizeof_fpos_t=0
8839fi
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008840fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008841echo "$as_me:$LINENO: result: $ac_cv_sizeof_fpos_t" >&5
8842echo "${ECHO_T}$ac_cv_sizeof_fpos_t" >&6
8843cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008844#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008845_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008846
Michael W. Hudson54241132001-12-07 15:38:26 +00008847
8848
Martin v. Löwis11437992002-04-12 09:54:03 +00008849echo "$as_me:$LINENO: checking for long long support" >&5
8850echo $ECHO_N "checking for long long support... $ECHO_C" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008851have_long_long=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008852cat >conftest.$ac_ext <<_ACEOF
8853#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008854/* confdefs.h. */
8855_ACEOF
8856cat confdefs.h >>conftest.$ac_ext
8857cat >>conftest.$ac_ext <<_ACEOF
8858/* end confdefs.h. */
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008859
Martin v. Löwis11437992002-04-12 09:54:03 +00008860int
8861main ()
8862{
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008863long long x; x = (long long)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008864 ;
8865 return 0;
8866}
8867_ACEOF
8868rm -f conftest.$ac_objext
8869if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8870 (eval $ac_compile) 2>&5
8871 ac_status=$?
8872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8873 (exit $ac_status); } &&
8874 { ac_try='test -s conftest.$ac_objext'
8875 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8876 (eval $ac_try) 2>&5
8877 ac_status=$?
8878 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8879 (exit $ac_status); }; }; then
8880
8881
8882cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008883#define HAVE_LONG_LONG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008884_ACEOF
8885
Martin v. Löwisc45929e2002-04-06 10:10:49 +00008886 have_long_long=yes
8887
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008888else
Martin v. Löwis11437992002-04-12 09:54:03 +00008889 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008890sed 's/^/| /' conftest.$ac_ext >&5
8891
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008892fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008893rm -f conftest.$ac_objext conftest.$ac_ext
8894echo "$as_me:$LINENO: result: $have_long_long" >&5
8895echo "${ECHO_T}$have_long_long" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00008896if test "$have_long_long" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008897echo "$as_me:$LINENO: checking for long long" >&5
8898echo $ECHO_N "checking for long long... $ECHO_C" >&6
8899if test "${ac_cv_type_long_long+set}" = set; then
8900 echo $ECHO_N "(cached) $ECHO_C" >&6
8901else
8902 cat >conftest.$ac_ext <<_ACEOF
8903#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008904/* confdefs.h. */
8905_ACEOF
8906cat confdefs.h >>conftest.$ac_ext
8907cat >>conftest.$ac_ext <<_ACEOF
8908/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008909$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008910int
8911main ()
8912{
8913if ((long long *) 0)
8914 return 0;
8915if (sizeof (long long))
8916 return 0;
8917 ;
8918 return 0;
8919}
8920_ACEOF
8921rm -f conftest.$ac_objext
8922if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8923 (eval $ac_compile) 2>&5
8924 ac_status=$?
8925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8926 (exit $ac_status); } &&
8927 { ac_try='test -s conftest.$ac_objext'
8928 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8929 (eval $ac_try) 2>&5
8930 ac_status=$?
8931 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8932 (exit $ac_status); }; }; then
8933 ac_cv_type_long_long=yes
8934else
8935 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00008936sed 's/^/| /' conftest.$ac_ext >&5
8937
Martin v. Löwis11437992002-04-12 09:54:03 +00008938ac_cv_type_long_long=no
8939fi
8940rm -f conftest.$ac_objext conftest.$ac_ext
8941fi
8942echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
8943echo "${ECHO_T}$ac_cv_type_long_long" >&6
8944
8945echo "$as_me:$LINENO: checking size of long long" >&5
8946echo $ECHO_N "checking size of long long... $ECHO_C" >&6
8947if test "${ac_cv_sizeof_long_long+set}" = set; then
8948 echo $ECHO_N "(cached) $ECHO_C" >&6
8949else
8950 if test "$ac_cv_type_long_long" = yes; then
8951 # The cast to unsigned long works around a bug in the HP C Compiler
8952 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8953 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8954 # This bug is HP SR number 8606223364.
8955 if test "$cross_compiling" = yes; then
8956 # Depending upon the size, compute the lo and hi bounds.
8957cat >conftest.$ac_ext <<_ACEOF
8958#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008959/* confdefs.h. */
8960_ACEOF
8961cat confdefs.h >>conftest.$ac_ext
8962cat >>conftest.$ac_ext <<_ACEOF
8963/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008964$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008965int
8966main ()
8967{
8968static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
8969test_array [0] = 0
8970
8971 ;
8972 return 0;
8973}
8974_ACEOF
8975rm -f conftest.$ac_objext
8976if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8977 (eval $ac_compile) 2>&5
8978 ac_status=$?
8979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8980 (exit $ac_status); } &&
8981 { ac_try='test -s conftest.$ac_objext'
8982 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8983 (eval $ac_try) 2>&5
8984 ac_status=$?
8985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8986 (exit $ac_status); }; }; then
8987 ac_lo=0 ac_mid=0
8988 while :; do
8989 cat >conftest.$ac_ext <<_ACEOF
8990#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00008991/* confdefs.h. */
8992_ACEOF
8993cat confdefs.h >>conftest.$ac_ext
8994cat >>conftest.$ac_ext <<_ACEOF
8995/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008996$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00008997int
8998main ()
8999{
9000static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
9001test_array [0] = 0
9002
9003 ;
9004 return 0;
9005}
9006_ACEOF
9007rm -f conftest.$ac_objext
9008if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9009 (eval $ac_compile) 2>&5
9010 ac_status=$?
9011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9012 (exit $ac_status); } &&
9013 { ac_try='test -s conftest.$ac_objext'
9014 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9015 (eval $ac_try) 2>&5
9016 ac_status=$?
9017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9018 (exit $ac_status); }; }; then
9019 ac_hi=$ac_mid; break
9020else
9021 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009022sed 's/^/| /' conftest.$ac_ext >&5
9023
Martin v. Löwis11437992002-04-12 09:54:03 +00009024ac_lo=`expr $ac_mid + 1`
9025 if test $ac_lo -le $ac_mid; then
9026 ac_lo= ac_hi=
9027 break
9028 fi
9029 ac_mid=`expr 2 '*' $ac_mid + 1`
9030fi
9031rm -f conftest.$ac_objext conftest.$ac_ext
9032 done
9033else
9034 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009035sed 's/^/| /' conftest.$ac_ext >&5
9036
Martin v. Löwis11437992002-04-12 09:54:03 +00009037cat >conftest.$ac_ext <<_ACEOF
9038#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009039/* confdefs.h. */
9040_ACEOF
9041cat confdefs.h >>conftest.$ac_ext
9042cat >>conftest.$ac_ext <<_ACEOF
9043/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009044$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009045int
9046main ()
9047{
9048static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
9049test_array [0] = 0
9050
9051 ;
9052 return 0;
9053}
9054_ACEOF
9055rm -f conftest.$ac_objext
9056if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9057 (eval $ac_compile) 2>&5
9058 ac_status=$?
9059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9060 (exit $ac_status); } &&
9061 { ac_try='test -s conftest.$ac_objext'
9062 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9063 (eval $ac_try) 2>&5
9064 ac_status=$?
9065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9066 (exit $ac_status); }; }; then
9067 ac_hi=-1 ac_mid=-1
9068 while :; do
9069 cat >conftest.$ac_ext <<_ACEOF
9070#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009071/* confdefs.h. */
9072_ACEOF
9073cat confdefs.h >>conftest.$ac_ext
9074cat >>conftest.$ac_ext <<_ACEOF
9075/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009076$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009077int
9078main ()
9079{
9080static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
9081test_array [0] = 0
9082
9083 ;
9084 return 0;
9085}
9086_ACEOF
9087rm -f conftest.$ac_objext
9088if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9089 (eval $ac_compile) 2>&5
9090 ac_status=$?
9091 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9092 (exit $ac_status); } &&
9093 { ac_try='test -s conftest.$ac_objext'
9094 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9095 (eval $ac_try) 2>&5
9096 ac_status=$?
9097 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9098 (exit $ac_status); }; }; then
9099 ac_lo=$ac_mid; break
9100else
9101 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009102sed 's/^/| /' conftest.$ac_ext >&5
9103
Martin v. Löwis11437992002-04-12 09:54:03 +00009104ac_hi=`expr '(' $ac_mid ')' - 1`
9105 if test $ac_mid -le $ac_hi; then
9106 ac_lo= ac_hi=
9107 break
9108 fi
9109 ac_mid=`expr 2 '*' $ac_mid`
9110fi
9111rm -f conftest.$ac_objext conftest.$ac_ext
9112 done
9113else
9114 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009115sed 's/^/| /' conftest.$ac_ext >&5
9116
Martin v. Löwis11437992002-04-12 09:54:03 +00009117ac_lo= ac_hi=
9118fi
9119rm -f conftest.$ac_objext conftest.$ac_ext
9120fi
9121rm -f conftest.$ac_objext conftest.$ac_ext
9122# Binary search between lo and hi bounds.
9123while test "x$ac_lo" != "x$ac_hi"; do
9124 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9125 cat >conftest.$ac_ext <<_ACEOF
9126#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009127/* confdefs.h. */
9128_ACEOF
9129cat confdefs.h >>conftest.$ac_ext
9130cat >>conftest.$ac_ext <<_ACEOF
9131/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009132$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009133int
9134main ()
9135{
9136static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
9137test_array [0] = 0
9138
9139 ;
9140 return 0;
9141}
9142_ACEOF
9143rm -f conftest.$ac_objext
9144if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9145 (eval $ac_compile) 2>&5
9146 ac_status=$?
9147 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9148 (exit $ac_status); } &&
9149 { ac_try='test -s conftest.$ac_objext'
9150 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9151 (eval $ac_try) 2>&5
9152 ac_status=$?
9153 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9154 (exit $ac_status); }; }; then
9155 ac_hi=$ac_mid
9156else
9157 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009158sed 's/^/| /' conftest.$ac_ext >&5
9159
Martin v. Löwis11437992002-04-12 09:54:03 +00009160ac_lo=`expr '(' $ac_mid ')' + 1`
9161fi
9162rm -f conftest.$ac_objext conftest.$ac_ext
9163done
9164case $ac_lo in
9165?*) ac_cv_sizeof_long_long=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00009166'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
9167See \`config.log' for more details." >&5
9168echo "$as_me: error: cannot compute sizeof (long long), 77
9169See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00009170 { (exit 1); exit 1; }; } ;;
9171esac
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009172else
9173 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00009174 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
9175See \`config.log' for more details." >&5
9176echo "$as_me: error: cannot run test program while cross compiling
9177See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00009178 { (exit 1); exit 1; }; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009179else
Martin v. Löwis11437992002-04-12 09:54:03 +00009180 cat >conftest.$ac_ext <<_ACEOF
9181#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009182/* confdefs.h. */
9183_ACEOF
9184cat confdefs.h >>conftest.$ac_ext
9185cat >>conftest.$ac_ext <<_ACEOF
9186/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009187$ac_includes_default
9188long longval () { return (long) (sizeof (long long)); }
9189unsigned long ulongval () { return (long) (sizeof (long long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009190#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009191#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009192int
9193main ()
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009194{
Martin v. Löwis11437992002-04-12 09:54:03 +00009195
9196 FILE *f = fopen ("conftest.val", "w");
9197 if (! f)
9198 exit (1);
9199 if (((long) (sizeof (long long))) < 0)
9200 {
9201 long i = longval ();
9202 if (i != ((long) (sizeof (long long))))
9203 exit (1);
9204 fprintf (f, "%ld\n", i);
9205 }
9206 else
9207 {
9208 unsigned long i = ulongval ();
9209 if (i != ((long) (sizeof (long long))))
9210 exit (1);
9211 fprintf (f, "%lu\n", i);
9212 }
9213 exit (ferror (f) || fclose (f) != 0);
9214
9215 ;
9216 return 0;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009217}
Martin v. Löwis11437992002-04-12 09:54:03 +00009218_ACEOF
9219rm -f conftest$ac_exeext
9220if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9221 (eval $ac_link) 2>&5
9222 ac_status=$?
9223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9224 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9225 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9226 (eval $ac_try) 2>&5
9227 ac_status=$?
9228 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9229 (exit $ac_status); }; }; then
9230 ac_cv_sizeof_long_long=`cat conftest.val`
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009231else
Martin v. Löwis11437992002-04-12 09:54:03 +00009232 echo "$as_me: program exited with status $ac_status" >&5
9233echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009234sed 's/^/| /' conftest.$ac_ext >&5
9235
Martin v. Löwis11437992002-04-12 09:54:03 +00009236( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00009237{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77
9238See \`config.log' for more details." >&5
9239echo "$as_me: error: cannot compute sizeof (long long), 77
9240See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00009241 { (exit 1); exit 1; }; }
9242fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00009243rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009244fi
9245fi
9246rm -f conftest.val
9247else
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009248 ac_cv_sizeof_long_long=0
9249fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009250fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009251echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
9252echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
9253cat >>confdefs.h <<_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009254#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
Martin v. Löwis11437992002-04-12 09:54:03 +00009255_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009256
Michael W. Hudson54241132001-12-07 15:38:26 +00009257
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009258fi
9259
Martin v. Löwis11437992002-04-12 09:54:03 +00009260echo "$as_me:$LINENO: checking for uintptr_t support" >&5
9261echo $ECHO_N "checking for uintptr_t support... $ECHO_C" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009262have_uintptr_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009263cat >conftest.$ac_ext <<_ACEOF
9264#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009265/* confdefs.h. */
9266_ACEOF
9267cat confdefs.h >>conftest.$ac_ext
9268cat >>conftest.$ac_ext <<_ACEOF
9269/* end confdefs.h. */
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009270
Martin v. Löwis11437992002-04-12 09:54:03 +00009271int
9272main ()
9273{
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009274uintptr_t x; x = (uintptr_t)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009275 ;
9276 return 0;
9277}
9278_ACEOF
9279rm -f conftest.$ac_objext
9280if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9281 (eval $ac_compile) 2>&5
9282 ac_status=$?
9283 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9284 (exit $ac_status); } &&
9285 { ac_try='test -s conftest.$ac_objext'
9286 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9287 (eval $ac_try) 2>&5
9288 ac_status=$?
9289 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9290 (exit $ac_status); }; }; then
9291
9292
9293cat >>confdefs.h <<\_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009294#define HAVE_UINTPTR_T 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009295_ACEOF
9296
Martin v. Löwisc45929e2002-04-06 10:10:49 +00009297 have_uintptr_t=yes
9298
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009299else
Martin v. Löwis11437992002-04-12 09:54:03 +00009300 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009301sed 's/^/| /' conftest.$ac_ext >&5
9302
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009303fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009304rm -f conftest.$ac_objext conftest.$ac_ext
9305echo "$as_me:$LINENO: result: $have_uintptr_t" >&5
9306echo "${ECHO_T}$have_uintptr_t" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009307if test "$have_uintptr_t" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009308echo "$as_me:$LINENO: checking for uintptr_t" >&5
9309echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6
9310if test "${ac_cv_type_uintptr_t+set}" = set; then
9311 echo $ECHO_N "(cached) $ECHO_C" >&6
9312else
9313 cat >conftest.$ac_ext <<_ACEOF
9314#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009315/* confdefs.h. */
9316_ACEOF
9317cat confdefs.h >>conftest.$ac_ext
9318cat >>conftest.$ac_ext <<_ACEOF
9319/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009320$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009321int
9322main ()
9323{
9324if ((uintptr_t *) 0)
9325 return 0;
9326if (sizeof (uintptr_t))
9327 return 0;
9328 ;
9329 return 0;
9330}
9331_ACEOF
9332rm -f conftest.$ac_objext
9333if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9334 (eval $ac_compile) 2>&5
9335 ac_status=$?
9336 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9337 (exit $ac_status); } &&
9338 { ac_try='test -s conftest.$ac_objext'
9339 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9340 (eval $ac_try) 2>&5
9341 ac_status=$?
9342 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9343 (exit $ac_status); }; }; then
9344 ac_cv_type_uintptr_t=yes
9345else
9346 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009347sed 's/^/| /' conftest.$ac_ext >&5
9348
Martin v. Löwis11437992002-04-12 09:54:03 +00009349ac_cv_type_uintptr_t=no
9350fi
9351rm -f conftest.$ac_objext conftest.$ac_ext
9352fi
9353echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
9354echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6
9355
9356echo "$as_me:$LINENO: checking size of uintptr_t" >&5
9357echo $ECHO_N "checking size of uintptr_t... $ECHO_C" >&6
9358if test "${ac_cv_sizeof_uintptr_t+set}" = set; then
9359 echo $ECHO_N "(cached) $ECHO_C" >&6
9360else
9361 if test "$ac_cv_type_uintptr_t" = yes; then
9362 # The cast to unsigned long works around a bug in the HP C Compiler
9363 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9364 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9365 # This bug is HP SR number 8606223364.
9366 if test "$cross_compiling" = yes; then
9367 # Depending upon the size, compute the lo and hi bounds.
9368cat >conftest.$ac_ext <<_ACEOF
9369#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009370/* confdefs.h. */
9371_ACEOF
9372cat confdefs.h >>conftest.$ac_ext
9373cat >>conftest.$ac_ext <<_ACEOF
9374/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009375$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009376int
9377main ()
9378{
9379static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= 0)];
9380test_array [0] = 0
9381
9382 ;
9383 return 0;
9384}
9385_ACEOF
9386rm -f conftest.$ac_objext
9387if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9388 (eval $ac_compile) 2>&5
9389 ac_status=$?
9390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9391 (exit $ac_status); } &&
9392 { ac_try='test -s conftest.$ac_objext'
9393 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9394 (eval $ac_try) 2>&5
9395 ac_status=$?
9396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9397 (exit $ac_status); }; }; then
9398 ac_lo=0 ac_mid=0
9399 while :; do
9400 cat >conftest.$ac_ext <<_ACEOF
9401#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009402/* confdefs.h. */
9403_ACEOF
9404cat confdefs.h >>conftest.$ac_ext
9405cat >>conftest.$ac_ext <<_ACEOF
9406/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009407$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009408int
9409main ()
9410{
9411static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
9412test_array [0] = 0
9413
9414 ;
9415 return 0;
9416}
9417_ACEOF
9418rm -f conftest.$ac_objext
9419if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9420 (eval $ac_compile) 2>&5
9421 ac_status=$?
9422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9423 (exit $ac_status); } &&
9424 { ac_try='test -s conftest.$ac_objext'
9425 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9426 (eval $ac_try) 2>&5
9427 ac_status=$?
9428 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9429 (exit $ac_status); }; }; then
9430 ac_hi=$ac_mid; break
9431else
9432 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009433sed 's/^/| /' conftest.$ac_ext >&5
9434
Martin v. Löwis11437992002-04-12 09:54:03 +00009435ac_lo=`expr $ac_mid + 1`
9436 if test $ac_lo -le $ac_mid; then
9437 ac_lo= ac_hi=
9438 break
9439 fi
9440 ac_mid=`expr 2 '*' $ac_mid + 1`
9441fi
9442rm -f conftest.$ac_objext conftest.$ac_ext
9443 done
9444else
9445 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009446sed 's/^/| /' conftest.$ac_ext >&5
9447
Martin v. Löwis11437992002-04-12 09:54:03 +00009448cat >conftest.$ac_ext <<_ACEOF
9449#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009450/* confdefs.h. */
9451_ACEOF
9452cat confdefs.h >>conftest.$ac_ext
9453cat >>conftest.$ac_ext <<_ACEOF
9454/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009455$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009456int
9457main ()
9458{
9459static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) < 0)];
9460test_array [0] = 0
9461
9462 ;
9463 return 0;
9464}
9465_ACEOF
9466rm -f conftest.$ac_objext
9467if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9468 (eval $ac_compile) 2>&5
9469 ac_status=$?
9470 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9471 (exit $ac_status); } &&
9472 { ac_try='test -s conftest.$ac_objext'
9473 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9474 (eval $ac_try) 2>&5
9475 ac_status=$?
9476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9477 (exit $ac_status); }; }; then
9478 ac_hi=-1 ac_mid=-1
9479 while :; do
9480 cat >conftest.$ac_ext <<_ACEOF
9481#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009482/* confdefs.h. */
9483_ACEOF
9484cat confdefs.h >>conftest.$ac_ext
9485cat >>conftest.$ac_ext <<_ACEOF
9486/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009487$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009488int
9489main ()
9490{
9491static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= $ac_mid)];
9492test_array [0] = 0
9493
9494 ;
9495 return 0;
9496}
9497_ACEOF
9498rm -f conftest.$ac_objext
9499if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9500 (eval $ac_compile) 2>&5
9501 ac_status=$?
9502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9503 (exit $ac_status); } &&
9504 { ac_try='test -s conftest.$ac_objext'
9505 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9506 (eval $ac_try) 2>&5
9507 ac_status=$?
9508 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9509 (exit $ac_status); }; }; then
9510 ac_lo=$ac_mid; break
9511else
9512 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009513sed 's/^/| /' conftest.$ac_ext >&5
9514
Martin v. Löwis11437992002-04-12 09:54:03 +00009515ac_hi=`expr '(' $ac_mid ')' - 1`
9516 if test $ac_mid -le $ac_hi; then
9517 ac_lo= ac_hi=
9518 break
9519 fi
9520 ac_mid=`expr 2 '*' $ac_mid`
9521fi
9522rm -f conftest.$ac_objext conftest.$ac_ext
9523 done
9524else
9525 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009526sed 's/^/| /' conftest.$ac_ext >&5
9527
Martin v. Löwis11437992002-04-12 09:54:03 +00009528ac_lo= ac_hi=
9529fi
9530rm -f conftest.$ac_objext conftest.$ac_ext
9531fi
9532rm -f conftest.$ac_objext conftest.$ac_ext
9533# Binary search between lo and hi bounds.
9534while test "x$ac_lo" != "x$ac_hi"; do
9535 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9536 cat >conftest.$ac_ext <<_ACEOF
9537#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009538/* confdefs.h. */
9539_ACEOF
9540cat confdefs.h >>conftest.$ac_ext
9541cat >>conftest.$ac_ext <<_ACEOF
9542/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009543$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +00009544int
9545main ()
9546{
9547static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
9548test_array [0] = 0
9549
9550 ;
9551 return 0;
9552}
9553_ACEOF
9554rm -f conftest.$ac_objext
9555if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9556 (eval $ac_compile) 2>&5
9557 ac_status=$?
9558 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9559 (exit $ac_status); } &&
9560 { ac_try='test -s conftest.$ac_objext'
9561 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9562 (eval $ac_try) 2>&5
9563 ac_status=$?
9564 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9565 (exit $ac_status); }; }; then
9566 ac_hi=$ac_mid
9567else
9568 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009569sed 's/^/| /' conftest.$ac_ext >&5
9570
Martin v. Löwis11437992002-04-12 09:54:03 +00009571ac_lo=`expr '(' $ac_mid ')' + 1`
9572fi
9573rm -f conftest.$ac_objext conftest.$ac_ext
9574done
9575case $ac_lo in
9576?*) ac_cv_sizeof_uintptr_t=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +00009577'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77
9578See \`config.log' for more details." >&5
9579echo "$as_me: error: cannot compute sizeof (uintptr_t), 77
9580See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00009581 { (exit 1); exit 1; }; } ;;
9582esac
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009583else
9584 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +00009585 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
9586See \`config.log' for more details." >&5
9587echo "$as_me: error: cannot run test program while cross compiling
9588See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00009589 { (exit 1); exit 1; }; }
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009590else
Martin v. Löwis11437992002-04-12 09:54:03 +00009591 cat >conftest.$ac_ext <<_ACEOF
9592#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009593/* confdefs.h. */
9594_ACEOF
9595cat confdefs.h >>conftest.$ac_ext
9596cat >>conftest.$ac_ext <<_ACEOF
9597/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009598$ac_includes_default
9599long longval () { return (long) (sizeof (uintptr_t)); }
9600unsigned long ulongval () { return (long) (sizeof (uintptr_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009601#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009602#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009603int
9604main ()
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009605{
Martin v. Löwis11437992002-04-12 09:54:03 +00009606
9607 FILE *f = fopen ("conftest.val", "w");
9608 if (! f)
9609 exit (1);
9610 if (((long) (sizeof (uintptr_t))) < 0)
9611 {
9612 long i = longval ();
9613 if (i != ((long) (sizeof (uintptr_t))))
9614 exit (1);
9615 fprintf (f, "%ld\n", i);
9616 }
9617 else
9618 {
9619 unsigned long i = ulongval ();
9620 if (i != ((long) (sizeof (uintptr_t))))
9621 exit (1);
9622 fprintf (f, "%lu\n", i);
9623 }
9624 exit (ferror (f) || fclose (f) != 0);
9625
9626 ;
9627 return 0;
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009628}
Martin v. Löwis11437992002-04-12 09:54:03 +00009629_ACEOF
9630rm -f conftest$ac_exeext
9631if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9632 (eval $ac_link) 2>&5
9633 ac_status=$?
9634 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9635 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9636 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9637 (eval $ac_try) 2>&5
9638 ac_status=$?
9639 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9640 (exit $ac_status); }; }; then
9641 ac_cv_sizeof_uintptr_t=`cat conftest.val`
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009642else
Martin v. Löwis11437992002-04-12 09:54:03 +00009643 echo "$as_me: program exited with status $ac_status" >&5
9644echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009645sed 's/^/| /' conftest.$ac_ext >&5
9646
Martin v. Löwis11437992002-04-12 09:54:03 +00009647( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +00009648{ { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77
9649See \`config.log' for more details." >&5
9650echo "$as_me: error: cannot compute sizeof (uintptr_t), 77
9651See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00009652 { (exit 1); exit 1; }; }
9653fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00009654rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009655fi
9656fi
9657rm -f conftest.val
9658else
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009659 ac_cv_sizeof_uintptr_t=0
9660fi
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009661fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009662echo "$as_me:$LINENO: result: $ac_cv_sizeof_uintptr_t" >&5
9663echo "${ECHO_T}$ac_cv_sizeof_uintptr_t" >&6
9664cat >>confdefs.h <<_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009665#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009666_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009667
Michael W. Hudson54241132001-12-07 15:38:26 +00009668
Barry Warsawbc7c7f92000-08-18 04:53:33 +00009669fi
9670
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009671# Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00009672echo "$as_me:$LINENO: checking size of off_t" >&5
9673echo $ECHO_N "checking size of off_t... $ECHO_C" >&6
9674if test "${ac_cv_sizeof_off_t+set}" = set; then
9675 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009676else
9677 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00009678 ac_cv_sizeof_off_t=4
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009679else
Martin v. Löwis11437992002-04-12 09:54:03 +00009680 cat >conftest.$ac_ext <<_ACEOF
9681#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009682/* confdefs.h. */
9683_ACEOF
9684cat confdefs.h >>conftest.$ac_ext
9685cat >>conftest.$ac_ext <<_ACEOF
9686/* end confdefs.h. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009687#include <stdio.h>
9688#include <sys/types.h>
9689main()
9690{
9691 FILE *f=fopen("conftestval", "w");
9692 if (!f) exit(1);
9693 fprintf(f, "%d\n", sizeof(off_t));
9694 exit(0);
9695}
Martin v. Löwis11437992002-04-12 09:54:03 +00009696_ACEOF
9697rm -f conftest$ac_exeext
9698if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9699 (eval $ac_link) 2>&5
9700 ac_status=$?
9701 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9702 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9703 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9704 (eval $ac_try) 2>&5
9705 ac_status=$?
9706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9707 (exit $ac_status); }; }; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009708 ac_cv_sizeof_off_t=`cat conftestval`
9709else
Martin v. Löwis11437992002-04-12 09:54:03 +00009710 echo "$as_me: program exited with status $ac_status" >&5
9711echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009712sed 's/^/| /' conftest.$ac_ext >&5
9713
Martin v. Löwis11437992002-04-12 09:54:03 +00009714( exit $ac_status )
9715ac_cv_sizeof_off_t=0
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009716fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00009717rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009718fi
9719
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009720fi
9721
Martin v. Löwis11437992002-04-12 09:54:03 +00009722echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
9723echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6
9724
9725cat >>confdefs.h <<_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009726#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009727_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009728
Michael W. Hudson54241132001-12-07 15:38:26 +00009729
Martin v. Löwis11437992002-04-12 09:54:03 +00009730echo "$as_me:$LINENO: checking whether to enable large file support" >&5
9731echo $ECHO_N "checking whether to enable large file support... $ECHO_C" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00009732if test "$have_long_long" = yes -a \
9733 "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
9734 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009735
Martin v. Löwis11437992002-04-12 09:54:03 +00009736cat >>confdefs.h <<\_ACEOF
9737#define HAVE_LARGEFILE_SUPPORT 1
9738_ACEOF
9739
9740 echo "$as_me:$LINENO: result: yes" >&5
9741echo "${ECHO_T}yes" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009742else
Martin v. Löwis11437992002-04-12 09:54:03 +00009743 echo "$as_me:$LINENO: result: no" >&5
9744echo "${ECHO_T}no" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00009745fi
9746
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009747# AC_CHECK_SIZEOF() doesn't include <time.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00009748echo "$as_me:$LINENO: checking size of time_t" >&5
9749echo $ECHO_N "checking size of time_t... $ECHO_C" >&6
9750if test "${ac_cv_sizeof_time_t+set}" = set; then
9751 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009752else
9753 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00009754 ac_cv_sizeof_time_t=4
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009755else
Martin v. Löwis11437992002-04-12 09:54:03 +00009756 cat >conftest.$ac_ext <<_ACEOF
9757#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009758/* confdefs.h. */
9759_ACEOF
9760cat confdefs.h >>conftest.$ac_ext
9761cat >>conftest.$ac_ext <<_ACEOF
9762/* end confdefs.h. */
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009763#include <stdio.h>
9764#include <time.h>
9765main()
9766{
9767 FILE *f=fopen("conftestval", "w");
9768 if (!f) exit(1);
9769 fprintf(f, "%d\n", sizeof(time_t));
9770 exit(0);
9771}
Martin v. Löwis11437992002-04-12 09:54:03 +00009772_ACEOF
9773rm -f conftest$ac_exeext
9774if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9775 (eval $ac_link) 2>&5
9776 ac_status=$?
9777 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9778 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9779 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9780 (eval $ac_try) 2>&5
9781 ac_status=$?
9782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9783 (exit $ac_status); }; }; then
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009784 ac_cv_sizeof_time_t=`cat conftestval`
9785else
Martin v. Löwis11437992002-04-12 09:54:03 +00009786 echo "$as_me: program exited with status $ac_status" >&5
9787echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009788sed 's/^/| /' conftest.$ac_ext >&5
9789
Martin v. Löwis11437992002-04-12 09:54:03 +00009790( exit $ac_status )
9791ac_cv_sizeof_time_t=0
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009792fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00009793rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009794fi
9795
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009796fi
9797
Martin v. Löwis11437992002-04-12 09:54:03 +00009798echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5
9799echo "${ECHO_T}$ac_cv_sizeof_time_t" >&6
9800
9801cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009802#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009803_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009804
Michael W. Hudson54241132001-12-07 15:38:26 +00009805
9806
Trent Mick635f6fb2000-08-23 21:33:05 +00009807# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +00009808ac_save_cc="$CC"
9809if test "$ac_cv_kpthread" = "yes"
9810then CC="$CC -Kpthread"
Martin v. Löwis5f433f02003-05-05 05:05:30 +00009811elif test "$ac_cv_kthread" = "yes"
9812then CC="$CC -Kthread"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +00009813elif test "$ac_cv_pthread" = "yes"
9814then CC="$CC -pthread"
Martin v. Löwis123cbd22001-07-19 14:21:10 +00009815fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009816echo "$as_me:$LINENO: checking for pthread_t" >&5
9817echo $ECHO_N "checking for pthread_t... $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009818have_pthread_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009819cat >conftest.$ac_ext <<_ACEOF
9820#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009821/* confdefs.h. */
9822_ACEOF
9823cat confdefs.h >>conftest.$ac_ext
9824cat >>conftest.$ac_ext <<_ACEOF
9825/* end confdefs.h. */
Trent Mick635f6fb2000-08-23 21:33:05 +00009826#include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009827int
9828main ()
9829{
Guido van Rossum12580492000-09-24 16:47:19 +00009830pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009831 ;
9832 return 0;
9833}
9834_ACEOF
9835rm -f conftest.$ac_objext
9836if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9837 (eval $ac_compile) 2>&5
9838 ac_status=$?
9839 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9840 (exit $ac_status); } &&
9841 { ac_try='test -s conftest.$ac_objext'
9842 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9843 (eval $ac_try) 2>&5
9844 ac_status=$?
9845 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9846 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00009847 have_pthread_t=yes
9848else
Martin v. Löwis11437992002-04-12 09:54:03 +00009849 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009850sed 's/^/| /' conftest.$ac_ext >&5
9851
Trent Mick635f6fb2000-08-23 21:33:05 +00009852fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009853rm -f conftest.$ac_objext conftest.$ac_ext
9854echo "$as_me:$LINENO: result: $have_pthread_t" >&5
9855echo "${ECHO_T}$have_pthread_t" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009856if test "$have_pthread_t" = yes ; then
9857 # AC_CHECK_SIZEOF() doesn't include <pthread.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00009858 echo "$as_me:$LINENO: checking size of pthread_t" >&5
9859echo $ECHO_N "checking size of pthread_t... $ECHO_C" >&6
9860 if test "${ac_cv_sizeof_pthread_t+set}" = set; then
9861 echo $ECHO_N "(cached) $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009862else
9863 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00009864 ac_cv_sizeof_pthread_t=4
Trent Mick635f6fb2000-08-23 21:33:05 +00009865else
Martin v. Löwis11437992002-04-12 09:54:03 +00009866 cat >conftest.$ac_ext <<_ACEOF
9867#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +00009868/* confdefs.h. */
9869_ACEOF
9870cat confdefs.h >>conftest.$ac_ext
9871cat >>conftest.$ac_ext <<_ACEOF
9872/* end confdefs.h. */
Trent Mick635f6fb2000-08-23 21:33:05 +00009873#include <stdio.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +00009874#include <pthread.h>
Trent Mick635f6fb2000-08-23 21:33:05 +00009875 main()
9876 {
9877 FILE *f=fopen("conftestval", "w");
9878 if (!f) exit(1);
9879 fprintf(f, "%d\n", sizeof(pthread_t));
9880 exit(0);
9881 }
Martin v. Löwis11437992002-04-12 09:54:03 +00009882_ACEOF
9883rm -f conftest$ac_exeext
9884if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9885 (eval $ac_link) 2>&5
9886 ac_status=$?
9887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9888 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9889 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9890 (eval $ac_try) 2>&5
9891 ac_status=$?
9892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9893 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00009894 ac_cv_sizeof_pthread_t=`cat conftestval`
9895else
Martin v. Löwis11437992002-04-12 09:54:03 +00009896 echo "$as_me: program exited with status $ac_status" >&5
9897echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +00009898sed 's/^/| /' conftest.$ac_ext >&5
9899
Martin v. Löwis11437992002-04-12 09:54:03 +00009900( exit $ac_status )
9901ac_cv_sizeof_pthread_t=0
Trent Mick635f6fb2000-08-23 21:33:05 +00009902fi
Skip Montanarod8d39a02003-07-10 20:44:10 +00009903rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Trent Mick635f6fb2000-08-23 21:33:05 +00009904fi
9905
Trent Mick635f6fb2000-08-23 21:33:05 +00009906fi
9907
Martin v. Löwis11437992002-04-12 09:54:03 +00009908 echo "$as_me:$LINENO: result: $ac_cv_sizeof_pthread_t" >&5
9909echo "${ECHO_T}$ac_cv_sizeof_pthread_t" >&6
9910
9911cat >>confdefs.h <<_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00009912#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009913_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00009914
9915fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +00009916CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +00009917
Martin v. Löwis11437992002-04-12 09:54:03 +00009918echo "$as_me:$LINENO: checking for --enable-toolbox-glue" >&5
9919echo $ECHO_N "checking for --enable-toolbox-glue... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009920# Check whether --enable-toolbox-glue or --disable-toolbox-glue was given.
9921if test "${enable_toolbox_glue+set}" = set; then
9922 enableval="$enable_toolbox_glue"
Jack Jansene578a632001-08-15 01:27:14 +00009923
Martin v. Löwis11437992002-04-12 09:54:03 +00009924fi;
Jack Jansene578a632001-08-15 01:27:14 +00009925
9926if test -z "$enable_toolbox_glue"
Martin v. Löwis11437992002-04-12 09:54:03 +00009927then
Jack Jansene578a632001-08-15 01:27:14 +00009928 case $ac_sys_system/$ac_sys_release in
9929 Darwin/*)
9930 enable_toolbox_glue="yes";;
9931 *)
9932 enable_toolbox_glue="no";;
9933 esac
9934fi
9935case "$enable_toolbox_glue" in
9936yes)
Jack Jansen666b1e72001-10-31 12:11:48 +00009937 extra_frameworks="-framework CoreServices -framework Foundation"
Jack Jansene578a632001-08-15 01:27:14 +00009938 extra_machdep_objs="Python/mactoolboxglue.o"
Jack Jansen591cbed2001-08-15 13:55:15 +00009939 extra_undefs="-u __dummy -u _PyMac_Error"
Martin v. Löwis11437992002-04-12 09:54:03 +00009940
9941cat >>confdefs.h <<\_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00009942#define USE_TOOLBOX_OBJECT_GLUE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009943_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00009944
9945 ;;
9946*)
9947 extra_frameworks=""
9948 extra_machdep_objs=""
Jack Jansen591cbed2001-08-15 13:55:15 +00009949 extra_undefs=""
Jack Jansene578a632001-08-15 01:27:14 +00009950 ;;
9951esac
Martin v. Löwis11437992002-04-12 09:54:03 +00009952echo "$as_me:$LINENO: result: $enable_toolbox_glue" >&5
9953echo "${ECHO_T}$enable_toolbox_glue" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00009954
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009955
9956case $ac_sys_system/$ac_sys_release in
Jack Jansen418c3b12001-11-14 10:59:57 +00009957 Darwin/1.3*)
Jack Jansenea0c3822002-08-01 21:57:49 +00009958 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00009959 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansen66b84832003-07-04 12:14:39 +00009960 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/Python'
Jack Jansena3891ea2001-09-07 14:25:12 +00009961 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +00009962 Darwin/*)
Jack Jansenea0c3822002-08-01 21:57:49 +00009963 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00009964 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansen66b84832003-07-04 12:14:39 +00009965 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/Python'
Jack Jansene578a632001-08-15 01:27:14 +00009966 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009967esac
9968
Martin v. Löwis11437992002-04-12 09:54:03 +00009969echo "$as_me:$LINENO: checking for --enable-framework" >&5
9970echo $ECHO_N "checking for --enable-framework... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009971if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009972then
Skip Montanarodecc6a42003-01-01 20:07:49 +00009973 BASECFLAGS="$BASECFLAGS -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +00009974 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +00009975 # in the build location.
Jack Jansenea0c3822002-08-01 21:57:49 +00009976 LDFLAGS="$LDFLAGS -Wl,-F."
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009977
Martin v. Löwis11437992002-04-12 09:54:03 +00009978cat >>confdefs.h <<\_ACEOF
9979#define WITH_NEXT_FRAMEWORK 1
9980_ACEOF
9981
9982 echo "$as_me:$LINENO: result: yes" >&5
9983echo "${ECHO_T}yes" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009984else
Martin v. Löwis11437992002-04-12 09:54:03 +00009985 echo "$as_me:$LINENO: result: no" >&5
9986echo "${ECHO_T}no" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009987fi
9988
Martin v. Löwis11437992002-04-12 09:54:03 +00009989echo "$as_me:$LINENO: checking for dyld" >&5
9990echo $ECHO_N "checking for dyld... $ECHO_C" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009991case $ac_sys_system/$ac_sys_release in
9992 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009993
Martin v. Löwis11437992002-04-12 09:54:03 +00009994cat >>confdefs.h <<\_ACEOF
9995#define WITH_DYLD 1
9996_ACEOF
9997
9998 echo "$as_me:$LINENO: result: always on for Darwin" >&5
9999echo "${ECHO_T}always on for Darwin" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +000010000 ;;
10001 *)
Martin v. Löwis11437992002-04-12 09:54:03 +000010002 echo "$as_me:$LINENO: result: no" >&5
10003echo "${ECHO_T}no" >&6
Jack Jansene578a632001-08-15 01:27:14 +000010004 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +000010005esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010006
Guido van Rossum0a516c91994-09-12 10:58:40 +000010007# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +000010008
Michael W. Hudson54241132001-12-07 15:38:26 +000010009
10010
10011
10012
Guido van Rossum0a516c91994-09-12 10:58:40 +000010013# SO is the extension of shared libraries `(including the dot!)
Guido van Rossumaef734b2001-01-10 21:09:12 +000010014# -- usually .so, .sl on HP-UX, .dll on Cygwin
Martin v. Löwis11437992002-04-12 09:54:03 +000010015echo "$as_me:$LINENO: checking SO" >&5
10016echo $ECHO_N "checking SO... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010017if test -z "$SO"
10018then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010019 case $ac_sys_system in
Guido van Rossum563e7081996-09-10 18:20:48 +000010020 hp*|HP*) SO=.sl;;
Guido van Rossumaef734b2001-01-10 21:09:12 +000010021 CYGWIN*) SO=.dll;;
Guido van Rossum563e7081996-09-10 18:20:48 +000010022 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010023 esac
Martin v. Löwis368de8f2003-06-14 14:46:38 +000010024else
10025 # this might also be a termcap variable, see #610332
10026 echo
10027 echo '====================================================================='
10028 echo '+ +'
10029 echo '+ WARNING: You have set SO in your environment. +'
10030 echo '+ Do you really mean to change the extension for shared libraries? +'
10031 echo '+ Continuing in 10 seconds to let you to ponder. +'
10032 echo '+ +'
10033 echo '====================================================================='
10034 sleep 10
Guido van Rossum0a516c91994-09-12 10:58:40 +000010035fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010036echo "$as_me:$LINENO: result: $SO" >&5
10037echo "${ECHO_T}$SO" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010038# LDSHARED is the ld *command* used to create shared library
Martin v. Löwis5b718fc2001-09-10 15:34:42 +000010039# -- "ld" on SunOS 4.x.x, "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010040# (Shared libraries in this instance are shared modules to be loaded into
10041# Python, as opposed to building Python itself as a shared library.)
Martin v. Löwis11437992002-04-12 09:54:03 +000010042echo "$as_me:$LINENO: checking LDSHARED" >&5
10043echo $ECHO_N "checking LDSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010044if test -z "$LDSHARED"
10045then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010046 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010047 AIX*)
10048 BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Guido van Rossumce608b02001-09-28 15:59:38 +000010049 LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010050 ;;
10051 BeOS*)
10052 BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY"
Guido van Rossumce608b02001-09-28 15:59:38 +000010053 LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010054 ;;
Guido van Rossum07397971997-04-29 21:49:50 +000010055 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +000010056 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010057 SunOS/4*) LDSHARED="ld";;
Martin v. Löwis11437992002-04-12 09:54:03 +000010058 SunOS/5*)
Greg Ward57c9a6632000-05-26 12:22:54 +000010059 if test "$GCC" = "yes"
Neil Schemenauer8ba94452001-02-19 18:18:48 +000010060 then LDSHARED='$(CC) -shared'
Martin v. Löwisaa5afe12002-10-07 06:21:41 +000010061 else LDSHARED='$(CC) -G';
Greg Ward57c9a6632000-05-26 12:22:54 +000010062 fi ;;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010063 hp*|HP*) LDSHARED="ld -b";;
Guido van Rossumda88dad1995-01-26 00:46:29 +000010064 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
10065 DYNIX/ptx*) LDSHARED="ld -G";;
Jack Jansen418c3b12001-11-14 10:59:57 +000010066 Darwin/1.3*)
Jack Jansena3891ea2001-09-07 14:25:12 +000010067 LDSHARED='$(CC) $(LDFLAGS) -bundle'
10068 if test "$enable_framework" ; then
10069 # Link against the framework. All externals should be defined.
10070 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
10071 else
10072 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +000010073 LDSHARED="$LDSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +000010074 fi ;;
Jack Jansene578a632001-08-15 01:27:14 +000010075 Darwin/*)
10076 LDSHARED='$(CC) $(LDFLAGS) -bundle'
10077 if test "$enable_framework" ; then
10078 # Link against the framework. All externals should be defined.
10079 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
10080 else
Michael W. Hudson594bc802002-03-07 09:59:15 +000010081 # No framework, use the Python app as bundle-loader
10082 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
Jack Jansenc28fc372003-02-25 13:14:43 +000010083 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010084 fi ;;
Martin v. Löwis3cba5c02002-09-16 17:50:59 +000010085 Linux*|GNU*) LDSHARED='$(CC) -shared';;
Guido van Rossum3c4bb801997-12-18 23:55:32 +000010086 dgux*) LDSHARED="ld -G";;
Guido van Rossum458e7fa1999-09-17 15:40:40 +000010087 BSD/OS*/4*) LDSHARED="gcc -shared";;
Martin v. Löwisd61888b2002-09-30 11:17:27 +000010088 OpenBSD*|FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +000010089 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +000010090 then
10091 LDSHARED="cc -shared ${LDFLAGS}"
10092 else
10093 LDSHARED="ld -Bshareable ${LDFLAGS}"
10094 fi;;
Martin v. Löwisd61888b2002-09-30 11:17:27 +000010095 NetBSD*) LDSHARED="cc -shared ${LDFLAGS}";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000010096 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000010097 if test "$GCC" = "yes"
Martin v. Löwis79f3c532002-12-11 12:51:58 +000010098 then LDSHARED='$(CC) -shared'
10099 else LDSHARED='$(CC) -G'
Martin v. Löwisbec19582001-03-21 15:57:54 +000010100 fi;;
Martin v. Löwis79f3c532002-12-11 12:51:58 +000010101 SCO_SV*) LDSHARED='$(CC) -Wl,-G,-Bexport';;
Trent Mick635f6fb2000-08-23 21:33:05 +000010102 Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
Guido van Rossumaef734b2001-01-10 21:09:12 +000010103 CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010104 atheos*) LDSHARED="gcc -shared";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010105 *) LDSHARED="ld";;
10106 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000010107fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010108echo "$as_me:$LINENO: result: $LDSHARED" >&5
10109echo "${ECHO_T}$LDSHARED" >&6
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010110BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +000010111# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010112# library (module) -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +000010113echo "$as_me:$LINENO: checking CCSHARED" >&5
10114echo $ECHO_N "checking CCSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010115if test -z "$CCSHARED"
10116then
Guido van Rossum07397971997-04-29 21:49:50 +000010117 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +000010118 SunOS*) if test "$GCC" = yes;
10119 then CCSHARED="-fPIC";
10120 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +000010121 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +000010122 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +000010123 else CCSHARED="+z";
10124 fi;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010125 Linux*|GNU*) CCSHARED="-fPIC";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +000010126 BSD/OS*/4*) CCSHARED="-fpic";;
Martin v. Löwis36546db2001-09-05 14:24:43 +000010127 FreeBSD*|NetBSD*|OpenBSD*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000010128 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000010129 if test "$GCC" = "yes"
10130 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010131 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +000010132 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000010133 SCO_SV*)
10134 if test "$GCC" = "yes"
10135 then CCSHARED="-fPIC"
10136 else CCSHARED="-Kpic -belf"
10137 fi;;
Trent Mick635f6fb2000-08-23 21:33:05 +000010138 Monterey*) CCSHARED="-G";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000010139 IRIX*/6*) case $CC in
10140 *gcc*) CCSHARED="-shared";;
Guido van Rossumee21f411998-04-20 18:51:54 +000010141 *) CCSHARED="";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000010142 esac;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010143 atheos*) CCSHARED="-fPIC";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010144 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000010145fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010146echo "$as_me:$LINENO: result: $CCSHARED" >&5
10147echo "${ECHO_T}$CCSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010148# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010149# the python executable -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +000010150echo "$as_me:$LINENO: checking LINKFORSHARED" >&5
10151echo $ECHO_N "checking LINKFORSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010152if test -z "$LINKFORSHARED"
10153then
Guido van Rossum07397971997-04-29 21:49:50 +000010154 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000010155 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +000010156 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +000010157 LINKFORSHARED="-Wl,-E -Wl,+s";;
10158# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +000010159 BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010160 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000010161 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +000010162 Darwin/*)
Jack Jansene578a632001-08-15 01:27:14 +000010163 # -u __dummy makes the linker aware of the objc runtime
10164 # in System.framework; otherwise, __objcInit (referenced in
10165 # crt1.o) gets erroneously defined as common, which breaks dynamic
10166 # loading of any modules which reference it in System.framework.
10167 # -u _PyMac_Error is needed to pull in the mac toolbox glue, which is
10168 # not used by the core itself but which needs to be in the core so
10169 # that dynamically loaded extension modules have access to it.
Jack Jansen97e3f002003-02-23 22:59:01 +000010170 # -prebind is no longer used, because it actually seems to give a
10171 # slowdown in stead of a speedup, maybe due to the large number of
10172 # dynamic loads Python does.
10173 LINKFORSHARED="$extra_undefs -framework System"
Jack Jansene578a632001-08-15 01:27:14 +000010174 if test "$enable_framework"
10175 then
10176 LINKFORSHARED="$LINKFORSHARED -framework Python"
10177 fi
10178 LINKFORSHARED="$LINKFORSHARED $extra_frameworks";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000010179 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000010180 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +000010181 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis11437992002-04-12 09:54:03 +000010182 FreeBSD*|NetBSD*|OpenBSD*)
Guido van Rossumdf693651999-01-07 21:50:41 +000010183 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
10184 then
10185 LINKFORSHARED="-Wl,--export-dynamic"
10186 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000010187 SunOS/5*) case $CC in
10188 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +000010189 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +000010190 then
10191 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +000010192 fi;;
10193 esac;;
Guido van Rossum0a516c91994-09-12 10:58:40 +000010194 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000010195fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010196echo "$as_me:$LINENO: result: $LINKFORSHARED" >&5
10197echo "${ECHO_T}$LINKFORSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +000010198
Michael W. Hudson54241132001-12-07 15:38:26 +000010199
Martin v. Löwis11437992002-04-12 09:54:03 +000010200echo "$as_me:$LINENO: checking CFLAGSFORSHARED" >&5
10201echo $ECHO_N "checking CFLAGSFORSHARED... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000010202if test ! "$LIBRARY" = "$LDLIBRARY"
10203then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +000010204 case $ac_sys_system in
10205 CYGWIN*)
10206 # Cygwin needs CCSHARED when building extension DLLs
10207 # but not when building the interpreter DLL.
10208 CFLAGSFORSHARED='';;
10209 *)
10210 CFLAGSFORSHARED='$(CCSHARED)'
10211 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000010212fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010213echo "$as_me:$LINENO: result: $CFLAGSFORSHARED" >&5
10214echo "${ECHO_T}$CFLAGSFORSHARED" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000010215
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010216# SHLIBS are libraries (except -lc and -lm) to link to the python shared
10217# library (with --enable-shared).
10218# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +000010219# symbols, this must be set to $(LIBS) (expanded by make). We do this even
10220# if it is not required, since it creates a dependency of the shared library
10221# to LIBS. This, in turn, means that applications linking the shared libpython
10222# don't need to link LIBS explicitly. The default should be only changed
10223# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010224
10225echo "$as_me:$LINENO: checking SHLIBS" >&5
10226echo $ECHO_N "checking SHLIBS... $ECHO_C" >&6
10227case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010228 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +000010229 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010230esac
10231echo "$as_me:$LINENO: result: $SHLIBS" >&5
10232echo "${ECHO_T}$SHLIBS" >&6
10233
10234
Guido van Rossum627b2d71993-12-24 10:39:16 +000010235# checks for libraries
Martin v. Löwis11437992002-04-12 09:54:03 +000010236
10237echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
10238echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
10239if test "${ac_cv_lib_dl_dlopen+set}" = set; then
10240 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010241else
Martin v. Löwis11437992002-04-12 09:54:03 +000010242 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010243LIBS="-ldl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010244cat >conftest.$ac_ext <<_ACEOF
10245#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010246/* confdefs.h. */
10247_ACEOF
10248cat confdefs.h >>conftest.$ac_ext
10249cat >>conftest.$ac_ext <<_ACEOF
10250/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010251
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010252/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010253#ifdef __cplusplus
10254extern "C"
10255#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010256/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010257 builtin and then its argument prototype would still apply. */
10258char dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010259int
10260main ()
10261{
10262dlopen ();
10263 ;
10264 return 0;
10265}
10266_ACEOF
10267rm -f conftest.$ac_objext conftest$ac_exeext
10268if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10269 (eval $ac_link) 2>&5
10270 ac_status=$?
10271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10272 (exit $ac_status); } &&
10273 { ac_try='test -s conftest$ac_exeext'
10274 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10275 (eval $ac_try) 2>&5
10276 ac_status=$?
10277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10278 (exit $ac_status); }; }; then
10279 ac_cv_lib_dl_dlopen=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010280else
Martin v. Löwis11437992002-04-12 09:54:03 +000010281 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010282sed 's/^/| /' conftest.$ac_ext >&5
10283
Martin v. Löwis11437992002-04-12 09:54:03 +000010284ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000010285fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010286rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10287LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000010288fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010289echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
10290echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
10291if test $ac_cv_lib_dl_dlopen = yes; then
10292 cat >>confdefs.h <<_ACEOF
10293#define HAVE_LIBDL 1
10294_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000010295
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010296 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +000010297
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010298fi
10299 # Dynamic linking for SunOS/Solaris and SYSV
Martin v. Löwis11437992002-04-12 09:54:03 +000010300
10301echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
10302echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
10303if test "${ac_cv_lib_dld_shl_load+set}" = set; then
10304 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010305else
Martin v. Löwis11437992002-04-12 09:54:03 +000010306 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010307LIBS="-ldld $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010308cat >conftest.$ac_ext <<_ACEOF
10309#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010310/* confdefs.h. */
10311_ACEOF
10312cat confdefs.h >>conftest.$ac_ext
10313cat >>conftest.$ac_ext <<_ACEOF
10314/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010315
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010316/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010317#ifdef __cplusplus
10318extern "C"
10319#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010320/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010321 builtin and then its argument prototype would still apply. */
10322char shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010323int
10324main ()
10325{
10326shl_load ();
10327 ;
10328 return 0;
10329}
10330_ACEOF
10331rm -f conftest.$ac_objext conftest$ac_exeext
10332if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10333 (eval $ac_link) 2>&5
10334 ac_status=$?
10335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10336 (exit $ac_status); } &&
10337 { ac_try='test -s conftest$ac_exeext'
10338 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10339 (eval $ac_try) 2>&5
10340 ac_status=$?
10341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10342 (exit $ac_status); }; }; then
10343 ac_cv_lib_dld_shl_load=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010344else
Martin v. Löwis11437992002-04-12 09:54:03 +000010345 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010346sed 's/^/| /' conftest.$ac_ext >&5
10347
Martin v. Löwis11437992002-04-12 09:54:03 +000010348ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000010349fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010350rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10351LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000010352fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010353echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
10354echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
10355if test $ac_cv_lib_dld_shl_load = yes; then
10356 cat >>confdefs.h <<_ACEOF
10357#define HAVE_LIBDLD 1
10358_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000010359
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010360 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010361
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010362fi
10363 # Dynamic linking for HP-UX
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010364echo "$as_me:$LINENO: checking for library containing sem_init" >&5
10365echo $ECHO_N "checking for library containing sem_init... $ECHO_C" >&6
10366if test "${ac_cv_search_sem_init+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010367 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010368else
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010369 ac_func_search_save_LIBS=$LIBS
10370ac_cv_search_sem_init=no
Martin v. Löwis11437992002-04-12 09:54:03 +000010371cat >conftest.$ac_ext <<_ACEOF
10372#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010373/* confdefs.h. */
10374_ACEOF
10375cat confdefs.h >>conftest.$ac_ext
10376cat >>conftest.$ac_ext <<_ACEOF
10377/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010378
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010379/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010380#ifdef __cplusplus
10381extern "C"
10382#endif
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010383/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010384 builtin and then its argument prototype would still apply. */
10385char sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010386int
10387main ()
10388{
10389sem_init ();
10390 ;
10391 return 0;
10392}
10393_ACEOF
10394rm -f conftest.$ac_objext conftest$ac_exeext
10395if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10396 (eval $ac_link) 2>&5
10397 ac_status=$?
10398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10399 (exit $ac_status); } &&
10400 { ac_try='test -s conftest$ac_exeext'
10401 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10402 (eval $ac_try) 2>&5
10403 ac_status=$?
10404 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10405 (exit $ac_status); }; }; then
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010406 ac_cv_search_sem_init="none required"
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010407else
Martin v. Löwis11437992002-04-12 09:54:03 +000010408 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010409sed 's/^/| /' conftest.$ac_ext >&5
10410
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010411fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010412rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010413if test "$ac_cv_search_sem_init" = no; then
Martin v. Löwisd3545ec2003-05-03 11:25:43 +000010414 for ac_lib in pthread rt posix4; do
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010415 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
10416 cat >conftest.$ac_ext <<_ACEOF
10417#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010418/* confdefs.h. */
10419_ACEOF
10420cat confdefs.h >>conftest.$ac_ext
10421cat >>conftest.$ac_ext <<_ACEOF
10422/* end confdefs.h. */
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010423
10424/* Override any gcc2 internal prototype to avoid an error. */
10425#ifdef __cplusplus
10426extern "C"
10427#endif
10428/* We use char because int might match the return type of a gcc2
10429 builtin and then its argument prototype would still apply. */
10430char sem_init ();
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010431int
10432main ()
10433{
10434sem_init ();
10435 ;
10436 return 0;
10437}
Martin v. Löwis11437992002-04-12 09:54:03 +000010438_ACEOF
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010439rm -f conftest.$ac_objext conftest$ac_exeext
10440if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10441 (eval $ac_link) 2>&5
10442 ac_status=$?
10443 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10444 (exit $ac_status); } &&
10445 { ac_try='test -s conftest$ac_exeext'
10446 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10447 (eval $ac_try) 2>&5
10448 ac_status=$?
10449 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10450 (exit $ac_status); }; }; then
10451 ac_cv_search_sem_init="-l$ac_lib"
10452break
10453else
10454 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010455sed 's/^/| /' conftest.$ac_ext >&5
10456
Martin v. Löwis82c19a72002-10-06 11:48:09 +000010457fi
10458rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10459 done
10460fi
10461LIBS=$ac_func_search_save_LIBS
10462fi
10463echo "$as_me:$LINENO: result: $ac_cv_search_sem_init" >&5
10464echo "${ECHO_T}$ac_cv_search_sem_init" >&6
10465if test "$ac_cv_search_sem_init" != no; then
10466 test "$ac_cv_search_sem_init" = "none required" || LIBS="$ac_cv_search_sem_init $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010467
Martin v. Löwis41933dd2002-03-21 15:10:58 +000010468fi
Martin v. Löwisd3545ec2003-05-03 11:25:43 +000010469 # 'Real Time' functions on Solaris
10470 # posix4 on Solaris 2.6
10471 # pthread (first!) on Linux
Martin v. Löwis19d17342003-06-14 21:03:05 +000010472# check if we need libintl for locale functions
10473echo "$as_me:$LINENO: checking for textdomain in -lintl" >&5
10474echo $ECHO_N "checking for textdomain in -lintl... $ECHO_C" >&6
10475if test "${ac_cv_lib_intl_textdomain+set}" = set; then
10476 echo $ECHO_N "(cached) $ECHO_C" >&6
10477else
10478 ac_check_lib_save_LIBS=$LIBS
10479LIBS="-lintl $LIBS"
10480cat >conftest.$ac_ext <<_ACEOF
10481#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010482/* confdefs.h. */
10483_ACEOF
10484cat confdefs.h >>conftest.$ac_ext
10485cat >>conftest.$ac_ext <<_ACEOF
10486/* end confdefs.h. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000010487
10488/* Override any gcc2 internal prototype to avoid an error. */
10489#ifdef __cplusplus
10490extern "C"
10491#endif
10492/* We use char because int might match the return type of a gcc2
10493 builtin and then its argument prototype would still apply. */
10494char textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000010495int
10496main ()
10497{
10498textdomain ();
10499 ;
10500 return 0;
10501}
10502_ACEOF
10503rm -f conftest.$ac_objext conftest$ac_exeext
10504if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10505 (eval $ac_link) 2>&5
10506 ac_status=$?
10507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10508 (exit $ac_status); } &&
10509 { ac_try='test -s conftest$ac_exeext'
10510 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10511 (eval $ac_try) 2>&5
10512 ac_status=$?
10513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10514 (exit $ac_status); }; }; then
10515 ac_cv_lib_intl_textdomain=yes
10516else
10517 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010518sed 's/^/| /' conftest.$ac_ext >&5
10519
Martin v. Löwis19d17342003-06-14 21:03:05 +000010520ac_cv_lib_intl_textdomain=no
10521fi
10522rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10523LIBS=$ac_check_lib_save_LIBS
10524fi
10525echo "$as_me:$LINENO: result: $ac_cv_lib_intl_textdomain" >&5
10526echo "${ECHO_T}$ac_cv_lib_intl_textdomain" >&6
10527if test $ac_cv_lib_intl_textdomain = yes; then
10528
10529cat >>confdefs.h <<\_ACEOF
10530#define WITH_LIBINTL 1
10531_ACEOF
10532
10533fi
10534
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010535
10536# checks for system dependent C++ extensions support
10537case "$ac_sys_system" in
Martin v. Löwis11437992002-04-12 09:54:03 +000010538 AIX*) echo "$as_me:$LINENO: checking for genuine AIX C++ extensions support" >&5
10539echo $ECHO_N "checking for genuine AIX C++ extensions support... $ECHO_C" >&6
10540 cat >conftest.$ac_ext <<_ACEOF
10541#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010542/* confdefs.h. */
10543_ACEOF
10544cat confdefs.h >>conftest.$ac_ext
10545cat >>conftest.$ac_ext <<_ACEOF
10546/* end confdefs.h. */
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010547#include "/usr/lpp/xlC/include/load.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010548int
10549main ()
10550{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010551loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +000010552 ;
10553 return 0;
10554}
10555_ACEOF
10556rm -f conftest.$ac_objext conftest$ac_exeext
10557if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10558 (eval $ac_link) 2>&5
10559 ac_status=$?
10560 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10561 (exit $ac_status); } &&
10562 { ac_try='test -s conftest$ac_exeext'
10563 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10564 (eval $ac_try) 2>&5
10565 ac_status=$?
10566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10567 (exit $ac_status); }; }; then
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010568
Martin v. Löwis11437992002-04-12 09:54:03 +000010569cat >>confdefs.h <<\_ACEOF
10570#define AIX_GENUINE_CPLUSPLUS 1
10571_ACEOF
10572
10573 echo "$as_me:$LINENO: result: yes" >&5
10574echo "${ECHO_T}yes" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010575else
Martin v. Löwis11437992002-04-12 09:54:03 +000010576 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010577sed 's/^/| /' conftest.$ac_ext >&5
10578
Martin v. Löwis11437992002-04-12 09:54:03 +000010579echo "$as_me:$LINENO: result: no" >&5
10580echo "${ECHO_T}no" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010581fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010582rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000010583 *) ;;
10584esac
10585
Guido van Rossum70c7f481998-03-26 18:44:10 +000010586# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
Martin v. Löwise1172582002-11-13 08:51:19 +000010587# However on SGI IRIX 4, these exist but are broken.
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010588# BeOS' sockets are stashed in libnet.
10589case "$ac_sys_system" in
10590IRIX*) ;;
Guido van Rossumb93a8621998-05-07 13:27:32 +000010591*)
Martin v. Löwis11437992002-04-12 09:54:03 +000010592echo "$as_me:$LINENO: checking for t_open in -lnsl" >&5
10593echo $ECHO_N "checking for t_open in -lnsl... $ECHO_C" >&6
10594if test "${ac_cv_lib_nsl_t_open+set}" = set; then
10595 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +000010596else
Martin v. Löwis11437992002-04-12 09:54:03 +000010597 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010598LIBS="-lnsl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010599cat >conftest.$ac_ext <<_ACEOF
10600#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010601/* confdefs.h. */
10602_ACEOF
10603cat confdefs.h >>conftest.$ac_ext
10604cat >>conftest.$ac_ext <<_ACEOF
10605/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010606
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010607/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010608#ifdef __cplusplus
10609extern "C"
10610#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010611/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010612 builtin and then its argument prototype would still apply. */
10613char t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010614int
10615main ()
10616{
10617t_open ();
10618 ;
10619 return 0;
10620}
10621_ACEOF
10622rm -f conftest.$ac_objext conftest$ac_exeext
10623if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10624 (eval $ac_link) 2>&5
10625 ac_status=$?
10626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10627 (exit $ac_status); } &&
10628 { ac_try='test -s conftest$ac_exeext'
10629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10630 (eval $ac_try) 2>&5
10631 ac_status=$?
10632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10633 (exit $ac_status); }; }; then
10634 ac_cv_lib_nsl_t_open=yes
Guido van Rossum79dddcb1995-01-12 12:25:42 +000010635else
Martin v. Löwis11437992002-04-12 09:54:03 +000010636 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010637sed 's/^/| /' conftest.$ac_ext >&5
10638
Martin v. Löwis11437992002-04-12 09:54:03 +000010639ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +000010640fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010641rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10642LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +000010643fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010644echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_t_open" >&5
10645echo "${ECHO_T}$ac_cv_lib_nsl_t_open" >&6
10646if test $ac_cv_lib_nsl_t_open = yes; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +000010647 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +000010648fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +000010649 # SVR4
Martin v. Löwis11437992002-04-12 09:54:03 +000010650echo "$as_me:$LINENO: checking for socket in -lsocket" >&5
10651echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6
10652if test "${ac_cv_lib_socket_socket+set}" = set; then
10653 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010654else
Martin v. Löwis11437992002-04-12 09:54:03 +000010655 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010656LIBS="-lsocket $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010657cat >conftest.$ac_ext <<_ACEOF
10658#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010659/* confdefs.h. */
10660_ACEOF
10661cat confdefs.h >>conftest.$ac_ext
10662cat >>conftest.$ac_ext <<_ACEOF
10663/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010664
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010665/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010666#ifdef __cplusplus
10667extern "C"
10668#endif
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010669/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010670 builtin and then its argument prototype would still apply. */
10671char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010672int
10673main ()
10674{
10675socket ();
10676 ;
10677 return 0;
10678}
10679_ACEOF
10680rm -f conftest.$ac_objext conftest$ac_exeext
10681if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10682 (eval $ac_link) 2>&5
10683 ac_status=$?
10684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10685 (exit $ac_status); } &&
10686 { ac_try='test -s conftest$ac_exeext'
10687 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10688 (eval $ac_try) 2>&5
10689 ac_status=$?
10690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10691 (exit $ac_status); }; }; then
10692 ac_cv_lib_socket_socket=yes
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010693else
Martin v. Löwis11437992002-04-12 09:54:03 +000010694 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010695sed 's/^/| /' conftest.$ac_ext >&5
10696
Martin v. Löwis11437992002-04-12 09:54:03 +000010697ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010698fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010699rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10700LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010701fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010702echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5
10703echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6
10704if test $ac_cv_lib_socket_socket = yes; then
Guido van Rossumad678af1998-10-02 14:42:15 +000010705 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +000010706fi
10707 # SVR4 sockets
Jeremy Hyltoncb25d5e2000-07-27 21:23:28 +000010708;;
10709esac
10710case "$ac_sys_system" in
10711BeOS*)
Martin v. Löwis11437992002-04-12 09:54:03 +000010712echo "$as_me:$LINENO: checking for socket in -lnet" >&5
10713echo $ECHO_N "checking for socket in -lnet... $ECHO_C" >&6
10714if test "${ac_cv_lib_net_socket+set}" = set; then
10715 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000010716else
Martin v. Löwis11437992002-04-12 09:54:03 +000010717 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +000010718LIBS="-lnet $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010719cat >conftest.$ac_ext <<_ACEOF
10720#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010721/* confdefs.h. */
10722_ACEOF
10723cat confdefs.h >>conftest.$ac_ext
10724cat >>conftest.$ac_ext <<_ACEOF
10725/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010726
Guido van Rossumad678af1998-10-02 14:42:15 +000010727/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010728#ifdef __cplusplus
10729extern "C"
10730#endif
Guido van Rossumad678af1998-10-02 14:42:15 +000010731/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010732 builtin and then its argument prototype would still apply. */
10733char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000010734int
10735main ()
10736{
10737socket ();
10738 ;
10739 return 0;
10740}
10741_ACEOF
10742rm -f conftest.$ac_objext conftest$ac_exeext
10743if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10744 (eval $ac_link) 2>&5
10745 ac_status=$?
10746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10747 (exit $ac_status); } &&
10748 { ac_try='test -s conftest$ac_exeext'
10749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10750 (eval $ac_try) 2>&5
10751 ac_status=$?
10752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10753 (exit $ac_status); }; }; then
10754 ac_cv_lib_net_socket=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000010755else
Martin v. Löwis11437992002-04-12 09:54:03 +000010756 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010757sed 's/^/| /' conftest.$ac_ext >&5
10758
Martin v. Löwis11437992002-04-12 09:54:03 +000010759ac_cv_lib_net_socket=no
Guido van Rossumad678af1998-10-02 14:42:15 +000010760fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010761rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10762LIBS=$ac_check_lib_save_LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +000010763fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010764echo "$as_me:$LINENO: result: $ac_cv_lib_net_socket" >&5
10765echo "${ECHO_T}$ac_cv_lib_net_socket" >&6
10766if test $ac_cv_lib_net_socket = yes; then
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010767 LIBS="-lnet $LIBS"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010768fi
10769 # BeOS
10770;;
10771esac
Guido van Rossum70c7f481998-03-26 18:44:10 +000010772
Martin v. Löwis11437992002-04-12 09:54:03 +000010773echo "$as_me:$LINENO: checking for --with-libs" >&5
10774echo $ECHO_N "checking for --with-libs... $ECHO_C" >&6
10775
Guido van Rossuma68acba1996-07-31 17:36:39 +000010776# Check whether --with-libs or --without-libs was given.
10777if test "${with_libs+set}" = set; then
10778 withval="$with_libs"
Martin v. Löwis11437992002-04-12 09:54:03 +000010779
10780echo "$as_me:$LINENO: result: $withval" >&5
10781echo "${ECHO_T}$withval" >&6
Guido van Rossuma68acba1996-07-31 17:36:39 +000010782LIBS="$withval $LIBS"
10783
10784else
Martin v. Löwis11437992002-04-12 09:54:03 +000010785 echo "$as_me:$LINENO: result: no" >&5
10786echo "${ECHO_T}no" >&6
10787fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000010788
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010789# Determine if signalmodule should be used.
Neil Schemenauerd32c2492001-01-24 17:25:28 +000010790
10791
Martin v. Löwis11437992002-04-12 09:54:03 +000010792echo "$as_me:$LINENO: checking for --with-signal-module" >&5
10793echo $ECHO_N "checking for --with-signal-module... $ECHO_C" >&6
10794
Neil Schemenauerd32c2492001-01-24 17:25:28 +000010795# Check whether --with-signal-module or --without-signal-module was given.
10796if test "${with_signal_module+set}" = set; then
10797 withval="$with_signal_module"
Neil Schemenauerd32c2492001-01-24 17:25:28 +000010798
Martin v. Löwis11437992002-04-12 09:54:03 +000010799fi;
Neil Schemenauerd32c2492001-01-24 17:25:28 +000010800
10801if test -z "$with_signal_module"
10802then with_signal_module="yes"
10803fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010804echo "$as_me:$LINENO: result: $with_signal_module" >&5
10805echo "${ECHO_T}$with_signal_module" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +000010806
10807if test "${with_signal_module}" = "yes"; then
10808 USE_SIGNAL_MODULE=""
10809 SIGNAL_OBJS=""
10810else
10811 USE_SIGNAL_MODULE="#"
10812 SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o"
10813fi
10814
Guido van Rossum3d15bd82001-01-10 18:53:48 +000010815# This is used to generate Setup.config
Guido van Rossum009f7871997-12-04 00:51:42 +000010816
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010817USE_THREAD_MODULE=""
Guido van Rossum009f7871997-12-04 00:51:42 +000010818
Martin v. Löwis11437992002-04-12 09:54:03 +000010819echo "$as_me:$LINENO: checking for --with-dec-threads" >&5
10820echo $ECHO_N "checking for --with-dec-threads... $ECHO_C" >&6
10821
Guido van Rossumec2f0731997-01-22 20:54:01 +000010822
10823# Check whether --with-dec-threads or --without-dec-threads was given.
10824if test "${with_dec_threads+set}" = set; then
10825 withval="$with_dec_threads"
Martin v. Löwis11437992002-04-12 09:54:03 +000010826
10827echo "$as_me:$LINENO: result: $withval" >&5
10828echo "${ECHO_T}$withval" >&6
Guido van Rossumec2f0731997-01-22 20:54:01 +000010829LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +000010830if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +000010831 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +000010832fi
Guido van Rossumec2f0731997-01-22 20:54:01 +000010833else
Martin v. Löwis11437992002-04-12 09:54:03 +000010834 echo "$as_me:$LINENO: result: no" >&5
10835echo "${ECHO_T}no" >&6
10836fi;
10837
10838# Templates for things AC_DEFINEd more than once.
10839# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +000010840
10841
Martin v. Löwis11437992002-04-12 09:54:03 +000010842
10843
10844
10845
10846
10847echo "$as_me:$LINENO: checking for --with-threads" >&5
10848echo $ECHO_N "checking for --with-threads... $ECHO_C" >&6
10849
Guido van Rossumec2f0731997-01-22 20:54:01 +000010850# Check whether --with-threads or --without-threads was given.
10851if test "${with_threads+set}" = set; then
10852 withval="$with_threads"
Guido van Rossumec2f0731997-01-22 20:54:01 +000010853
Martin v. Löwis11437992002-04-12 09:54:03 +000010854fi;
Guido van Rossumec2f0731997-01-22 20:54:01 +000010855
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010856# --with-thread is deprecated, but check for it anyway
Martin v. Löwis11437992002-04-12 09:54:03 +000010857
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010858# Check whether --with-thread or --without-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010859if test "${with_thread+set}" = set; then
10860 withval="$with_thread"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010861 with_threads=$with_thread
Martin v. Löwis11437992002-04-12 09:54:03 +000010862fi;
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010863
10864if test -z "$with_threads"
10865then with_threads="yes"
10866fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010867echo "$as_me:$LINENO: result: $with_threads" >&5
10868echo "${ECHO_T}$with_threads" >&6
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010869
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010870
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010871if test "$with_threads" = "no"
10872then
10873 USE_THREAD_MODULE="#"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010874elif test "$ac_cv_pthread_is_default" = yes
10875then
Martin v. Löwis11437992002-04-12 09:54:03 +000010876 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010877#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010878_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010879
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010880 # Defining _REENTRANT on system with POSIX threads should not hurt.
Martin v. Löwis11437992002-04-12 09:54:03 +000010881 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010882#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010883_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010884
10885 posix_threads=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000010886 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010887elif test "$ac_cv_kpthread" = "yes"
10888then
10889 CC="$CC -Kpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000010890 cat >>confdefs.h <<\_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000010891#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010892_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000010893
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010894 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010895 THREADOBJ="Python/thread.o"
Martin v. Löwis5f433f02003-05-05 05:05:30 +000010896elif test "$ac_cv_kthread" = "yes"
10897then
10898 CC="$CC -Kthread"
10899 cat >>confdefs.h <<\_ACEOF
10900#define WITH_THREAD 1
10901_ACEOF
10902
10903 posix_threads=yes
10904 THREADOBJ="Python/thread.o"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000010905elif test "$ac_cv_pthread" = "yes"
10906then
10907 CC="$CC -pthread"
10908 cat >>confdefs.h <<\_ACEOF
10909#define WITH_THREAD 1
10910_ACEOF
10911
10912 posix_threads=yes
10913 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010914else
10915 if test ! -z "$with_threads" -a -d "$with_threads"
10916 then LDFLAGS="$LDFLAGS -L$with_threads"
10917 fi
10918 if test ! -z "$withval" -a -d "$withval"
10919 then LDFLAGS="$LDFLAGS -L$withval"
10920 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010921
10922 # According to the POSIX spec, a pthreads implementation must
10923 # define _POSIX_THREADS in unistd.h. Some apparently don't (which ones?)
Martin v. Löwis11437992002-04-12 09:54:03 +000010924 echo "$as_me:$LINENO: checking for _POSIX_THREADS in unistd.h" >&5
10925echo $ECHO_N "checking for _POSIX_THREADS in unistd.h... $ECHO_C" >&6
10926 cat >conftest.$ac_ext <<_ACEOF
10927#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010928/* confdefs.h. */
10929_ACEOF
10930cat confdefs.h >>conftest.$ac_ext
10931cat >>conftest.$ac_ext <<_ACEOF
10932/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +000010933
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010934#include <unistd.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +000010935#ifdef _POSIX_THREADS
10936yes
10937#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000010938
10939_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010940if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000010941 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010942 unistd_defines_pthreads=yes
10943else
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010944 unistd_defines_pthreads=no
10945fi
10946rm -f conftest*
10947
Martin v. Löwis11437992002-04-12 09:54:03 +000010948 echo "$as_me:$LINENO: result: $unistd_defines_pthreads" >&5
10949echo "${ECHO_T}$unistd_defines_pthreads" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010950
Martin v. Löwis11437992002-04-12 09:54:03 +000010951 cat >>confdefs.h <<\_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000010952#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010953_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000010954
Martin v. Löwis11437992002-04-12 09:54:03 +000010955 if test "${ac_cv_header_cthreads_h+set}" = set; then
10956 echo "$as_me:$LINENO: checking for cthreads.h" >&5
10957echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
10958if test "${ac_cv_header_cthreads_h+set}" = set; then
10959 echo $ECHO_N "(cached) $ECHO_C" >&6
10960fi
10961echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
10962echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010963else
Martin v. Löwis11437992002-04-12 09:54:03 +000010964 # Is the header compilable?
10965echo "$as_me:$LINENO: checking cthreads.h usability" >&5
10966echo $ECHO_N "checking cthreads.h usability... $ECHO_C" >&6
10967cat >conftest.$ac_ext <<_ACEOF
10968#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000010969/* confdefs.h. */
10970_ACEOF
10971cat confdefs.h >>conftest.$ac_ext
10972cat >>conftest.$ac_ext <<_ACEOF
10973/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010974$ac_includes_default
10975#include <cthreads.h>
10976_ACEOF
10977rm -f conftest.$ac_objext
10978if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10979 (eval $ac_compile) 2>&5
10980 ac_status=$?
10981 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10982 (exit $ac_status); } &&
10983 { ac_try='test -s conftest.$ac_objext'
10984 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10985 (eval $ac_try) 2>&5
10986 ac_status=$?
10987 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10988 (exit $ac_status); }; }; then
10989 ac_header_compiler=yes
10990else
10991 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000010992sed 's/^/| /' conftest.$ac_ext >&5
10993
Martin v. Löwis11437992002-04-12 09:54:03 +000010994ac_header_compiler=no
10995fi
10996rm -f conftest.$ac_objext conftest.$ac_ext
10997echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10998echo "${ECHO_T}$ac_header_compiler" >&6
10999
11000# Is the header present?
11001echo "$as_me:$LINENO: checking cthreads.h presence" >&5
11002echo $ECHO_N "checking cthreads.h presence... $ECHO_C" >&6
11003cat >conftest.$ac_ext <<_ACEOF
11004#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011005/* confdefs.h. */
11006_ACEOF
11007cat confdefs.h >>conftest.$ac_ext
11008cat >>conftest.$ac_ext <<_ACEOF
11009/* end confdefs.h. */
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011010#include <cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011011_ACEOF
11012if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11013 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11014 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +000011015 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000011016 rm -f conftest.er1
11017 cat conftest.err >&5
11018 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11019 (exit $ac_status); } >/dev/null; then
11020 if test -s conftest.err; then
11021 ac_cpp_err=$ac_c_preproc_warn_flag
11022 else
11023 ac_cpp_err=
11024 fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011025else
Martin v. Löwis11437992002-04-12 09:54:03 +000011026 ac_cpp_err=yes
11027fi
11028if test -z "$ac_cpp_err"; then
11029 ac_header_preproc=yes
11030else
11031 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011032sed 's/^/| /' conftest.$ac_ext >&5
11033
Martin v. Löwis11437992002-04-12 09:54:03 +000011034 ac_header_preproc=no
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011035fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011036rm -f conftest.err conftest.$ac_ext
11037echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11038echo "${ECHO_T}$ac_header_preproc" >&6
11039
11040# So? What about this header?
11041case $ac_header_compiler:$ac_header_preproc in
11042 yes:no )
11043 { echo "$as_me:$LINENO: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
11044echo "$as_me: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11045 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011046echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;}
11047 (
11048 cat <<\_ASBOX
11049## ------------------------------------ ##
11050## Report this to bug-autoconf@gnu.org. ##
11051## ------------------------------------ ##
11052_ASBOX
11053 ) |
11054 sed "s/^/$as_me: WARNING: /" >&2
11055 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011056 no:yes )
11057 { echo "$as_me:$LINENO: WARNING: cthreads.h: present but cannot be compiled" >&5
11058echo "$as_me: WARNING: cthreads.h: present but cannot be compiled" >&2;}
11059 { echo "$as_me:$LINENO: WARNING: cthreads.h: check for missing prerequisite headers?" >&5
11060echo "$as_me: WARNING: cthreads.h: check for missing prerequisite headers?" >&2;}
11061 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011062echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;}
11063 (
11064 cat <<\_ASBOX
11065## ------------------------------------ ##
11066## Report this to bug-autoconf@gnu.org. ##
11067## ------------------------------------ ##
11068_ASBOX
11069 ) |
11070 sed "s/^/$as_me: WARNING: /" >&2
11071 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011072esac
11073echo "$as_me:$LINENO: checking for cthreads.h" >&5
11074echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
11075if test "${ac_cv_header_cthreads_h+set}" = set; then
11076 echo $ECHO_N "(cached) $ECHO_C" >&6
11077else
11078 ac_cv_header_cthreads_h=$ac_header_preproc
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011079fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011080echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
11081echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
11082
11083fi
11084if test $ac_cv_header_cthreads_h = yes; then
11085 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011086#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011087_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011088
Martin v. Löwis11437992002-04-12 09:54:03 +000011089 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011090#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011091_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011092
Martin v. Löwis11437992002-04-12 09:54:03 +000011093
11094cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011095#define HURD_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011096_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011097
11098 LIBS="$LIBS -lthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011099 THREADOBJ="Python/thread.o"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011100else
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011101
Martin v. Löwis11437992002-04-12 09:54:03 +000011102 if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
11103 echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
11104echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
11105if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
11106 echo $ECHO_N "(cached) $ECHO_C" >&6
11107fi
11108echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
11109echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011110else
Martin v. Löwis11437992002-04-12 09:54:03 +000011111 # Is the header compilable?
11112echo "$as_me:$LINENO: checking mach/cthreads.h usability" >&5
11113echo $ECHO_N "checking mach/cthreads.h usability... $ECHO_C" >&6
11114cat >conftest.$ac_ext <<_ACEOF
11115#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011116/* confdefs.h. */
11117_ACEOF
11118cat confdefs.h >>conftest.$ac_ext
11119cat >>conftest.$ac_ext <<_ACEOF
11120/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011121$ac_includes_default
11122#include <mach/cthreads.h>
11123_ACEOF
11124rm -f conftest.$ac_objext
11125if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11126 (eval $ac_compile) 2>&5
11127 ac_status=$?
11128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11129 (exit $ac_status); } &&
11130 { ac_try='test -s conftest.$ac_objext'
11131 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11132 (eval $ac_try) 2>&5
11133 ac_status=$?
11134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11135 (exit $ac_status); }; }; then
11136 ac_header_compiler=yes
11137else
11138 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011139sed 's/^/| /' conftest.$ac_ext >&5
11140
Martin v. Löwis11437992002-04-12 09:54:03 +000011141ac_header_compiler=no
11142fi
11143rm -f conftest.$ac_objext conftest.$ac_ext
11144echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11145echo "${ECHO_T}$ac_header_compiler" >&6
11146
11147# Is the header present?
11148echo "$as_me:$LINENO: checking mach/cthreads.h presence" >&5
11149echo $ECHO_N "checking mach/cthreads.h presence... $ECHO_C" >&6
11150cat >conftest.$ac_ext <<_ACEOF
11151#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011152/* confdefs.h. */
11153_ACEOF
11154cat confdefs.h >>conftest.$ac_ext
11155cat >>conftest.$ac_ext <<_ACEOF
11156/* end confdefs.h. */
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011157#include <mach/cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011158_ACEOF
11159if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11160 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11161 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +000011162 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000011163 rm -f conftest.er1
11164 cat conftest.err >&5
11165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11166 (exit $ac_status); } >/dev/null; then
11167 if test -s conftest.err; then
11168 ac_cpp_err=$ac_c_preproc_warn_flag
11169 else
11170 ac_cpp_err=
11171 fi
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011172else
Martin v. Löwis11437992002-04-12 09:54:03 +000011173 ac_cpp_err=yes
11174fi
11175if test -z "$ac_cpp_err"; then
11176 ac_header_preproc=yes
11177else
11178 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011179sed 's/^/| /' conftest.$ac_ext >&5
11180
Martin v. Löwis11437992002-04-12 09:54:03 +000011181 ac_header_preproc=no
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011182fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011183rm -f conftest.err conftest.$ac_ext
11184echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11185echo "${ECHO_T}$ac_header_preproc" >&6
11186
11187# So? What about this header?
11188case $ac_header_compiler:$ac_header_preproc in
11189 yes:no )
11190 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
11191echo "$as_me: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11192 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011193echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;}
11194 (
11195 cat <<\_ASBOX
11196## ------------------------------------ ##
11197## Report this to bug-autoconf@gnu.org. ##
11198## ------------------------------------ ##
11199_ASBOX
11200 ) |
11201 sed "s/^/$as_me: WARNING: /" >&2
11202 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011203 no:yes )
11204 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: present but cannot be compiled" >&5
11205echo "$as_me: WARNING: mach/cthreads.h: present but cannot be compiled" >&2;}
11206 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&5
11207echo "$as_me: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&2;}
11208 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011209echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;}
11210 (
11211 cat <<\_ASBOX
11212## ------------------------------------ ##
11213## Report this to bug-autoconf@gnu.org. ##
11214## ------------------------------------ ##
11215_ASBOX
11216 ) |
11217 sed "s/^/$as_me: WARNING: /" >&2
11218 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011219esac
11220echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
11221echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
11222if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
11223 echo $ECHO_N "(cached) $ECHO_C" >&6
11224else
11225 ac_cv_header_mach_cthreads_h=$ac_header_preproc
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011226fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011227echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
11228echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
11229
11230fi
11231if test $ac_cv_header_mach_cthreads_h = yes; then
11232 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011233#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011234_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011235
Martin v. Löwis11437992002-04-12 09:54:03 +000011236 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011237#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011238_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011239
Martin v. Löwis11437992002-04-12 09:54:03 +000011240
11241cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011242#define MACH_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011243_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011244
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011245 THREADOBJ="Python/thread.o"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011246else
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011247
Martin v. Löwis11437992002-04-12 09:54:03 +000011248 echo "$as_me:$LINENO: checking for --with-pth" >&5
11249echo $ECHO_N "checking for --with-pth... $ECHO_C" >&6
11250
11251# Check whether --with-pth or --without-pth was given.
Guido van Rossum9e8181b2000-09-19 00:46:46 +000011252if test "${with_pth+set}" = set; then
11253 withval="$with_pth"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011254 echo "$as_me:$LINENO: result: $withval" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011255echo "${ECHO_T}$withval" >&6
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011256 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000011257#define WITH_THREAD 1
11258_ACEOF
11259
11260
11261cat >>confdefs.h <<\_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000011262#define HAVE_PTH 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011263_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000011264
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011265 LIBS="-lpth $LIBS"
11266 THREADOBJ="Python/thread.o"
Guido van Rossum9e8181b2000-09-19 00:46:46 +000011267else
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011268 echo "$as_me:$LINENO: result: no" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011269echo "${ECHO_T}no" >&6
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011270
11271 # Just looking for pthread_create in libpthread is not enough:
11272 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
11273 # So we really have to include pthread.h, and then link.
11274 _libs=$LIBS
11275 LIBS="$LIBS -lpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000011276 echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
11277echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6
11278 cat >conftest.$ac_ext <<_ACEOF
11279#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011280/* confdefs.h. */
11281_ACEOF
11282cat confdefs.h >>conftest.$ac_ext
11283cat >>conftest.$ac_ext <<_ACEOF
11284/* end confdefs.h. */
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011285#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000011286
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011287void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000011288int
11289main ()
11290{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011291
11292pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000011293 ;
11294 return 0;
11295}
11296_ACEOF
11297rm -f conftest.$ac_objext conftest$ac_exeext
11298if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11299 (eval $ac_link) 2>&5
11300 ac_status=$?
11301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11302 (exit $ac_status); } &&
11303 { ac_try='test -s conftest$ac_exeext'
11304 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11305 (eval $ac_try) 2>&5
11306 ac_status=$?
11307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11308 (exit $ac_status); }; }; then
11309
11310 echo "$as_me:$LINENO: result: yes" >&5
11311echo "${ECHO_T}yes" >&6
11312 cat >>confdefs.h <<\_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000011313#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011314_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000011315
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011316 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011317 THREADOBJ="Python/thread.o"
Guido van Rossum02a1c402000-02-25 19:26:31 +000011318else
Martin v. Löwis11437992002-04-12 09:54:03 +000011319 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011320sed 's/^/| /' conftest.$ac_ext >&5
11321
Martin v. Löwis11437992002-04-12 09:54:03 +000011322
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000011323 LIBS=$_libs
Martin v. Löwis11437992002-04-12 09:54:03 +000011324 echo "$as_me:$LINENO: checking for pthread_detach" >&5
11325echo $ECHO_N "checking for pthread_detach... $ECHO_C" >&6
11326if test "${ac_cv_func_pthread_detach+set}" = set; then
11327 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000011328else
Martin v. Löwis11437992002-04-12 09:54:03 +000011329 cat >conftest.$ac_ext <<_ACEOF
11330#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011331/* confdefs.h. */
11332_ACEOF
11333cat confdefs.h >>conftest.$ac_ext
11334cat >>conftest.$ac_ext <<_ACEOF
11335/* end confdefs.h. */
Guido van Rossumad678af1998-10-02 14:42:15 +000011336/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000011337 which can conflict with char pthread_detach (); below.
11338 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11339 <limits.h> exists even on freestanding compilers. */
11340#ifdef __STDC__
11341# include <limits.h>
11342#else
11343# include <assert.h>
11344#endif
Guido van Rossumad678af1998-10-02 14:42:15 +000011345/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011346#ifdef __cplusplus
11347extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011348{
Martin v. Löwis11437992002-04-12 09:54:03 +000011349#endif
Guido van Rossumad678af1998-10-02 14:42:15 +000011350/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011351 builtin and then its argument prototype would still apply. */
11352char pthread_detach ();
Guido van Rossumad678af1998-10-02 14:42:15 +000011353/* The GNU C library defines this for functions which it implements
11354 to always fail with ENOSYS. Some functions are actually named
11355 something starting with __ and the normal name is an alias. */
Guido van Rossumea516321998-12-17 18:08:55 +000011356#if defined (__stub_pthread_detach) || defined (__stub___pthread_detach)
Guido van Rossumad678af1998-10-02 14:42:15 +000011357choke me
11358#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000011359char (*f) () = pthread_detach;
11360#endif
11361#ifdef __cplusplus
11362}
Guido van Rossumad678af1998-10-02 14:42:15 +000011363#endif
11364
Skip Montanarod8d39a02003-07-10 20:44:10 +000011365int
11366main ()
11367{
11368return f != pthread_detach;
Martin v. Löwis11437992002-04-12 09:54:03 +000011369 ;
11370 return 0;
11371}
11372_ACEOF
11373rm -f conftest.$ac_objext conftest$ac_exeext
11374if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11375 (eval $ac_link) 2>&5
11376 ac_status=$?
11377 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11378 (exit $ac_status); } &&
11379 { ac_try='test -s conftest$ac_exeext'
11380 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11381 (eval $ac_try) 2>&5
11382 ac_status=$?
11383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11384 (exit $ac_status); }; }; then
11385 ac_cv_func_pthread_detach=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000011386else
Martin v. Löwis11437992002-04-12 09:54:03 +000011387 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011388sed 's/^/| /' conftest.$ac_ext >&5
11389
Martin v. Löwis11437992002-04-12 09:54:03 +000011390ac_cv_func_pthread_detach=no
Guido van Rossumad678af1998-10-02 14:42:15 +000011391fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011392rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumad678af1998-10-02 14:42:15 +000011393fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011394echo "$as_me:$LINENO: result: $ac_cv_func_pthread_detach" >&5
11395echo "${ECHO_T}$ac_cv_func_pthread_detach" >&6
11396if test $ac_cv_func_pthread_detach = yes; then
11397 cat >>confdefs.h <<\_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000011398#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011399_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000011400
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011401 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011402 THREADOBJ="Python/thread.o"
Guido van Rossumad678af1998-10-02 14:42:15 +000011403else
Guido van Rossumad678af1998-10-02 14:42:15 +000011404
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011405 if test "${ac_cv_header_atheos_threads_h+set}" = set; then
11406 echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
11407echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
11408if test "${ac_cv_header_atheos_threads_h+set}" = set; then
11409 echo $ECHO_N "(cached) $ECHO_C" >&6
11410fi
11411echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
11412echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
11413else
11414 # Is the header compilable?
11415echo "$as_me:$LINENO: checking atheos/threads.h usability" >&5
11416echo $ECHO_N "checking atheos/threads.h usability... $ECHO_C" >&6
11417cat >conftest.$ac_ext <<_ACEOF
11418#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011419/* confdefs.h. */
11420_ACEOF
11421cat confdefs.h >>conftest.$ac_ext
11422cat >>conftest.$ac_ext <<_ACEOF
11423/* end confdefs.h. */
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011424$ac_includes_default
11425#include <atheos/threads.h>
11426_ACEOF
11427rm -f conftest.$ac_objext
11428if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11429 (eval $ac_compile) 2>&5
11430 ac_status=$?
11431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11432 (exit $ac_status); } &&
11433 { ac_try='test -s conftest.$ac_objext'
11434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11435 (eval $ac_try) 2>&5
11436 ac_status=$?
11437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11438 (exit $ac_status); }; }; then
11439 ac_header_compiler=yes
11440else
11441 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011442sed 's/^/| /' conftest.$ac_ext >&5
11443
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011444ac_header_compiler=no
11445fi
11446rm -f conftest.$ac_objext conftest.$ac_ext
11447echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11448echo "${ECHO_T}$ac_header_compiler" >&6
11449
11450# Is the header present?
11451echo "$as_me:$LINENO: checking atheos/threads.h presence" >&5
11452echo $ECHO_N "checking atheos/threads.h presence... $ECHO_C" >&6
11453cat >conftest.$ac_ext <<_ACEOF
11454#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011455/* confdefs.h. */
11456_ACEOF
11457cat confdefs.h >>conftest.$ac_ext
11458cat >>conftest.$ac_ext <<_ACEOF
11459/* end confdefs.h. */
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011460#include <atheos/threads.h>
11461_ACEOF
11462if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11463 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11464 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +000011465 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011466 rm -f conftest.er1
11467 cat conftest.err >&5
11468 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11469 (exit $ac_status); } >/dev/null; then
11470 if test -s conftest.err; then
11471 ac_cpp_err=$ac_c_preproc_warn_flag
11472 else
11473 ac_cpp_err=
11474 fi
11475else
11476 ac_cpp_err=yes
11477fi
11478if test -z "$ac_cpp_err"; then
11479 ac_header_preproc=yes
11480else
11481 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011482sed 's/^/| /' conftest.$ac_ext >&5
11483
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011484 ac_header_preproc=no
11485fi
11486rm -f conftest.err conftest.$ac_ext
11487echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11488echo "${ECHO_T}$ac_header_preproc" >&6
11489
11490# So? What about this header?
11491case $ac_header_compiler:$ac_header_preproc in
11492 yes:no )
11493 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&5
11494echo "$as_me: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11495 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011496echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;}
11497 (
11498 cat <<\_ASBOX
11499## ------------------------------------ ##
11500## Report this to bug-autoconf@gnu.org. ##
11501## ------------------------------------ ##
11502_ASBOX
11503 ) |
11504 sed "s/^/$as_me: WARNING: /" >&2
11505 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011506 no:yes )
11507 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: present but cannot be compiled" >&5
11508echo "$as_me: WARNING: atheos/threads.h: present but cannot be compiled" >&2;}
11509 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&5
11510echo "$as_me: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&2;}
11511 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011512echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;}
11513 (
11514 cat <<\_ASBOX
11515## ------------------------------------ ##
11516## Report this to bug-autoconf@gnu.org. ##
11517## ------------------------------------ ##
11518_ASBOX
11519 ) |
11520 sed "s/^/$as_me: WARNING: /" >&2
11521 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011522esac
11523echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
11524echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
11525if test "${ac_cv_header_atheos_threads_h+set}" = set; then
11526 echo $ECHO_N "(cached) $ECHO_C" >&6
11527else
11528 ac_cv_header_atheos_threads_h=$ac_header_preproc
11529fi
11530echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
11531echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
11532
11533fi
11534if test $ac_cv_header_atheos_threads_h = yes; then
11535 cat >>confdefs.h <<\_ACEOF
11536#define WITH_THREAD 1
11537_ACEOF
11538
11539
11540cat >>confdefs.h <<\_ACEOF
11541#define ATHEOS_THREADS 1
11542_ACEOF
11543
11544 THREADOBJ="Python/thread.o"
11545else
11546
Martin v. Löwis11437992002-04-12 09:54:03 +000011547 if test "${ac_cv_header_kernel_OS_h+set}" = set; then
11548 echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
11549echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
11550if test "${ac_cv_header_kernel_OS_h+set}" = set; then
11551 echo $ECHO_N "(cached) $ECHO_C" >&6
11552fi
11553echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
11554echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011555else
Martin v. Löwis11437992002-04-12 09:54:03 +000011556 # Is the header compilable?
11557echo "$as_me:$LINENO: checking kernel/OS.h usability" >&5
11558echo $ECHO_N "checking kernel/OS.h usability... $ECHO_C" >&6
11559cat >conftest.$ac_ext <<_ACEOF
11560#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011561/* confdefs.h. */
11562_ACEOF
11563cat confdefs.h >>conftest.$ac_ext
11564cat >>conftest.$ac_ext <<_ACEOF
11565/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011566$ac_includes_default
11567#include <kernel/OS.h>
11568_ACEOF
11569rm -f conftest.$ac_objext
11570if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11571 (eval $ac_compile) 2>&5
11572 ac_status=$?
11573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11574 (exit $ac_status); } &&
11575 { ac_try='test -s conftest.$ac_objext'
11576 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11577 (eval $ac_try) 2>&5
11578 ac_status=$?
11579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11580 (exit $ac_status); }; }; then
11581 ac_header_compiler=yes
11582else
11583 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011584sed 's/^/| /' conftest.$ac_ext >&5
11585
Martin v. Löwis11437992002-04-12 09:54:03 +000011586ac_header_compiler=no
11587fi
11588rm -f conftest.$ac_objext conftest.$ac_ext
11589echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11590echo "${ECHO_T}$ac_header_compiler" >&6
11591
11592# Is the header present?
11593echo "$as_me:$LINENO: checking kernel/OS.h presence" >&5
11594echo $ECHO_N "checking kernel/OS.h presence... $ECHO_C" >&6
11595cat >conftest.$ac_ext <<_ACEOF
11596#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011597/* confdefs.h. */
11598_ACEOF
11599cat confdefs.h >>conftest.$ac_ext
11600cat >>conftest.$ac_ext <<_ACEOF
11601/* end confdefs.h. */
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011602#include <kernel/OS.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011603_ACEOF
11604if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
11605 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
11606 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +000011607 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000011608 rm -f conftest.er1
11609 cat conftest.err >&5
11610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11611 (exit $ac_status); } >/dev/null; then
11612 if test -s conftest.err; then
11613 ac_cpp_err=$ac_c_preproc_warn_flag
11614 else
11615 ac_cpp_err=
11616 fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011617else
Martin v. Löwis11437992002-04-12 09:54:03 +000011618 ac_cpp_err=yes
11619fi
11620if test -z "$ac_cpp_err"; then
11621 ac_header_preproc=yes
11622else
11623 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011624sed 's/^/| /' conftest.$ac_ext >&5
11625
Martin v. Löwis11437992002-04-12 09:54:03 +000011626 ac_header_preproc=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011627fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011628rm -f conftest.err conftest.$ac_ext
11629echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11630echo "${ECHO_T}$ac_header_preproc" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011631
Martin v. Löwis11437992002-04-12 09:54:03 +000011632# So? What about this header?
11633case $ac_header_compiler:$ac_header_preproc in
11634 yes:no )
11635 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&5
11636echo "$as_me: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11637 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011638echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;}
11639 (
11640 cat <<\_ASBOX
11641## ------------------------------------ ##
11642## Report this to bug-autoconf@gnu.org. ##
11643## ------------------------------------ ##
11644_ASBOX
11645 ) |
11646 sed "s/^/$as_me: WARNING: /" >&2
11647 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011648 no:yes )
11649 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: present but cannot be compiled" >&5
11650echo "$as_me: WARNING: kernel/OS.h: present but cannot be compiled" >&2;}
11651 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&5
11652echo "$as_me: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&2;}
11653 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011654echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;}
11655 (
11656 cat <<\_ASBOX
11657## ------------------------------------ ##
11658## Report this to bug-autoconf@gnu.org. ##
11659## ------------------------------------ ##
11660_ASBOX
11661 ) |
11662 sed "s/^/$as_me: WARNING: /" >&2
11663 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011664esac
11665echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
11666echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
11667if test "${ac_cv_header_kernel_OS_h+set}" = set; then
11668 echo $ECHO_N "(cached) $ECHO_C" >&6
11669else
11670 ac_cv_header_kernel_OS_h=$ac_header_preproc
11671fi
11672echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
11673echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
11674
11675fi
11676if test $ac_cv_header_kernel_OS_h = yes; then
11677 cat >>confdefs.h <<\_ACEOF
11678#define WITH_THREAD 1
11679_ACEOF
11680
11681
11682cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011683#define BEOS_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011684_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011685
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011686 THREADOBJ="Python/thread.o"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011687else
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011688
Martin v. Löwis11437992002-04-12 09:54:03 +000011689 echo "$as_me:$LINENO: checking for pthread_create in -lpthreads" >&5
11690echo $ECHO_N "checking for pthread_create in -lpthreads... $ECHO_C" >&6
11691if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then
11692 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011693else
Martin v. Löwis11437992002-04-12 09:54:03 +000011694 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011695LIBS="-lpthreads $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011696cat >conftest.$ac_ext <<_ACEOF
11697#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011698/* confdefs.h. */
11699_ACEOF
11700cat confdefs.h >>conftest.$ac_ext
11701cat >>conftest.$ac_ext <<_ACEOF
11702/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011703
Greg Steinadf63d62000-07-05 10:38:09 +000011704/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011705#ifdef __cplusplus
11706extern "C"
11707#endif
Greg Steinadf63d62000-07-05 10:38:09 +000011708/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011709 builtin and then its argument prototype would still apply. */
11710char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011711int
11712main ()
11713{
11714pthread_create ();
11715 ;
11716 return 0;
11717}
11718_ACEOF
11719rm -f conftest.$ac_objext conftest$ac_exeext
11720if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11721 (eval $ac_link) 2>&5
11722 ac_status=$?
11723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11724 (exit $ac_status); } &&
11725 { ac_try='test -s conftest$ac_exeext'
11726 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11727 (eval $ac_try) 2>&5
11728 ac_status=$?
11729 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11730 (exit $ac_status); }; }; then
11731 ac_cv_lib_pthreads_pthread_create=yes
Greg Steinadf63d62000-07-05 10:38:09 +000011732else
Martin v. Löwis11437992002-04-12 09:54:03 +000011733 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011734sed 's/^/| /' conftest.$ac_ext >&5
11735
Martin v. Löwis11437992002-04-12 09:54:03 +000011736ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000011737fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011738rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11739LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000011740fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011741echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_create" >&5
11742echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_create" >&6
11743if test $ac_cv_lib_pthreads_pthread_create = yes; then
11744 cat >>confdefs.h <<\_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000011745#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011746_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000011747
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011748 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000011749 LIBS="$LIBS -lpthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011750 THREADOBJ="Python/thread.o"
Greg Steinadf63d62000-07-05 10:38:09 +000011751else
Greg Steinadf63d62000-07-05 10:38:09 +000011752
Martin v. Löwis11437992002-04-12 09:54:03 +000011753 echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
11754echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6
11755if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
11756 echo $ECHO_N "(cached) $ECHO_C" >&6
Greg Steinadf63d62000-07-05 10:38:09 +000011757else
Martin v. Löwis11437992002-04-12 09:54:03 +000011758 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000011759LIBS="-lc_r $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011760cat >conftest.$ac_ext <<_ACEOF
11761#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011762/* confdefs.h. */
11763_ACEOF
11764cat confdefs.h >>conftest.$ac_ext
11765cat >>conftest.$ac_ext <<_ACEOF
11766/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011767
Guido van Rossum49545951997-12-02 19:28:29 +000011768/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011769#ifdef __cplusplus
11770extern "C"
11771#endif
Guido van Rossum49545951997-12-02 19:28:29 +000011772/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011773 builtin and then its argument prototype would still apply. */
11774char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011775int
11776main ()
11777{
11778pthread_create ();
11779 ;
11780 return 0;
11781}
11782_ACEOF
11783rm -f conftest.$ac_objext conftest$ac_exeext
11784if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11785 (eval $ac_link) 2>&5
11786 ac_status=$?
11787 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11788 (exit $ac_status); } &&
11789 { ac_try='test -s conftest$ac_exeext'
11790 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11791 (eval $ac_try) 2>&5
11792 ac_status=$?
11793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11794 (exit $ac_status); }; }; then
11795 ac_cv_lib_c_r_pthread_create=yes
Guido van Rossum49545951997-12-02 19:28:29 +000011796else
Martin v. Löwis11437992002-04-12 09:54:03 +000011797 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011798sed 's/^/| /' conftest.$ac_ext >&5
11799
Martin v. Löwis11437992002-04-12 09:54:03 +000011800ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000011801fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011802rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11803LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000011804fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011805echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
11806echo "${ECHO_T}$ac_cv_lib_c_r_pthread_create" >&6
11807if test $ac_cv_lib_c_r_pthread_create = yes; then
11808 cat >>confdefs.h <<\_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000011809#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011810_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000011811
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011812 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000011813 LIBS="$LIBS -lc_r"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011814 THREADOBJ="Python/thread.o"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011815else
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011816
Martin v. Löwis11437992002-04-12 09:54:03 +000011817 echo "$as_me:$LINENO: checking for __d6_pthread_create in -lthread" >&5
11818echo $ECHO_N "checking for __d6_pthread_create in -lthread... $ECHO_C" >&6
11819if test "${ac_cv_lib_thread___d6_pthread_create+set}" = set; then
11820 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011821else
Martin v. Löwis11437992002-04-12 09:54:03 +000011822 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000011823LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011824cat >conftest.$ac_ext <<_ACEOF
11825#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011826/* confdefs.h. */
11827_ACEOF
11828cat confdefs.h >>conftest.$ac_ext
11829cat >>conftest.$ac_ext <<_ACEOF
11830/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011831
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011832/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011833#ifdef __cplusplus
11834extern "C"
11835#endif
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011836/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011837 builtin and then its argument prototype would still apply. */
11838char __d6_pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011839int
11840main ()
11841{
11842__d6_pthread_create ();
11843 ;
11844 return 0;
11845}
11846_ACEOF
11847rm -f conftest.$ac_objext conftest$ac_exeext
11848if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11849 (eval $ac_link) 2>&5
11850 ac_status=$?
11851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11852 (exit $ac_status); } &&
11853 { ac_try='test -s conftest$ac_exeext'
11854 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11855 (eval $ac_try) 2>&5
11856 ac_status=$?
11857 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11858 (exit $ac_status); }; }; then
11859 ac_cv_lib_thread___d6_pthread_create=yes
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011860else
Martin v. Löwis11437992002-04-12 09:54:03 +000011861 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011862sed 's/^/| /' conftest.$ac_ext >&5
11863
Martin v. Löwis11437992002-04-12 09:54:03 +000011864ac_cv_lib_thread___d6_pthread_create=no
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011865fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011866rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11867LIBS=$ac_check_lib_save_LIBS
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011868fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011869echo "$as_me:$LINENO: result: $ac_cv_lib_thread___d6_pthread_create" >&5
11870echo "${ECHO_T}$ac_cv_lib_thread___d6_pthread_create" >&6
11871if test $ac_cv_lib_thread___d6_pthread_create = yes; then
11872 cat >>confdefs.h <<\_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011873#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011874_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011875
Martin v. Löwis779ffc02002-12-02 22:17:01 +000011876 echo Systems with __d6_pthread_create are not supported anymore.
11877 echo See README
11878 exit 1
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011879 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000011880 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011881 THREADOBJ="Python/thread.o"
Guido van Rossum49545951997-12-02 19:28:29 +000011882else
Guido van Rossum49545951997-12-02 19:28:29 +000011883
Martin v. Löwis11437992002-04-12 09:54:03 +000011884 echo "$as_me:$LINENO: checking for __pthread_create_system in -lpthread" >&5
11885echo $ECHO_N "checking for __pthread_create_system in -lpthread... $ECHO_C" >&6
11886if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then
11887 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011888else
Martin v. Löwis11437992002-04-12 09:54:03 +000011889 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011890LIBS="-lpthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011891cat >conftest.$ac_ext <<_ACEOF
11892#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011893/* confdefs.h. */
11894_ACEOF
11895cat confdefs.h >>conftest.$ac_ext
11896cat >>conftest.$ac_ext <<_ACEOF
11897/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011898
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011899/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011900#ifdef __cplusplus
11901extern "C"
11902#endif
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011903/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011904 builtin and then its argument prototype would still apply. */
11905char __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011906int
11907main ()
11908{
11909__pthread_create_system ();
11910 ;
11911 return 0;
11912}
11913_ACEOF
11914rm -f conftest.$ac_objext conftest$ac_exeext
11915if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11916 (eval $ac_link) 2>&5
11917 ac_status=$?
11918 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11919 (exit $ac_status); } &&
11920 { ac_try='test -s conftest$ac_exeext'
11921 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11922 (eval $ac_try) 2>&5
11923 ac_status=$?
11924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11925 (exit $ac_status); }; }; then
11926 ac_cv_lib_pthread___pthread_create_system=yes
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011927else
Martin v. Löwis11437992002-04-12 09:54:03 +000011928 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011929sed 's/^/| /' conftest.$ac_ext >&5
11930
Martin v. Löwis11437992002-04-12 09:54:03 +000011931ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011932fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011933rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11934LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011935fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011936echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_create_system" >&5
11937echo "${ECHO_T}$ac_cv_lib_pthread___pthread_create_system" >&6
11938if test $ac_cv_lib_pthread___pthread_create_system = yes; then
11939 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011940#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011941_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011942
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011943 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000011944 LIBS="$LIBS -lpthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011945 THREADOBJ="Python/thread.o"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011946else
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000011947
Martin v. Löwis11437992002-04-12 09:54:03 +000011948 echo "$as_me:$LINENO: checking for pthread_create in -lcma" >&5
11949echo $ECHO_N "checking for pthread_create in -lcma... $ECHO_C" >&6
11950if test "${ac_cv_lib_cma_pthread_create+set}" = set; then
11951 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb93a8621998-05-07 13:27:32 +000011952else
Martin v. Löwis11437992002-04-12 09:54:03 +000011953 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000011954LIBS="-lcma $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011955cat >conftest.$ac_ext <<_ACEOF
11956#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000011957/* confdefs.h. */
11958_ACEOF
11959cat confdefs.h >>conftest.$ac_ext
11960cat >>conftest.$ac_ext <<_ACEOF
11961/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011962
Guido van Rossumb93a8621998-05-07 13:27:32 +000011963/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011964#ifdef __cplusplus
11965extern "C"
11966#endif
Guido van Rossumb93a8621998-05-07 13:27:32 +000011967/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011968 builtin and then its argument prototype would still apply. */
11969char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000011970int
11971main ()
11972{
11973pthread_create ();
11974 ;
11975 return 0;
11976}
11977_ACEOF
11978rm -f conftest.$ac_objext conftest$ac_exeext
11979if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11980 (eval $ac_link) 2>&5
11981 ac_status=$?
11982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11983 (exit $ac_status); } &&
11984 { ac_try='test -s conftest$ac_exeext'
11985 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11986 (eval $ac_try) 2>&5
11987 ac_status=$?
11988 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11989 (exit $ac_status); }; }; then
11990 ac_cv_lib_cma_pthread_create=yes
Guido van Rossumb93a8621998-05-07 13:27:32 +000011991else
Martin v. Löwis11437992002-04-12 09:54:03 +000011992 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000011993sed 's/^/| /' conftest.$ac_ext >&5
11994
Martin v. Löwis11437992002-04-12 09:54:03 +000011995ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000011996fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011997rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11998LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000011999fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012000echo "$as_me:$LINENO: result: $ac_cv_lib_cma_pthread_create" >&5
12001echo "${ECHO_T}$ac_cv_lib_cma_pthread_create" >&6
12002if test $ac_cv_lib_cma_pthread_create = yes; then
12003 cat >>confdefs.h <<\_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000012004#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012005_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000012006
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012007 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000012008 LIBS="$LIBS -lcma"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000012009 THREADOBJ="Python/thread.o"
Guido van Rossumb93a8621998-05-07 13:27:32 +000012010else
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000012011
Martin v. Löwis130fb172001-07-19 11:00:41 +000012012 USE_THREAD_MODULE="#"
Guido van Rossum2d38f911996-06-26 19:47:01 +000012013fi
12014
Guido van Rossum627b2d71993-12-24 10:39:16 +000012015
Guido van Rossum7b3853f1996-07-30 18:09:35 +000012016fi
12017
Guido van Rossum0be3e491997-05-22 20:33:33 +000012018fi
12019
Guido van Rossum49545951997-12-02 19:28:29 +000012020fi
12021
Guido van Rossumb93a8621998-05-07 13:27:32 +000012022fi
12023
Guido van Rossumec95c7b1998-08-04 17:59:56 +000012024fi
12025
Guido van Rossum07bd90e2000-05-08 13:41:38 +000012026
Michael W. Hudson54241132001-12-07 15:38:26 +000012027fi
12028
Martin v. Löwisf90ae202002-06-11 06:22:31 +000012029
12030fi
12031
Martin v. Löwisa6e97582002-01-01 18:41:33 +000012032fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012033rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12034fi;
12035fi
12036
12037
12038fi
12039
Martin v. Löwisa6e97582002-01-01 18:41:33 +000012040
Michael W. Hudson54241132001-12-07 15:38:26 +000012041
Martin v. Löwis11437992002-04-12 09:54:03 +000012042 echo "$as_me:$LINENO: checking for usconfig in -lmpc" >&5
12043echo $ECHO_N "checking for usconfig in -lmpc... $ECHO_C" >&6
12044if test "${ac_cv_lib_mpc_usconfig+set}" = set; then
12045 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012046else
Martin v. Löwis11437992002-04-12 09:54:03 +000012047 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012048LIBS="-lmpc $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012049cat >conftest.$ac_ext <<_ACEOF
12050#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012051/* confdefs.h. */
12052_ACEOF
12053cat confdefs.h >>conftest.$ac_ext
12054cat >>conftest.$ac_ext <<_ACEOF
12055/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012056
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012057/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012058#ifdef __cplusplus
12059extern "C"
12060#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012061/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012062 builtin and then its argument prototype would still apply. */
12063char usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012064int
12065main ()
12066{
12067usconfig ();
12068 ;
12069 return 0;
12070}
12071_ACEOF
12072rm -f conftest.$ac_objext conftest$ac_exeext
12073if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12074 (eval $ac_link) 2>&5
12075 ac_status=$?
12076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12077 (exit $ac_status); } &&
12078 { ac_try='test -s conftest$ac_exeext'
12079 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12080 (eval $ac_try) 2>&5
12081 ac_status=$?
12082 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12083 (exit $ac_status); }; }; then
12084 ac_cv_lib_mpc_usconfig=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012085else
Martin v. Löwis11437992002-04-12 09:54:03 +000012086 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012087sed 's/^/| /' conftest.$ac_ext >&5
12088
Martin v. Löwis11437992002-04-12 09:54:03 +000012089ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000012090fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012091rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12092LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012093fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012094echo "$as_me:$LINENO: result: $ac_cv_lib_mpc_usconfig" >&5
12095echo "${ECHO_T}$ac_cv_lib_mpc_usconfig" >&6
12096if test $ac_cv_lib_mpc_usconfig = yes; then
12097 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012098#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012099_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012100
Martin v. Löwis130fb172001-07-19 11:00:41 +000012101 LIBS="$LIBS -lmpc"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000012102 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000012103 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000012104fi
12105
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000012106
Neal Norwitza978ab02002-11-02 16:58:05 +000012107 if test "$posix_threads" != "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012108 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
12109echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
12110if test "${ac_cv_lib_thread_thr_create+set}" = set; then
12111 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012112else
Martin v. Löwis11437992002-04-12 09:54:03 +000012113 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012114LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012115cat >conftest.$ac_ext <<_ACEOF
12116#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012117/* confdefs.h. */
12118_ACEOF
12119cat confdefs.h >>conftest.$ac_ext
12120cat >>conftest.$ac_ext <<_ACEOF
12121/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012122
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012123/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012124#ifdef __cplusplus
12125extern "C"
12126#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012127/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012128 builtin and then its argument prototype would still apply. */
12129char thr_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000012130int
12131main ()
12132{
12133thr_create ();
12134 ;
12135 return 0;
12136}
12137_ACEOF
12138rm -f conftest.$ac_objext conftest$ac_exeext
12139if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12140 (eval $ac_link) 2>&5
12141 ac_status=$?
12142 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12143 (exit $ac_status); } &&
12144 { ac_try='test -s conftest$ac_exeext'
12145 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12146 (eval $ac_try) 2>&5
12147 ac_status=$?
12148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12149 (exit $ac_status); }; }; then
12150 ac_cv_lib_thread_thr_create=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012151else
Martin v. Löwis11437992002-04-12 09:54:03 +000012152 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012153sed 's/^/| /' conftest.$ac_ext >&5
12154
Martin v. Löwis11437992002-04-12 09:54:03 +000012155ac_cv_lib_thread_thr_create=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000012156fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012157rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12158LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012159fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012160echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
12161echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
12162if test $ac_cv_lib_thread_thr_create = yes; then
12163 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012164#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012165_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012166
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000012167 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000012168 THREADOBJ="Python/thread.o"
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000012169 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000012170fi
12171
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000012172 fi
Michael W. Hudson54241132001-12-07 15:38:26 +000012173
Martin v. Löwis130fb172001-07-19 11:00:41 +000012174 if test "$USE_THREAD_MODULE" != "#"
12175 then
12176 # If the above checks didn't disable threads, (at least) OSF1
12177 # needs this '-threads' argument during linking.
12178 case $ac_sys_system in
12179 OSF1) LDLAST=-threads;;
12180 esac
Jeremy Hylton1a2ca862000-10-16 16:59:12 +000012181 fi
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012182fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012183
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012184if test "$posix_threads" = "yes"; then
12185 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012186
12187cat >>confdefs.h <<\_ACEOF
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012188#define _POSIX_THREADS 1
12189_ACEOF
12190
12191 fi
12192
12193 # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8.
12194 case $ac_sys_system/$ac_sys_release in
12195 SunOS/5.6)
12196cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012197#define HAVE_PTHREAD_DESTRUCTOR 1
12198_ACEOF
12199
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012200 ;;
12201 SunOS/5.8)
12202cat >>confdefs.h <<\_ACEOF
12203#define HAVE_BROKEN_POSIX_SEMAPHORES 1
12204_ACEOF
12205
12206 ;;
12207 esac
12208
12209 echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
12210echo $ECHO_N "checking if PTHREAD_SCOPE_SYSTEM is supported... $ECHO_C" >&6
12211 if test "${ac_cv_pthread_system_supported+set}" = set; then
12212 echo $ECHO_N "(cached) $ECHO_C" >&6
12213else
12214 if test "$cross_compiling" = yes; then
12215 ac_cv_pthread_system_supported=no
12216else
12217 cat >conftest.$ac_ext <<_ACEOF
12218#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012219/* confdefs.h. */
12220_ACEOF
12221cat confdefs.h >>conftest.$ac_ext
12222cat >>conftest.$ac_ext <<_ACEOF
12223/* end confdefs.h. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012224#include <pthread.h>
12225 void *foo(void *parm) {
12226 return NULL;
12227 }
12228 main() {
12229 pthread_attr_t attr;
12230 pthread_t id;
12231 if (pthread_attr_init(&attr)) exit(-1);
12232 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1);
12233 if (pthread_create(&id, &attr, foo, NULL)) exit(-1);
12234 exit(0);
12235 }
12236_ACEOF
12237rm -f conftest$ac_exeext
12238if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12239 (eval $ac_link) 2>&5
12240 ac_status=$?
12241 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12242 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12243 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12244 (eval $ac_try) 2>&5
12245 ac_status=$?
12246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12247 (exit $ac_status); }; }; then
12248 ac_cv_pthread_system_supported=yes
12249else
12250 echo "$as_me: program exited with status $ac_status" >&5
12251echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012252sed 's/^/| /' conftest.$ac_ext >&5
12253
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012254( exit $ac_status )
12255ac_cv_pthread_system_supported=no
12256fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000012257rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012258fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000012259
Guido van Rossum627b2d71993-12-24 10:39:16 +000012260fi
12261
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012262 echo "$as_me:$LINENO: result: $ac_cv_pthread_system_supported" >&5
12263echo "${ECHO_T}$ac_cv_pthread_system_supported" >&6
12264 if test "$ac_cv_pthread_system_supported" = "yes"; then
12265
12266cat >>confdefs.h <<\_ACEOF
12267#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1
12268_ACEOF
12269
12270 fi
12271
12272for ac_func in pthread_sigmask
12273do
12274as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12275echo "$as_me:$LINENO: checking for $ac_func" >&5
12276echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12277if eval "test \"\${$as_ac_var+set}\" = set"; then
12278 echo $ECHO_N "(cached) $ECHO_C" >&6
12279else
12280 cat >conftest.$ac_ext <<_ACEOF
12281#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012282/* confdefs.h. */
12283_ACEOF
12284cat confdefs.h >>conftest.$ac_ext
12285cat >>conftest.$ac_ext <<_ACEOF
12286/* end confdefs.h. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012287/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000012288 which can conflict with char $ac_func (); below.
12289 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12290 <limits.h> exists even on freestanding compilers. */
12291#ifdef __STDC__
12292# include <limits.h>
12293#else
12294# include <assert.h>
12295#endif
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012296/* Override any gcc2 internal prototype to avoid an error. */
12297#ifdef __cplusplus
12298extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012299{
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012300#endif
12301/* We use char because int might match the return type of a gcc2
12302 builtin and then its argument prototype would still apply. */
12303char $ac_func ();
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012304/* The GNU C library defines this for functions which it implements
12305 to always fail with ENOSYS. Some functions are actually named
12306 something starting with __ and the normal name is an alias. */
12307#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12308choke me
12309#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000012310char (*f) () = $ac_func;
12311#endif
12312#ifdef __cplusplus
12313}
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012314#endif
12315
Skip Montanarod8d39a02003-07-10 20:44:10 +000012316int
12317main ()
12318{
12319return f != $ac_func;
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012320 ;
12321 return 0;
12322}
12323_ACEOF
12324rm -f conftest.$ac_objext conftest$ac_exeext
12325if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12326 (eval $ac_link) 2>&5
12327 ac_status=$?
12328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12329 (exit $ac_status); } &&
12330 { ac_try='test -s conftest$ac_exeext'
12331 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12332 (eval $ac_try) 2>&5
12333 ac_status=$?
12334 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12335 (exit $ac_status); }; }; then
12336 eval "$as_ac_var=yes"
12337else
12338 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012339sed 's/^/| /' conftest.$ac_ext >&5
12340
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000012341eval "$as_ac_var=no"
12342fi
12343rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12344fi
12345echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12346echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12347if test `eval echo '${'$as_ac_var'}'` = yes; then
12348 cat >>confdefs.h <<_ACEOF
12349#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12350_ACEOF
12351
12352fi
12353done
12354
12355fi
12356
12357
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012358# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000012359
12360
12361echo "$as_me:$LINENO: checking if --enable-ipv6 is specified" >&5
12362echo $ECHO_N "checking if --enable-ipv6 is specified... $ECHO_C" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012363# Check whether --enable-ipv6 or --disable-ipv6 was given.
12364if test "${enable_ipv6+set}" = set; then
12365 enableval="$enable_ipv6"
12366 case "$enableval" in
12367 no)
Martin v. Löwis11437992002-04-12 09:54:03 +000012368 echo "$as_me:$LINENO: result: no" >&5
12369echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012370 ipv6=no
12371 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000012372 *) echo "$as_me:$LINENO: result: yes" >&5
12373echo "${ECHO_T}yes" >&6
12374 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012375#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012376_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012377
12378 ipv6=yes
12379 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000012380 esac
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012381else
Martin v. Löwis11437992002-04-12 09:54:03 +000012382
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012383 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012384 echo "$as_me:$LINENO: result: no" >&5
12385echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012386 ipv6=no
12387
12388else
Martin v. Löwis11437992002-04-12 09:54:03 +000012389 cat >conftest.$ac_ext <<_ACEOF
12390#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012391/* confdefs.h. */
12392_ACEOF
12393cat confdefs.h >>conftest.$ac_ext
12394cat >>conftest.$ac_ext <<_ACEOF
12395/* end confdefs.h. */
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012396 /* AF_INET6 available check */
12397#include <sys/types.h>
12398#include <sys/socket.h>
12399main()
12400{
12401 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
12402 exit(1);
12403 else
12404 exit(0);
12405}
12406
Martin v. Löwis11437992002-04-12 09:54:03 +000012407_ACEOF
12408rm -f conftest$ac_exeext
12409if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12410 (eval $ac_link) 2>&5
12411 ac_status=$?
12412 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12413 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12414 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12415 (eval $ac_try) 2>&5
12416 ac_status=$?
12417 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12418 (exit $ac_status); }; }; then
12419 echo "$as_me:$LINENO: result: yes" >&5
12420echo "${ECHO_T}yes" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012421 ipv6=yes
12422else
Martin v. Löwis11437992002-04-12 09:54:03 +000012423 echo "$as_me: program exited with status $ac_status" >&5
12424echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012425sed 's/^/| /' conftest.$ac_ext >&5
12426
Martin v. Löwis11437992002-04-12 09:54:03 +000012427( exit $ac_status )
12428echo "$as_me:$LINENO: result: no" >&5
12429echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012430 ipv6=no
12431fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000012432rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012433fi
12434
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012435if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012436 echo "$as_me:$LINENO: checking if RFC2553 API is available" >&5
12437echo $ECHO_N "checking if RFC2553 API is available... $ECHO_C" >&6
12438 cat >conftest.$ac_ext <<_ACEOF
12439#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012440/* confdefs.h. */
12441_ACEOF
12442cat confdefs.h >>conftest.$ac_ext
12443cat >>conftest.$ac_ext <<_ACEOF
12444/* end confdefs.h. */
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012445#include <sys/types.h>
12446#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012447int
12448main ()
12449{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012450struct sockaddr_in6 x;
12451x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000012452 ;
12453 return 0;
12454}
12455_ACEOF
12456rm -f conftest.$ac_objext
12457if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12458 (eval $ac_compile) 2>&5
12459 ac_status=$?
12460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12461 (exit $ac_status); } &&
12462 { ac_try='test -s conftest.$ac_objext'
12463 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12464 (eval $ac_try) 2>&5
12465 ac_status=$?
12466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12467 (exit $ac_status); }; }; then
12468 echo "$as_me:$LINENO: result: yes" >&5
12469echo "${ECHO_T}yes" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012470 ipv6=yes
12471else
Martin v. Löwis11437992002-04-12 09:54:03 +000012472 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012473sed 's/^/| /' conftest.$ac_ext >&5
12474
Martin v. Löwis11437992002-04-12 09:54:03 +000012475echo "$as_me:$LINENO: result: no" >&5
12476echo "${ECHO_T}no" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012477 ipv6=no
12478fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012479rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012480fi
12481
12482if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012483 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012484#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012485_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000012486
12487fi
12488
Martin v. Löwis11437992002-04-12 09:54:03 +000012489fi;
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012490
12491ipv6type=unknown
12492ipv6lib=none
12493ipv6trylibc=no
12494
12495if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012496 echo "$as_me:$LINENO: checking ipv6 stack type" >&5
12497echo $ECHO_N "checking ipv6 stack type... $ECHO_C" >&6
Guido van Rossumb8552162001-09-05 14:58:11 +000012498 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
12499 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012500 case $i in
12501 inria)
Martin v. Löwis11437992002-04-12 09:54:03 +000012502 cat >conftest.$ac_ext <<_ACEOF
12503#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012504/* confdefs.h. */
12505_ACEOF
12506cat confdefs.h >>conftest.$ac_ext
12507cat >>conftest.$ac_ext <<_ACEOF
12508/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012509
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012510#include <netinet/in.h>
12511#ifdef IPV6_INRIA_VERSION
12512yes
12513#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012514_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012515if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000012516 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000012517 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012518fi
12519rm -f conftest*
12520
12521 ;;
12522 kame)
Martin v. Löwis11437992002-04-12 09:54:03 +000012523 cat >conftest.$ac_ext <<_ACEOF
12524#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012525/* confdefs.h. */
12526_ACEOF
12527cat confdefs.h >>conftest.$ac_ext
12528cat >>conftest.$ac_ext <<_ACEOF
12529/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012530
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012531#include <netinet/in.h>
12532#ifdef __KAME__
12533yes
12534#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012535_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012536if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000012537 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012538 ipv6type=$i;
12539 ipv6lib=inet6
12540 ipv6libdir=/usr/local/v6/lib
12541 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012542fi
12543rm -f conftest*
12544
12545 ;;
12546 linux-glibc)
Martin v. Löwis11437992002-04-12 09:54:03 +000012547 cat >conftest.$ac_ext <<_ACEOF
12548#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012549/* confdefs.h. */
12550_ACEOF
12551cat confdefs.h >>conftest.$ac_ext
12552cat >>conftest.$ac_ext <<_ACEOF
12553/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012554
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012555#include <features.h>
12556#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
12557yes
12558#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012559_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012560if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000012561 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012562 ipv6type=$i;
12563 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012564fi
12565rm -f conftest*
12566
12567 ;;
12568 linux-inet6)
12569 if test -d /usr/inet6; then
12570 ipv6type=$i
12571 ipv6lib=inet6
12572 ipv6libdir=/usr/inet6/lib
Skip Montanarodecc6a42003-01-01 20:07:49 +000012573 BASECFLAGS="-I/usr/inet6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012574 fi
12575 ;;
12576 solaris)
12577 if test -f /etc/netconfig; then
12578 if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then
12579 ipv6type=$i
12580 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012581 fi
12582 fi
12583 ;;
12584 toshiba)
Martin v. Löwis11437992002-04-12 09:54:03 +000012585 cat >conftest.$ac_ext <<_ACEOF
12586#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012587/* confdefs.h. */
12588_ACEOF
12589cat confdefs.h >>conftest.$ac_ext
12590cat >>conftest.$ac_ext <<_ACEOF
12591/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012592
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012593#include <sys/param.h>
12594#ifdef _TOSHIBA_INET6
12595yes
12596#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012597_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012598if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000012599 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012600 ipv6type=$i;
12601 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000012602 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012603fi
12604rm -f conftest*
12605
12606 ;;
12607 v6d)
Martin v. Löwis11437992002-04-12 09:54:03 +000012608 cat >conftest.$ac_ext <<_ACEOF
12609#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012610/* confdefs.h. */
12611_ACEOF
12612cat confdefs.h >>conftest.$ac_ext
12613cat >>conftest.$ac_ext <<_ACEOF
12614/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012615
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012616#include </usr/local/v6/include/sys/v6config.h>
12617#ifdef __V6D__
12618yes
12619#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012620_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012621if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000012622 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012623 ipv6type=$i;
12624 ipv6lib=v6;
12625 ipv6libdir=/usr/local/v6/lib;
Skip Montanarodecc6a42003-01-01 20:07:49 +000012626 BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012627fi
12628rm -f conftest*
12629
12630 ;;
12631 zeta)
Martin v. Löwis11437992002-04-12 09:54:03 +000012632 cat >conftest.$ac_ext <<_ACEOF
12633#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012634/* confdefs.h. */
12635_ACEOF
12636cat confdefs.h >>conftest.$ac_ext
12637cat >>conftest.$ac_ext <<_ACEOF
12638/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000012639
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012640#include <sys/param.h>
12641#ifdef _ZETA_MINAMI_INET6
12642yes
12643#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012644_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012645if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000012646 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012647 ipv6type=$i;
12648 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000012649 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012650fi
12651rm -f conftest*
12652
12653 ;;
12654 esac
12655 if test "$ipv6type" != "unknown"; then
12656 break
12657 fi
12658 done
Martin v. Löwis11437992002-04-12 09:54:03 +000012659 echo "$as_me:$LINENO: result: $ipv6type" >&5
12660echo "${ECHO_T}$ipv6type" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000012661fi
12662
12663if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
12664 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
12665 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
12666 echo "using lib$ipv6lib"
12667 else
12668 if test $ipv6trylibc = "yes"; then
12669 echo "using libc"
12670 else
12671 echo 'Fatal: no $ipv6lib library found. cannot continue.'
12672 echo "You need to fetch lib$ipv6lib.a from appropriate"
12673 echo 'ipv6 kit and compile beforehand.'
12674 exit 1
12675 fi
12676 fi
12677fi
12678
Jack Jansen7b8c7542002-04-14 20:12:41 +000012679# Check for universal newline support
Guido van Rossum402905e2002-08-15 13:56:35 +000012680echo "$as_me:$LINENO: checking for --with-universal-newlines" >&5
12681echo $ECHO_N "checking for --with-universal-newlines... $ECHO_C" >&6
Jack Jansen7b8c7542002-04-14 20:12:41 +000012682
12683# Check whether --with-universal-newlines or --without-universal-newlines was given.
12684if test "${with_universal_newlines+set}" = set; then
12685 withval="$with_universal_newlines"
12686
12687fi;
12688
12689if test -z "$with_universal_newlines"
12690then with_universal_newlines="yes"
12691fi
Martin v. Löwis7e4cfcb2002-12-19 16:21:49 +000012692if test "$with_universal_newlines" = "no"
Martin v. Löwis03d00d52002-12-19 19:03:31 +000012693then
Martin v. Löwis7e4cfcb2002-12-19 16:21:49 +000012694 echo --without-universal-newlines is unsupported, see README
12695 exit 1
Martin v. Löwis03d00d52002-12-19 19:03:31 +000012696else
Martin v. Löwise8aea582002-04-16 05:51:02 +000012697
12698cat >>confdefs.h <<\_ACEOF
Jack Jansen7b8c7542002-04-14 20:12:41 +000012699#define WITH_UNIVERSAL_NEWLINES 1
12700_ACEOF
12701
12702fi
12703echo "$as_me:$LINENO: result: $with_universal_newlines" >&5
12704echo "${ECHO_T}$with_universal_newlines" >&6
12705
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000012706# Check for --with-doc-strings
12707echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
12708echo $ECHO_N "checking for --with-doc-strings... $ECHO_C" >&6
12709
12710# Check whether --with-doc-strings or --without-doc-strings was given.
12711if test "${with_doc_strings+set}" = set; then
12712 withval="$with_doc_strings"
12713
12714fi;
12715
12716if test -z "$with_doc_strings"
12717then with_doc_strings="yes"
12718fi
12719if test "$with_doc_strings" != "no"
12720then
12721
12722cat >>confdefs.h <<\_ACEOF
12723#define WITH_DOC_STRINGS 1
12724_ACEOF
12725
12726fi
12727echo "$as_me:$LINENO: result: $with_doc_strings" >&5
12728echo "${ECHO_T}$with_doc_strings" >&6
12729
Neil Schemenauera35c6882001-02-27 04:45:05 +000012730# Check for Python-specific malloc support
Martin v. Löwis11437992002-04-12 09:54:03 +000012731echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
12732echo $ECHO_N "checking for --with-pymalloc... $ECHO_C" >&6
12733
Neil Schemenauera35c6882001-02-27 04:45:05 +000012734# Check whether --with-pymalloc or --without-pymalloc was given.
12735if test "${with_pymalloc+set}" = set; then
12736 withval="$with_pymalloc"
Michael W. Hudson54241132001-12-07 15:38:26 +000012737
Martin v. Löwis11437992002-04-12 09:54:03 +000012738fi;
Neil Schemenauera35c6882001-02-27 04:45:05 +000012739
Neil Schemenauer16c22972002-03-22 15:34:49 +000012740if test -z "$with_pymalloc"
12741then with_pymalloc="yes"
12742fi
12743if test "$with_pymalloc" != "no"
12744then
Martin v. Löwis11437992002-04-12 09:54:03 +000012745
12746cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000012747#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012748_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000012749
12750fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012751echo "$as_me:$LINENO: result: $with_pymalloc" >&5
12752echo "${ECHO_T}$with_pymalloc" >&6
Neil Schemenauer16c22972002-03-22 15:34:49 +000012753
Barry Warsawef82cd72000-06-30 16:21:01 +000012754# Check for --with-wctype-functions
Martin v. Löwis11437992002-04-12 09:54:03 +000012755echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
12756echo $ECHO_N "checking for --with-wctype-functions... $ECHO_C" >&6
12757
Barry Warsawef82cd72000-06-30 16:21:01 +000012758# Check whether --with-wctype-functions or --without-wctype-functions was given.
12759if test "${with_wctype_functions+set}" = set; then
12760 withval="$with_wctype_functions"
Martin v. Löwis11437992002-04-12 09:54:03 +000012761
Barry Warsawef82cd72000-06-30 16:21:01 +000012762if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000012763then
12764
12765cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000012766#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012767_ACEOF
12768
12769 echo "$as_me:$LINENO: result: yes" >&5
12770echo "${ECHO_T}yes" >&6
12771else echo "$as_me:$LINENO: result: no" >&5
12772echo "${ECHO_T}no" >&6
Barry Warsawef82cd72000-06-30 16:21:01 +000012773fi
12774else
Martin v. Löwis11437992002-04-12 09:54:03 +000012775 echo "$as_me:$LINENO: result: no" >&5
12776echo "${ECHO_T}no" >&6
12777fi;
Barry Warsawef82cd72000-06-30 16:21:01 +000012778
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012779# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000012780
Guido van Rossum98935bf2001-09-05 19:13:16 +000012781DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000012782
Martin v. Löwis11437992002-04-12 09:54:03 +000012783echo "$as_me:$LINENO: checking for --with-sgi-dl" >&5
12784echo $ECHO_N "checking for --with-sgi-dl... $ECHO_C" >&6
12785
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012786# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012787if test "${with_sgi_dl+set}" = set; then
12788 withval="$with_sgi_dl"
Martin v. Löwis11437992002-04-12 09:54:03 +000012789
12790echo "$as_me:$LINENO: result: $withval" >&5
12791echo "${ECHO_T}$withval" >&6
Martin v. Löwis9ef33762002-12-02 22:23:56 +000012792echo --with-sgi-dl is unsupported, see README
Martin v. Löwis779ffc02002-12-02 22:17:01 +000012793exit 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012794
12795cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012796#define WITH_SGI_DL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012797_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000012798
Guido van Rossume97ee181999-12-20 21:27:22 +000012799DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000012800dldir=$withval
Guido van Rossum40951012000-10-07 16:21:27 +000012801if test ! -z "$dldir" -a -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000012802then LDFLAGS="$LDFLAGS -L$dldir"
Martin v. Löwis11437992002-04-12 09:54:03 +000012803else { { echo "$as_me:$LINENO: error: proper usage is --with-sgi-dl=DIRECTORY" >&5
12804echo "$as_me: error: proper usage is --with-sgi-dl=DIRECTORY" >&2;}
12805 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000012806fi
12807DLINCLDIR=${dldir}
12808LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000012809else
Martin v. Löwis11437992002-04-12 09:54:03 +000012810 echo "$as_me:$LINENO: result: no" >&5
12811echo "${ECHO_T}no" >&6
12812fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000012813
Martin v. Löwis11437992002-04-12 09:54:03 +000012814echo "$as_me:$LINENO: checking for --with-dl-dld" >&5
12815echo $ECHO_N "checking for --with-dl-dld... $ECHO_C" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000012816
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012817# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012818if test "${with_dl_dld+set}" = set; then
12819 withval="$with_dl_dld"
Martin v. Löwis11437992002-04-12 09:54:03 +000012820
12821echo "$as_me:$LINENO: result: $withval" >&5
12822echo "${ECHO_T}$withval" >&6
Martin v. Löwis9ef33762002-12-02 22:23:56 +000012823echo --with-dl-dld is unsupported, see README
Martin v. Löwis779ffc02002-12-02 22:17:01 +000012824exit 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012825
12826cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012827#define WITH_DL_DLD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012828_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000012829
Guido van Rossume97ee181999-12-20 21:27:22 +000012830DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000012831dldir=`echo "$withval" | sed 's/,.*//'`
12832dlddir=`echo "$withval" | sed 's/.*,//'`
Barry Warsaw7d1219d2000-10-05 18:45:53 +000012833if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000012834then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000012835else { { echo "$as_me:$LINENO: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&5
12836echo "$as_me: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&2;}
12837 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000012838fi
12839DLINCLDIR=${dldir}
12840LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000012841else
Martin v. Löwis11437992002-04-12 09:54:03 +000012842 echo "$as_me:$LINENO: result: no" >&5
12843echo "${ECHO_T}no" >&6
12844fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000012845
Guido van Rossume97ee181999-12-20 21:27:22 +000012846# the dlopen() function means we might want to use dynload_shlib.o. some
12847# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000012848
Thomas Wouters3a584202000-08-05 23:28:51 +000012849for ac_func in dlopen
12850do
Martin v. Löwis11437992002-04-12 09:54:03 +000012851as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12852echo "$as_me:$LINENO: checking for $ac_func" >&5
12853echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12854if eval "test \"\${$as_ac_var+set}\" = set"; then
12855 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000012856else
Martin v. Löwis11437992002-04-12 09:54:03 +000012857 cat >conftest.$ac_ext <<_ACEOF
12858#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012859/* confdefs.h. */
12860_ACEOF
12861cat confdefs.h >>conftest.$ac_ext
12862cat >>conftest.$ac_ext <<_ACEOF
12863/* end confdefs.h. */
Guido van Rossume97ee181999-12-20 21:27:22 +000012864/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000012865 which can conflict with char $ac_func (); below.
12866 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12867 <limits.h> exists even on freestanding compilers. */
12868#ifdef __STDC__
12869# include <limits.h>
12870#else
12871# include <assert.h>
12872#endif
Guido van Rossume97ee181999-12-20 21:27:22 +000012873/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012874#ifdef __cplusplus
12875extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000012876{
Martin v. Löwis11437992002-04-12 09:54:03 +000012877#endif
Guido van Rossume97ee181999-12-20 21:27:22 +000012878/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012879 builtin and then its argument prototype would still apply. */
12880char $ac_func ();
Guido van Rossume97ee181999-12-20 21:27:22 +000012881/* The GNU C library defines this for functions which it implements
12882 to always fail with ENOSYS. Some functions are actually named
12883 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012884#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossume97ee181999-12-20 21:27:22 +000012885choke me
12886#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000012887char (*f) () = $ac_func;
12888#endif
12889#ifdef __cplusplus
12890}
Guido van Rossume97ee181999-12-20 21:27:22 +000012891#endif
12892
Skip Montanarod8d39a02003-07-10 20:44:10 +000012893int
12894main ()
12895{
12896return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000012897 ;
12898 return 0;
12899}
12900_ACEOF
12901rm -f conftest.$ac_objext conftest$ac_exeext
12902if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12903 (eval $ac_link) 2>&5
12904 ac_status=$?
12905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12906 (exit $ac_status); } &&
12907 { ac_try='test -s conftest$ac_exeext'
12908 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12909 (eval $ac_try) 2>&5
12910 ac_status=$?
12911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12912 (exit $ac_status); }; }; then
12913 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012914else
Martin v. Löwis11437992002-04-12 09:54:03 +000012915 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000012916sed 's/^/| /' conftest.$ac_ext >&5
12917
Martin v. Löwis11437992002-04-12 09:54:03 +000012918eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012919fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012920rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012921fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012922echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12923echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12924if test `eval echo '${'$as_ac_var'}'` = yes; then
12925 cat >>confdefs.h <<_ACEOF
12926#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12927_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000012928
Guido van Rossume97ee181999-12-20 21:27:22 +000012929fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012930done
Guido van Rossume97ee181999-12-20 21:27:22 +000012931
Michael W. Hudson54241132001-12-07 15:38:26 +000012932
Guido van Rossume97ee181999-12-20 21:27:22 +000012933# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
12934# loading of modules.
12935
Martin v. Löwis11437992002-04-12 09:54:03 +000012936echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
12937echo $ECHO_N "checking DYNLOADFILE... $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000012938if test -z "$DYNLOADFILE"
12939then
12940 case $ac_sys_system/$ac_sys_release in
12941 AIX*) DYNLOADFILE="dynload_aix.o";;
12942 BeOS*) DYNLOADFILE="dynload_beos.o";;
12943 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Jack Jansene578a632001-08-15 01:27:14 +000012944 Darwin/*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000012945 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000012946 *)
12947 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
12948 # out any dynamic loading
12949 if test "$ac_cv_func_dlopen" = yes
12950 then DYNLOADFILE="dynload_shlib.o"
12951 else DYNLOADFILE="dynload_stub.o"
12952 fi
12953 ;;
12954 esac
12955fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012956echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
12957echo "${ECHO_T}$DYNLOADFILE" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000012958if test "$DYNLOADFILE" != "dynload_stub.o"
12959then
Martin v. Löwis11437992002-04-12 09:54:03 +000012960
12961cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000012962#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012963_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000012964
12965fi
12966
Neil Schemenauer4e425612001-06-19 15:44:15 +000012967# MACHDEP_OBJS can be set to platform-specific object files needed by Python
12968
Michael W. Hudson54241132001-12-07 15:38:26 +000012969
Martin v. Löwis11437992002-04-12 09:54:03 +000012970echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
12971echo $ECHO_N "checking MACHDEP_OBJS... $ECHO_C" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000012972if test -z "$MACHDEP_OBJS"
12973then
Jack Jansene578a632001-08-15 01:27:14 +000012974 MACHDEP_OBJS=$extra_machdep_objs
12975else
12976 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000012977fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012978echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
12979echo "${ECHO_T}MACHDEP_OBJS" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000012980
Guido van Rossum627b2d71993-12-24 10:39:16 +000012981# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000012982
12983
12984
12985
12986
12987
12988
12989
12990
12991
12992
12993
12994
12995
12996
12997
12998
12999
13000
13001
13002
13003
13004
13005
13006
13007
13008
13009
13010
13011
13012
13013
13014
13015
13016
13017
13018
13019
13020
13021
13022
13023
13024
13025
13026
13027
13028
13029
13030
13031
13032
13033
13034
13035
13036
13037
13038
13039
13040
13041
13042
13043
13044
13045
13046
13047
13048
13049
13050
13051
13052
13053
13054
Martin v. Löwis9c36c292002-12-21 18:34:06 +000013055
Martin v. Löwisd5843682002-11-21 20:41:28 +000013056for ac_func in alarm chown clock confstr ctermid execv \
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013057 fchdir fork fsync fdatasync fpathconf ftime ftruncate \
Martin v. Löwis438b5342002-12-27 10:16:42 +000013058 gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \
13059 getpriority getpwent getwd \
Martin v. Löwise9416172003-05-03 10:12:45 +000013060 kill killpg lchown lstat mkfifo mknod mktime \
Martin v. Löwisa5f09072002-10-11 05:37:59 +000013061 mremap nice pathconf pause plock poll pthread_init \
Guido van Rossum162e38c2003-02-19 15:25:10 +000013062 putenv readlink realpath \
Martin v. Löwisd5843682002-11-21 20:41:28 +000013063 select setegid seteuid setgid \
Martin v. Löwis4daacb12003-03-28 18:37:01 +000013064 setlocale setregid setreuid setsid setpgid setpgrp setuid setvbuf snprintf \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013065 sigaction siginterrupt sigrelse strftime strptime \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000013066 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Martin v. Löwis438b5342002-12-27 10:16:42 +000013067 truncate uname unsetenv utimes waitpid wcscoll _getpty
Guido van Rossum627b2d71993-12-24 10:39:16 +000013068do
Martin v. Löwis11437992002-04-12 09:54:03 +000013069as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13070echo "$as_me:$LINENO: checking for $ac_func" >&5
13071echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13072if eval "test \"\${$as_ac_var+set}\" = set"; then
13073 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013074else
Martin v. Löwis11437992002-04-12 09:54:03 +000013075 cat >conftest.$ac_ext <<_ACEOF
13076#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013077/* confdefs.h. */
13078_ACEOF
13079cat confdefs.h >>conftest.$ac_ext
13080cat >>conftest.$ac_ext <<_ACEOF
13081/* end confdefs.h. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013082/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000013083 which can conflict with char $ac_func (); below.
13084 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13085 <limits.h> exists even on freestanding compilers. */
13086#ifdef __STDC__
13087# include <limits.h>
13088#else
13089# include <assert.h>
13090#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013091/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013092#ifdef __cplusplus
13093extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013094{
Martin v. Löwis11437992002-04-12 09:54:03 +000013095#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000013096/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000013097 builtin and then its argument prototype would still apply. */
13098char $ac_func ();
Guido van Rossum627b2d71993-12-24 10:39:16 +000013099/* The GNU C library defines this for functions which it implements
13100 to always fail with ENOSYS. Some functions are actually named
13101 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013102#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000013103choke me
13104#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000013105char (*f) () = $ac_func;
13106#endif
13107#ifdef __cplusplus
13108}
Guido van Rossum627b2d71993-12-24 10:39:16 +000013109#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013110
Skip Montanarod8d39a02003-07-10 20:44:10 +000013111int
13112main ()
13113{
13114return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000013115 ;
13116 return 0;
13117}
13118_ACEOF
13119rm -f conftest.$ac_objext conftest$ac_exeext
13120if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13121 (eval $ac_link) 2>&5
13122 ac_status=$?
13123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13124 (exit $ac_status); } &&
13125 { ac_try='test -s conftest$ac_exeext'
13126 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13127 (eval $ac_try) 2>&5
13128 ac_status=$?
13129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13130 (exit $ac_status); }; }; then
13131 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013132else
Martin v. Löwis11437992002-04-12 09:54:03 +000013133 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013134sed 's/^/| /' conftest.$ac_ext >&5
13135
Martin v. Löwis11437992002-04-12 09:54:03 +000013136eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013137fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013138rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013139fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013140echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13141echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13142if test `eval echo '${'$as_ac_var'}'` = yes; then
13143 cat >>confdefs.h <<_ACEOF
13144#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13145_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000013146
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013147fi
13148done
13149
Michael W. Hudson54241132001-12-07 15:38:26 +000013150
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013151# For some functions, having a definition is not sufficient, since
13152# we want to take their address.
13153echo "$as_me:$LINENO: checking for chroot" >&5
13154echo $ECHO_N "checking for chroot... $ECHO_C" >&6
13155cat >conftest.$ac_ext <<_ACEOF
13156#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013157/* confdefs.h. */
13158_ACEOF
13159cat confdefs.h >>conftest.$ac_ext
13160cat >>conftest.$ac_ext <<_ACEOF
13161/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013162#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013163int
13164main ()
13165{
13166void *x=chroot
13167 ;
13168 return 0;
13169}
13170_ACEOF
13171rm -f conftest.$ac_objext
13172if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13173 (eval $ac_compile) 2>&5
13174 ac_status=$?
13175 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13176 (exit $ac_status); } &&
13177 { ac_try='test -s conftest.$ac_objext'
13178 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13179 (eval $ac_try) 2>&5
13180 ac_status=$?
13181 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13182 (exit $ac_status); }; }; then
13183
13184cat >>confdefs.h <<\_ACEOF
13185#define HAVE_CHROOT 1
13186_ACEOF
13187
13188 echo "$as_me:$LINENO: result: yes" >&5
13189echo "${ECHO_T}yes" >&6
13190else
13191 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013192sed 's/^/| /' conftest.$ac_ext >&5
13193
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013194echo "$as_me:$LINENO: result: no" >&5
13195echo "${ECHO_T}no" >&6
13196
13197fi
13198rm -f conftest.$ac_objext conftest.$ac_ext
13199echo "$as_me:$LINENO: checking for link" >&5
13200echo $ECHO_N "checking for link... $ECHO_C" >&6
13201cat >conftest.$ac_ext <<_ACEOF
13202#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013203/* confdefs.h. */
13204_ACEOF
13205cat confdefs.h >>conftest.$ac_ext
13206cat >>conftest.$ac_ext <<_ACEOF
13207/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013208#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013209int
13210main ()
13211{
13212void *x=link
13213 ;
13214 return 0;
13215}
13216_ACEOF
13217rm -f conftest.$ac_objext
13218if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13219 (eval $ac_compile) 2>&5
13220 ac_status=$?
13221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13222 (exit $ac_status); } &&
13223 { ac_try='test -s conftest.$ac_objext'
13224 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13225 (eval $ac_try) 2>&5
13226 ac_status=$?
13227 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13228 (exit $ac_status); }; }; then
13229
13230cat >>confdefs.h <<\_ACEOF
13231#define HAVE_LINK 1
13232_ACEOF
13233
13234 echo "$as_me:$LINENO: result: yes" >&5
13235echo "${ECHO_T}yes" >&6
13236else
13237 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013238sed 's/^/| /' conftest.$ac_ext >&5
13239
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013240echo "$as_me:$LINENO: result: no" >&5
13241echo "${ECHO_T}no" >&6
13242
13243fi
13244rm -f conftest.$ac_objext conftest.$ac_ext
13245echo "$as_me:$LINENO: checking for symlink" >&5
13246echo $ECHO_N "checking for symlink... $ECHO_C" >&6
13247cat >conftest.$ac_ext <<_ACEOF
13248#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013249/* confdefs.h. */
13250_ACEOF
13251cat confdefs.h >>conftest.$ac_ext
13252cat >>conftest.$ac_ext <<_ACEOF
13253/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013254#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013255int
13256main ()
13257{
13258void *x=symlink
13259 ;
13260 return 0;
13261}
13262_ACEOF
13263rm -f conftest.$ac_objext
13264if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13265 (eval $ac_compile) 2>&5
13266 ac_status=$?
13267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13268 (exit $ac_status); } &&
13269 { ac_try='test -s conftest.$ac_objext'
13270 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13271 (eval $ac_try) 2>&5
13272 ac_status=$?
13273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13274 (exit $ac_status); }; }; then
13275
13276cat >>confdefs.h <<\_ACEOF
13277#define HAVE_SYMLINK 1
13278_ACEOF
13279
13280 echo "$as_me:$LINENO: result: yes" >&5
13281echo "${ECHO_T}yes" >&6
13282else
13283 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013284sed 's/^/| /' conftest.$ac_ext >&5
13285
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000013286echo "$as_me:$LINENO: result: no" >&5
13287echo "${ECHO_T}no" >&6
13288
13289fi
13290rm -f conftest.$ac_objext conftest.$ac_ext
13291
Martin v. Löwisd5843682002-11-21 20:41:28 +000013292# On some systems (eg. FreeBSD 5), we would find a definition of the
13293# functions ctermid_r, setgroups in the library, but no prototype
13294# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
13295# address to avoid compiler warnings and potential miscompilations
13296# because of the missing prototypes.
13297
13298echo "$as_me:$LINENO: checking for ctermid_r" >&5
13299echo $ECHO_N "checking for ctermid_r... $ECHO_C" >&6
13300cat >conftest.$ac_ext <<_ACEOF
13301#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013302/* confdefs.h. */
13303_ACEOF
13304cat confdefs.h >>conftest.$ac_ext
13305cat >>conftest.$ac_ext <<_ACEOF
13306/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000013307
13308#include "confdefs.h"
13309#include <stdio.h>
13310
Martin v. Löwisd5843682002-11-21 20:41:28 +000013311int
13312main ()
13313{
13314void* p = ctermid_r
13315 ;
13316 return 0;
13317}
13318_ACEOF
13319rm -f conftest.$ac_objext
13320if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13321 (eval $ac_compile) 2>&5
13322 ac_status=$?
13323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13324 (exit $ac_status); } &&
13325 { ac_try='test -s conftest.$ac_objext'
13326 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13327 (eval $ac_try) 2>&5
13328 ac_status=$?
13329 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13330 (exit $ac_status); }; }; then
13331
13332cat >>confdefs.h <<\_ACEOF
13333#define HAVE_CTERMID_R 1
13334_ACEOF
13335
13336 echo "$as_me:$LINENO: result: yes" >&5
13337echo "${ECHO_T}yes" >&6
13338else
13339 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013340sed 's/^/| /' conftest.$ac_ext >&5
13341
Martin v. Löwisd5843682002-11-21 20:41:28 +000013342echo "$as_me:$LINENO: result: no" >&5
13343echo "${ECHO_T}no" >&6
13344
13345fi
13346rm -f conftest.$ac_objext conftest.$ac_ext
13347
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013348echo "$as_me:$LINENO: checking for flock" >&5
13349echo $ECHO_N "checking for flock... $ECHO_C" >&6
13350cat >conftest.$ac_ext <<_ACEOF
13351#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013352/* confdefs.h. */
13353_ACEOF
13354cat confdefs.h >>conftest.$ac_ext
13355cat >>conftest.$ac_ext <<_ACEOF
13356/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013357
13358#include "confdefs.h"
13359#include <sys/file.h>
13360
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013361int
13362main ()
13363{
13364void* p = flock
13365 ;
13366 return 0;
13367}
13368_ACEOF
13369rm -f conftest.$ac_objext
13370if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13371 (eval $ac_compile) 2>&5
13372 ac_status=$?
13373 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13374 (exit $ac_status); } &&
13375 { ac_try='test -s conftest.$ac_objext'
13376 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13377 (eval $ac_try) 2>&5
13378 ac_status=$?
13379 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13380 (exit $ac_status); }; }; then
13381
13382cat >>confdefs.h <<\_ACEOF
13383#define HAVE_FLOCK 1
13384_ACEOF
13385
13386 echo "$as_me:$LINENO: result: yes" >&5
13387echo "${ECHO_T}yes" >&6
13388else
13389 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013390sed 's/^/| /' conftest.$ac_ext >&5
13391
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013392echo "$as_me:$LINENO: result: no" >&5
13393echo "${ECHO_T}no" >&6
13394
13395fi
13396rm -f conftest.$ac_objext conftest.$ac_ext
13397
13398echo "$as_me:$LINENO: checking for getpagesize" >&5
13399echo $ECHO_N "checking for getpagesize... $ECHO_C" >&6
13400cat >conftest.$ac_ext <<_ACEOF
13401#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013402/* confdefs.h. */
13403_ACEOF
13404cat confdefs.h >>conftest.$ac_ext
13405cat >>conftest.$ac_ext <<_ACEOF
13406/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013407
13408#include "confdefs.h"
13409#include <unistd.h>
13410
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013411int
13412main ()
13413{
13414void* p = getpagesize
13415 ;
13416 return 0;
13417}
13418_ACEOF
13419rm -f conftest.$ac_objext
13420if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13421 (eval $ac_compile) 2>&5
13422 ac_status=$?
13423 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13424 (exit $ac_status); } &&
13425 { ac_try='test -s conftest.$ac_objext'
13426 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13427 (eval $ac_try) 2>&5
13428 ac_status=$?
13429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13430 (exit $ac_status); }; }; then
13431
13432cat >>confdefs.h <<\_ACEOF
13433#define HAVE_GETPAGESIZE 1
13434_ACEOF
13435
13436 echo "$as_me:$LINENO: result: yes" >&5
13437echo "${ECHO_T}yes" >&6
13438else
13439 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013440sed 's/^/| /' conftest.$ac_ext >&5
13441
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000013442echo "$as_me:$LINENO: result: no" >&5
13443echo "${ECHO_T}no" >&6
13444
13445fi
13446rm -f conftest.$ac_objext conftest.$ac_ext
13447
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000013448for ac_prog in true
13449do
13450 # Extract the first word of "$ac_prog", so it can be a program name with args.
13451set dummy $ac_prog; ac_word=$2
13452echo "$as_me:$LINENO: checking for $ac_word" >&5
13453echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13454if test "${ac_cv_prog_TRUE+set}" = set; then
13455 echo $ECHO_N "(cached) $ECHO_C" >&6
13456else
13457 if test -n "$TRUE"; then
13458 ac_cv_prog_TRUE="$TRUE" # Let the user override the test.
13459else
13460as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13461for as_dir in $PATH
13462do
13463 IFS=$as_save_IFS
13464 test -z "$as_dir" && as_dir=.
13465 for ac_exec_ext in '' $ac_executable_extensions; do
13466 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13467 ac_cv_prog_TRUE="$ac_prog"
13468 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13469 break 2
13470 fi
13471done
13472done
13473
13474fi
13475fi
13476TRUE=$ac_cv_prog_TRUE
13477if test -n "$TRUE"; then
13478 echo "$as_me:$LINENO: result: $TRUE" >&5
13479echo "${ECHO_T}$TRUE" >&6
13480else
13481 echo "$as_me:$LINENO: result: no" >&5
13482echo "${ECHO_T}no" >&6
13483fi
13484
13485 test -n "$TRUE" && break
13486done
13487test -n "$TRUE" || TRUE="/bin/true"
13488
13489
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013490echo "$as_me:$LINENO: checking for inet_aton in -lc" >&5
13491echo $ECHO_N "checking for inet_aton in -lc... $ECHO_C" >&6
13492if test "${ac_cv_lib_c_inet_aton+set}" = set; then
13493 echo $ECHO_N "(cached) $ECHO_C" >&6
13494else
13495 ac_check_lib_save_LIBS=$LIBS
13496LIBS="-lc $LIBS"
13497cat >conftest.$ac_ext <<_ACEOF
13498#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013499/* confdefs.h. */
13500_ACEOF
13501cat confdefs.h >>conftest.$ac_ext
13502cat >>conftest.$ac_ext <<_ACEOF
13503/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013504
13505/* Override any gcc2 internal prototype to avoid an error. */
13506#ifdef __cplusplus
13507extern "C"
13508#endif
13509/* We use char because int might match the return type of a gcc2
13510 builtin and then its argument prototype would still apply. */
13511char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013512int
13513main ()
13514{
13515inet_aton ();
13516 ;
13517 return 0;
13518}
13519_ACEOF
13520rm -f conftest.$ac_objext conftest$ac_exeext
13521if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13522 (eval $ac_link) 2>&5
13523 ac_status=$?
13524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13525 (exit $ac_status); } &&
13526 { ac_try='test -s conftest$ac_exeext'
13527 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13528 (eval $ac_try) 2>&5
13529 ac_status=$?
13530 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13531 (exit $ac_status); }; }; then
13532 ac_cv_lib_c_inet_aton=yes
13533else
13534 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013535sed 's/^/| /' conftest.$ac_ext >&5
13536
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013537ac_cv_lib_c_inet_aton=no
13538fi
13539rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13540LIBS=$ac_check_lib_save_LIBS
13541fi
13542echo "$as_me:$LINENO: result: $ac_cv_lib_c_inet_aton" >&5
13543echo "${ECHO_T}$ac_cv_lib_c_inet_aton" >&6
13544if test $ac_cv_lib_c_inet_aton = yes; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000013545 $ac_cv_prog_TRUE
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013546else
13547
13548echo "$as_me:$LINENO: checking for inet_aton in -lresolv" >&5
13549echo $ECHO_N "checking for inet_aton in -lresolv... $ECHO_C" >&6
13550if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then
13551 echo $ECHO_N "(cached) $ECHO_C" >&6
13552else
13553 ac_check_lib_save_LIBS=$LIBS
13554LIBS="-lresolv $LIBS"
13555cat >conftest.$ac_ext <<_ACEOF
13556#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013557/* confdefs.h. */
13558_ACEOF
13559cat confdefs.h >>conftest.$ac_ext
13560cat >>conftest.$ac_ext <<_ACEOF
13561/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013562
13563/* Override any gcc2 internal prototype to avoid an error. */
13564#ifdef __cplusplus
13565extern "C"
13566#endif
13567/* We use char because int might match the return type of a gcc2
13568 builtin and then its argument prototype would still apply. */
13569char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013570int
13571main ()
13572{
13573inet_aton ();
13574 ;
13575 return 0;
13576}
13577_ACEOF
13578rm -f conftest.$ac_objext conftest$ac_exeext
13579if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13580 (eval $ac_link) 2>&5
13581 ac_status=$?
13582 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13583 (exit $ac_status); } &&
13584 { ac_try='test -s conftest$ac_exeext'
13585 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13586 (eval $ac_try) 2>&5
13587 ac_status=$?
13588 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13589 (exit $ac_status); }; }; then
13590 ac_cv_lib_resolv_inet_aton=yes
13591else
13592 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013593sed 's/^/| /' conftest.$ac_ext >&5
13594
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013595ac_cv_lib_resolv_inet_aton=no
13596fi
13597rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13598LIBS=$ac_check_lib_save_LIBS
13599fi
13600echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_inet_aton" >&5
13601echo "${ECHO_T}$ac_cv_lib_resolv_inet_aton" >&6
13602if test $ac_cv_lib_resolv_inet_aton = yes; then
13603 cat >>confdefs.h <<_ACEOF
13604#define HAVE_LIBRESOLV 1
13605_ACEOF
13606
13607 LIBS="-lresolv $LIBS"
13608
13609fi
13610
13611
13612fi
13613
13614
Martin v. Löwise9416172003-05-03 10:12:45 +000013615echo "$as_me:$LINENO: checking for hstrerror" >&5
13616echo $ECHO_N "checking for hstrerror... $ECHO_C" >&6
13617cat >conftest.$ac_ext <<_ACEOF
13618#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013619/* confdefs.h. */
13620_ACEOF
13621cat confdefs.h >>conftest.$ac_ext
13622cat >>conftest.$ac_ext <<_ACEOF
13623/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000013624
13625#include "confdefs.h"
13626#include <netdb.h>
13627
Martin v. Löwise9416172003-05-03 10:12:45 +000013628int
13629main ()
13630{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013631void* p = hstrerror; hstrerror(0)
Martin v. Löwise9416172003-05-03 10:12:45 +000013632 ;
13633 return 0;
13634}
13635_ACEOF
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013636rm -f conftest.$ac_objext conftest$ac_exeext
13637if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13638 (eval $ac_link) 2>&5
Martin v. Löwise9416172003-05-03 10:12:45 +000013639 ac_status=$?
13640 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13641 (exit $ac_status); } &&
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013642 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwise9416172003-05-03 10:12:45 +000013643 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13644 (eval $ac_try) 2>&5
13645 ac_status=$?
13646 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13647 (exit $ac_status); }; }; then
13648
13649cat >>confdefs.h <<\_ACEOF
13650#define HAVE_HSTRERROR 1
13651_ACEOF
13652
13653 echo "$as_me:$LINENO: result: yes" >&5
13654echo "${ECHO_T}yes" >&6
13655else
13656 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013657sed 's/^/| /' conftest.$ac_ext >&5
13658
Martin v. Löwise9416172003-05-03 10:12:45 +000013659echo "$as_me:$LINENO: result: no" >&5
13660echo "${ECHO_T}no" >&6
13661
13662fi
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013663rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000013664
13665echo "$as_me:$LINENO: checking for inet_aton" >&5
13666echo $ECHO_N "checking for inet_aton... $ECHO_C" >&6
13667cat >conftest.$ac_ext <<_ACEOF
13668#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013669/* confdefs.h. */
13670_ACEOF
13671cat confdefs.h >>conftest.$ac_ext
13672cat >>conftest.$ac_ext <<_ACEOF
13673/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000013674
13675#include "confdefs.h"
13676#include <sys/socket.h>
13677#include <netinet/in.h>
13678#include <arpa/inet.h>
13679
Martin v. Löwise9416172003-05-03 10:12:45 +000013680int
13681main ()
13682{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013683void* p = inet_aton;inet_aton(0,0)
Martin v. Löwise9416172003-05-03 10:12:45 +000013684 ;
13685 return 0;
13686}
13687_ACEOF
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013688rm -f conftest.$ac_objext conftest$ac_exeext
13689if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13690 (eval $ac_link) 2>&5
Martin v. Löwise9416172003-05-03 10:12:45 +000013691 ac_status=$?
13692 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13693 (exit $ac_status); } &&
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013694 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwise9416172003-05-03 10:12:45 +000013695 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13696 (eval $ac_try) 2>&5
13697 ac_status=$?
13698 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13699 (exit $ac_status); }; }; then
13700
13701cat >>confdefs.h <<\_ACEOF
13702#define HAVE_INET_ATON 1
13703_ACEOF
13704
13705 echo "$as_me:$LINENO: result: yes" >&5
13706echo "${ECHO_T}yes" >&6
13707else
13708 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013709sed 's/^/| /' conftest.$ac_ext >&5
13710
Martin v. Löwise9416172003-05-03 10:12:45 +000013711echo "$as_me:$LINENO: result: no" >&5
13712echo "${ECHO_T}no" >&6
13713
13714fi
Martin v. Löwis95c419b2003-05-03 12:10:48 +000013715rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000013716
13717echo "$as_me:$LINENO: checking for inet_pton" >&5
13718echo $ECHO_N "checking for inet_pton... $ECHO_C" >&6
13719cat >conftest.$ac_ext <<_ACEOF
13720#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013721/* confdefs.h. */
13722_ACEOF
13723cat confdefs.h >>conftest.$ac_ext
13724cat >>conftest.$ac_ext <<_ACEOF
13725/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000013726
13727#include "confdefs.h"
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000013728#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000013729#include <sys/socket.h>
13730#include <netinet/in.h>
13731#include <arpa/inet.h>
13732
Martin v. Löwise9416172003-05-03 10:12:45 +000013733int
13734main ()
13735{
13736void* p = inet_pton
13737 ;
13738 return 0;
13739}
13740_ACEOF
13741rm -f conftest.$ac_objext
13742if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13743 (eval $ac_compile) 2>&5
13744 ac_status=$?
13745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13746 (exit $ac_status); } &&
13747 { ac_try='test -s conftest.$ac_objext'
13748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13749 (eval $ac_try) 2>&5
13750 ac_status=$?
13751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13752 (exit $ac_status); }; }; then
13753
13754cat >>confdefs.h <<\_ACEOF
13755#define HAVE_INET_PTON 1
13756_ACEOF
13757
13758 echo "$as_me:$LINENO: result: yes" >&5
13759echo "${ECHO_T}yes" >&6
13760else
13761 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013762sed 's/^/| /' conftest.$ac_ext >&5
13763
Martin v. Löwise9416172003-05-03 10:12:45 +000013764echo "$as_me:$LINENO: result: no" >&5
13765echo "${ECHO_T}no" >&6
13766
13767fi
13768rm -f conftest.$ac_objext conftest.$ac_ext
13769
Martin v. Löwisd6640d42003-07-06 09:29:52 +000013770# On some systems, setgroups is in unistd.h, on others, in grp.h
Martin v. Löwisd5843682002-11-21 20:41:28 +000013771echo "$as_me:$LINENO: checking for setgroups" >&5
13772echo $ECHO_N "checking for setgroups... $ECHO_C" >&6
13773cat >conftest.$ac_ext <<_ACEOF
13774#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013775/* confdefs.h. */
13776_ACEOF
13777cat confdefs.h >>conftest.$ac_ext
13778cat >>conftest.$ac_ext <<_ACEOF
13779/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000013780
13781#include "confdefs.h"
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000013782#include <unistd.h>
Martin v. Löwisd6640d42003-07-06 09:29:52 +000013783#ifdef HAVE_GRP_H
13784#include <grp.h>
13785#endif
Martin v. Löwisd5843682002-11-21 20:41:28 +000013786
Martin v. Löwisd5843682002-11-21 20:41:28 +000013787int
13788main ()
13789{
13790void* p = setgroups
13791 ;
13792 return 0;
13793}
13794_ACEOF
13795rm -f conftest.$ac_objext
13796if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13797 (eval $ac_compile) 2>&5
13798 ac_status=$?
13799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13800 (exit $ac_status); } &&
13801 { ac_try='test -s conftest.$ac_objext'
13802 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13803 (eval $ac_try) 2>&5
13804 ac_status=$?
13805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13806 (exit $ac_status); }; }; then
13807
13808cat >>confdefs.h <<\_ACEOF
13809#define HAVE_SETGROUPS 1
13810_ACEOF
13811
13812 echo "$as_me:$LINENO: result: yes" >&5
13813echo "${ECHO_T}yes" >&6
13814else
13815 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013816sed 's/^/| /' conftest.$ac_ext >&5
13817
Martin v. Löwisd5843682002-11-21 20:41:28 +000013818echo "$as_me:$LINENO: result: no" >&5
13819echo "${ECHO_T}no" >&6
13820
13821fi
13822rm -f conftest.$ac_objext conftest.$ac_ext
13823
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013824# check for openpty and forkpty
13825
Martin v. Löwis11437992002-04-12 09:54:03 +000013826
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013827for ac_func in openpty
13828do
Martin v. Löwis11437992002-04-12 09:54:03 +000013829as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13830echo "$as_me:$LINENO: checking for $ac_func" >&5
13831echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13832if eval "test \"\${$as_ac_var+set}\" = set"; then
13833 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013834else
Martin v. Löwis11437992002-04-12 09:54:03 +000013835 cat >conftest.$ac_ext <<_ACEOF
13836#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013837/* confdefs.h. */
13838_ACEOF
13839cat confdefs.h >>conftest.$ac_ext
13840cat >>conftest.$ac_ext <<_ACEOF
13841/* end confdefs.h. */
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013842/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000013843 which can conflict with char $ac_func (); below.
13844 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13845 <limits.h> exists even on freestanding compilers. */
13846#ifdef __STDC__
13847# include <limits.h>
13848#else
13849# include <assert.h>
13850#endif
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013851/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013852#ifdef __cplusplus
13853extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013854{
Martin v. Löwis11437992002-04-12 09:54:03 +000013855#endif
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013856/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000013857 builtin and then its argument prototype would still apply. */
13858char $ac_func ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013859/* The GNU C library defines this for functions which it implements
13860 to always fail with ENOSYS. Some functions are actually named
13861 something starting with __ and the normal name is an alias. */
13862#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13863choke me
13864#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000013865char (*f) () = $ac_func;
13866#endif
13867#ifdef __cplusplus
13868}
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013869#endif
13870
Skip Montanarod8d39a02003-07-10 20:44:10 +000013871int
13872main ()
13873{
13874return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000013875 ;
13876 return 0;
13877}
13878_ACEOF
13879rm -f conftest.$ac_objext conftest$ac_exeext
13880if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13881 (eval $ac_link) 2>&5
13882 ac_status=$?
13883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13884 (exit $ac_status); } &&
13885 { ac_try='test -s conftest$ac_exeext'
13886 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13887 (eval $ac_try) 2>&5
13888 ac_status=$?
13889 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13890 (exit $ac_status); }; }; then
13891 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013892else
Martin v. Löwis11437992002-04-12 09:54:03 +000013893 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013894sed 's/^/| /' conftest.$ac_ext >&5
13895
Martin v. Löwis11437992002-04-12 09:54:03 +000013896eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013897fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013898rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013899fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013900echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13901echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13902if test `eval echo '${'$as_ac_var'}'` = yes; then
13903 cat >>confdefs.h <<_ACEOF
13904#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13905_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013906
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000013907else
Martin v. Löwis11437992002-04-12 09:54:03 +000013908 echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
13909echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
13910if test "${ac_cv_lib_util_openpty+set}" = set; then
13911 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000013912else
Martin v. Löwis11437992002-04-12 09:54:03 +000013913 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000013914LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000013915cat >conftest.$ac_ext <<_ACEOF
13916#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013917/* confdefs.h. */
13918_ACEOF
13919cat confdefs.h >>conftest.$ac_ext
13920cat >>conftest.$ac_ext <<_ACEOF
13921/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013922
Fred Drake8cef4cf2000-06-28 16:40:38 +000013923/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013924#ifdef __cplusplus
13925extern "C"
13926#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000013927/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000013928 builtin and then its argument prototype would still apply. */
13929char openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013930int
13931main ()
13932{
13933openpty ();
13934 ;
13935 return 0;
13936}
13937_ACEOF
13938rm -f conftest.$ac_objext conftest$ac_exeext
13939if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13940 (eval $ac_link) 2>&5
13941 ac_status=$?
13942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13943 (exit $ac_status); } &&
13944 { ac_try='test -s conftest$ac_exeext'
13945 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13946 (eval $ac_try) 2>&5
13947 ac_status=$?
13948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13949 (exit $ac_status); }; }; then
13950 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000013951else
Martin v. Löwis11437992002-04-12 09:54:03 +000013952 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000013953sed 's/^/| /' conftest.$ac_ext >&5
13954
Martin v. Löwis11437992002-04-12 09:54:03 +000013955ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000013956fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013957rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13958LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000013959fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013960echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
13961echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
13962if test $ac_cv_lib_util_openpty = yes; then
13963 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000013964#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013965_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000013966 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000013967fi
13968
13969fi
13970done
13971
Martin v. Löwis11437992002-04-12 09:54:03 +000013972
Fred Drake8cef4cf2000-06-28 16:40:38 +000013973for ac_func in forkpty
13974do
Martin v. Löwis11437992002-04-12 09:54:03 +000013975as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13976echo "$as_me:$LINENO: checking for $ac_func" >&5
13977echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13978if eval "test \"\${$as_ac_var+set}\" = set"; then
13979 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000013980else
Martin v. Löwis11437992002-04-12 09:54:03 +000013981 cat >conftest.$ac_ext <<_ACEOF
13982#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000013983/* confdefs.h. */
13984_ACEOF
13985cat confdefs.h >>conftest.$ac_ext
13986cat >>conftest.$ac_ext <<_ACEOF
13987/* end confdefs.h. */
Fred Drake8cef4cf2000-06-28 16:40:38 +000013988/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000013989 which can conflict with char $ac_func (); below.
13990 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13991 <limits.h> exists even on freestanding compilers. */
13992#ifdef __STDC__
13993# include <limits.h>
13994#else
13995# include <assert.h>
13996#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000013997/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013998#ifdef __cplusplus
13999extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014000{
Martin v. Löwis11437992002-04-12 09:54:03 +000014001#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000014002/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014003 builtin and then its argument prototype would still apply. */
14004char $ac_func ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000014005/* The GNU C library defines this for functions which it implements
14006 to always fail with ENOSYS. Some functions are actually named
14007 something starting with __ and the normal name is an alias. */
14008#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14009choke me
14010#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014011char (*f) () = $ac_func;
14012#endif
14013#ifdef __cplusplus
14014}
Fred Drake8cef4cf2000-06-28 16:40:38 +000014015#endif
14016
Skip Montanarod8d39a02003-07-10 20:44:10 +000014017int
14018main ()
14019{
14020return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014021 ;
14022 return 0;
14023}
14024_ACEOF
14025rm -f conftest.$ac_objext conftest$ac_exeext
14026if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14027 (eval $ac_link) 2>&5
14028 ac_status=$?
14029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14030 (exit $ac_status); } &&
14031 { ac_try='test -s conftest$ac_exeext'
14032 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14033 (eval $ac_try) 2>&5
14034 ac_status=$?
14035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14036 (exit $ac_status); }; }; then
14037 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014038else
Martin v. Löwis11437992002-04-12 09:54:03 +000014039 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014040sed 's/^/| /' conftest.$ac_ext >&5
14041
Martin v. Löwis11437992002-04-12 09:54:03 +000014042eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014043fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014044rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014045fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014046echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14047echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14048if test `eval echo '${'$as_ac_var'}'` = yes; then
14049 cat >>confdefs.h <<_ACEOF
14050#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14051_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000014052
Fred Drake8cef4cf2000-06-28 16:40:38 +000014053else
Martin v. Löwis11437992002-04-12 09:54:03 +000014054 echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
14055echo $ECHO_N "checking for forkpty in -lutil... $ECHO_C" >&6
14056if test "${ac_cv_lib_util_forkpty+set}" = set; then
14057 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000014058else
Martin v. Löwis11437992002-04-12 09:54:03 +000014059 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000014060LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014061cat >conftest.$ac_ext <<_ACEOF
14062#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014063/* confdefs.h. */
14064_ACEOF
14065cat confdefs.h >>conftest.$ac_ext
14066cat >>conftest.$ac_ext <<_ACEOF
14067/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014068
Fred Drake8cef4cf2000-06-28 16:40:38 +000014069/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014070#ifdef __cplusplus
14071extern "C"
14072#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000014073/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014074 builtin and then its argument prototype would still apply. */
14075char forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014076int
14077main ()
14078{
14079forkpty ();
14080 ;
14081 return 0;
14082}
14083_ACEOF
14084rm -f conftest.$ac_objext conftest$ac_exeext
14085if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14086 (eval $ac_link) 2>&5
14087 ac_status=$?
14088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14089 (exit $ac_status); } &&
14090 { ac_try='test -s conftest$ac_exeext'
14091 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14092 (eval $ac_try) 2>&5
14093 ac_status=$?
14094 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14095 (exit $ac_status); }; }; then
14096 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000014097else
Martin v. Löwis11437992002-04-12 09:54:03 +000014098 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014099sed 's/^/| /' conftest.$ac_ext >&5
14100
Martin v. Löwis11437992002-04-12 09:54:03 +000014101ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000014102fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014103rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14104LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000014105fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014106echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
14107echo "${ECHO_T}$ac_cv_lib_util_forkpty" >&6
14108if test $ac_cv_lib_util_forkpty = yes; then
14109 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000014110#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014111_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000014112 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000014113fi
14114
14115fi
14116done
14117
Jack Jansendd19cf82001-12-06 22:36:17 +000014118
Michael W. Hudson54241132001-12-07 15:38:26 +000014119# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000014120
14121
14122
14123
14124
14125
Fred Drake8cef4cf2000-06-28 16:40:38 +000014126for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
14127do
Martin v. Löwis11437992002-04-12 09:54:03 +000014128as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14129echo "$as_me:$LINENO: checking for $ac_func" >&5
14130echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14131if eval "test \"\${$as_ac_var+set}\" = set"; then
14132 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000014133else
Martin v. Löwis11437992002-04-12 09:54:03 +000014134 cat >conftest.$ac_ext <<_ACEOF
14135#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014136/* confdefs.h. */
14137_ACEOF
14138cat confdefs.h >>conftest.$ac_ext
14139cat >>conftest.$ac_ext <<_ACEOF
14140/* end confdefs.h. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000014141/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000014142 which can conflict with char $ac_func (); below.
14143 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14144 <limits.h> exists even on freestanding compilers. */
14145#ifdef __STDC__
14146# include <limits.h>
14147#else
14148# include <assert.h>
14149#endif
Guido van Rossumf98e2a71999-01-06 18:53:34 +000014150/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014151#ifdef __cplusplus
14152extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014153{
Martin v. Löwis11437992002-04-12 09:54:03 +000014154#endif
Guido van Rossumf98e2a71999-01-06 18:53:34 +000014155/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014156 builtin and then its argument prototype would still apply. */
14157char $ac_func ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000014158/* The GNU C library defines this for functions which it implements
14159 to always fail with ENOSYS. Some functions are actually named
14160 something starting with __ and the normal name is an alias. */
14161#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14162choke me
14163#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014164char (*f) () = $ac_func;
14165#endif
14166#ifdef __cplusplus
14167}
Guido van Rossumf98e2a71999-01-06 18:53:34 +000014168#endif
14169
Skip Montanarod8d39a02003-07-10 20:44:10 +000014170int
14171main ()
14172{
14173return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014174 ;
14175 return 0;
14176}
14177_ACEOF
14178rm -f conftest.$ac_objext conftest$ac_exeext
14179if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14180 (eval $ac_link) 2>&5
14181 ac_status=$?
14182 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14183 (exit $ac_status); } &&
14184 { ac_try='test -s conftest$ac_exeext'
14185 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14186 (eval $ac_try) 2>&5
14187 ac_status=$?
14188 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14189 (exit $ac_status); }; }; then
14190 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014191else
Martin v. Löwis11437992002-04-12 09:54:03 +000014192 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014193sed 's/^/| /' conftest.$ac_ext >&5
14194
Martin v. Löwis11437992002-04-12 09:54:03 +000014195eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014196fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014197rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014198fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014199echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14200echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14201if test `eval echo '${'$as_ac_var'}'` = yes; then
14202 cat >>confdefs.h <<_ACEOF
14203#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14204_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000014205
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014206fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000014207done
14208
Michael W. Hudson54241132001-12-07 15:38:26 +000014209
Martin v. Löwis11437992002-04-12 09:54:03 +000014210
14211
14212
14213
14214
Martin v. Löwis1142de32002-03-29 16:28:31 +000014215for ac_func in dup2 getcwd strdup strerror memmove
Thomas Wouters3a584202000-08-05 23:28:51 +000014216do
Martin v. Löwis11437992002-04-12 09:54:03 +000014217as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14218echo "$as_me:$LINENO: checking for $ac_func" >&5
14219echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14220if eval "test \"\${$as_ac_var+set}\" = set"; then
14221 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014222else
Martin v. Löwis11437992002-04-12 09:54:03 +000014223 cat >conftest.$ac_ext <<_ACEOF
14224#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014225/* confdefs.h. */
14226_ACEOF
14227cat confdefs.h >>conftest.$ac_ext
14228cat >>conftest.$ac_ext <<_ACEOF
14229/* end confdefs.h. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014230/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000014231 which can conflict with char $ac_func (); below.
14232 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14233 <limits.h> exists even on freestanding compilers. */
14234#ifdef __STDC__
14235# include <limits.h>
14236#else
14237# include <assert.h>
14238#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014239/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014240#ifdef __cplusplus
14241extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014242{
Martin v. Löwis11437992002-04-12 09:54:03 +000014243#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014244/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014245 builtin and then its argument prototype would still apply. */
14246char $ac_func ();
Guido van Rossum627b2d71993-12-24 10:39:16 +000014247/* The GNU C library defines this for functions which it implements
14248 to always fail with ENOSYS. Some functions are actually named
14249 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000014250#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000014251choke me
14252#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014253char (*f) () = $ac_func;
14254#endif
14255#ifdef __cplusplus
14256}
Guido van Rossum627b2d71993-12-24 10:39:16 +000014257#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014258
Skip Montanarod8d39a02003-07-10 20:44:10 +000014259int
14260main ()
14261{
14262return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014263 ;
14264 return 0;
14265}
14266_ACEOF
14267rm -f conftest.$ac_objext conftest$ac_exeext
14268if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14269 (eval $ac_link) 2>&5
14270 ac_status=$?
14271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14272 (exit $ac_status); } &&
14273 { ac_try='test -s conftest$ac_exeext'
14274 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14275 (eval $ac_try) 2>&5
14276 ac_status=$?
14277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14278 (exit $ac_status); }; }; then
14279 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000014280else
Martin v. Löwis11437992002-04-12 09:54:03 +000014281 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014282sed 's/^/| /' conftest.$ac_ext >&5
14283
Martin v. Löwis11437992002-04-12 09:54:03 +000014284eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000014285fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014286rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000014287fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014288echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14289echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14290if test `eval echo '${'$as_ac_var'}'` = yes; then
14291 cat >>confdefs.h <<_ACEOF
14292#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14293_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000014294
Martin v. Löwis1142de32002-03-29 16:28:31 +000014295else
Martin v. Löwis11437992002-04-12 09:54:03 +000014296 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Martin v. Löwis1142de32002-03-29 16:28:31 +000014297fi
14298done
14299
14300
Martin v. Löwis11437992002-04-12 09:54:03 +000014301
Martin v. Löwis1142de32002-03-29 16:28:31 +000014302for ac_func in getpgrp
14303do
Martin v. Löwis11437992002-04-12 09:54:03 +000014304as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14305echo "$as_me:$LINENO: checking for $ac_func" >&5
14306echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14307if eval "test \"\${$as_ac_var+set}\" = set"; then
14308 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000014309else
Martin v. Löwis11437992002-04-12 09:54:03 +000014310 cat >conftest.$ac_ext <<_ACEOF
14311#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014312/* confdefs.h. */
14313_ACEOF
14314cat confdefs.h >>conftest.$ac_ext
14315cat >>conftest.$ac_ext <<_ACEOF
14316/* end confdefs.h. */
Martin v. Löwis1142de32002-03-29 16:28:31 +000014317/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000014318 which can conflict with char $ac_func (); below.
14319 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14320 <limits.h> exists even on freestanding compilers. */
14321#ifdef __STDC__
14322# include <limits.h>
14323#else
14324# include <assert.h>
14325#endif
Martin v. Löwis1142de32002-03-29 16:28:31 +000014326/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014327#ifdef __cplusplus
14328extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014329{
Martin v. Löwis11437992002-04-12 09:54:03 +000014330#endif
Martin v. Löwis1142de32002-03-29 16:28:31 +000014331/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014332 builtin and then its argument prototype would still apply. */
14333char $ac_func ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000014334/* The GNU C library defines this for functions which it implements
14335 to always fail with ENOSYS. Some functions are actually named
14336 something starting with __ and the normal name is an alias. */
14337#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14338choke me
14339#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014340char (*f) () = $ac_func;
14341#endif
14342#ifdef __cplusplus
14343}
Martin v. Löwis1142de32002-03-29 16:28:31 +000014344#endif
14345
Skip Montanarod8d39a02003-07-10 20:44:10 +000014346int
14347main ()
14348{
14349return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014350 ;
14351 return 0;
14352}
14353_ACEOF
14354rm -f conftest.$ac_objext conftest$ac_exeext
14355if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14356 (eval $ac_link) 2>&5
14357 ac_status=$?
14358 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14359 (exit $ac_status); } &&
14360 { ac_try='test -s conftest$ac_exeext'
14361 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14362 (eval $ac_try) 2>&5
14363 ac_status=$?
14364 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14365 (exit $ac_status); }; }; then
14366 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014367else
Martin v. Löwis11437992002-04-12 09:54:03 +000014368 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014369sed 's/^/| /' conftest.$ac_ext >&5
14370
Martin v. Löwis11437992002-04-12 09:54:03 +000014371eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014372fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014373rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014374fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014375echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14376echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14377if test `eval echo '${'$as_ac_var'}'` = yes; then
14378 cat >>confdefs.h <<_ACEOF
14379#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14380_ACEOF
14381 cat >conftest.$ac_ext <<_ACEOF
14382#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014383/* confdefs.h. */
14384_ACEOF
14385cat confdefs.h >>conftest.$ac_ext
14386cat >>conftest.$ac_ext <<_ACEOF
14387/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014388#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014389int
14390main ()
14391{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014392getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000014393 ;
14394 return 0;
14395}
14396_ACEOF
14397rm -f conftest.$ac_objext
14398if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14399 (eval $ac_compile) 2>&5
14400 ac_status=$?
14401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14402 (exit $ac_status); } &&
14403 { ac_try='test -s conftest.$ac_objext'
14404 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14405 (eval $ac_try) 2>&5
14406 ac_status=$?
14407 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14408 (exit $ac_status); }; }; then
14409
14410cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014411#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014412_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014413
Martin v. Löwis11437992002-04-12 09:54:03 +000014414
Guido van Rossumf78abae1997-01-21 22:02:36 +000014415else
Martin v. Löwis11437992002-04-12 09:54:03 +000014416 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014417sed 's/^/| /' conftest.$ac_ext >&5
14418
Guido van Rossum627b2d71993-12-24 10:39:16 +000014419fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014420rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014421
Guido van Rossum627b2d71993-12-24 10:39:16 +000014422fi
Thomas Wouters3a584202000-08-05 23:28:51 +000014423done
Guido van Rossum627b2d71993-12-24 10:39:16 +000014424
Jack Jansen150753c2003-03-29 22:07:47 +000014425
14426for ac_func in setpgrp
14427do
14428as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14429echo "$as_me:$LINENO: checking for $ac_func" >&5
14430echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14431if eval "test \"\${$as_ac_var+set}\" = set"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014432 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014433else
Martin v. Löwis11437992002-04-12 09:54:03 +000014434 cat >conftest.$ac_ext <<_ACEOF
14435#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014436/* confdefs.h. */
14437_ACEOF
14438cat confdefs.h >>conftest.$ac_ext
14439cat >>conftest.$ac_ext <<_ACEOF
14440/* end confdefs.h. */
Jack Jansen150753c2003-03-29 22:07:47 +000014441/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000014442 which can conflict with char $ac_func (); below.
14443 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14444 <limits.h> exists even on freestanding compilers. */
14445#ifdef __STDC__
14446# include <limits.h>
14447#else
14448# include <assert.h>
14449#endif
Jack Jansen150753c2003-03-29 22:07:47 +000014450/* Override any gcc2 internal prototype to avoid an error. */
14451#ifdef __cplusplus
14452extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014453{
Martin v. Löwis11437992002-04-12 09:54:03 +000014454#endif
Jack Jansen150753c2003-03-29 22:07:47 +000014455/* We use char because int might match the return type of a gcc2
14456 builtin and then its argument prototype would still apply. */
14457char $ac_func ();
Jack Jansen150753c2003-03-29 22:07:47 +000014458/* The GNU C library defines this for functions which it implements
14459 to always fail with ENOSYS. Some functions are actually named
14460 something starting with __ and the normal name is an alias. */
14461#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14462choke me
14463#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014464char (*f) () = $ac_func;
14465#endif
14466#ifdef __cplusplus
14467}
Jack Jansen150753c2003-03-29 22:07:47 +000014468#endif
14469
Skip Montanarod8d39a02003-07-10 20:44:10 +000014470int
14471main ()
14472{
14473return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014474 ;
14475 return 0;
14476}
14477_ACEOF
Jack Jansen150753c2003-03-29 22:07:47 +000014478rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwis11437992002-04-12 09:54:03 +000014479if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14480 (eval $ac_link) 2>&5
14481 ac_status=$?
14482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jack Jansen150753c2003-03-29 22:07:47 +000014483 (exit $ac_status); } &&
14484 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwis11437992002-04-12 09:54:03 +000014485 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14486 (eval $ac_try) 2>&5
14487 ac_status=$?
14488 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14489 (exit $ac_status); }; }; then
Jack Jansen150753c2003-03-29 22:07:47 +000014490 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014491else
Jack Jansen150753c2003-03-29 22:07:47 +000014492 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014493sed 's/^/| /' conftest.$ac_ext >&5
14494
Jack Jansen150753c2003-03-29 22:07:47 +000014495eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014496fi
Jack Jansen150753c2003-03-29 22:07:47 +000014497rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014498fi
Jack Jansen150753c2003-03-29 22:07:47 +000014499echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14500echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14501if test `eval echo '${'$as_ac_var'}'` = yes; then
14502 cat >>confdefs.h <<_ACEOF
14503#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14504_ACEOF
14505 cat >conftest.$ac_ext <<_ACEOF
14506#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014507/* confdefs.h. */
14508_ACEOF
14509cat confdefs.h >>conftest.$ac_ext
14510cat >>conftest.$ac_ext <<_ACEOF
14511/* end confdefs.h. */
Jack Jansen150753c2003-03-29 22:07:47 +000014512#include <unistd.h>
Jack Jansen150753c2003-03-29 22:07:47 +000014513int
14514main ()
14515{
14516setpgrp(0,0);
14517 ;
14518 return 0;
14519}
14520_ACEOF
14521rm -f conftest.$ac_objext
14522if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14523 (eval $ac_compile) 2>&5
14524 ac_status=$?
14525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14526 (exit $ac_status); } &&
14527 { ac_try='test -s conftest.$ac_objext'
14528 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14529 (eval $ac_try) 2>&5
14530 ac_status=$?
14531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14532 (exit $ac_status); }; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014533
14534cat >>confdefs.h <<\_ACEOF
Jack Jansen150753c2003-03-29 22:07:47 +000014535#define SETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014536_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000014537
Jack Jansen150753c2003-03-29 22:07:47 +000014538
14539else
14540 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014541sed 's/^/| /' conftest.$ac_ext >&5
14542
Guido van Rossum8eee56f1994-10-20 22:18:37 +000014543fi
Jack Jansen150753c2003-03-29 22:07:47 +000014544rm -f conftest.$ac_objext conftest.$ac_ext
14545
14546fi
14547done
Guido van Rossum8eee56f1994-10-20 22:18:37 +000014548
Martin v. Löwis11437992002-04-12 09:54:03 +000014549
Thomas Wouters3a584202000-08-05 23:28:51 +000014550for ac_func in gettimeofday
14551do
Martin v. Löwis11437992002-04-12 09:54:03 +000014552as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14553echo "$as_me:$LINENO: checking for $ac_func" >&5
14554echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14555if eval "test \"\${$as_ac_var+set}\" = set"; then
14556 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014557else
Martin v. Löwis11437992002-04-12 09:54:03 +000014558 cat >conftest.$ac_ext <<_ACEOF
14559#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014560/* confdefs.h. */
14561_ACEOF
14562cat confdefs.h >>conftest.$ac_ext
14563cat >>conftest.$ac_ext <<_ACEOF
14564/* end confdefs.h. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014565/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000014566 which can conflict with char $ac_func (); below.
14567 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14568 <limits.h> exists even on freestanding compilers. */
14569#ifdef __STDC__
14570# include <limits.h>
14571#else
14572# include <assert.h>
14573#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014574/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014575#ifdef __cplusplus
14576extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014577{
Martin v. Löwis11437992002-04-12 09:54:03 +000014578#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014579/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014580 builtin and then its argument prototype would still apply. */
14581char $ac_func ();
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014582/* The GNU C library defines this for functions which it implements
14583 to always fail with ENOSYS. Some functions are actually named
14584 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000014585#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014586choke me
14587#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014588char (*f) () = $ac_func;
14589#endif
14590#ifdef __cplusplus
14591}
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014592#endif
14593
Skip Montanarod8d39a02003-07-10 20:44:10 +000014594int
14595main ()
14596{
14597return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014598 ;
14599 return 0;
14600}
14601_ACEOF
14602rm -f conftest.$ac_objext conftest$ac_exeext
14603if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14604 (eval $ac_link) 2>&5
14605 ac_status=$?
14606 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14607 (exit $ac_status); } &&
14608 { ac_try='test -s conftest$ac_exeext'
14609 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14610 (eval $ac_try) 2>&5
14611 ac_status=$?
14612 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14613 (exit $ac_status); }; }; then
14614 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014615else
Martin v. Löwis11437992002-04-12 09:54:03 +000014616 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014617sed 's/^/| /' conftest.$ac_ext >&5
14618
Martin v. Löwis11437992002-04-12 09:54:03 +000014619eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014620fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014621rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014622fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014623echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14624echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14625if test `eval echo '${'$as_ac_var'}'` = yes; then
14626 cat >>confdefs.h <<_ACEOF
14627#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14628_ACEOF
14629 cat >conftest.$ac_ext <<_ACEOF
14630#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014631/* confdefs.h. */
14632_ACEOF
14633cat confdefs.h >>conftest.$ac_ext
14634cat >>conftest.$ac_ext <<_ACEOF
14635/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000014636#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014637int
14638main ()
14639{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014640gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000014641 ;
14642 return 0;
14643}
14644_ACEOF
14645rm -f conftest.$ac_objext
14646if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14647 (eval $ac_compile) 2>&5
14648 ac_status=$?
14649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14650 (exit $ac_status); } &&
14651 { ac_try='test -s conftest.$ac_objext'
14652 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14653 (eval $ac_try) 2>&5
14654 ac_status=$?
14655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14656 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000014657 :
14658else
Martin v. Löwis11437992002-04-12 09:54:03 +000014659 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014660sed 's/^/| /' conftest.$ac_ext >&5
14661
Martin v. Löwis11437992002-04-12 09:54:03 +000014662
14663cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014664#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014665_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014666
Martin v. Löwis11437992002-04-12 09:54:03 +000014667
Guido van Rossum627b2d71993-12-24 10:39:16 +000014668fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014669rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014670
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014671fi
Thomas Wouters3a584202000-08-05 23:28:51 +000014672done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014673
Michael W. Hudson54241132001-12-07 15:38:26 +000014674
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014675echo "$as_me:$LINENO: checking for major" >&5
14676echo $ECHO_N "checking for major... $ECHO_C" >&6
14677cat >conftest.$ac_ext <<_ACEOF
14678#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014679/* confdefs.h. */
14680_ACEOF
14681cat confdefs.h >>conftest.$ac_ext
14682cat >>conftest.$ac_ext <<_ACEOF
14683/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014684
Neal Norwitz6eb37f02003-02-23 23:28:15 +000014685#if defined(MAJOR_IN_MKDEV)
14686#include <sys/mkdev.h>
14687#elif defined(MAJOR_IN_SYSMACROS)
14688#include <sys/sysmacros.h>
14689#else
14690#include <sys/types.h>
14691#endif
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014692
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014693int
14694main ()
14695{
14696
14697 makedev(major(0),minor(0));
14698
14699 ;
14700 return 0;
14701}
14702_ACEOF
Martin v. Löwise3271202002-11-07 07:42:30 +000014703rm -f conftest.$ac_objext conftest$ac_exeext
14704if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14705 (eval $ac_link) 2>&5
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014706 ac_status=$?
14707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14708 (exit $ac_status); } &&
Martin v. Löwise3271202002-11-07 07:42:30 +000014709 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014710 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14711 (eval $ac_try) 2>&5
14712 ac_status=$?
14713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14714 (exit $ac_status); }; }; then
14715
14716
14717cat >>confdefs.h <<\_ACEOF
14718#define HAVE_DEVICE_MACROS 1
14719_ACEOF
14720
14721 echo "$as_me:$LINENO: result: yes" >&5
14722echo "${ECHO_T}yes" >&6
14723
14724else
14725 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014726sed 's/^/| /' conftest.$ac_ext >&5
14727
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000014728
14729 echo "$as_me:$LINENO: result: no" >&5
14730echo "${ECHO_T}no" >&6
14731
14732fi
Martin v. Löwise3271202002-11-07 07:42:30 +000014733rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014734
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014735# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000014736# for [no]getaddrinfo in netdb.h.
14737echo "$as_me:$LINENO: checking for getaddrinfo" >&5
14738echo $ECHO_N "checking for getaddrinfo... $ECHO_C" >&6
14739cat >conftest.$ac_ext <<_ACEOF
14740#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014741/* confdefs.h. */
14742_ACEOF
14743cat confdefs.h >>conftest.$ac_ext
14744cat >>conftest.$ac_ext <<_ACEOF
14745/* end confdefs.h. */
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014746
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000014747#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014748#include <sys/socket.h>
14749#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000014750#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014751
Martin v. Löwis11437992002-04-12 09:54:03 +000014752int
14753main ()
14754{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014755
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014756getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014757
Martin v. Löwis11437992002-04-12 09:54:03 +000014758 ;
14759 return 0;
14760}
14761_ACEOF
14762rm -f conftest.$ac_objext conftest$ac_exeext
14763if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14764 (eval $ac_link) 2>&5
14765 ac_status=$?
14766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14767 (exit $ac_status); } &&
14768 { ac_try='test -s conftest$ac_exeext'
14769 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14770 (eval $ac_try) 2>&5
14771 ac_status=$?
14772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14773 (exit $ac_status); }; }; then
14774
14775echo "$as_me:$LINENO: result: yes" >&5
14776echo "${ECHO_T}yes" >&6
14777echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
14778echo $ECHO_N "checking getaddrinfo bug... $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014779if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014780 echo "$as_me:$LINENO: result: buggy" >&5
14781echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014782buggygetaddrinfo=yes
14783else
Martin v. Löwis11437992002-04-12 09:54:03 +000014784 cat >conftest.$ac_ext <<_ACEOF
14785#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014786/* confdefs.h. */
14787_ACEOF
14788cat confdefs.h >>conftest.$ac_ext
14789cat >>conftest.$ac_ext <<_ACEOF
14790/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014791
14792#include <sys/types.h>
14793#include <netdb.h>
14794#include <string.h>
14795#include <sys/socket.h>
14796#include <netinet/in.h>
14797
14798main()
14799{
14800 int passive, gaierr, inet4 = 0, inet6 = 0;
14801 struct addrinfo hints, *ai, *aitop;
14802 char straddr[INET6_ADDRSTRLEN], strport[16];
14803
14804 for (passive = 0; passive <= 1; passive++) {
14805 memset(&hints, 0, sizeof(hints));
14806 hints.ai_family = AF_UNSPEC;
14807 hints.ai_flags = passive ? AI_PASSIVE : 0;
14808 hints.ai_socktype = SOCK_STREAM;
14809 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
14810 (void)gai_strerror(gaierr);
14811 goto bad;
14812 }
14813 for (ai = aitop; ai; ai = ai->ai_next) {
14814 if (ai->ai_addr == NULL ||
14815 ai->ai_addrlen == 0 ||
14816 getnameinfo(ai->ai_addr, ai->ai_addrlen,
14817 straddr, sizeof(straddr), strport, sizeof(strport),
14818 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
14819 goto bad;
14820 }
14821 switch (ai->ai_family) {
14822 case AF_INET:
14823 if (strcmp(strport, "54321") != 0) {
14824 goto bad;
14825 }
14826 if (passive) {
14827 if (strcmp(straddr, "0.0.0.0") != 0) {
14828 goto bad;
14829 }
14830 } else {
14831 if (strcmp(straddr, "127.0.0.1") != 0) {
14832 goto bad;
14833 }
14834 }
14835 inet4++;
14836 break;
14837 case AF_INET6:
14838 if (strcmp(strport, "54321") != 0) {
14839 goto bad;
14840 }
14841 if (passive) {
14842 if (strcmp(straddr, "::") != 0) {
14843 goto bad;
14844 }
14845 } else {
14846 if (strcmp(straddr, "::1") != 0) {
14847 goto bad;
14848 }
14849 }
14850 inet6++;
14851 break;
14852 case AF_UNSPEC:
14853 goto bad;
14854 break;
14855 default:
14856 /* another family support? */
14857 break;
14858 }
14859 }
14860 }
14861
14862 if (!(inet4 == 0 || inet4 == 2))
14863 goto bad;
14864 if (!(inet6 == 0 || inet6 == 2))
14865 goto bad;
14866
14867 if (aitop)
14868 freeaddrinfo(aitop);
14869 exit(0);
14870
14871 bad:
14872 if (aitop)
14873 freeaddrinfo(aitop);
14874 exit(1);
14875}
14876
Martin v. Löwis11437992002-04-12 09:54:03 +000014877_ACEOF
14878rm -f conftest$ac_exeext
14879if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14880 (eval $ac_link) 2>&5
14881 ac_status=$?
14882 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14883 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14884 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14885 (eval $ac_try) 2>&5
14886 ac_status=$?
14887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14888 (exit $ac_status); }; }; then
14889 echo "$as_me:$LINENO: result: good" >&5
14890echo "${ECHO_T}good" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014891buggygetaddrinfo=no
14892else
Martin v. Löwis11437992002-04-12 09:54:03 +000014893 echo "$as_me: program exited with status $ac_status" >&5
14894echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014895sed 's/^/| /' conftest.$ac_ext >&5
14896
Martin v. Löwis11437992002-04-12 09:54:03 +000014897( exit $ac_status )
14898echo "$as_me:$LINENO: result: buggy" >&5
14899echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014900buggygetaddrinfo=yes
14901fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000014902rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014903fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014904else
Martin v. Löwis11437992002-04-12 09:54:03 +000014905 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014906sed 's/^/| /' conftest.$ac_ext >&5
14907
Martin v. Löwis11437992002-04-12 09:54:03 +000014908
14909echo "$as_me:$LINENO: result: no" >&5
14910echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014911buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014912
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014913fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014914rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014915
14916if test "$buggygetaddrinfo" = "yes"; then
14917 if test "$ipv6" = "yes"; then
14918 echo 'Fatal: You must get working getaddrinfo() function.'
14919 echo ' or you can specify "--disable-ipv6"'.
14920 exit 1
14921 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014922else
Martin v. Löwis11437992002-04-12 09:54:03 +000014923
14924cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014925#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014926_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000014927
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014928fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014929
Jack Jansen9a66b6d2001-08-08 13:56:14 +000014930for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014931do
Martin v. Löwis11437992002-04-12 09:54:03 +000014932as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14933echo "$as_me:$LINENO: checking for $ac_func" >&5
14934echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14935if eval "test \"\${$as_ac_var+set}\" = set"; then
14936 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014937else
Martin v. Löwis11437992002-04-12 09:54:03 +000014938 cat >conftest.$ac_ext <<_ACEOF
14939#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014940/* confdefs.h. */
14941_ACEOF
14942cat confdefs.h >>conftest.$ac_ext
14943cat >>conftest.$ac_ext <<_ACEOF
14944/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014945/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000014946 which can conflict with char $ac_func (); below.
14947 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14948 <limits.h> exists even on freestanding compilers. */
14949#ifdef __STDC__
14950# include <limits.h>
14951#else
14952# include <assert.h>
14953#endif
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014954/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014955#ifdef __cplusplus
14956extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000014957{
Martin v. Löwis11437992002-04-12 09:54:03 +000014958#endif
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014959/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014960 builtin and then its argument prototype would still apply. */
14961char $ac_func ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014962/* The GNU C library defines this for functions which it implements
14963 to always fail with ENOSYS. Some functions are actually named
14964 something starting with __ and the normal name is an alias. */
14965#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14966choke me
14967#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000014968char (*f) () = $ac_func;
14969#endif
14970#ifdef __cplusplus
14971}
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014972#endif
14973
Skip Montanarod8d39a02003-07-10 20:44:10 +000014974int
14975main ()
14976{
14977return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000014978 ;
14979 return 0;
14980}
14981_ACEOF
14982rm -f conftest.$ac_objext conftest$ac_exeext
14983if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14984 (eval $ac_link) 2>&5
14985 ac_status=$?
14986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14987 (exit $ac_status); } &&
14988 { ac_try='test -s conftest$ac_exeext'
14989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14990 (eval $ac_try) 2>&5
14991 ac_status=$?
14992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14993 (exit $ac_status); }; }; then
14994 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014995else
Martin v. Löwis11437992002-04-12 09:54:03 +000014996 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000014997sed 's/^/| /' conftest.$ac_ext >&5
14998
Martin v. Löwis11437992002-04-12 09:54:03 +000014999eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000015000fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015001rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015002fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015003echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15004echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15005if test `eval echo '${'$as_ac_var'}'` = yes; then
15006 cat >>confdefs.h <<_ACEOF
15007#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15008_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015009
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015010fi
15011done
15012
Michael W. Hudson54241132001-12-07 15:38:26 +000015013
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015014# checks for structures
Martin v. Löwis11437992002-04-12 09:54:03 +000015015echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
15016echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
15017if test "${ac_cv_header_time+set}" = set; then
15018 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015019else
Martin v. Löwis11437992002-04-12 09:54:03 +000015020 cat >conftest.$ac_ext <<_ACEOF
15021#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015022/* confdefs.h. */
15023_ACEOF
15024cat confdefs.h >>conftest.$ac_ext
15025cat >>conftest.$ac_ext <<_ACEOF
15026/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015027#include <sys/types.h>
15028#include <sys/time.h>
15029#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015030
Martin v. Löwis11437992002-04-12 09:54:03 +000015031int
15032main ()
15033{
15034if ((struct tm *) 0)
15035return 0;
15036 ;
15037 return 0;
15038}
15039_ACEOF
15040rm -f conftest.$ac_objext
15041if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15042 (eval $ac_compile) 2>&5
15043 ac_status=$?
15044 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15045 (exit $ac_status); } &&
15046 { ac_try='test -s conftest.$ac_objext'
15047 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15048 (eval $ac_try) 2>&5
15049 ac_status=$?
15050 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15051 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015052 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000015053else
Martin v. Löwis11437992002-04-12 09:54:03 +000015054 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015055sed 's/^/| /' conftest.$ac_ext >&5
15056
Martin v. Löwis11437992002-04-12 09:54:03 +000015057ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015058fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015059rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015060fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015061echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
15062echo "${ECHO_T}$ac_cv_header_time" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000015063if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015064
15065cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015066#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015067_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015068
15069fi
15070
Martin v. Löwis11437992002-04-12 09:54:03 +000015071echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
15072echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
15073if test "${ac_cv_struct_tm+set}" = set; then
15074 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015075else
Martin v. Löwis11437992002-04-12 09:54:03 +000015076 cat >conftest.$ac_ext <<_ACEOF
15077#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015078/* confdefs.h. */
15079_ACEOF
15080cat confdefs.h >>conftest.$ac_ext
15081cat >>conftest.$ac_ext <<_ACEOF
15082/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015083#include <sys/types.h>
15084#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015085
Martin v. Löwis11437992002-04-12 09:54:03 +000015086int
15087main ()
15088{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015089struct tm *tp; tp->tm_sec;
Martin v. Löwis11437992002-04-12 09:54:03 +000015090 ;
15091 return 0;
15092}
15093_ACEOF
15094rm -f conftest.$ac_objext
15095if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15096 (eval $ac_compile) 2>&5
15097 ac_status=$?
15098 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15099 (exit $ac_status); } &&
15100 { ac_try='test -s conftest.$ac_objext'
15101 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15102 (eval $ac_try) 2>&5
15103 ac_status=$?
15104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15105 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015106 ac_cv_struct_tm=time.h
15107else
Martin v. Löwis11437992002-04-12 09:54:03 +000015108 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015109sed 's/^/| /' conftest.$ac_ext >&5
15110
Martin v. Löwis11437992002-04-12 09:54:03 +000015111ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015112fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015113rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015114fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015115echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
15116echo "${ECHO_T}$ac_cv_struct_tm" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000015117if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015118
15119cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015120#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015121_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015122
15123fi
15124
Martin v. Löwis11437992002-04-12 09:54:03 +000015125echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
15126echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
15127if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
15128 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015129else
Martin v. Löwis11437992002-04-12 09:54:03 +000015130 cat >conftest.$ac_ext <<_ACEOF
15131#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015132/* confdefs.h. */
15133_ACEOF
15134cat confdefs.h >>conftest.$ac_ext
15135cat >>conftest.$ac_ext <<_ACEOF
15136/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015137#include <sys/types.h>
15138#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000015139
15140
Martin v. Löwis11437992002-04-12 09:54:03 +000015141int
15142main ()
15143{
15144static struct tm ac_aggr;
15145if (ac_aggr.tm_zone)
15146return 0;
15147 ;
15148 return 0;
15149}
15150_ACEOF
15151rm -f conftest.$ac_objext
15152if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15153 (eval $ac_compile) 2>&5
15154 ac_status=$?
15155 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15156 (exit $ac_status); } &&
15157 { ac_try='test -s conftest.$ac_objext'
15158 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15159 (eval $ac_try) 2>&5
15160 ac_status=$?
15161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15162 (exit $ac_status); }; }; then
15163 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000015164else
Martin v. Löwis11437992002-04-12 09:54:03 +000015165 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015166sed 's/^/| /' conftest.$ac_ext >&5
15167
15168cat >conftest.$ac_ext <<_ACEOF
15169#line $LINENO "configure"
15170/* confdefs.h. */
15171_ACEOF
15172cat confdefs.h >>conftest.$ac_ext
15173cat >>conftest.$ac_ext <<_ACEOF
15174/* end confdefs.h. */
15175#include <sys/types.h>
15176#include <$ac_cv_struct_tm>
15177
15178
15179int
15180main ()
15181{
15182static struct tm ac_aggr;
15183if (sizeof ac_aggr.tm_zone)
15184return 0;
15185 ;
15186 return 0;
15187}
15188_ACEOF
15189rm -f conftest.$ac_objext
15190if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15191 (eval $ac_compile) 2>&5
15192 ac_status=$?
15193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15194 (exit $ac_status); } &&
15195 { ac_try='test -s conftest.$ac_objext'
15196 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15197 (eval $ac_try) 2>&5
15198 ac_status=$?
15199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15200 (exit $ac_status); }; }; then
15201 ac_cv_member_struct_tm_tm_zone=yes
15202else
15203 echo "$as_me: failed program was:" >&5
15204sed 's/^/| /' conftest.$ac_ext >&5
15205
Martin v. Löwis11437992002-04-12 09:54:03 +000015206ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000015207fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015208rm -f conftest.$ac_objext conftest.$ac_ext
15209fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000015210rm -f conftest.$ac_objext conftest.$ac_ext
15211fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015212echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
15213echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
15214if test $ac_cv_member_struct_tm_tm_zone = yes; then
15215
15216cat >>confdefs.h <<_ACEOF
15217#define HAVE_STRUCT_TM_TM_ZONE 1
15218_ACEOF
15219
15220
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015221fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015222
Martin v. Löwis11437992002-04-12 09:54:03 +000015223if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15224
15225cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015226#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015227_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015228
15229else
Martin v. Löwis11437992002-04-12 09:54:03 +000015230 echo "$as_me:$LINENO: checking for tzname" >&5
15231echo $ECHO_N "checking for tzname... $ECHO_C" >&6
15232if test "${ac_cv_var_tzname+set}" = set; then
15233 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015234else
Martin v. Löwis11437992002-04-12 09:54:03 +000015235 cat >conftest.$ac_ext <<_ACEOF
15236#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015237/* confdefs.h. */
15238_ACEOF
15239cat confdefs.h >>conftest.$ac_ext
15240cat >>conftest.$ac_ext <<_ACEOF
15241/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000015242#include <time.h>
15243#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015244extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000015245#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015246
Martin v. Löwis11437992002-04-12 09:54:03 +000015247int
15248main ()
15249{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015250atoi(*tzname);
Martin v. Löwis11437992002-04-12 09:54:03 +000015251 ;
15252 return 0;
15253}
15254_ACEOF
15255rm -f conftest.$ac_objext conftest$ac_exeext
15256if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15257 (eval $ac_link) 2>&5
15258 ac_status=$?
15259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15260 (exit $ac_status); } &&
15261 { ac_try='test -s conftest$ac_exeext'
15262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15263 (eval $ac_try) 2>&5
15264 ac_status=$?
15265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15266 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015267 ac_cv_var_tzname=yes
15268else
Martin v. Löwis11437992002-04-12 09:54:03 +000015269 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015270sed 's/^/| /' conftest.$ac_ext >&5
15271
Martin v. Löwis11437992002-04-12 09:54:03 +000015272ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015273fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015274rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000015275fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015276echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
15277echo "${ECHO_T}$ac_cv_var_tzname" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000015278 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015279
15280cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015281#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015282_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000015283
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015284 fi
15285fi
15286
Martin v. Löwis11437992002-04-12 09:54:03 +000015287echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
15288echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6
15289if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
15290 echo $ECHO_N "(cached) $ECHO_C" >&6
15291else
15292 cat >conftest.$ac_ext <<_ACEOF
15293#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015294/* confdefs.h. */
15295_ACEOF
15296cat confdefs.h >>conftest.$ac_ext
15297cat >>conftest.$ac_ext <<_ACEOF
15298/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015299$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000015300int
15301main ()
15302{
15303static struct stat ac_aggr;
15304if (ac_aggr.st_rdev)
15305return 0;
15306 ;
15307 return 0;
15308}
15309_ACEOF
15310rm -f conftest.$ac_objext
15311if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15312 (eval $ac_compile) 2>&5
15313 ac_status=$?
15314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15315 (exit $ac_status); } &&
15316 { ac_try='test -s conftest.$ac_objext'
15317 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15318 (eval $ac_try) 2>&5
15319 ac_status=$?
15320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15321 (exit $ac_status); }; }; then
15322 ac_cv_member_struct_stat_st_rdev=yes
15323else
15324 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015325sed 's/^/| /' conftest.$ac_ext >&5
15326
15327cat >conftest.$ac_ext <<_ACEOF
15328#line $LINENO "configure"
15329/* confdefs.h. */
15330_ACEOF
15331cat confdefs.h >>conftest.$ac_ext
15332cat >>conftest.$ac_ext <<_ACEOF
15333/* end confdefs.h. */
15334$ac_includes_default
15335int
15336main ()
15337{
15338static struct stat ac_aggr;
15339if (sizeof ac_aggr.st_rdev)
15340return 0;
15341 ;
15342 return 0;
15343}
15344_ACEOF
15345rm -f conftest.$ac_objext
15346if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15347 (eval $ac_compile) 2>&5
15348 ac_status=$?
15349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15350 (exit $ac_status); } &&
15351 { ac_try='test -s conftest.$ac_objext'
15352 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15353 (eval $ac_try) 2>&5
15354 ac_status=$?
15355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15356 (exit $ac_status); }; }; then
15357 ac_cv_member_struct_stat_st_rdev=yes
15358else
15359 echo "$as_me: failed program was:" >&5
15360sed 's/^/| /' conftest.$ac_ext >&5
15361
Martin v. Löwis11437992002-04-12 09:54:03 +000015362ac_cv_member_struct_stat_st_rdev=no
15363fi
15364rm -f conftest.$ac_objext conftest.$ac_ext
15365fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000015366rm -f conftest.$ac_objext conftest.$ac_ext
15367fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015368echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
15369echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6
15370if test $ac_cv_member_struct_stat_st_rdev = yes; then
15371
15372cat >>confdefs.h <<_ACEOF
15373#define HAVE_STRUCT_STAT_ST_RDEV 1
15374_ACEOF
15375
15376
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015377fi
15378
Martin v. Löwis11437992002-04-12 09:54:03 +000015379echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
15380echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
15381if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
15382 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015383else
Martin v. Löwis11437992002-04-12 09:54:03 +000015384 cat >conftest.$ac_ext <<_ACEOF
15385#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015386/* confdefs.h. */
15387_ACEOF
15388cat confdefs.h >>conftest.$ac_ext
15389cat >>conftest.$ac_ext <<_ACEOF
15390/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015391$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000015392int
15393main ()
15394{
15395static struct stat ac_aggr;
15396if (ac_aggr.st_blksize)
15397return 0;
15398 ;
15399 return 0;
15400}
15401_ACEOF
15402rm -f conftest.$ac_objext
15403if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15404 (eval $ac_compile) 2>&5
15405 ac_status=$?
15406 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15407 (exit $ac_status); } &&
15408 { ac_try='test -s conftest.$ac_objext'
15409 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15410 (eval $ac_try) 2>&5
15411 ac_status=$?
15412 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15413 (exit $ac_status); }; }; then
15414 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000015415else
Martin v. Löwis11437992002-04-12 09:54:03 +000015416 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015417sed 's/^/| /' conftest.$ac_ext >&5
15418
15419cat >conftest.$ac_ext <<_ACEOF
15420#line $LINENO "configure"
15421/* confdefs.h. */
15422_ACEOF
15423cat confdefs.h >>conftest.$ac_ext
15424cat >>conftest.$ac_ext <<_ACEOF
15425/* end confdefs.h. */
15426$ac_includes_default
15427int
15428main ()
15429{
15430static struct stat ac_aggr;
15431if (sizeof ac_aggr.st_blksize)
15432return 0;
15433 ;
15434 return 0;
15435}
15436_ACEOF
15437rm -f conftest.$ac_objext
15438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15439 (eval $ac_compile) 2>&5
15440 ac_status=$?
15441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15442 (exit $ac_status); } &&
15443 { ac_try='test -s conftest.$ac_objext'
15444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15445 (eval $ac_try) 2>&5
15446 ac_status=$?
15447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15448 (exit $ac_status); }; }; then
15449 ac_cv_member_struct_stat_st_blksize=yes
15450else
15451 echo "$as_me: failed program was:" >&5
15452sed 's/^/| /' conftest.$ac_ext >&5
15453
Martin v. Löwis11437992002-04-12 09:54:03 +000015454ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000015455fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015456rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015457fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000015458rm -f conftest.$ac_objext conftest.$ac_ext
15459fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015460echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
15461echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
15462if test $ac_cv_member_struct_stat_st_blksize = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000015463
Martin v. Löwis11437992002-04-12 09:54:03 +000015464cat >>confdefs.h <<_ACEOF
15465#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
15466_ACEOF
15467
15468
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015469fi
15470
Martin v. Löwis11437992002-04-12 09:54:03 +000015471echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
15472echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6
15473if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
15474 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015475else
Martin v. Löwis11437992002-04-12 09:54:03 +000015476 cat >conftest.$ac_ext <<_ACEOF
15477#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015478/* confdefs.h. */
15479_ACEOF
15480cat confdefs.h >>conftest.$ac_ext
15481cat >>conftest.$ac_ext <<_ACEOF
15482/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015483$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000015484int
15485main ()
15486{
15487static struct stat ac_aggr;
15488if (ac_aggr.st_blocks)
15489return 0;
15490 ;
15491 return 0;
15492}
15493_ACEOF
15494rm -f conftest.$ac_objext
15495if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15496 (eval $ac_compile) 2>&5
15497 ac_status=$?
15498 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15499 (exit $ac_status); } &&
15500 { ac_try='test -s conftest.$ac_objext'
15501 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15502 (eval $ac_try) 2>&5
15503 ac_status=$?
15504 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15505 (exit $ac_status); }; }; then
15506 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000015507else
Martin v. Löwis11437992002-04-12 09:54:03 +000015508 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015509sed 's/^/| /' conftest.$ac_ext >&5
15510
15511cat >conftest.$ac_ext <<_ACEOF
15512#line $LINENO "configure"
15513/* confdefs.h. */
15514_ACEOF
15515cat confdefs.h >>conftest.$ac_ext
15516cat >>conftest.$ac_ext <<_ACEOF
15517/* end confdefs.h. */
15518$ac_includes_default
15519int
15520main ()
15521{
15522static struct stat ac_aggr;
15523if (sizeof ac_aggr.st_blocks)
15524return 0;
15525 ;
15526 return 0;
15527}
15528_ACEOF
15529rm -f conftest.$ac_objext
15530if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15531 (eval $ac_compile) 2>&5
15532 ac_status=$?
15533 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15534 (exit $ac_status); } &&
15535 { ac_try='test -s conftest.$ac_objext'
15536 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15537 (eval $ac_try) 2>&5
15538 ac_status=$?
15539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15540 (exit $ac_status); }; }; then
15541 ac_cv_member_struct_stat_st_blocks=yes
15542else
15543 echo "$as_me: failed program was:" >&5
15544sed 's/^/| /' conftest.$ac_ext >&5
15545
Martin v. Löwis11437992002-04-12 09:54:03 +000015546ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000015547fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015548rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015549fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000015550rm -f conftest.$ac_objext conftest.$ac_ext
15551fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015552echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
15553echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6
15554if test $ac_cv_member_struct_stat_st_blocks = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000015555
Martin v. Löwis11437992002-04-12 09:54:03 +000015556cat >>confdefs.h <<_ACEOF
15557#define HAVE_STRUCT_STAT_ST_BLOCKS 1
15558_ACEOF
15559
15560
15561cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015562#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015563_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015564
15565else
Martin v. Löwis11437992002-04-12 09:54:03 +000015566 LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000015567fi
15568
Michael W. Hudson54241132001-12-07 15:38:26 +000015569
Martin v. Löwis11437992002-04-12 09:54:03 +000015570
15571echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
15572echo $ECHO_N "checking for time.h that defines altzone... $ECHO_C" >&6
15573if test "${ac_cv_header_time_altzone+set}" = set; then
15574 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015575else
Martin v. Löwis11437992002-04-12 09:54:03 +000015576 cat >conftest.$ac_ext <<_ACEOF
15577#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015578/* confdefs.h. */
15579_ACEOF
15580cat confdefs.h >>conftest.$ac_ext
15581cat >>conftest.$ac_ext <<_ACEOF
15582/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000015583#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015584int
15585main ()
15586{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015587return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000015588 ;
15589 return 0;
15590}
15591_ACEOF
15592rm -f conftest.$ac_objext
15593if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15594 (eval $ac_compile) 2>&5
15595 ac_status=$?
15596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15597 (exit $ac_status); } &&
15598 { ac_try='test -s conftest.$ac_objext'
15599 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15600 (eval $ac_try) 2>&5
15601 ac_status=$?
15602 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15603 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015604 ac_cv_header_time_altzone=yes
15605else
Martin v. Löwis11437992002-04-12 09:54:03 +000015606 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015607sed 's/^/| /' conftest.$ac_ext >&5
15608
Martin v. Löwis11437992002-04-12 09:54:03 +000015609ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +000015610fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015611rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015612fi
15613
Martin v. Löwis11437992002-04-12 09:54:03 +000015614echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
15615echo "${ECHO_T}$ac_cv_header_time_altzone" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015616if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015617
15618cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015619#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015620_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015621
15622fi
15623
Guido van Rossumda88dad1995-01-26 00:46:29 +000015624was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +000015625echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
15626echo $ECHO_N "checking whether sys/select.h and sys/time.h may both be included... $ECHO_C" >&6
15627cat >conftest.$ac_ext <<_ACEOF
15628#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015629/* confdefs.h. */
15630_ACEOF
15631cat confdefs.h >>conftest.$ac_ext
15632cat >>conftest.$ac_ext <<_ACEOF
15633/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000015634
15635#include <sys/types.h>
15636#include <sys/select.h>
15637#include <sys/time.h>
15638
Martin v. Löwis11437992002-04-12 09:54:03 +000015639int
15640main ()
15641{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015642;
Martin v. Löwis11437992002-04-12 09:54:03 +000015643 ;
15644 return 0;
15645}
15646_ACEOF
15647rm -f conftest.$ac_objext
15648if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15649 (eval $ac_compile) 2>&5
15650 ac_status=$?
15651 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15652 (exit $ac_status); } &&
15653 { ac_try='test -s conftest.$ac_objext'
15654 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15655 (eval $ac_try) 2>&5
15656 ac_status=$?
15657 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15658 (exit $ac_status); }; }; then
15659
15660
15661cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015662#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015663_ACEOF
15664
Martin v. Löwisc45929e2002-04-06 10:10:49 +000015665 was_it_defined=yes
15666
Guido van Rossumf78abae1997-01-21 22:02:36 +000015667else
Martin v. Löwis11437992002-04-12 09:54:03 +000015668 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015669sed 's/^/| /' conftest.$ac_ext >&5
15670
Guido van Rossum7f43da71994-08-01 12:15:30 +000015671fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015672rm -f conftest.$ac_objext conftest.$ac_ext
15673echo "$as_me:$LINENO: result: $was_it_defined" >&5
15674echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000015675
Martin v. Löwis11437992002-04-12 09:54:03 +000015676echo "$as_me:$LINENO: checking for addrinfo" >&5
15677echo $ECHO_N "checking for addrinfo... $ECHO_C" >&6
15678if test "${ac_cv_struct_addrinfo+set}" = set; then
15679 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015680else
Martin v. Löwis11437992002-04-12 09:54:03 +000015681 cat >conftest.$ac_ext <<_ACEOF
15682#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015683/* confdefs.h. */
15684_ACEOF
15685cat confdefs.h >>conftest.$ac_ext
15686cat >>conftest.$ac_ext <<_ACEOF
15687/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015688
15689# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015690int
15691main ()
15692{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015693struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000015694 ;
15695 return 0;
15696}
15697_ACEOF
15698rm -f conftest.$ac_objext
15699if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15700 (eval $ac_compile) 2>&5
15701 ac_status=$?
15702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15703 (exit $ac_status); } &&
15704 { ac_try='test -s conftest.$ac_objext'
15705 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15706 (eval $ac_try) 2>&5
15707 ac_status=$?
15708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15709 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015710 ac_cv_struct_addrinfo=yes
15711else
Martin v. Löwis11437992002-04-12 09:54:03 +000015712 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015713sed 's/^/| /' conftest.$ac_ext >&5
15714
Martin v. Löwis11437992002-04-12 09:54:03 +000015715ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015716fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015717rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015718fi
15719
Martin v. Löwis11437992002-04-12 09:54:03 +000015720echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
15721echo "${ECHO_T}$ac_cv_struct_addrinfo" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015722if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015723
15724cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015725#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015726_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015727
15728fi
15729
Martin v. Löwis11437992002-04-12 09:54:03 +000015730echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
15731echo $ECHO_N "checking for sockaddr_storage... $ECHO_C" >&6
15732if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
15733 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015734else
Martin v. Löwis11437992002-04-12 09:54:03 +000015735 cat >conftest.$ac_ext <<_ACEOF
15736#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015737/* confdefs.h. */
15738_ACEOF
15739cat confdefs.h >>conftest.$ac_ext
15740cat >>conftest.$ac_ext <<_ACEOF
15741/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015742
15743# include <sys/types.h>
15744# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015745int
15746main ()
15747{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015748struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000015749 ;
15750 return 0;
15751}
15752_ACEOF
15753rm -f conftest.$ac_objext
15754if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15755 (eval $ac_compile) 2>&5
15756 ac_status=$?
15757 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15758 (exit $ac_status); } &&
15759 { ac_try='test -s conftest.$ac_objext'
15760 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15761 (eval $ac_try) 2>&5
15762 ac_status=$?
15763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15764 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015765 ac_cv_struct_sockaddr_storage=yes
15766else
Martin v. Löwis11437992002-04-12 09:54:03 +000015767 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015768sed 's/^/| /' conftest.$ac_ext >&5
15769
Martin v. Löwis11437992002-04-12 09:54:03 +000015770ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015771fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015772rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015773fi
15774
Martin v. Löwis11437992002-04-12 09:54:03 +000015775echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
15776echo "${ECHO_T}$ac_cv_struct_sockaddr_storage" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015777if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015778
15779cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015780#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015781_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000015782
15783fi
15784
Guido van Rossum627b2d71993-12-24 10:39:16 +000015785# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000015786
Michael W. Hudson54241132001-12-07 15:38:26 +000015787
Martin v. Löwis11437992002-04-12 09:54:03 +000015788echo "$as_me:$LINENO: checking whether char is unsigned" >&5
15789echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
15790if test "${ac_cv_c_char_unsigned+set}" = set; then
15791 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000015792else
Martin v. Löwis11437992002-04-12 09:54:03 +000015793 cat >conftest.$ac_ext <<_ACEOF
15794#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015795/* confdefs.h. */
15796_ACEOF
15797cat confdefs.h >>conftest.$ac_ext
15798cat >>conftest.$ac_ext <<_ACEOF
15799/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015800$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000015801int
15802main ()
15803{
15804static int test_array [1 - 2 * !(((char) -1) < 0)];
15805test_array [0] = 0
15806
15807 ;
15808 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000015809}
Martin v. Löwis11437992002-04-12 09:54:03 +000015810_ACEOF
15811rm -f conftest.$ac_objext
15812if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15813 (eval $ac_compile) 2>&5
15814 ac_status=$?
15815 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15816 (exit $ac_status); } &&
15817 { ac_try='test -s conftest.$ac_objext'
15818 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15819 (eval $ac_try) 2>&5
15820 ac_status=$?
15821 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15822 (exit $ac_status); }; }; then
Michael W. Hudson54241132001-12-07 15:38:26 +000015823 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000015824else
15825 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015826sed 's/^/| /' conftest.$ac_ext >&5
15827
Martin v. Löwis11437992002-04-12 09:54:03 +000015828ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015829fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015830rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015831fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015832echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
15833echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015834if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015835 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015836#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015837_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015838
15839fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000015840
Martin v. Löwis11437992002-04-12 09:54:03 +000015841echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
15842echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
15843if test "${ac_cv_c_const+set}" = set; then
15844 echo $ECHO_N "(cached) $ECHO_C" >&6
15845else
15846 cat >conftest.$ac_ext <<_ACEOF
15847#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015848/* confdefs.h. */
15849_ACEOF
15850cat confdefs.h >>conftest.$ac_ext
15851cat >>conftest.$ac_ext <<_ACEOF
15852/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015853
Martin v. Löwis11437992002-04-12 09:54:03 +000015854int
15855main ()
15856{
15857/* FIXME: Include the comments suggested by Paul. */
15858#ifndef __cplusplus
15859 /* Ultrix mips cc rejects this. */
15860 typedef int charset[2];
15861 const charset x;
15862 /* SunOS 4.1.1 cc rejects this. */
15863 char const *const *ccp;
15864 char **p;
15865 /* NEC SVR4.0.2 mips cc rejects this. */
15866 struct point {int x, y;};
15867 static struct point const zero = {0,0};
15868 /* AIX XL C 1.02.0.0 rejects this.
15869 It does not let you subtract one const X* pointer from another in
15870 an arm of an if-expression whose if-part is not a constant
15871 expression */
15872 const char *g = "string";
15873 ccp = &g + (g ? g-g : 0);
15874 /* HPUX 7.0 cc rejects these. */
15875 ++ccp;
15876 p = (char**) ccp;
15877 ccp = (char const *const *) p;
15878 { /* SCO 3.2v4 cc rejects this. */
15879 char *t;
15880 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015881
Martin v. Löwis11437992002-04-12 09:54:03 +000015882 *t++ = 0;
15883 }
15884 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
15885 int x[] = {25, 17};
15886 const int *foo = &x[0];
15887 ++foo;
15888 }
15889 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
15890 typedef const int *iptr;
15891 iptr p = 0;
15892 ++p;
15893 }
15894 { /* AIX XL C 1.02.0.0 rejects this saying
15895 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
15896 struct s { int j; const int *ap[3]; };
15897 struct s *b; b->j = 5;
15898 }
15899 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
15900 const int foo = 10;
15901 }
15902#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000015903
Martin v. Löwis11437992002-04-12 09:54:03 +000015904 ;
15905 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000015906}
Martin v. Löwis11437992002-04-12 09:54:03 +000015907_ACEOF
15908rm -f conftest.$ac_objext
15909if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15910 (eval $ac_compile) 2>&5
15911 ac_status=$?
15912 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15913 (exit $ac_status); } &&
15914 { ac_try='test -s conftest.$ac_objext'
15915 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15916 (eval $ac_try) 2>&5
15917 ac_status=$?
15918 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15919 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015920 ac_cv_c_const=yes
15921else
Martin v. Löwis11437992002-04-12 09:54:03 +000015922 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015923sed 's/^/| /' conftest.$ac_ext >&5
15924
Martin v. Löwis11437992002-04-12 09:54:03 +000015925ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015926fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015927rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015928fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015929echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
15930echo "${ECHO_T}$ac_cv_c_const" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015931if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015932
15933cat >>confdefs.h <<\_ACEOF
15934#define const
15935_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015936
15937fi
15938
Michael W. Hudson54241132001-12-07 15:38:26 +000015939
Guido van Rossumda88dad1995-01-26 00:46:29 +000015940works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000015941echo "$as_me:$LINENO: checking for working volatile" >&5
15942echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
15943cat >conftest.$ac_ext <<_ACEOF
15944#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015945/* confdefs.h. */
15946_ACEOF
15947cat confdefs.h >>conftest.$ac_ext
15948cat >>conftest.$ac_ext <<_ACEOF
15949/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000015950
Martin v. Löwis11437992002-04-12 09:54:03 +000015951int
15952main ()
15953{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015954volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000015955 ;
15956 return 0;
15957}
15958_ACEOF
15959rm -f conftest.$ac_objext
15960if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15961 (eval $ac_compile) 2>&5
15962 ac_status=$?
15963 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15964 (exit $ac_status); } &&
15965 { ac_try='test -s conftest.$ac_objext'
15966 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15967 (eval $ac_try) 2>&5
15968 ac_status=$?
15969 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15970 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000015971 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000015972else
Martin v. Löwis11437992002-04-12 09:54:03 +000015973 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000015974sed 's/^/| /' conftest.$ac_ext >&5
15975
Martin v. Löwis11437992002-04-12 09:54:03 +000015976
15977cat >>confdefs.h <<\_ACEOF
15978#define volatile
15979_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000015980
Martin v. Löwisc45929e2002-04-06 10:10:49 +000015981
Guido van Rossum627b2d71993-12-24 10:39:16 +000015982fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015983rm -f conftest.$ac_objext conftest.$ac_ext
15984echo "$as_me:$LINENO: result: $works" >&5
15985echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000015986
Guido van Rossumda88dad1995-01-26 00:46:29 +000015987works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000015988echo "$as_me:$LINENO: checking for working signed char" >&5
15989echo $ECHO_N "checking for working signed char... $ECHO_C" >&6
15990cat >conftest.$ac_ext <<_ACEOF
15991#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000015992/* confdefs.h. */
15993_ACEOF
15994cat confdefs.h >>conftest.$ac_ext
15995cat >>conftest.$ac_ext <<_ACEOF
15996/* end confdefs.h. */
Guido van Rossumdabb11b1994-10-11 15:04:27 +000015997
Martin v. Löwis11437992002-04-12 09:54:03 +000015998int
15999main ()
16000{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016001signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000016002 ;
16003 return 0;
16004}
16005_ACEOF
16006rm -f conftest.$ac_objext
16007if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16008 (eval $ac_compile) 2>&5
16009 ac_status=$?
16010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16011 (exit $ac_status); } &&
16012 { ac_try='test -s conftest.$ac_objext'
16013 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16014 (eval $ac_try) 2>&5
16015 ac_status=$?
16016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16017 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000016018 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000016019else
Martin v. Löwis11437992002-04-12 09:54:03 +000016020 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016021sed 's/^/| /' conftest.$ac_ext >&5
16022
Martin v. Löwis11437992002-04-12 09:54:03 +000016023
16024cat >>confdefs.h <<\_ACEOF
16025#define signed
16026_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000016027
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016028
Guido van Rossum7f43da71994-08-01 12:15:30 +000016029fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016030rm -f conftest.$ac_objext conftest.$ac_ext
16031echo "$as_me:$LINENO: result: $works" >&5
16032echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000016033
Guido van Rossumda88dad1995-01-26 00:46:29 +000016034have_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000016035echo "$as_me:$LINENO: checking for prototypes" >&5
16036echo $ECHO_N "checking for prototypes... $ECHO_C" >&6
16037cat >conftest.$ac_ext <<_ACEOF
16038#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016039/* confdefs.h. */
16040_ACEOF
16041cat confdefs.h >>conftest.$ac_ext
16042cat >>conftest.$ac_ext <<_ACEOF
16043/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000016044int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016045int
16046main ()
16047{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016048return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000016049 ;
16050 return 0;
16051}
16052_ACEOF
16053rm -f conftest.$ac_objext
16054if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16055 (eval $ac_compile) 2>&5
16056 ac_status=$?
16057 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16058 (exit $ac_status); } &&
16059 { ac_try='test -s conftest.$ac_objext'
16060 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16061 (eval $ac_try) 2>&5
16062 ac_status=$?
16063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16064 (exit $ac_status); }; }; then
16065
16066
16067cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016068#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016069_ACEOF
16070
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016071 have_prototypes=yes
16072
Guido van Rossumf78abae1997-01-21 22:02:36 +000016073else
Martin v. Löwis11437992002-04-12 09:54:03 +000016074 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016075sed 's/^/| /' conftest.$ac_ext >&5
16076
Guido van Rossum7f43da71994-08-01 12:15:30 +000016077fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016078rm -f conftest.$ac_objext conftest.$ac_ext
16079echo "$as_me:$LINENO: result: $have_prototypes" >&5
16080echo "${ECHO_T}$have_prototypes" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016081
Guido van Rossumda88dad1995-01-26 00:46:29 +000016082works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000016083echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
16084echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6
16085cat >conftest.$ac_ext <<_ACEOF
16086#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016087/* confdefs.h. */
16088_ACEOF
16089cat confdefs.h >>conftest.$ac_ext
16090cat >>conftest.$ac_ext <<_ACEOF
16091/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000016092
16093#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000016094int foo(int x, ...) {
16095 va_list va;
16096 va_start(va, x);
16097 va_arg(va, int);
16098 va_arg(va, char *);
16099 va_arg(va, double);
16100 return 0;
16101}
Guido van Rossum7f43da71994-08-01 12:15:30 +000016102
Martin v. Löwis11437992002-04-12 09:54:03 +000016103int
16104main ()
16105{
Guido van Rossum90eea071996-08-30 20:58:57 +000016106return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000016107 ;
16108 return 0;
16109}
16110_ACEOF
16111rm -f conftest.$ac_objext
16112if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16113 (eval $ac_compile) 2>&5
16114 ac_status=$?
16115 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16116 (exit $ac_status); } &&
16117 { ac_try='test -s conftest.$ac_objext'
16118 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16119 (eval $ac_try) 2>&5
16120 ac_status=$?
16121 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16122 (exit $ac_status); }; }; then
16123
16124
16125cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016126#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016127_ACEOF
16128
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016129 works=yes
16130
Guido van Rossumf78abae1997-01-21 22:02:36 +000016131else
Martin v. Löwis11437992002-04-12 09:54:03 +000016132 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016133sed 's/^/| /' conftest.$ac_ext >&5
16134
Guido van Rossum627b2d71993-12-24 10:39:16 +000016135fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016136rm -f conftest.$ac_objext conftest.$ac_ext
16137echo "$as_me:$LINENO: result: $works" >&5
16138echo "${ECHO_T}$works" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016139
Guido van Rossumda88dad1995-01-26 00:46:29 +000016140if test "$have_prototypes" = yes; then
16141bad_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000016142echo "$as_me:$LINENO: checking for bad exec* prototypes" >&5
16143echo $ECHO_N "checking for bad exec* prototypes... $ECHO_C" >&6
16144cat >conftest.$ac_ext <<_ACEOF
16145#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016146/* confdefs.h. */
16147_ACEOF
16148cat confdefs.h >>conftest.$ac_ext
16149cat >>conftest.$ac_ext <<_ACEOF
16150/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000016151#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016152int
16153main ()
16154{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016155char **t;execve("@",t,t);
Martin v. Löwis11437992002-04-12 09:54:03 +000016156 ;
16157 return 0;
16158}
16159_ACEOF
16160rm -f conftest.$ac_objext
16161if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16162 (eval $ac_compile) 2>&5
16163 ac_status=$?
16164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16165 (exit $ac_status); } &&
16166 { ac_try='test -s conftest.$ac_objext'
16167 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16168 (eval $ac_try) 2>&5
16169 ac_status=$?
16170 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16171 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000016172 :
16173else
Martin v. Löwis11437992002-04-12 09:54:03 +000016174 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016175sed 's/^/| /' conftest.$ac_ext >&5
16176
Martin v. Löwis11437992002-04-12 09:54:03 +000016177
16178cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016179#define BAD_EXEC_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016180_ACEOF
16181
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016182 bad_prototypes=yes
16183
Guido van Rossum627b2d71993-12-24 10:39:16 +000016184fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016185rm -f conftest.$ac_objext conftest.$ac_ext
16186echo "$as_me:$LINENO: result: $bad_prototypes" >&5
16187echo "${ECHO_T}$bad_prototypes" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000016188fi
16189
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016190# check if sockaddr has sa_len member
Martin v. Löwis11437992002-04-12 09:54:03 +000016191echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
16192echo $ECHO_N "checking if sockaddr has sa_len member... $ECHO_C" >&6
16193cat >conftest.$ac_ext <<_ACEOF
16194#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016195/* confdefs.h. */
16196_ACEOF
16197cat confdefs.h >>conftest.$ac_ext
16198cat >>conftest.$ac_ext <<_ACEOF
16199/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016200#include <sys/types.h>
16201#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016202int
16203main ()
16204{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016205struct sockaddr x;
16206x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000016207 ;
16208 return 0;
16209}
16210_ACEOF
16211rm -f conftest.$ac_objext
16212if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16213 (eval $ac_compile) 2>&5
16214 ac_status=$?
16215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16216 (exit $ac_status); } &&
16217 { ac_try='test -s conftest.$ac_objext'
16218 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16219 (eval $ac_try) 2>&5
16220 ac_status=$?
16221 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16222 (exit $ac_status); }; }; then
16223 echo "$as_me:$LINENO: result: yes" >&5
16224echo "${ECHO_T}yes" >&6
16225
16226cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016227#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016228_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016229
16230else
Martin v. Löwis11437992002-04-12 09:54:03 +000016231 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016232sed 's/^/| /' conftest.$ac_ext >&5
16233
Martin v. Löwis11437992002-04-12 09:54:03 +000016234echo "$as_me:$LINENO: result: no" >&5
16235echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016236fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016237rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000016238
Guido van Rossumda88dad1995-01-26 00:46:29 +000016239va_list_is_array=no
Martin v. Löwis11437992002-04-12 09:54:03 +000016240echo "$as_me:$LINENO: checking whether va_list is an array" >&5
16241echo $ECHO_N "checking whether va_list is an array... $ECHO_C" >&6
16242cat >conftest.$ac_ext <<_ACEOF
16243#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016244/* confdefs.h. */
16245_ACEOF
16246cat confdefs.h >>conftest.$ac_ext
16247cat >>conftest.$ac_ext <<_ACEOF
16248/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016249
16250#ifdef HAVE_STDARG_PROTOTYPES
16251#include <stdarg.h>
16252#else
16253#include <varargs.h>
16254#endif
16255
Martin v. Löwis11437992002-04-12 09:54:03 +000016256int
16257main ()
16258{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016259va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000016260 ;
16261 return 0;
16262}
16263_ACEOF
16264rm -f conftest.$ac_objext
16265if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16266 (eval $ac_compile) 2>&5
16267 ac_status=$?
16268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16269 (exit $ac_status); } &&
16270 { ac_try='test -s conftest.$ac_objext'
16271 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16272 (eval $ac_try) 2>&5
16273 ac_status=$?
16274 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16275 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016276 :
16277else
Martin v. Löwis11437992002-04-12 09:54:03 +000016278 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016279sed 's/^/| /' conftest.$ac_ext >&5
16280
Martin v. Löwis11437992002-04-12 09:54:03 +000016281
16282
16283cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016284#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016285_ACEOF
16286
Guido van Rossumda88dad1995-01-26 00:46:29 +000016287 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000016288
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016289fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016290rm -f conftest.$ac_objext conftest.$ac_ext
16291echo "$as_me:$LINENO: result: $va_list_is_array" >&5
16292echo "${ECHO_T}$va_list_is_array" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016293
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016294# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000016295
16296
16297
16298echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
16299echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
16300if test "${ac_cv_func_gethostbyname_r+set}" = set; then
16301 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016302else
Martin v. Löwis11437992002-04-12 09:54:03 +000016303 cat >conftest.$ac_ext <<_ACEOF
16304#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016305/* confdefs.h. */
16306_ACEOF
16307cat confdefs.h >>conftest.$ac_ext
16308cat >>conftest.$ac_ext <<_ACEOF
16309/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016310/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000016311 which can conflict with char gethostbyname_r (); below.
16312 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16313 <limits.h> exists even on freestanding compilers. */
16314#ifdef __STDC__
16315# include <limits.h>
16316#else
16317# include <assert.h>
16318#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016319/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016320#ifdef __cplusplus
16321extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016322{
Martin v. Löwis11437992002-04-12 09:54:03 +000016323#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016324/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016325 builtin and then its argument prototype would still apply. */
16326char gethostbyname_r ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016327/* The GNU C library defines this for functions which it implements
16328 to always fail with ENOSYS. Some functions are actually named
16329 something starting with __ and the normal name is an alias. */
16330#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
16331choke me
16332#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000016333char (*f) () = gethostbyname_r;
16334#endif
16335#ifdef __cplusplus
16336}
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016337#endif
16338
Skip Montanarod8d39a02003-07-10 20:44:10 +000016339int
16340main ()
16341{
16342return f != gethostbyname_r;
Martin v. Löwis11437992002-04-12 09:54:03 +000016343 ;
16344 return 0;
16345}
16346_ACEOF
16347rm -f conftest.$ac_objext conftest$ac_exeext
16348if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16349 (eval $ac_link) 2>&5
16350 ac_status=$?
16351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16352 (exit $ac_status); } &&
16353 { ac_try='test -s conftest$ac_exeext'
16354 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16355 (eval $ac_try) 2>&5
16356 ac_status=$?
16357 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16358 (exit $ac_status); }; }; then
16359 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016360else
Martin v. Löwis11437992002-04-12 09:54:03 +000016361 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016362sed 's/^/| /' conftest.$ac_ext >&5
16363
Martin v. Löwis11437992002-04-12 09:54:03 +000016364ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016365fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016366rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016367fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016368echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
16369echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
16370if test $ac_cv_func_gethostbyname_r = yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016371
Martin v. Löwis11437992002-04-12 09:54:03 +000016372 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016373#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016374_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016375
Martin v. Löwis11437992002-04-12 09:54:03 +000016376 echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
16377echo $ECHO_N "checking gethostbyname_r with 6 args... $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016378 OLD_CFLAGS=$CFLAGS
16379 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016380 cat >conftest.$ac_ext <<_ACEOF
16381#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016382/* confdefs.h. */
16383_ACEOF
16384cat confdefs.h >>conftest.$ac_ext
16385cat >>conftest.$ac_ext <<_ACEOF
16386/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016387
16388# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016389
Martin v. Löwis11437992002-04-12 09:54:03 +000016390int
16391main ()
16392{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016393
16394 char *name;
16395 struct hostent *he, *res;
16396 char buffer[2048];
16397 int buflen = 2048;
16398 int h_errnop;
16399
16400 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000016401
16402 ;
16403 return 0;
16404}
16405_ACEOF
16406rm -f conftest.$ac_objext
16407if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16408 (eval $ac_compile) 2>&5
16409 ac_status=$?
16410 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16411 (exit $ac_status); } &&
16412 { ac_try='test -s conftest.$ac_objext'
16413 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16414 (eval $ac_try) 2>&5
16415 ac_status=$?
16416 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16417 (exit $ac_status); }; }; then
16418
16419 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016420#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016421_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016422
Martin v. Löwis11437992002-04-12 09:54:03 +000016423
16424cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016425#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016426_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016427
Martin v. Löwis11437992002-04-12 09:54:03 +000016428 echo "$as_me:$LINENO: result: yes" >&5
16429echo "${ECHO_T}yes" >&6
16430
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016431else
Martin v. Löwis11437992002-04-12 09:54:03 +000016432 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016433sed 's/^/| /' conftest.$ac_ext >&5
16434
Martin v. Löwis11437992002-04-12 09:54:03 +000016435
16436 echo "$as_me:$LINENO: result: no" >&5
16437echo "${ECHO_T}no" >&6
16438 echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
16439echo $ECHO_N "checking gethostbyname_r with 5 args... $ECHO_C" >&6
16440 cat >conftest.$ac_ext <<_ACEOF
16441#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016442/* confdefs.h. */
16443_ACEOF
16444cat confdefs.h >>conftest.$ac_ext
16445cat >>conftest.$ac_ext <<_ACEOF
16446/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016447
16448# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016449
Martin v. Löwis11437992002-04-12 09:54:03 +000016450int
16451main ()
16452{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016453
16454 char *name;
16455 struct hostent *he;
16456 char buffer[2048];
16457 int buflen = 2048;
16458 int h_errnop;
16459
16460 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000016461
16462 ;
16463 return 0;
16464}
16465_ACEOF
16466rm -f conftest.$ac_objext
16467if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16468 (eval $ac_compile) 2>&5
16469 ac_status=$?
16470 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16471 (exit $ac_status); } &&
16472 { ac_try='test -s conftest.$ac_objext'
16473 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16474 (eval $ac_try) 2>&5
16475 ac_status=$?
16476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16477 (exit $ac_status); }; }; then
16478
16479 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016480#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016481_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016482
Martin v. Löwis11437992002-04-12 09:54:03 +000016483
16484cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016485#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016486_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016487
Martin v. Löwis11437992002-04-12 09:54:03 +000016488 echo "$as_me:$LINENO: result: yes" >&5
16489echo "${ECHO_T}yes" >&6
16490
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016491else
Martin v. Löwis11437992002-04-12 09:54:03 +000016492 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016493sed 's/^/| /' conftest.$ac_ext >&5
16494
Martin v. Löwis11437992002-04-12 09:54:03 +000016495
16496 echo "$as_me:$LINENO: result: no" >&5
16497echo "${ECHO_T}no" >&6
16498 echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
16499echo $ECHO_N "checking gethostbyname_r with 3 args... $ECHO_C" >&6
16500 cat >conftest.$ac_ext <<_ACEOF
16501#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016502/* confdefs.h. */
16503_ACEOF
16504cat confdefs.h >>conftest.$ac_ext
16505cat >>conftest.$ac_ext <<_ACEOF
16506/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016507
16508# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016509
Martin v. Löwis11437992002-04-12 09:54:03 +000016510int
16511main ()
16512{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016513
16514 char *name;
16515 struct hostent *he;
16516 struct hostent_data data;
16517
16518 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000016519
16520 ;
16521 return 0;
16522}
16523_ACEOF
16524rm -f conftest.$ac_objext
16525if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16526 (eval $ac_compile) 2>&5
16527 ac_status=$?
16528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16529 (exit $ac_status); } &&
16530 { ac_try='test -s conftest.$ac_objext'
16531 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16532 (eval $ac_try) 2>&5
16533 ac_status=$?
16534 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16535 (exit $ac_status); }; }; then
16536
16537 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016538#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016539_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000016540
Martin v. Löwis11437992002-04-12 09:54:03 +000016541
16542cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016543#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016544_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016545
Martin v. Löwis11437992002-04-12 09:54:03 +000016546 echo "$as_me:$LINENO: result: yes" >&5
16547echo "${ECHO_T}yes" >&6
16548
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016549else
Martin v. Löwis11437992002-04-12 09:54:03 +000016550 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016551sed 's/^/| /' conftest.$ac_ext >&5
16552
Martin v. Löwis11437992002-04-12 09:54:03 +000016553
16554 echo "$as_me:$LINENO: result: no" >&5
16555echo "${ECHO_T}no" >&6
16556
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016557fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016558rm -f conftest.$ac_objext conftest.$ac_ext
16559
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016560fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016561rm -f conftest.$ac_objext conftest.$ac_ext
16562
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016563fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016564rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016565 CFLAGS=$OLD_CFLAGS
16566
16567else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016568
Martin v. Löwis11437992002-04-12 09:54:03 +000016569
16570for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000016571do
Martin v. Löwis11437992002-04-12 09:54:03 +000016572as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16573echo "$as_me:$LINENO: checking for $ac_func" >&5
16574echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16575if eval "test \"\${$as_ac_var+set}\" = set"; then
16576 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016577else
Martin v. Löwis11437992002-04-12 09:54:03 +000016578 cat >conftest.$ac_ext <<_ACEOF
16579#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016580/* confdefs.h. */
16581_ACEOF
16582cat confdefs.h >>conftest.$ac_ext
16583cat >>conftest.$ac_ext <<_ACEOF
16584/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016585/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000016586 which can conflict with char $ac_func (); below.
16587 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16588 <limits.h> exists even on freestanding compilers. */
16589#ifdef __STDC__
16590# include <limits.h>
16591#else
16592# include <assert.h>
16593#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016594/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016595#ifdef __cplusplus
16596extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016597{
Martin v. Löwis11437992002-04-12 09:54:03 +000016598#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016599/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016600 builtin and then its argument prototype would still apply. */
16601char $ac_func ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016602/* The GNU C library defines this for functions which it implements
16603 to always fail with ENOSYS. Some functions are actually named
16604 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000016605#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016606choke me
16607#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000016608char (*f) () = $ac_func;
16609#endif
16610#ifdef __cplusplus
16611}
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016612#endif
16613
Skip Montanarod8d39a02003-07-10 20:44:10 +000016614int
16615main ()
16616{
16617return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000016618 ;
16619 return 0;
16620}
16621_ACEOF
16622rm -f conftest.$ac_objext conftest$ac_exeext
16623if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16624 (eval $ac_link) 2>&5
16625 ac_status=$?
16626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16627 (exit $ac_status); } &&
16628 { ac_try='test -s conftest$ac_exeext'
16629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16630 (eval $ac_try) 2>&5
16631 ac_status=$?
16632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16633 (exit $ac_status); }; }; then
16634 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000016635else
Martin v. Löwis11437992002-04-12 09:54:03 +000016636 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016637sed 's/^/| /' conftest.$ac_ext >&5
16638
Martin v. Löwis11437992002-04-12 09:54:03 +000016639eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000016640fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016641rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000016642fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016643echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16644echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16645if test `eval echo '${'$as_ac_var'}'` = yes; then
16646 cat >>confdefs.h <<_ACEOF
16647#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16648_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016649
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016650fi
Thomas Wouters3a584202000-08-05 23:28:51 +000016651done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016652
Michael W. Hudson54241132001-12-07 15:38:26 +000016653
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000016654fi
16655
Michael W. Hudson54241132001-12-07 15:38:26 +000016656
16657
16658
16659
16660
16661
Guido van Rossum627b2d71993-12-24 10:39:16 +000016662# checks for system services
16663# (none yet)
16664
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016665# Linux requires this for correct f.p. operations
Martin v. Löwis11437992002-04-12 09:54:03 +000016666echo "$as_me:$LINENO: checking for __fpu_control" >&5
16667echo $ECHO_N "checking for __fpu_control... $ECHO_C" >&6
16668if test "${ac_cv_func___fpu_control+set}" = set; then
16669 echo $ECHO_N "(cached) $ECHO_C" >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016670else
Martin v. Löwis11437992002-04-12 09:54:03 +000016671 cat >conftest.$ac_ext <<_ACEOF
16672#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016673/* confdefs.h. */
16674_ACEOF
16675cat confdefs.h >>conftest.$ac_ext
16676cat >>conftest.$ac_ext <<_ACEOF
16677/* end confdefs.h. */
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016678/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000016679 which can conflict with char __fpu_control (); below.
16680 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16681 <limits.h> exists even on freestanding compilers. */
16682#ifdef __STDC__
16683# include <limits.h>
16684#else
16685# include <assert.h>
16686#endif
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016687/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016688#ifdef __cplusplus
16689extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016690{
Martin v. Löwis11437992002-04-12 09:54:03 +000016691#endif
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016692/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016693 builtin and then its argument prototype would still apply. */
16694char __fpu_control ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016695/* The GNU C library defines this for functions which it implements
16696 to always fail with ENOSYS. Some functions are actually named
16697 something starting with __ and the normal name is an alias. */
16698#if defined (__stub___fpu_control) || defined (__stub_____fpu_control)
16699choke me
16700#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000016701char (*f) () = __fpu_control;
16702#endif
16703#ifdef __cplusplus
16704}
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016705#endif
16706
Skip Montanarod8d39a02003-07-10 20:44:10 +000016707int
16708main ()
16709{
16710return f != __fpu_control;
Martin v. Löwis11437992002-04-12 09:54:03 +000016711 ;
16712 return 0;
16713}
16714_ACEOF
16715rm -f conftest.$ac_objext conftest$ac_exeext
16716if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16717 (eval $ac_link) 2>&5
16718 ac_status=$?
16719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16720 (exit $ac_status); } &&
16721 { ac_try='test -s conftest$ac_exeext'
16722 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16723 (eval $ac_try) 2>&5
16724 ac_status=$?
16725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16726 (exit $ac_status); }; }; then
16727 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016728else
Martin v. Löwis11437992002-04-12 09:54:03 +000016729 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016730sed 's/^/| /' conftest.$ac_ext >&5
16731
Martin v. Löwis11437992002-04-12 09:54:03 +000016732ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016733fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016734rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016735fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016736echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
16737echo "${ECHO_T}$ac_cv_func___fpu_control" >&6
16738if test $ac_cv_func___fpu_control = yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016739 :
16740else
Martin v. Löwis11437992002-04-12 09:54:03 +000016741
16742echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
16743echo $ECHO_N "checking for __fpu_control in -lieee... $ECHO_C" >&6
16744if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
16745 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016746else
Martin v. Löwis11437992002-04-12 09:54:03 +000016747 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016748LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016749cat >conftest.$ac_ext <<_ACEOF
16750#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016751/* confdefs.h. */
16752_ACEOF
16753cat confdefs.h >>conftest.$ac_ext
16754cat >>conftest.$ac_ext <<_ACEOF
16755/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016756
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016757/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016758#ifdef __cplusplus
16759extern "C"
16760#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016761/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016762 builtin and then its argument prototype would still apply. */
16763char __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000016764int
16765main ()
16766{
16767__fpu_control ();
16768 ;
16769 return 0;
16770}
16771_ACEOF
16772rm -f conftest.$ac_objext conftest$ac_exeext
16773if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16774 (eval $ac_link) 2>&5
16775 ac_status=$?
16776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16777 (exit $ac_status); } &&
16778 { ac_try='test -s conftest$ac_exeext'
16779 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16780 (eval $ac_try) 2>&5
16781 ac_status=$?
16782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16783 (exit $ac_status); }; }; then
16784 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000016785else
Martin v. Löwis11437992002-04-12 09:54:03 +000016786 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016787sed 's/^/| /' conftest.$ac_ext >&5
16788
Martin v. Löwis11437992002-04-12 09:54:03 +000016789ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000016790fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016791rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16792LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016793fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016794echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
16795echo "${ECHO_T}$ac_cv_lib_ieee___fpu_control" >&6
16796if test $ac_cv_lib_ieee___fpu_control = yes; then
16797 cat >>confdefs.h <<_ACEOF
16798#define HAVE_LIBIEEE 1
16799_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016800
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016801 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016802
Guido van Rossum627b2d71993-12-24 10:39:16 +000016803fi
16804
Michael W. Hudson54241132001-12-07 15:38:26 +000016805
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000016806fi
16807
Michael W. Hudson54241132001-12-07 15:38:26 +000016808
Guido van Rossum7f253911997-05-09 02:42:48 +000016809# Check for --with-fpectl
Martin v. Löwis11437992002-04-12 09:54:03 +000016810echo "$as_me:$LINENO: checking for --with-fpectl" >&5
16811echo $ECHO_N "checking for --with-fpectl... $ECHO_C" >&6
16812
Guido van Rossum7f253911997-05-09 02:42:48 +000016813# Check whether --with-fpectl or --without-fpectl was given.
16814if test "${with_fpectl+set}" = set; then
16815 withval="$with_fpectl"
Martin v. Löwis11437992002-04-12 09:54:03 +000016816
Guido van Rossum7f253911997-05-09 02:42:48 +000016817if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000016818then
16819
16820cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000016821#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016822_ACEOF
16823
16824 echo "$as_me:$LINENO: result: yes" >&5
16825echo "${ECHO_T}yes" >&6
16826else echo "$as_me:$LINENO: result: no" >&5
16827echo "${ECHO_T}no" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000016828fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000016829else
Martin v. Löwis11437992002-04-12 09:54:03 +000016830 echo "$as_me:$LINENO: result: no" >&5
16831echo "${ECHO_T}no" >&6
16832fi;
Guido van Rossum7f253911997-05-09 02:42:48 +000016833
Guido van Rossum7f43da71994-08-01 12:15:30 +000016834# check for --with-libm=...
16835
Guido van Rossum563e7081996-09-10 18:20:48 +000016836case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000016837Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000016838BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000016839*) LIBM=-lm
16840esac
Martin v. Löwis11437992002-04-12 09:54:03 +000016841echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
16842echo $ECHO_N "checking for --with-libm=STRING... $ECHO_C" >&6
16843
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016844# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016845if test "${with_libm+set}" = set; then
16846 withval="$with_libm"
Martin v. Löwis11437992002-04-12 09:54:03 +000016847
Guido van Rossum7f253911997-05-09 02:42:48 +000016848if test "$withval" = no
16849then LIBM=
Martin v. Löwis11437992002-04-12 09:54:03 +000016850 echo "$as_me:$LINENO: result: force LIBM empty" >&5
16851echo "${ECHO_T}force LIBM empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000016852elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000016853then LIBM=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000016854 echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
16855echo "${ECHO_T}set LIBM=\"$withval\"" >&6
16856else { { echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
16857echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
16858 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000016859fi
Guido van Rossum7f253911997-05-09 02:42:48 +000016860else
Martin v. Löwis11437992002-04-12 09:54:03 +000016861 echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
16862echo "${ECHO_T}default LIBM=\"$LIBM\"" >&6
16863fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000016864
16865# check for --with-libc=...
16866
Martin v. Löwis11437992002-04-12 09:54:03 +000016867echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
16868echo $ECHO_N "checking for --with-libc=STRING... $ECHO_C" >&6
16869
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016870# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016871if test "${with_libc+set}" = set; then
16872 withval="$with_libc"
Martin v. Löwis11437992002-04-12 09:54:03 +000016873
Guido van Rossum7f253911997-05-09 02:42:48 +000016874if test "$withval" = no
16875then LIBC=
Martin v. Löwis11437992002-04-12 09:54:03 +000016876 echo "$as_me:$LINENO: result: force LIBC empty" >&5
16877echo "${ECHO_T}force LIBC empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000016878elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000016879then LIBC=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000016880 echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
16881echo "${ECHO_T}set LIBC=\"$withval\"" >&6
16882else { { echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
16883echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
16884 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000016885fi
Guido van Rossum7f253911997-05-09 02:42:48 +000016886else
Martin v. Löwis11437992002-04-12 09:54:03 +000016887 echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
16888echo "${ECHO_T}default LIBC=\"$LIBC\"" >&6
16889fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000016890
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000016891# check for hypot() in math library
16892LIBS_SAVE=$LIBS
16893LIBS="$LIBS $LIBM"
Martin v. Löwis11437992002-04-12 09:54:03 +000016894
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000016895for ac_func in hypot
16896do
Martin v. Löwis11437992002-04-12 09:54:03 +000016897as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16898echo "$as_me:$LINENO: checking for $ac_func" >&5
16899echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16900if eval "test \"\${$as_ac_var+set}\" = set"; then
16901 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000016902else
Martin v. Löwis11437992002-04-12 09:54:03 +000016903 cat >conftest.$ac_ext <<_ACEOF
16904#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016905/* confdefs.h. */
16906_ACEOF
16907cat confdefs.h >>conftest.$ac_ext
16908cat >>conftest.$ac_ext <<_ACEOF
16909/* end confdefs.h. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016910/* System header to define __stub macros and hopefully few prototypes,
Skip Montanarod8d39a02003-07-10 20:44:10 +000016911 which can conflict with char $ac_func (); below.
16912 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16913 <limits.h> exists even on freestanding compilers. */
16914#ifdef __STDC__
16915# include <limits.h>
16916#else
16917# include <assert.h>
16918#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016919/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016920#ifdef __cplusplus
16921extern "C"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016922{
Martin v. Löwis11437992002-04-12 09:54:03 +000016923#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016924/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016925 builtin and then its argument prototype would still apply. */
16926char $ac_func ();
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000016927/* The GNU C library defines this for functions which it implements
16928 to always fail with ENOSYS. Some functions are actually named
16929 something starting with __ and the normal name is an alias. */
16930#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16931choke me
16932#else
Skip Montanarod8d39a02003-07-10 20:44:10 +000016933char (*f) () = $ac_func;
16934#endif
16935#ifdef __cplusplus
16936}
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000016937#endif
16938
Skip Montanarod8d39a02003-07-10 20:44:10 +000016939int
16940main ()
16941{
16942return f != $ac_func;
Martin v. Löwis11437992002-04-12 09:54:03 +000016943 ;
16944 return 0;
16945}
16946_ACEOF
16947rm -f conftest.$ac_objext conftest$ac_exeext
16948if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16949 (eval $ac_link) 2>&5
16950 ac_status=$?
16951 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16952 (exit $ac_status); } &&
16953 { ac_try='test -s conftest$ac_exeext'
16954 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16955 (eval $ac_try) 2>&5
16956 ac_status=$?
16957 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16958 (exit $ac_status); }; }; then
16959 eval "$as_ac_var=yes"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000016960else
Martin v. Löwis11437992002-04-12 09:54:03 +000016961 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000016962sed 's/^/| /' conftest.$ac_ext >&5
16963
Martin v. Löwis11437992002-04-12 09:54:03 +000016964eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000016965fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016966rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000016967fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016968echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16969echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16970if test `eval echo '${'$as_ac_var'}'` = yes; then
16971 cat >>confdefs.h <<_ACEOF
16972#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16973_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000016974
Michael W. Hudson54241132001-12-07 15:38:26 +000016975else
Martin v. Löwis11437992002-04-12 09:54:03 +000016976 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000016977fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +000016978done
16979
Michael W. Hudson54241132001-12-07 15:38:26 +000016980
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000016981LIBS=$LIBS_SAVE
16982
Guido van Rossumef2255b2000-03-10 22:30:29 +000016983# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000016984if test "${ac_cv_header_wchar_h+set}" = set; then
16985 echo "$as_me:$LINENO: checking for wchar.h" >&5
16986echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
16987if test "${ac_cv_header_wchar_h+set}" = set; then
16988 echo $ECHO_N "(cached) $ECHO_C" >&6
16989fi
16990echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
16991echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000016992else
Martin v. Löwis11437992002-04-12 09:54:03 +000016993 # Is the header compilable?
16994echo "$as_me:$LINENO: checking wchar.h usability" >&5
16995echo $ECHO_N "checking wchar.h usability... $ECHO_C" >&6
16996cat >conftest.$ac_ext <<_ACEOF
16997#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000016998/* confdefs.h. */
16999_ACEOF
17000cat confdefs.h >>conftest.$ac_ext
17001cat >>conftest.$ac_ext <<_ACEOF
17002/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017003$ac_includes_default
17004#include <wchar.h>
17005_ACEOF
17006rm -f conftest.$ac_objext
17007if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17008 (eval $ac_compile) 2>&5
17009 ac_status=$?
17010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17011 (exit $ac_status); } &&
17012 { ac_try='test -s conftest.$ac_objext'
17013 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17014 (eval $ac_try) 2>&5
17015 ac_status=$?
17016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17017 (exit $ac_status); }; }; then
17018 ac_header_compiler=yes
17019else
17020 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017021sed 's/^/| /' conftest.$ac_ext >&5
17022
Martin v. Löwis11437992002-04-12 09:54:03 +000017023ac_header_compiler=no
17024fi
17025rm -f conftest.$ac_objext conftest.$ac_ext
17026echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
17027echo "${ECHO_T}$ac_header_compiler" >&6
17028
17029# Is the header present?
17030echo "$as_me:$LINENO: checking wchar.h presence" >&5
17031echo $ECHO_N "checking wchar.h presence... $ECHO_C" >&6
17032cat >conftest.$ac_ext <<_ACEOF
17033#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017034/* confdefs.h. */
17035_ACEOF
17036cat confdefs.h >>conftest.$ac_ext
17037cat >>conftest.$ac_ext <<_ACEOF
17038/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000017039#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000017040_ACEOF
17041if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17042 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17043 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +000017044 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000017045 rm -f conftest.er1
17046 cat conftest.err >&5
17047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17048 (exit $ac_status); } >/dev/null; then
17049 if test -s conftest.err; then
17050 ac_cpp_err=$ac_c_preproc_warn_flag
17051 else
17052 ac_cpp_err=
17053 fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000017054else
Martin v. Löwis11437992002-04-12 09:54:03 +000017055 ac_cpp_err=yes
17056fi
17057if test -z "$ac_cpp_err"; then
17058 ac_header_preproc=yes
17059else
17060 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017061sed 's/^/| /' conftest.$ac_ext >&5
17062
Martin v. Löwis11437992002-04-12 09:54:03 +000017063 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000017064fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017065rm -f conftest.err conftest.$ac_ext
17066echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
17067echo "${ECHO_T}$ac_header_preproc" >&6
17068
17069# So? What about this header?
17070case $ac_header_compiler:$ac_header_preproc in
17071 yes:no )
17072 { echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
17073echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
17074 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017075echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;}
17076 (
17077 cat <<\_ASBOX
17078## ------------------------------------ ##
17079## Report this to bug-autoconf@gnu.org. ##
17080## ------------------------------------ ##
17081_ASBOX
17082 ) |
17083 sed "s/^/$as_me: WARNING: /" >&2
17084 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000017085 no:yes )
17086 { echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
17087echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
17088 { echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
17089echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
17090 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017091echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;}
17092 (
17093 cat <<\_ASBOX
17094## ------------------------------------ ##
17095## Report this to bug-autoconf@gnu.org. ##
17096## ------------------------------------ ##
17097_ASBOX
17098 ) |
17099 sed "s/^/$as_me: WARNING: /" >&2
17100 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000017101esac
17102echo "$as_me:$LINENO: checking for wchar.h" >&5
17103echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
17104if test "${ac_cv_header_wchar_h+set}" = set; then
17105 echo $ECHO_N "(cached) $ECHO_C" >&6
17106else
17107 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000017108fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017109echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
17110echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
17111
17112fi
17113if test $ac_cv_header_wchar_h = yes; then
17114
17115
17116cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000017117#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000017118_ACEOF
17119
Martin v. Löwisc45929e2002-04-06 10:10:49 +000017120 wchar_h="yes"
17121
Guido van Rossumef2255b2000-03-10 22:30:29 +000017122else
Martin v. Löwis11437992002-04-12 09:54:03 +000017123 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000017124
17125fi
17126
Michael W. Hudson54241132001-12-07 15:38:26 +000017127
Martin v. Löwis11437992002-04-12 09:54:03 +000017128
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017129# determine wchar_t size
17130if test "$wchar_h" = yes
17131then
Martin v. Löwis11437992002-04-12 09:54:03 +000017132 echo "$as_me:$LINENO: checking for wchar_t" >&5
17133echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
17134if test "${ac_cv_type_wchar_t+set}" = set; then
17135 echo $ECHO_N "(cached) $ECHO_C" >&6
17136else
17137 cat >conftest.$ac_ext <<_ACEOF
17138#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017139/* confdefs.h. */
17140_ACEOF
17141cat confdefs.h >>conftest.$ac_ext
17142cat >>conftest.$ac_ext <<_ACEOF
17143/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017144#include <wchar.h>
17145
Martin v. Löwis11437992002-04-12 09:54:03 +000017146int
17147main ()
17148{
17149if ((wchar_t *) 0)
17150 return 0;
17151if (sizeof (wchar_t))
17152 return 0;
17153 ;
17154 return 0;
17155}
17156_ACEOF
17157rm -f conftest.$ac_objext
17158if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17159 (eval $ac_compile) 2>&5
17160 ac_status=$?
17161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17162 (exit $ac_status); } &&
17163 { ac_try='test -s conftest.$ac_objext'
17164 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17165 (eval $ac_try) 2>&5
17166 ac_status=$?
17167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17168 (exit $ac_status); }; }; then
17169 ac_cv_type_wchar_t=yes
17170else
17171 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017172sed 's/^/| /' conftest.$ac_ext >&5
17173
Martin v. Löwis11437992002-04-12 09:54:03 +000017174ac_cv_type_wchar_t=no
17175fi
17176rm -f conftest.$ac_objext conftest.$ac_ext
17177fi
17178echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
17179echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
17180
17181echo "$as_me:$LINENO: checking size of wchar_t" >&5
17182echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
17183if test "${ac_cv_sizeof_wchar_t+set}" = set; then
17184 echo $ECHO_N "(cached) $ECHO_C" >&6
17185else
17186 if test "$ac_cv_type_wchar_t" = yes; then
17187 # The cast to unsigned long works around a bug in the HP C Compiler
17188 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17189 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17190 # This bug is HP SR number 8606223364.
17191 if test "$cross_compiling" = yes; then
17192 # Depending upon the size, compute the lo and hi bounds.
17193cat >conftest.$ac_ext <<_ACEOF
17194#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017195/* confdefs.h. */
17196_ACEOF
17197cat confdefs.h >>conftest.$ac_ext
17198cat >>conftest.$ac_ext <<_ACEOF
17199/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017200#include <wchar.h>
17201
Martin v. Löwis11437992002-04-12 09:54:03 +000017202int
17203main ()
17204{
17205static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
17206test_array [0] = 0
17207
17208 ;
17209 return 0;
17210}
17211_ACEOF
17212rm -f conftest.$ac_objext
17213if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17214 (eval $ac_compile) 2>&5
17215 ac_status=$?
17216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17217 (exit $ac_status); } &&
17218 { ac_try='test -s conftest.$ac_objext'
17219 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17220 (eval $ac_try) 2>&5
17221 ac_status=$?
17222 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17223 (exit $ac_status); }; }; then
17224 ac_lo=0 ac_mid=0
17225 while :; do
17226 cat >conftest.$ac_ext <<_ACEOF
17227#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017228/* confdefs.h. */
17229_ACEOF
17230cat confdefs.h >>conftest.$ac_ext
17231cat >>conftest.$ac_ext <<_ACEOF
17232/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017233#include <wchar.h>
17234
Martin v. Löwis11437992002-04-12 09:54:03 +000017235int
17236main ()
17237{
17238static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
17239test_array [0] = 0
17240
17241 ;
17242 return 0;
17243}
17244_ACEOF
17245rm -f conftest.$ac_objext
17246if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17247 (eval $ac_compile) 2>&5
17248 ac_status=$?
17249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17250 (exit $ac_status); } &&
17251 { ac_try='test -s conftest.$ac_objext'
17252 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17253 (eval $ac_try) 2>&5
17254 ac_status=$?
17255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17256 (exit $ac_status); }; }; then
17257 ac_hi=$ac_mid; break
17258else
17259 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017260sed 's/^/| /' conftest.$ac_ext >&5
17261
Martin v. Löwis11437992002-04-12 09:54:03 +000017262ac_lo=`expr $ac_mid + 1`
17263 if test $ac_lo -le $ac_mid; then
17264 ac_lo= ac_hi=
17265 break
17266 fi
17267 ac_mid=`expr 2 '*' $ac_mid + 1`
17268fi
17269rm -f conftest.$ac_objext conftest.$ac_ext
17270 done
17271else
17272 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017273sed 's/^/| /' conftest.$ac_ext >&5
17274
Martin v. Löwis11437992002-04-12 09:54:03 +000017275cat >conftest.$ac_ext <<_ACEOF
17276#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017277/* confdefs.h. */
17278_ACEOF
17279cat confdefs.h >>conftest.$ac_ext
17280cat >>conftest.$ac_ext <<_ACEOF
17281/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017282#include <wchar.h>
17283
Martin v. Löwis11437992002-04-12 09:54:03 +000017284int
17285main ()
17286{
17287static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
17288test_array [0] = 0
17289
17290 ;
17291 return 0;
17292}
17293_ACEOF
17294rm -f conftest.$ac_objext
17295if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17296 (eval $ac_compile) 2>&5
17297 ac_status=$?
17298 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17299 (exit $ac_status); } &&
17300 { ac_try='test -s conftest.$ac_objext'
17301 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17302 (eval $ac_try) 2>&5
17303 ac_status=$?
17304 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17305 (exit $ac_status); }; }; then
17306 ac_hi=-1 ac_mid=-1
17307 while :; do
17308 cat >conftest.$ac_ext <<_ACEOF
17309#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017310/* confdefs.h. */
17311_ACEOF
17312cat confdefs.h >>conftest.$ac_ext
17313cat >>conftest.$ac_ext <<_ACEOF
17314/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017315#include <wchar.h>
17316
Martin v. Löwis11437992002-04-12 09:54:03 +000017317int
17318main ()
17319{
17320static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
17321test_array [0] = 0
17322
17323 ;
17324 return 0;
17325}
17326_ACEOF
17327rm -f conftest.$ac_objext
17328if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17329 (eval $ac_compile) 2>&5
17330 ac_status=$?
17331 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17332 (exit $ac_status); } &&
17333 { ac_try='test -s conftest.$ac_objext'
17334 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17335 (eval $ac_try) 2>&5
17336 ac_status=$?
17337 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17338 (exit $ac_status); }; }; then
17339 ac_lo=$ac_mid; break
17340else
17341 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017342sed 's/^/| /' conftest.$ac_ext >&5
17343
Martin v. Löwis11437992002-04-12 09:54:03 +000017344ac_hi=`expr '(' $ac_mid ')' - 1`
17345 if test $ac_mid -le $ac_hi; then
17346 ac_lo= ac_hi=
17347 break
17348 fi
17349 ac_mid=`expr 2 '*' $ac_mid`
17350fi
17351rm -f conftest.$ac_objext conftest.$ac_ext
17352 done
17353else
17354 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017355sed 's/^/| /' conftest.$ac_ext >&5
17356
Martin v. Löwis11437992002-04-12 09:54:03 +000017357ac_lo= ac_hi=
17358fi
17359rm -f conftest.$ac_objext conftest.$ac_ext
17360fi
17361rm -f conftest.$ac_objext conftest.$ac_ext
17362# Binary search between lo and hi bounds.
17363while test "x$ac_lo" != "x$ac_hi"; do
17364 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17365 cat >conftest.$ac_ext <<_ACEOF
17366#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017367/* confdefs.h. */
17368_ACEOF
17369cat confdefs.h >>conftest.$ac_ext
17370cat >>conftest.$ac_ext <<_ACEOF
17371/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017372#include <wchar.h>
17373
Martin v. Löwis11437992002-04-12 09:54:03 +000017374int
17375main ()
17376{
17377static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
17378test_array [0] = 0
17379
17380 ;
17381 return 0;
17382}
17383_ACEOF
17384rm -f conftest.$ac_objext
17385if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17386 (eval $ac_compile) 2>&5
17387 ac_status=$?
17388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17389 (exit $ac_status); } &&
17390 { ac_try='test -s conftest.$ac_objext'
17391 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17392 (eval $ac_try) 2>&5
17393 ac_status=$?
17394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17395 (exit $ac_status); }; }; then
17396 ac_hi=$ac_mid
17397else
17398 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017399sed 's/^/| /' conftest.$ac_ext >&5
17400
Martin v. Löwis11437992002-04-12 09:54:03 +000017401ac_lo=`expr '(' $ac_mid ')' + 1`
17402fi
17403rm -f conftest.$ac_objext conftest.$ac_ext
17404done
17405case $ac_lo in
17406?*) ac_cv_sizeof_wchar_t=$ac_lo;;
Skip Montanarod8d39a02003-07-10 20:44:10 +000017407'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
17408See \`config.log' for more details." >&5
17409echo "$as_me: error: cannot compute sizeof (wchar_t), 77
17410See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000017411 { (exit 1); exit 1; }; } ;;
17412esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017413else
17414 if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000017415 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
17416See \`config.log' for more details." >&5
17417echo "$as_me: error: cannot run test program while cross compiling
17418See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000017419 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000017420else
Martin v. Löwis11437992002-04-12 09:54:03 +000017421 cat >conftest.$ac_ext <<_ACEOF
17422#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017423/* confdefs.h. */
17424_ACEOF
17425cat confdefs.h >>conftest.$ac_ext
17426cat >>conftest.$ac_ext <<_ACEOF
17427/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017428#include <wchar.h>
17429
17430long longval () { return (long) (sizeof (wchar_t)); }
17431unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000017432#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000017433#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000017434int
17435main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017436{
Martin v. Löwis11437992002-04-12 09:54:03 +000017437
17438 FILE *f = fopen ("conftest.val", "w");
17439 if (! f)
17440 exit (1);
17441 if (((long) (sizeof (wchar_t))) < 0)
17442 {
17443 long i = longval ();
17444 if (i != ((long) (sizeof (wchar_t))))
17445 exit (1);
17446 fprintf (f, "%ld\n", i);
17447 }
17448 else
17449 {
17450 unsigned long i = ulongval ();
17451 if (i != ((long) (sizeof (wchar_t))))
17452 exit (1);
17453 fprintf (f, "%lu\n", i);
17454 }
17455 exit (ferror (f) || fclose (f) != 0);
17456
17457 ;
17458 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000017459}
Martin v. Löwis11437992002-04-12 09:54:03 +000017460_ACEOF
17461rm -f conftest$ac_exeext
17462if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17463 (eval $ac_link) 2>&5
17464 ac_status=$?
17465 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17466 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17467 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17468 (eval $ac_try) 2>&5
17469 ac_status=$?
17470 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17471 (exit $ac_status); }; }; then
17472 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000017473else
Martin v. Löwis11437992002-04-12 09:54:03 +000017474 echo "$as_me: program exited with status $ac_status" >&5
17475echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017476sed 's/^/| /' conftest.$ac_ext >&5
17477
Martin v. Löwis11437992002-04-12 09:54:03 +000017478( exit $ac_status )
Skip Montanarod8d39a02003-07-10 20:44:10 +000017479{ { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77
17480See \`config.log' for more details." >&5
17481echo "$as_me: error: cannot compute sizeof (wchar_t), 77
17482See \`config.log' for more details." >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000017483 { (exit 1); exit 1; }; }
17484fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000017485rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000017486fi
17487fi
17488rm -f conftest.val
17489else
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017490 ac_cv_sizeof_wchar_t=0
Guido van Rossumef2255b2000-03-10 22:30:29 +000017491fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000017492fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017493echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
17494echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
17495cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017496#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000017497_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017498
Michael W. Hudson54241132001-12-07 15:38:26 +000017499
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017500fi
17501
Martin v. Löwis11437992002-04-12 09:54:03 +000017502echo "$as_me:$LINENO: checking what type to use for unicode" >&5
17503echo $ECHO_N "checking what type to use for unicode... $ECHO_C" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017504# Check whether --enable-unicode or --disable-unicode was given.
17505if test "${enable_unicode+set}" = set; then
17506 enableval="$enable_unicode"
Martin v. Löwis11437992002-04-12 09:54:03 +000017507
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017508else
17509 enable_unicode=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000017510fi;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017511
17512if test $enable_unicode = yes
17513then
Martin v. Löwisfd917792001-06-27 20:22:04 +000017514 # Without any arguments, Py_UNICODE defaults to two-byte mode
17515 enable_unicode="ucs2"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017516fi
17517
Martin v. Löwis0036cba2002-04-12 09:58:45 +000017518
17519
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017520case "$enable_unicode" in
17521ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000017522 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017523#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000017524_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017525
17526 ;;
17527ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000017528 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017529#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000017530_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017531
17532 ;;
17533esac
17534
Michael W. Hudson54241132001-12-07 15:38:26 +000017535
Martin v. Löwis11437992002-04-12 09:54:03 +000017536
17537
Martin v. Löwis0036cba2002-04-12 09:58:45 +000017538
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017539if test "$enable_unicode" = "no"
17540then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000017541 UNICODE_OBJS=""
Martin v. Löwis11437992002-04-12 09:54:03 +000017542 echo "$as_me:$LINENO: result: not used" >&5
17543echo "${ECHO_T}not used" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017544else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000017545 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000017546
17547cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017548#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000017549_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017550
17551 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t"
17552 then
17553 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017554
Martin v. Löwis11437992002-04-12 09:54:03 +000017555cat >>confdefs.h <<\_ACEOF
17556#define HAVE_USABLE_WCHAR_T 1
17557_ACEOF
17558
17559 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017560#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000017561_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017562
17563 elif test "$ac_cv_sizeof_short" = "$unicode_size"
17564 then
17565 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000017566 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017567#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000017568_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017569
17570 elif test "$ac_cv_sizeof_long" = "$unicode_size"
17571 then
17572 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000017573 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017574#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000017575_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017576
17577 else
17578 PY_UNICODE_TYPE="no type found"
17579 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017580 echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
17581echo "${ECHO_T}$PY_UNICODE_TYPE" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000017582fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000017583
17584# check for endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000017585echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
17586echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
17587if test "${ac_cv_c_bigendian+set}" = set; then
17588 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000017589else
Martin v. Löwis11437992002-04-12 09:54:03 +000017590 # See if sys/param.h defines the BYTE_ORDER macro.
17591cat >conftest.$ac_ext <<_ACEOF
17592#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017593/* confdefs.h. */
17594_ACEOF
17595cat confdefs.h >>conftest.$ac_ext
17596cat >>conftest.$ac_ext <<_ACEOF
17597/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000017598#include <sys/types.h>
17599#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000017600
Martin v. Löwis11437992002-04-12 09:54:03 +000017601int
17602main ()
17603{
Guido van Rossumef2255b2000-03-10 22:30:29 +000017604#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
17605 bogus endian macros
17606#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000017607
17608 ;
17609 return 0;
17610}
17611_ACEOF
17612rm -f conftest.$ac_objext
17613if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17614 (eval $ac_compile) 2>&5
17615 ac_status=$?
17616 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17617 (exit $ac_status); } &&
17618 { ac_try='test -s conftest.$ac_objext'
17619 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17620 (eval $ac_try) 2>&5
17621 ac_status=$?
17622 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17623 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000017624 # It does; now see whether it defined to BIG_ENDIAN or not.
Martin v. Löwis11437992002-04-12 09:54:03 +000017625cat >conftest.$ac_ext <<_ACEOF
17626#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017627/* confdefs.h. */
17628_ACEOF
17629cat confdefs.h >>conftest.$ac_ext
17630cat >>conftest.$ac_ext <<_ACEOF
17631/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000017632#include <sys/types.h>
17633#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000017634
Martin v. Löwis11437992002-04-12 09:54:03 +000017635int
17636main ()
17637{
Guido van Rossumef2255b2000-03-10 22:30:29 +000017638#if BYTE_ORDER != BIG_ENDIAN
17639 not big endian
17640#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000017641
17642 ;
17643 return 0;
17644}
17645_ACEOF
17646rm -f conftest.$ac_objext
17647if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17648 (eval $ac_compile) 2>&5
17649 ac_status=$?
17650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17651 (exit $ac_status); } &&
17652 { ac_try='test -s conftest.$ac_objext'
17653 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17654 (eval $ac_try) 2>&5
17655 ac_status=$?
17656 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17657 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000017658 ac_cv_c_bigendian=yes
17659else
Martin v. Löwis11437992002-04-12 09:54:03 +000017660 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017661sed 's/^/| /' conftest.$ac_ext >&5
17662
Martin v. Löwis11437992002-04-12 09:54:03 +000017663ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000017664fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017665rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000017666else
Martin v. Löwis11437992002-04-12 09:54:03 +000017667 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017668sed 's/^/| /' conftest.$ac_ext >&5
17669
Martin v. Löwis11437992002-04-12 09:54:03 +000017670# It does not; compile a test program.
Guido van Rossumef2255b2000-03-10 22:30:29 +000017671if test "$cross_compiling" = yes; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000017672 # try to guess the endianness by grepping values into an object file
Martin v. Löwis11437992002-04-12 09:54:03 +000017673 ac_cv_c_bigendian=unknown
17674 cat >conftest.$ac_ext <<_ACEOF
17675#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017676/* confdefs.h. */
17677_ACEOF
17678cat confdefs.h >>conftest.$ac_ext
17679cat >>conftest.$ac_ext <<_ACEOF
17680/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017681short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
17682short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
17683void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
17684short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
17685short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
17686void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
Martin v. Löwis11437992002-04-12 09:54:03 +000017687int
17688main ()
17689{
17690 _ascii (); _ebcdic ();
17691 ;
17692 return 0;
17693}
17694_ACEOF
17695rm -f conftest.$ac_objext
17696if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17697 (eval $ac_compile) 2>&5
17698 ac_status=$?
17699 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17700 (exit $ac_status); } &&
17701 { ac_try='test -s conftest.$ac_objext'
17702 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17703 (eval $ac_try) 2>&5
17704 ac_status=$?
17705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17706 (exit $ac_status); }; }; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000017707 if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
Martin v. Löwis11437992002-04-12 09:54:03 +000017708 ac_cv_c_bigendian=yes
17709fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000017710if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
Martin v. Löwis11437992002-04-12 09:54:03 +000017711 if test "$ac_cv_c_bigendian" = unknown; then
17712 ac_cv_c_bigendian=no
17713 else
17714 # finding both strings is unlikely to happen, but who knows?
17715 ac_cv_c_bigendian=unknown
17716 fi
17717fi
17718else
17719 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017720sed 's/^/| /' conftest.$ac_ext >&5
17721
Martin v. Löwis11437992002-04-12 09:54:03 +000017722fi
17723rm -f conftest.$ac_objext conftest.$ac_ext
17724else
17725 cat >conftest.$ac_ext <<_ACEOF
17726#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017727/* confdefs.h. */
17728_ACEOF
17729cat confdefs.h >>conftest.$ac_ext
17730cat >>conftest.$ac_ext <<_ACEOF
17731/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017732int
17733main ()
17734{
Guido van Rossumef2255b2000-03-10 22:30:29 +000017735 /* Are we little or big endian? From Harbison&Steele. */
17736 union
17737 {
17738 long l;
17739 char c[sizeof (long)];
17740 } u;
17741 u.l = 1;
17742 exit (u.c[sizeof (long) - 1] == 1);
17743}
Martin v. Löwis11437992002-04-12 09:54:03 +000017744_ACEOF
17745rm -f conftest$ac_exeext
17746if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17747 (eval $ac_link) 2>&5
17748 ac_status=$?
17749 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17750 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17751 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17752 (eval $ac_try) 2>&5
17753 ac_status=$?
17754 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17755 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000017756 ac_cv_c_bigendian=no
17757else
Martin v. Löwis11437992002-04-12 09:54:03 +000017758 echo "$as_me: program exited with status $ac_status" >&5
17759echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017760sed 's/^/| /' conftest.$ac_ext >&5
17761
Martin v. Löwis11437992002-04-12 09:54:03 +000017762( exit $ac_status )
17763ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000017764fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000017765rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000017766fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017767fi
17768rm -f conftest.$ac_objext conftest.$ac_ext
17769fi
17770echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
17771echo "${ECHO_T}$ac_cv_c_bigendian" >&6
17772case $ac_cv_c_bigendian in
17773 yes)
Jack Jansendd19cf82001-12-06 22:36:17 +000017774
Martin v. Löwis11437992002-04-12 09:54:03 +000017775cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000017776#define WORDS_BIGENDIAN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000017777_ACEOF
17778 ;;
17779 no)
17780 ;;
17781 *)
Skip Montanarod8d39a02003-07-10 20:44:10 +000017782 { { echo "$as_me:$LINENO: error: unknown endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000017783presetting ac_cv_c_bigendian=no (or yes) will help" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017784echo "$as_me: error: unknown endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000017785presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
17786 { (exit 1); exit 1; }; } ;;
17787esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000017788
Michael W. Hudson54241132001-12-07 15:38:26 +000017789
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017790# Check whether right shifting a negative integer extends the sign bit
17791# or fills with zeros (like the Cray J90, according to Tim Peters).
Martin v. Löwis11437992002-04-12 09:54:03 +000017792echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
17793echo $ECHO_N "checking whether right shift extends the sign bit... $ECHO_C" >&6
17794if test "${ac_cv_rshift_extends_sign+set}" = set; then
17795 echo $ECHO_N "(cached) $ECHO_C" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000017796else
Martin v. Löwis11437992002-04-12 09:54:03 +000017797
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017798if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000017799 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017800else
Martin v. Löwis11437992002-04-12 09:54:03 +000017801 cat >conftest.$ac_ext <<_ACEOF
17802#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017803/* confdefs.h. */
17804_ACEOF
17805cat confdefs.h >>conftest.$ac_ext
17806cat >>conftest.$ac_ext <<_ACEOF
17807/* end confdefs.h. */
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017808
17809int main()
17810{
Vladimir Marangozova6180282000-07-12 05:05:06 +000017811 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017812}
17813
Martin v. Löwis11437992002-04-12 09:54:03 +000017814_ACEOF
17815rm -f conftest$ac_exeext
17816if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17817 (eval $ac_link) 2>&5
17818 ac_status=$?
17819 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17820 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17821 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17822 (eval $ac_try) 2>&5
17823 ac_status=$?
17824 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17825 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000017826 ac_cv_rshift_extends_sign=yes
17827else
Martin v. Löwis11437992002-04-12 09:54:03 +000017828 echo "$as_me: program exited with status $ac_status" >&5
17829echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017830sed 's/^/| /' conftest.$ac_ext >&5
17831
Martin v. Löwis11437992002-04-12 09:54:03 +000017832( exit $ac_status )
17833ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000017834fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000017835rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000017836fi
Vladimir Marangozova6180282000-07-12 05:05:06 +000017837fi
17838
Martin v. Löwis11437992002-04-12 09:54:03 +000017839echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
17840echo "${ECHO_T}$ac_cv_rshift_extends_sign" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000017841if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017842then
Martin v. Löwis11437992002-04-12 09:54:03 +000017843
17844cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017845#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000017846_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017847
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017848fi
17849
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017850# check for getc_unlocked and related locking functions
Martin v. Löwis11437992002-04-12 09:54:03 +000017851echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
17852echo $ECHO_N "checking for getc_unlocked() and friends... $ECHO_C" >&6
17853if test "${ac_cv_have_getc_unlocked+set}" = set; then
17854 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017855else
Martin v. Löwis11437992002-04-12 09:54:03 +000017856
17857cat >conftest.$ac_ext <<_ACEOF
17858#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017859/* confdefs.h. */
17860_ACEOF
17861cat confdefs.h >>conftest.$ac_ext
17862cat >>conftest.$ac_ext <<_ACEOF
17863/* end confdefs.h. */
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017864#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000017865int
17866main ()
17867{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017868
17869 FILE *f = fopen("/dev/null", "r");
17870 flockfile(f);
17871 getc_unlocked(f);
17872 funlockfile(f);
17873
Martin v. Löwis11437992002-04-12 09:54:03 +000017874 ;
17875 return 0;
17876}
17877_ACEOF
17878rm -f conftest.$ac_objext conftest$ac_exeext
17879if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17880 (eval $ac_link) 2>&5
17881 ac_status=$?
17882 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17883 (exit $ac_status); } &&
17884 { ac_try='test -s conftest$ac_exeext'
17885 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17886 (eval $ac_try) 2>&5
17887 ac_status=$?
17888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17889 (exit $ac_status); }; }; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017890 ac_cv_have_getc_unlocked=yes
17891else
Martin v. Löwis11437992002-04-12 09:54:03 +000017892 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017893sed 's/^/| /' conftest.$ac_ext >&5
17894
Martin v. Löwis11437992002-04-12 09:54:03 +000017895ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017896fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017897rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017898fi
17899
Martin v. Löwis11437992002-04-12 09:54:03 +000017900echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
17901echo "${ECHO_T}$ac_cv_have_getc_unlocked" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017902if test "$ac_cv_have_getc_unlocked" = yes
17903then
Martin v. Löwis11437992002-04-12 09:54:03 +000017904
17905cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017906#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000017907_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000017908
17909fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000017910
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000017911# check for readline 2.2
17912cat >conftest.$ac_ext <<_ACEOF
17913#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017914/* confdefs.h. */
17915_ACEOF
17916cat confdefs.h >>conftest.$ac_ext
17917cat >>conftest.$ac_ext <<_ACEOF
17918/* end confdefs.h. */
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000017919#include <readline/readline.h>
17920_ACEOF
17921if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
17922 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
17923 ac_status=$?
Skip Montanarod8d39a02003-07-10 20:44:10 +000017924 grep -v '^ *+' conftest.er1 >conftest.err
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000017925 rm -f conftest.er1
17926 cat conftest.err >&5
17927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
17928 (exit $ac_status); } >/dev/null; then
17929 if test -s conftest.err; then
17930 ac_cpp_err=$ac_c_preproc_warn_flag
17931 else
17932 ac_cpp_err=
17933 fi
17934else
17935 ac_cpp_err=yes
17936fi
17937if test -z "$ac_cpp_err"; then
17938 have_readline=yes
17939else
17940 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000017941sed 's/^/| /' conftest.$ac_ext >&5
17942
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000017943 have_readline=no
17944fi
17945rm -f conftest.err conftest.$ac_ext
17946if test $have_readline = yes
17947then
17948 cat >conftest.$ac_ext <<_ACEOF
17949#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017950/* confdefs.h. */
17951_ACEOF
17952cat confdefs.h >>conftest.$ac_ext
17953cat >>conftest.$ac_ext <<_ACEOF
17954/* end confdefs.h. */
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000017955#include <readline/readline.h>
17956
17957_ACEOF
17958if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanarod8d39a02003-07-10 20:44:10 +000017959 $EGREP "extern int rl_completion_append_character;" >/dev/null 2>&1; then
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000017960
17961cat >>confdefs.h <<\_ACEOF
17962#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
17963_ACEOF
17964
17965fi
17966rm -f conftest*
17967
17968fi
17969
Martin v. Löwis0daad592001-09-30 21:09:59 +000017970# check for readline 4.0
Martin v. Löwis11437992002-04-12 09:54:03 +000017971echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
17972echo $ECHO_N "checking for rl_pre_input_hook in -lreadline... $ECHO_C" >&6
17973if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
17974 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000017975else
Martin v. Löwis11437992002-04-12 09:54:03 +000017976 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum353ae582001-07-10 16:45:32 +000017977LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000017978cat >conftest.$ac_ext <<_ACEOF
17979#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000017980/* confdefs.h. */
17981_ACEOF
17982cat confdefs.h >>conftest.$ac_ext
17983cat >>conftest.$ac_ext <<_ACEOF
17984/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017985
Guido van Rossum353ae582001-07-10 16:45:32 +000017986/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000017987#ifdef __cplusplus
17988extern "C"
17989#endif
Guido van Rossum353ae582001-07-10 16:45:32 +000017990/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000017991 builtin and then its argument prototype would still apply. */
17992char rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000017993int
17994main ()
17995{
17996rl_pre_input_hook ();
17997 ;
17998 return 0;
17999}
18000_ACEOF
18001rm -f conftest.$ac_objext conftest$ac_exeext
18002if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18003 (eval $ac_link) 2>&5
18004 ac_status=$?
18005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18006 (exit $ac_status); } &&
18007 { ac_try='test -s conftest$ac_exeext'
18008 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18009 (eval $ac_try) 2>&5
18010 ac_status=$?
18011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18012 (exit $ac_status); }; }; then
18013 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000018014else
Martin v. Löwis11437992002-04-12 09:54:03 +000018015 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018016sed 's/^/| /' conftest.$ac_ext >&5
18017
Martin v. Löwis11437992002-04-12 09:54:03 +000018018ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000018019fi
Martin v. Löwis11437992002-04-12 09:54:03 +000018020rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18021LIBS=$ac_check_lib_save_LIBS
18022fi
18023echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
18024echo "${ECHO_T}$ac_cv_lib_readline_rl_pre_input_hook" >&6
18025if test $ac_cv_lib_readline_rl_pre_input_hook = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000018026
Martin v. Löwis11437992002-04-12 09:54:03 +000018027cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000018028#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018029_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000018030
Martin v. Löwis0daad592001-09-30 21:09:59 +000018031fi
18032
Michael W. Hudson54241132001-12-07 15:38:26 +000018033
Martin v. Löwis0daad592001-09-30 21:09:59 +000018034# check for readline 4.2
Martin v. Löwis11437992002-04-12 09:54:03 +000018035echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
18036echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6
18037if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
18038 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000018039else
Martin v. Löwis11437992002-04-12 09:54:03 +000018040 ac_check_lib_save_LIBS=$LIBS
Martin v. Löwis0daad592001-09-30 21:09:59 +000018041LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000018042cat >conftest.$ac_ext <<_ACEOF
18043#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018044/* confdefs.h. */
18045_ACEOF
18046cat confdefs.h >>conftest.$ac_ext
18047cat >>conftest.$ac_ext <<_ACEOF
18048/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018049
Martin v. Löwis0daad592001-09-30 21:09:59 +000018050/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018051#ifdef __cplusplus
18052extern "C"
18053#endif
Martin v. Löwis0daad592001-09-30 21:09:59 +000018054/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000018055 builtin and then its argument prototype would still apply. */
18056char rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018057int
18058main ()
18059{
18060rl_completion_matches ();
18061 ;
18062 return 0;
18063}
18064_ACEOF
18065rm -f conftest.$ac_objext conftest$ac_exeext
18066if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18067 (eval $ac_link) 2>&5
18068 ac_status=$?
18069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18070 (exit $ac_status); } &&
18071 { ac_try='test -s conftest$ac_exeext'
18072 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18073 (eval $ac_try) 2>&5
18074 ac_status=$?
18075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18076 (exit $ac_status); }; }; then
18077 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000018078else
Martin v. Löwis11437992002-04-12 09:54:03 +000018079 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018080sed 's/^/| /' conftest.$ac_ext >&5
18081
Martin v. Löwis11437992002-04-12 09:54:03 +000018082ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000018083fi
Martin v. Löwis11437992002-04-12 09:54:03 +000018084rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18085LIBS=$ac_check_lib_save_LIBS
18086fi
18087echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
18088echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6
18089if test $ac_cv_lib_readline_rl_completion_matches = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000018090
Martin v. Löwis11437992002-04-12 09:54:03 +000018091cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000018092#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018093_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000018094
Guido van Rossum353ae582001-07-10 16:45:32 +000018095fi
18096
Jack Jansendd19cf82001-12-06 22:36:17 +000018097
Martin v. Löwis11437992002-04-12 09:54:03 +000018098echo "$as_me:$LINENO: checking for broken nice()" >&5
18099echo $ECHO_N "checking for broken nice()... $ECHO_C" >&6
18100if test "${ac_cv_broken_nice+set}" = set; then
18101 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000018102else
Martin v. Löwis11437992002-04-12 09:54:03 +000018103
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018104if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000018105 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018106else
Martin v. Löwis11437992002-04-12 09:54:03 +000018107 cat >conftest.$ac_ext <<_ACEOF
18108#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018109/* confdefs.h. */
18110_ACEOF
18111cat confdefs.h >>conftest.$ac_ext
18112cat >>conftest.$ac_ext <<_ACEOF
18113/* end confdefs.h. */
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018114
18115int main()
18116{
18117 int val1 = nice(1);
18118 if (val1 != -1 && val1 == nice(2))
18119 exit(0);
18120 exit(1);
18121}
18122
Martin v. Löwis11437992002-04-12 09:54:03 +000018123_ACEOF
18124rm -f conftest$ac_exeext
18125if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18126 (eval $ac_link) 2>&5
18127 ac_status=$?
18128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18129 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18131 (eval $ac_try) 2>&5
18132 ac_status=$?
18133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18134 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018135 ac_cv_broken_nice=yes
18136else
Martin v. Löwis11437992002-04-12 09:54:03 +000018137 echo "$as_me: program exited with status $ac_status" >&5
18138echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018139sed 's/^/| /' conftest.$ac_ext >&5
18140
Martin v. Löwis11437992002-04-12 09:54:03 +000018141( exit $ac_status )
18142ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018143fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000018144rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018145fi
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018146fi
18147
Martin v. Löwis11437992002-04-12 09:54:03 +000018148echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
18149echo "${ECHO_T}$ac_cv_broken_nice" >&6
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018150if test "$ac_cv_broken_nice" = yes
18151then
Martin v. Löwis11437992002-04-12 09:54:03 +000018152
18153cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018154#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018155_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000018156
18157fi
18158
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018159# tzset(3) exists and works like we expect it to
18160echo "$as_me:$LINENO: checking for working tzset()" >&5
18161echo $ECHO_N "checking for working tzset()... $ECHO_C" >&6
18162if test "${ac_cv_working_tzset+set}" = set; then
18163 echo $ECHO_N "(cached) $ECHO_C" >&6
18164else
18165
18166if test "$cross_compiling" = yes; then
18167 ac_cv_working_tzset=no
18168else
18169 cat >conftest.$ac_ext <<_ACEOF
18170#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018171/* confdefs.h. */
18172_ACEOF
18173cat confdefs.h >>conftest.$ac_ext
18174cat >>conftest.$ac_ext <<_ACEOF
18175/* end confdefs.h. */
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018176
18177#include <stdlib.h>
18178#include <time.h>
18179int main()
18180{
18181 int gmt_hour;
18182 int eastern_hour;
18183 time_t now;
18184 now = time((time_t*)NULL);
Neal Norwitz7f2588c2003-04-11 15:35:53 +000018185 putenv("TZ=UTC+0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018186 tzset();
18187 gmt_hour = localtime(&now)->tm_hour;
Neal Norwitz7f2588c2003-04-11 15:35:53 +000018188 putenv("TZ=EST+5EDT,M4.1.0,M10.5.0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018189 tzset();
18190 eastern_hour = localtime(&now)->tm_hour;
18191 if (eastern_hour == gmt_hour)
18192 exit(1);
18193 exit(0);
18194}
18195
18196_ACEOF
18197rm -f conftest$ac_exeext
18198if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18199 (eval $ac_link) 2>&5
18200 ac_status=$?
18201 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18202 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18203 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18204 (eval $ac_try) 2>&5
18205 ac_status=$?
18206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18207 (exit $ac_status); }; }; then
18208 ac_cv_working_tzset=yes
18209else
18210 echo "$as_me: program exited with status $ac_status" >&5
18211echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018212sed 's/^/| /' conftest.$ac_ext >&5
18213
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018214( exit $ac_status )
18215ac_cv_working_tzset=no
18216fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000018217rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumd11b62e2003-03-14 21:51:36 +000018218fi
18219fi
18220
18221echo "$as_me:$LINENO: result: $ac_cv_working_tzset" >&5
18222echo "${ECHO_T}$ac_cv_working_tzset" >&6
18223if test "$ac_cv_working_tzset" = yes
18224then
18225
18226cat >>confdefs.h <<\_ACEOF
18227#define HAVE_WORKING_TZSET 1
18228_ACEOF
18229
18230fi
18231
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018232# Look for subsecond timestamps in struct stat
18233echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
18234echo $ECHO_N "checking for tv_nsec in struct stat... $ECHO_C" >&6
18235if test "${ac_cv_stat_tv_nsec+set}" = set; then
18236 echo $ECHO_N "(cached) $ECHO_C" >&6
18237else
18238 cat >conftest.$ac_ext <<_ACEOF
18239#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018240/* confdefs.h. */
18241_ACEOF
18242cat confdefs.h >>conftest.$ac_ext
18243cat >>conftest.$ac_ext <<_ACEOF
18244/* end confdefs.h. */
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018245#include <sys/stat.h>
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018246int
18247main ()
18248{
18249
18250struct stat st;
18251st.st_mtim.tv_nsec = 1;
18252
18253 ;
18254 return 0;
18255}
18256_ACEOF
18257rm -f conftest.$ac_objext
18258if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18259 (eval $ac_compile) 2>&5
18260 ac_status=$?
18261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18262 (exit $ac_status); } &&
18263 { ac_try='test -s conftest.$ac_objext'
18264 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18265 (eval $ac_try) 2>&5
18266 ac_status=$?
18267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18268 (exit $ac_status); }; }; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000018269 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018270else
18271 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018272sed 's/^/| /' conftest.$ac_ext >&5
18273
Martin v. Löwis94717ed2002-09-09 14:24:16 +000018274ac_cv_stat_tv_nsec=no
18275fi
18276rm -f conftest.$ac_objext conftest.$ac_ext
18277fi
18278
18279echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
18280echo "${ECHO_T}$ac_cv_stat_tv_nsec" >&6
18281if test "$ac_cv_stat_tv_nsec" = yes
18282then
18283
18284cat >>confdefs.h <<\_ACEOF
18285#define HAVE_STAT_TV_NSEC 1
18286_ACEOF
18287
18288fi
18289
Jack Jansen666b1e72001-10-31 12:11:48 +000018290# On HP/UX 11.0, mvwdelch is a block with a return statement
Martin v. Löwis11437992002-04-12 09:54:03 +000018291echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
18292echo $ECHO_N "checking whether mvwdelch is an expression... $ECHO_C" >&6
18293if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
18294 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000018295else
Martin v. Löwis11437992002-04-12 09:54:03 +000018296 cat >conftest.$ac_ext <<_ACEOF
18297#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018298/* confdefs.h. */
18299_ACEOF
18300cat confdefs.h >>conftest.$ac_ext
18301cat >>conftest.$ac_ext <<_ACEOF
18302/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000018303#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000018304int
18305main ()
18306{
Jack Jansen666b1e72001-10-31 12:11:48 +000018307
18308 int rtn;
18309 rtn = mvwdelch(0,0,0);
18310
Martin v. Löwis11437992002-04-12 09:54:03 +000018311 ;
18312 return 0;
18313}
18314_ACEOF
18315rm -f conftest.$ac_objext
18316if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18317 (eval $ac_compile) 2>&5
18318 ac_status=$?
18319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18320 (exit $ac_status); } &&
18321 { ac_try='test -s conftest.$ac_objext'
18322 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18323 (eval $ac_try) 2>&5
18324 ac_status=$?
18325 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18326 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000018327 ac_cv_mvwdelch_is_expression=yes
18328else
Martin v. Löwis11437992002-04-12 09:54:03 +000018329 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018330sed 's/^/| /' conftest.$ac_ext >&5
18331
Martin v. Löwis11437992002-04-12 09:54:03 +000018332ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000018333fi
Martin v. Löwis11437992002-04-12 09:54:03 +000018334rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000018335fi
18336
Martin v. Löwis11437992002-04-12 09:54:03 +000018337echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
18338echo "${ECHO_T}$ac_cv_mvwdelch_is_expression" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000018339
18340if test "$ac_cv_mvwdelch_is_expression" = yes
18341then
Martin v. Löwis11437992002-04-12 09:54:03 +000018342
18343cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000018344#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018345_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000018346
18347fi
18348
Martin v. Löwis11437992002-04-12 09:54:03 +000018349echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
18350echo $ECHO_N "checking whether WINDOW has _flags... $ECHO_C" >&6
18351if test "${ac_cv_window_has_flags+set}" = set; then
18352 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000018353else
Martin v. Löwis11437992002-04-12 09:54:03 +000018354 cat >conftest.$ac_ext <<_ACEOF
18355#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018356/* confdefs.h. */
18357_ACEOF
18358cat confdefs.h >>conftest.$ac_ext
18359cat >>conftest.$ac_ext <<_ACEOF
18360/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000018361#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000018362int
18363main ()
18364{
Jack Jansen666b1e72001-10-31 12:11:48 +000018365
18366 WINDOW *w;
18367 w->_flags = 0;
18368
Martin v. Löwis11437992002-04-12 09:54:03 +000018369 ;
18370 return 0;
18371}
18372_ACEOF
18373rm -f conftest.$ac_objext
18374if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18375 (eval $ac_compile) 2>&5
18376 ac_status=$?
18377 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18378 (exit $ac_status); } &&
18379 { ac_try='test -s conftest.$ac_objext'
18380 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18381 (eval $ac_try) 2>&5
18382 ac_status=$?
18383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18384 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000018385 ac_cv_window_has_flags=yes
18386else
Martin v. Löwis11437992002-04-12 09:54:03 +000018387 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018388sed 's/^/| /' conftest.$ac_ext >&5
18389
Martin v. Löwis11437992002-04-12 09:54:03 +000018390ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000018391fi
Martin v. Löwis11437992002-04-12 09:54:03 +000018392rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000018393fi
18394
Martin v. Löwis11437992002-04-12 09:54:03 +000018395echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
18396echo "${ECHO_T}$ac_cv_window_has_flags" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000018397
Jack Jansen666b1e72001-10-31 12:11:48 +000018398
18399if test "$ac_cv_window_has_flags" = yes
18400then
Martin v. Löwis11437992002-04-12 09:54:03 +000018401
18402cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000018403#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018404_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000018405
18406fi
18407
Martin v. Löwis24a880b2002-12-31 12:55:15 +000018408echo "$as_me:$LINENO: checking for /dev/ptmx" >&5
18409echo $ECHO_N "checking for /dev/ptmx... $ECHO_C" >&6
18410
18411if test -e /dev/ptmx
18412then
18413 echo "$as_me:$LINENO: result: yes" >&5
18414echo "${ECHO_T}yes" >&6
18415
18416cat >>confdefs.h <<\_ACEOF
18417#define HAVE_DEV_PTMX 1
18418_ACEOF
18419
18420else
18421 echo "$as_me:$LINENO: result: no" >&5
18422echo "${ECHO_T}no" >&6
18423fi
18424
Neal Norwitz865400f2003-03-21 01:42:58 +000018425echo "$as_me:$LINENO: checking for /dev/ptc" >&5
18426echo $ECHO_N "checking for /dev/ptc... $ECHO_C" >&6
18427
18428if test -e /dev/ptc
18429then
18430 echo "$as_me:$LINENO: result: yes" >&5
18431echo "${ECHO_T}yes" >&6
18432
18433cat >>confdefs.h <<\_ACEOF
18434#define HAVE_DEV_PTC 1
18435_ACEOF
18436
18437else
18438 echo "$as_me:$LINENO: result: no" >&5
18439echo "${ECHO_T}no" >&6
18440fi
18441
Martin v. Löwis11437992002-04-12 09:54:03 +000018442echo "$as_me:$LINENO: checking for socklen_t" >&5
18443echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
18444if test "${ac_cv_type_socklen_t+set}" = set; then
18445 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000018446else
Martin v. Löwis11437992002-04-12 09:54:03 +000018447 cat >conftest.$ac_ext <<_ACEOF
18448#line $LINENO "configure"
Skip Montanarod8d39a02003-07-10 20:44:10 +000018449/* confdefs.h. */
18450_ACEOF
18451cat confdefs.h >>conftest.$ac_ext
18452cat >>conftest.$ac_ext <<_ACEOF
18453/* end confdefs.h. */
Martin v. Löwis01c04012002-11-11 14:58:44 +000018454
18455#ifdef HAVE_SYS_TYPES_H
18456#include <sys/types.h>
18457#endif
18458#ifdef HAVE_SYS_SOCKET_H
18459#include <sys/socket.h>
18460#endif
18461
18462
Martin v. Löwis11437992002-04-12 09:54:03 +000018463int
18464main ()
18465{
18466if ((socklen_t *) 0)
18467 return 0;
18468if (sizeof (socklen_t))
18469 return 0;
18470 ;
18471 return 0;
18472}
18473_ACEOF
18474rm -f conftest.$ac_objext
18475if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18476 (eval $ac_compile) 2>&5
18477 ac_status=$?
18478 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18479 (exit $ac_status); } &&
18480 { ac_try='test -s conftest.$ac_objext'
18481 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18482 (eval $ac_try) 2>&5
18483 ac_status=$?
18484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
18485 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000018486 ac_cv_type_socklen_t=yes
Guido van Rossum95713eb2000-05-18 20:53:31 +000018487else
Martin v. Löwis11437992002-04-12 09:54:03 +000018488 echo "$as_me: failed program was:" >&5
Skip Montanarod8d39a02003-07-10 20:44:10 +000018489sed 's/^/| /' conftest.$ac_ext >&5
18490
Martin v. Löwis11437992002-04-12 09:54:03 +000018491ac_cv_type_socklen_t=no
Guido van Rossum95713eb2000-05-18 20:53:31 +000018492fi
Martin v. Löwis11437992002-04-12 09:54:03 +000018493rm -f conftest.$ac_objext conftest.$ac_ext
18494fi
18495echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
18496echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
18497if test $ac_cv_type_socklen_t = yes; then
18498 :
18499else
Guido van Rossum95713eb2000-05-18 20:53:31 +000018500
Martin v. Löwis01c04012002-11-11 14:58:44 +000018501cat >>confdefs.h <<\_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000018502#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000018503_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000018504
18505fi
18506
Michael W. Hudson54241132001-12-07 15:38:26 +000018507
Michael W. Hudson54241132001-12-07 15:38:26 +000018508
18509
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000018510for h in `(cd $srcdir;echo Python/thread_*.h)`
18511do
18512 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
18513done
18514
Michael W. Hudson54241132001-12-07 15:38:26 +000018515
Jack Jansen0b06be72002-06-21 14:48:38 +000018516SRCDIRS="Parser Grammar Objects Python Modules Mac Mac/Python"
Martin v. Löwis11437992002-04-12 09:54:03 +000018517echo "$as_me:$LINENO: checking for build directories" >&5
18518echo $ECHO_N "checking for build directories... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +000018519for dir in $SRCDIRS; do
18520 if test ! -d $dir; then
18521 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000018522 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000018523done
Martin v. Löwis11437992002-04-12 09:54:03 +000018524echo "$as_me:$LINENO: result: done" >&5
18525echo "${ECHO_T}done" >&6
Fred Drake036144d2000-10-26 17:09:35 +000018526
Guido van Rossum627b2d71993-12-24 10:39:16 +000018527# generate output files
Skip Montanarod8d39a02003-07-10 20:44:10 +000018528 ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config"
Martin v. Löwis88afe662002-10-26 13:47:44 +000018529
Martin v. Löwis11437992002-04-12 09:54:03 +000018530cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018531# This file is a shell script that caches the results of configure
18532# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000018533# scripts and configure runs, see configure's option --config-cache.
18534# It is not useful on other systems. If it contains results you don't
18535# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018536#
Martin v. Löwis11437992002-04-12 09:54:03 +000018537# config.status only pays attention to the cache file if you give it
18538# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018539#
Skip Montanarod8d39a02003-07-10 20:44:10 +000018540# `ac_cv_env_foo' variables (set or unset) will be overridden when
Martin v. Löwis11437992002-04-12 09:54:03 +000018541# loading this file, other *unset* `ac_cv_foo' will be assigned the
18542# following values.
18543
18544_ACEOF
18545
Guido van Rossumf78abae1997-01-21 22:02:36 +000018546# The following way of writing the cache mishandles newlines in values,
18547# but we know of no workaround that is simple, portable, and efficient.
18548# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000018549# Ultrix sh set writes to stderr and can't be redirected directly,
18550# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwis11437992002-04-12 09:54:03 +000018551{
18552 (set) 2>&1 |
18553 case `(ac_space=' '; set | grep ac_space) 2>&1` in
18554 *ac_space=\ *)
18555 # `set' does not quote correctly, so add quotes (double-quote
18556 # substitution turns \\\\ into \\, and sed turns \\ into \).
18557 sed -n \
18558 "s/'/'\\\\''/g;
18559 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
18560 ;;
18561 *)
18562 # `set' quotes correctly as required by POSIX, so do not add quotes.
18563 sed -n \
18564 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
18565 ;;
18566 esac;
18567} |
18568 sed '
18569 t clear
18570 : clear
18571 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
18572 t end
18573 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
18574 : end' >>confcache
Skip Montanarod8d39a02003-07-10 20:44:10 +000018575if diff $cache_file confcache >/dev/null 2>&1; then :; else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000018576 if test -w $cache_file; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018577 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
18578 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000018579 else
18580 echo "not updating unwritable cache $cache_file"
18581 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018582fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000018583rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000018584
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018585test "x$prefix" = xNONE && prefix=$ac_default_prefix
18586# Let make expand exec_prefix.
18587test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000018588
Martin v. Löwis11437992002-04-12 09:54:03 +000018589# VPATH may cause trouble with some makes, so we remove $(srcdir),
18590# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
18591# trailing colons and then remove the whole line if VPATH becomes empty
18592# (actually we leave an empty line to preserve line numbers).
Guido van Rossum7f43da71994-08-01 12:15:30 +000018593if test "x$srcdir" = x.; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018594 ac_vpsub='/^[ ]*VPATH[ ]*=/{
18595s/:*\$(srcdir):*/:/;
18596s/:*\${srcdir}:*/:/;
18597s/:*@srcdir@:*/:/;
18598s/^\([^=]*=[ ]*\):*/\1/;
18599s/:*$//;
18600s/^[^=]*=[ ]*$//;
18601}'
Guido van Rossum7f43da71994-08-01 12:15:30 +000018602fi
18603
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018604DEFS=-DHAVE_CONFIG_H
18605
Skip Montanarod8d39a02003-07-10 20:44:10 +000018606ac_libobjs=
18607ac_ltlibobjs=
18608for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
18609 # 1. Remove the extension, and $U if already installed.
18610 ac_i=`echo "$ac_i" |
18611 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
18612 # 2. Add them.
18613 ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
18614 ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
18615done
18616LIBOBJS=$ac_libobjs
18617
18618LTLIBOBJS=$ac_ltlibobjs
18619
18620
Martin v. Löwis11437992002-04-12 09:54:03 +000018621
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018622: ${CONFIG_STATUS=./config.status}
Martin v. Löwis11437992002-04-12 09:54:03 +000018623ac_clean_files_save=$ac_clean_files
18624ac_clean_files="$ac_clean_files $CONFIG_STATUS"
18625{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
18626echo "$as_me: creating $CONFIG_STATUS" >&6;}
18627cat >$CONFIG_STATUS <<_ACEOF
18628#! $SHELL
18629# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000018630# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018631# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000018632# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000018633
Martin v. Löwis11437992002-04-12 09:54:03 +000018634debug=false
Skip Montanarod8d39a02003-07-10 20:44:10 +000018635ac_cs_recheck=false
18636ac_cs_silent=false
Martin v. Löwis11437992002-04-12 09:54:03 +000018637SHELL=\${CONFIG_SHELL-$SHELL}
18638_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000018639
Martin v. Löwis11437992002-04-12 09:54:03 +000018640cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000018641## --------------------- ##
18642## M4sh Initialization. ##
18643## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000018644
Martin v. Löwis11437992002-04-12 09:54:03 +000018645# Be Bourne compatible
18646if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18647 emulate sh
18648 NULLCMD=:
Skip Montanarod8d39a02003-07-10 20:44:10 +000018649 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
18650 # is contrary to our usage. Disable this feature.
18651 alias -g '${1+"$@"}'='"$@"'
Martin v. Löwis11437992002-04-12 09:54:03 +000018652elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
18653 set -o posix
Michael W. Hudson54241132001-12-07 15:38:26 +000018654fi
Michael W. Hudson54241132001-12-07 15:38:26 +000018655
Martin v. Löwis11437992002-04-12 09:54:03 +000018656# Support unset when possible.
18657if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
18658 as_unset=unset
18659else
18660 as_unset=false
18661fi
Michael W. Hudson54241132001-12-07 15:38:26 +000018662
Skip Montanarod8d39a02003-07-10 20:44:10 +000018663
18664# Work around bugs in pre-3.0 UWIN ksh.
18665$as_unset ENV MAIL MAILPATH
18666PS1='$ '
18667PS2='> '
18668PS4='+ '
18669
18670# NLS nuisances.
18671for as_var in \
18672 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
18673 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
18674 LC_TELEPHONE LC_TIME
18675do
18676 if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
18677 eval $as_var=C; export $as_var
18678 else
18679 $as_unset $as_var
18680 fi
18681done
18682
18683# Required to use basename.
18684if expr a : '\(a\)' >/dev/null 2>&1; then
18685 as_expr=expr
18686else
18687 as_expr=false
18688fi
18689
18690if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
18691 as_basename=basename
18692else
18693 as_basename=false
18694fi
Martin v. Löwis11437992002-04-12 09:54:03 +000018695
18696
18697# Name of the executable.
Skip Montanarod8d39a02003-07-10 20:44:10 +000018698as_me=`$as_basename "$0" ||
Martin v. Löwis11437992002-04-12 09:54:03 +000018699$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
18700 X"$0" : 'X\(//\)$' \| \
18701 X"$0" : 'X\(/\)$' \| \
18702 . : '\(.\)' 2>/dev/null ||
18703echo X/"$0" |
18704 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
18705 /^X\/\(\/\/\)$/{ s//\1/; q; }
18706 /^X\/\(\/\).*/{ s//\1/; q; }
18707 s/.*/./; q'`
18708
Skip Montanarod8d39a02003-07-10 20:44:10 +000018709
Martin v. Löwis11437992002-04-12 09:54:03 +000018710# PATH needs CR, and LINENO needs CR and PATH.
18711# Avoid depending upon Character Ranges.
18712as_cr_letters='abcdefghijklmnopqrstuvwxyz'
18713as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
18714as_cr_Letters=$as_cr_letters$as_cr_LETTERS
18715as_cr_digits='0123456789'
18716as_cr_alnum=$as_cr_Letters$as_cr_digits
18717
18718# The user is always right.
18719if test "${PATH_SEPARATOR+set}" != set; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000018720 echo "#! /bin/sh" >conf$$.sh
18721 echo "exit 0" >>conf$$.sh
18722 chmod +x conf$$.sh
18723 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018724 PATH_SEPARATOR=';'
18725 else
18726 PATH_SEPARATOR=:
18727 fi
Skip Montanarod8d39a02003-07-10 20:44:10 +000018728 rm -f conf$$.sh
Martin v. Löwis11437992002-04-12 09:54:03 +000018729fi
18730
18731
18732 as_lineno_1=$LINENO
18733 as_lineno_2=$LINENO
18734 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18735 test "x$as_lineno_1" != "x$as_lineno_2" &&
18736 test "x$as_lineno_3" = "x$as_lineno_2" || {
18737 # Find who we are. Look in the path if we contain no path at all
18738 # relative or not.
18739 case $0 in
18740 *[\\/]* ) as_myself=$0 ;;
18741 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18742for as_dir in $PATH
18743do
18744 IFS=$as_save_IFS
18745 test -z "$as_dir" && as_dir=.
18746 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
18747done
18748
18749 ;;
18750 esac
18751 # We did not find ourselves, most probably we were run as `sh COMMAND'
18752 # in which case we are not to be found in the path.
18753 if test "x$as_myself" = x; then
18754 as_myself=$0
18755 fi
18756 if test ! -f "$as_myself"; then
18757 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
18758echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
18759 { (exit 1); exit 1; }; }
18760 fi
18761 case $CONFIG_SHELL in
18762 '')
18763 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18764for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
18765do
18766 IFS=$as_save_IFS
18767 test -z "$as_dir" && as_dir=.
18768 for as_base in sh bash ksh sh5; do
18769 case $as_dir in
18770 /*)
18771 if ("$as_dir/$as_base" -c '
18772 as_lineno_1=$LINENO
18773 as_lineno_2=$LINENO
18774 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
18775 test "x$as_lineno_1" != "x$as_lineno_2" &&
18776 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000018777 $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
18778 $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
Martin v. Löwis11437992002-04-12 09:54:03 +000018779 CONFIG_SHELL=$as_dir/$as_base
18780 export CONFIG_SHELL
18781 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
18782 fi;;
18783 esac
18784 done
18785done
18786;;
Jack Jansendd19cf82001-12-06 22:36:17 +000018787 esac
18788
Martin v. Löwis11437992002-04-12 09:54:03 +000018789 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
18790 # uniformly replaced by the line number. The first 'sed' inserts a
18791 # line-number line before each line; the second 'sed' does the real
18792 # work. The second script uses 'N' to pair each line-number line
18793 # with the numbered line, and appends trailing '-' during
18794 # substitution so that $LINENO is not a special case at line end.
18795 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
18796 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
18797 sed '=' <$as_myself |
18798 sed '
18799 N
18800 s,$,-,
18801 : loop
18802 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
18803 t loop
18804 s,-$,,
18805 s,^['$as_cr_digits']*\n,,
18806 ' >$as_me.lineno &&
18807 chmod +x $as_me.lineno ||
18808 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
18809echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
18810 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000018811
Martin v. Löwis11437992002-04-12 09:54:03 +000018812 # Don't try to exec as it changes $[0], causing all sort of problems
18813 # (the dirname of $[0] is not the place where we might find the
18814 # original and so on. Autoconf is especially sensible to this).
18815 . ./$as_me.lineno
18816 # Exit status is that of the last command.
18817 exit
18818}
18819
18820
18821case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
18822 *c*,-n*) ECHO_N= ECHO_C='
18823' ECHO_T=' ' ;;
18824 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
18825 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
18826esac
18827
18828if expr a : '\(a\)' >/dev/null 2>&1; then
18829 as_expr=expr
18830else
18831 as_expr=false
18832fi
18833
18834rm -f conf$$ conf$$.exe conf$$.file
18835echo >conf$$.file
18836if ln -s conf$$.file conf$$ 2>/dev/null; then
18837 # We could just check for DJGPP; but this test a) works b) is more generic
18838 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
18839 if test -f conf$$.exe; then
18840 # Don't use ln at all; we don't have any links
18841 as_ln_s='cp -p'
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018842 else
Martin v. Löwis11437992002-04-12 09:54:03 +000018843 as_ln_s='ln -s'
18844 fi
18845elif ln conf$$.file conf$$ 2>/dev/null; then
18846 as_ln_s=ln
18847else
18848 as_ln_s='cp -p'
18849fi
18850rm -f conf$$ conf$$.exe conf$$.file
18851
Skip Montanarod8d39a02003-07-10 20:44:10 +000018852if mkdir -p . 2>/dev/null; then
18853 as_mkdir_p=:
18854else
18855 as_mkdir_p=false
18856fi
18857
Martin v. Löwis11437992002-04-12 09:54:03 +000018858as_executable_p="test -f"
18859
18860# Sed expression to map a string onto a valid CPP name.
18861as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
18862
18863# Sed expression to map a string onto a valid variable name.
18864as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
18865
18866
18867# IFS
18868# We need space, tab and new line, in precisely that order.
18869as_nl='
18870'
18871IFS=" $as_nl"
18872
18873# CDPATH.
Skip Montanarod8d39a02003-07-10 20:44:10 +000018874$as_unset CDPATH
Martin v. Löwis11437992002-04-12 09:54:03 +000018875
18876exec 6>&1
18877
18878# Open the log real soon, to keep \$[0] and so on meaningful, and to
18879# report actual input values of CONFIG_FILES etc. instead of their
18880# values after options handling. Logging --version etc. is OK.
18881exec 5>>config.log
18882{
18883 echo
18884 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
18885## Running $as_me. ##
18886_ASBOX
18887} >&5
18888cat >&5 <<_CSEOF
18889
Martin v. Löwis88afe662002-10-26 13:47:44 +000018890This file was extended by python $as_me 2.3, which was
Skip Montanarod8d39a02003-07-10 20:44:10 +000018891generated by GNU Autoconf 2.57. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +000018892
18893 CONFIG_FILES = $CONFIG_FILES
18894 CONFIG_HEADERS = $CONFIG_HEADERS
18895 CONFIG_LINKS = $CONFIG_LINKS
18896 CONFIG_COMMANDS = $CONFIG_COMMANDS
18897 $ $0 $@
18898
18899_CSEOF
18900echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
18901echo >&5
18902_ACEOF
18903
18904# Files that config.status was made for.
18905if test -n "$ac_config_files"; then
18906 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
18907fi
18908
18909if test -n "$ac_config_headers"; then
18910 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
18911fi
18912
18913if test -n "$ac_config_links"; then
18914 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
18915fi
18916
18917if test -n "$ac_config_commands"; then
18918 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
18919fi
18920
18921cat >>$CONFIG_STATUS <<\_ACEOF
18922
18923ac_cs_usage="\
18924\`$as_me' instantiates files from templates according to the
18925current configuration.
18926
18927Usage: $0 [OPTIONS] [FILE]...
18928
18929 -h, --help print this help, then exit
18930 -V, --version print version number, then exit
Skip Montanarod8d39a02003-07-10 20:44:10 +000018931 -q, --quiet do not print progress messages
Martin v. Löwis11437992002-04-12 09:54:03 +000018932 -d, --debug don't remove temporary files
18933 --recheck update $as_me by reconfiguring in the same conditions
18934 --file=FILE[:TEMPLATE]
18935 instantiate the configuration file FILE
18936 --header=FILE[:TEMPLATE]
18937 instantiate the configuration header FILE
18938
18939Configuration files:
18940$config_files
18941
18942Configuration headers:
18943$config_headers
18944
18945Report bugs to <bug-autoconf@gnu.org>."
18946_ACEOF
18947
18948cat >>$CONFIG_STATUS <<_ACEOF
18949ac_cs_version="\\
Martin v. Löwis88afe662002-10-26 13:47:44 +000018950python config.status 2.3
Skip Montanarod8d39a02003-07-10 20:44:10 +000018951configured by $0, generated by GNU Autoconf 2.57,
Martin v. Löwis11437992002-04-12 09:54:03 +000018952 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
18953
18954Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
18955Free Software Foundation, Inc.
18956This config.status script is free software; the Free Software Foundation
18957gives unlimited permission to copy, distribute and modify it."
18958srcdir=$srcdir
18959INSTALL="$INSTALL"
18960_ACEOF
18961
18962cat >>$CONFIG_STATUS <<\_ACEOF
18963# If no file are specified by the user, then we need to provide default
18964# value. By we need to know if files were specified by the user.
18965ac_need_defaults=:
18966while test $# != 0
18967do
18968 case $1 in
18969 --*=*)
18970 ac_option=`expr "x$1" : 'x\([^=]*\)='`
18971 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
Skip Montanarod8d39a02003-07-10 20:44:10 +000018972 ac_shift=:
Martin v. Löwis11437992002-04-12 09:54:03 +000018973 ;;
Skip Montanarod8d39a02003-07-10 20:44:10 +000018974 -*)
18975 ac_option=$1
18976 ac_optarg=$2
18977 ac_shift=shift
18978 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000018979 *) # This is not an option, so the user has probably given explicit
18980 # arguments.
Skip Montanarod8d39a02003-07-10 20:44:10 +000018981 ac_option=$1
Martin v. Löwis11437992002-04-12 09:54:03 +000018982 ac_need_defaults=false;;
18983 esac
18984
Skip Montanarod8d39a02003-07-10 20:44:10 +000018985 case $ac_option in
Martin v. Löwis11437992002-04-12 09:54:03 +000018986 # Handling of the options.
18987_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000018988cat >>$CONFIG_STATUS <<\_ACEOF
Skip Montanarod8d39a02003-07-10 20:44:10 +000018989 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
18990 ac_cs_recheck=: ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000018991 --version | --vers* | -V )
18992 echo "$ac_cs_version"; exit 0 ;;
18993 --he | --h)
18994 # Conflict between --help and --header
18995 { { echo "$as_me:$LINENO: error: ambiguous option: $1
18996Try \`$0 --help' for more information." >&5
18997echo "$as_me: error: ambiguous option: $1
18998Try \`$0 --help' for more information." >&2;}
18999 { (exit 1); exit 1; }; };;
19000 --help | --hel | -h )
19001 echo "$ac_cs_usage"; exit 0 ;;
19002 --debug | --d* | -d )
19003 debug=: ;;
19004 --file | --fil | --fi | --f )
Skip Montanarod8d39a02003-07-10 20:44:10 +000019005 $ac_shift
19006 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
Martin v. Löwis11437992002-04-12 09:54:03 +000019007 ac_need_defaults=false;;
19008 --header | --heade | --head | --hea )
Skip Montanarod8d39a02003-07-10 20:44:10 +000019009 $ac_shift
19010 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
Martin v. Löwis11437992002-04-12 09:54:03 +000019011 ac_need_defaults=false;;
Skip Montanarod8d39a02003-07-10 20:44:10 +000019012 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
19013 | -silent | --silent | --silen | --sile | --sil | --si | --s)
19014 ac_cs_silent=: ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000019015
19016 # This is an error.
19017 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
19018Try \`$0 --help' for more information." >&5
19019echo "$as_me: error: unrecognized option: $1
19020Try \`$0 --help' for more information." >&2;}
19021 { (exit 1); exit 1; }; } ;;
19022
19023 *) ac_config_targets="$ac_config_targets $1" ;;
19024
19025 esac
19026 shift
19027done
19028
Skip Montanarod8d39a02003-07-10 20:44:10 +000019029ac_configure_extra_args=
19030
19031if $ac_cs_silent; then
19032 exec 6>/dev/null
19033 ac_configure_extra_args="$ac_configure_extra_args --silent"
19034fi
19035
19036_ACEOF
19037cat >>$CONFIG_STATUS <<_ACEOF
19038if \$ac_cs_recheck; then
19039 echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
19040 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
19041fi
19042
Martin v. Löwis11437992002-04-12 09:54:03 +000019043_ACEOF
19044
19045
19046
19047
19048
19049cat >>$CONFIG_STATUS <<\_ACEOF
19050for ac_config_target in $ac_config_targets
19051do
19052 case "$ac_config_target" in
19053 # Handling of arguments.
19054 "Makefile.pre" ) CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
19055 "Modules/Setup.config" ) CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
19056 "pyconfig.h" ) CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
19057 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
19058echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
19059 { (exit 1); exit 1; }; };;
19060 esac
19061done
19062
19063# If the user did not use the arguments to specify the items to instantiate,
19064# then the envvar interface is used. Set only those that are not.
19065# We use the long form for the default assignment because of an extremely
19066# bizarre bug on SunOS 4.1.3.
19067if $ac_need_defaults; then
19068 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19069 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19070fi
19071
Skip Montanarod8d39a02003-07-10 20:44:10 +000019072# Have a temporary directory for convenience. Make it in the build tree
19073# simply because there is no reason to put it here, and in addition,
19074# creating and moving files from /tmp can sometimes cause problems.
Martin v. Löwis11437992002-04-12 09:54:03 +000019075# Create a temporary directory, and hook for its removal unless debugging.
19076$debug ||
19077{
19078 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
19079 trap '{ (exit 1); exit 1; }' 1 2 13 15
19080}
19081
19082# Create a (secure) tmp directory for tmp files.
Skip Montanarod8d39a02003-07-10 20:44:10 +000019083
Martin v. Löwis11437992002-04-12 09:54:03 +000019084{
Skip Montanarod8d39a02003-07-10 20:44:10 +000019085 tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
Martin v. Löwis11437992002-04-12 09:54:03 +000019086 test -n "$tmp" && test -d "$tmp"
19087} ||
19088{
Skip Montanarod8d39a02003-07-10 20:44:10 +000019089 tmp=./confstat$$-$RANDOM
Martin v. Löwis11437992002-04-12 09:54:03 +000019090 (umask 077 && mkdir $tmp)
19091} ||
19092{
Skip Montanarod8d39a02003-07-10 20:44:10 +000019093 echo "$me: cannot create a temporary directory in ." >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000019094 { (exit 1); exit 1; }
19095}
19096
19097_ACEOF
19098
19099cat >>$CONFIG_STATUS <<_ACEOF
19100
19101#
19102# CONFIG_FILES section.
19103#
19104
19105# No need to generate the scripts if there are no CONFIG_FILES.
19106# This happens for instance when ./config.status config.h
19107if test -n "\$CONFIG_FILES"; then
19108 # Protect against being on the right side of a sed subst in config.status.
19109 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
19110 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
19111s,@SHELL@,$SHELL,;t t
19112s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
19113s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
19114s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
19115s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
19116s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
19117s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
19118s,@exec_prefix@,$exec_prefix,;t t
19119s,@prefix@,$prefix,;t t
19120s,@program_transform_name@,$program_transform_name,;t t
19121s,@bindir@,$bindir,;t t
19122s,@sbindir@,$sbindir,;t t
19123s,@libexecdir@,$libexecdir,;t t
19124s,@datadir@,$datadir,;t t
19125s,@sysconfdir@,$sysconfdir,;t t
19126s,@sharedstatedir@,$sharedstatedir,;t t
19127s,@localstatedir@,$localstatedir,;t t
19128s,@libdir@,$libdir,;t t
19129s,@includedir@,$includedir,;t t
19130s,@oldincludedir@,$oldincludedir,;t t
19131s,@infodir@,$infodir,;t t
19132s,@mandir@,$mandir,;t t
19133s,@build_alias@,$build_alias,;t t
19134s,@host_alias@,$host_alias,;t t
19135s,@target_alias@,$target_alias,;t t
19136s,@DEFS@,$DEFS,;t t
19137s,@ECHO_C@,$ECHO_C,;t t
19138s,@ECHO_N@,$ECHO_N,;t t
19139s,@ECHO_T@,$ECHO_T,;t t
19140s,@LIBS@,$LIBS,;t t
19141s,@VERSION@,$VERSION,;t t
19142s,@SOVERSION@,$SOVERSION,;t t
19143s,@CONFIG_ARGS@,$CONFIG_ARGS,;t t
19144s,@PYTHONFRAMEWORK@,$PYTHONFRAMEWORK,;t t
19145s,@PYTHONFRAMEWORKDIR@,$PYTHONFRAMEWORKDIR,;t t
19146s,@PYTHONFRAMEWORKPREFIX@,$PYTHONFRAMEWORKPREFIX,;t t
19147s,@PYTHONFRAMEWORKINSTALLDIR@,$PYTHONFRAMEWORKINSTALLDIR,;t t
19148s,@MACHDEP@,$MACHDEP,;t t
19149s,@SGI_ABI@,$SGI_ABI,;t t
Jack Jansen83f898c2002-12-30 22:23:40 +000019150s,@EXTRAPLATDIR@,$EXTRAPLATDIR,;t t
Jack Jansen7b59b422003-03-17 15:44:10 +000019151s,@EXTRAMACHDEPPATH@,$EXTRAMACHDEPPATH,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000019152s,@CXX@,$CXX,;t t
19153s,@MAINOBJ@,$MAINOBJ,;t t
19154s,@EXEEXT@,$EXEEXT,;t t
19155s,@CC@,$CC,;t t
19156s,@CFLAGS@,$CFLAGS,;t t
19157s,@LDFLAGS@,$LDFLAGS,;t t
19158s,@CPPFLAGS@,$CPPFLAGS,;t t
19159s,@ac_ct_CC@,$ac_ct_CC,;t t
19160s,@OBJEXT@,$OBJEXT,;t t
19161s,@CPP@,$CPP,;t t
Skip Montanarod8d39a02003-07-10 20:44:10 +000019162s,@EGREP@,$EGREP,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000019163s,@BUILDEXEEXT@,$BUILDEXEEXT,;t t
19164s,@LIBRARY@,$LIBRARY,;t t
19165s,@LDLIBRARY@,$LDLIBRARY,;t t
19166s,@DLLLIBRARY@,$DLLLIBRARY,;t t
19167s,@BLDLIBRARY@,$BLDLIBRARY,;t t
19168s,@LDLIBRARYDIR@,$LDLIBRARYDIR,;t t
19169s,@INSTSONAME@,$INSTSONAME,;t t
19170s,@RUNSHARED@,$RUNSHARED,;t t
19171s,@LINKCC@,$LINKCC,;t t
19172s,@RANLIB@,$RANLIB,;t t
19173s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
19174s,@AR@,$AR,;t t
19175s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
19176s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
19177s,@INSTALL_DATA@,$INSTALL_DATA,;t t
19178s,@LN@,$LN,;t t
19179s,@OPT@,$OPT,;t t
Skip Montanarodecc6a42003-01-01 20:07:49 +000019180s,@BASECFLAGS@,$BASECFLAGS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000019181s,@LIBTOOL_CRUFT@,$LIBTOOL_CRUFT,;t t
19182s,@SO@,$SO,;t t
19183s,@LDSHARED@,$LDSHARED,;t t
19184s,@BLDSHARED@,$BLDSHARED,;t t
19185s,@CCSHARED@,$CCSHARED,;t t
19186s,@LINKFORSHARED@,$LINKFORSHARED,;t t
19187s,@CFLAGSFORSHARED@,$CFLAGSFORSHARED,;t t
Martin v. Löwisf90ae202002-06-11 06:22:31 +000019188s,@SHLIBS@,$SHLIBS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000019189s,@USE_SIGNAL_MODULE@,$USE_SIGNAL_MODULE,;t t
19190s,@SIGNAL_OBJS@,$SIGNAL_OBJS,;t t
19191s,@USE_THREAD_MODULE@,$USE_THREAD_MODULE,;t t
19192s,@LDLAST@,$LDLAST,;t t
19193s,@THREADOBJ@,$THREADOBJ,;t t
19194s,@DLINCLDIR@,$DLINCLDIR,;t t
19195s,@DYNLOADFILE@,$DYNLOADFILE,;t t
19196s,@MACHDEP_OBJS@,$MACHDEP_OBJS,;t t
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000019197s,@TRUE@,$TRUE,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000019198s,@LIBOBJS@,$LIBOBJS,;t t
19199s,@HAVE_GETHOSTBYNAME_R_6_ARG@,$HAVE_GETHOSTBYNAME_R_6_ARG,;t t
19200s,@HAVE_GETHOSTBYNAME_R_5_ARG@,$HAVE_GETHOSTBYNAME_R_5_ARG,;t t
19201s,@HAVE_GETHOSTBYNAME_R_3_ARG@,$HAVE_GETHOSTBYNAME_R_3_ARG,;t t
19202s,@HAVE_GETHOSTBYNAME_R@,$HAVE_GETHOSTBYNAME_R,;t t
19203s,@HAVE_GETHOSTBYNAME@,$HAVE_GETHOSTBYNAME,;t t
19204s,@LIBM@,$LIBM,;t t
19205s,@LIBC@,$LIBC,;t t
19206s,@UNICODE_OBJS@,$UNICODE_OBJS,;t t
19207s,@THREADHEADERS@,$THREADHEADERS,;t t
19208s,@SRCDIRS@,$SRCDIRS,;t t
Skip Montanarod8d39a02003-07-10 20:44:10 +000019209s,@LTLIBOBJS@,$LTLIBOBJS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000019210CEOF
19211
19212_ACEOF
19213
19214 cat >>$CONFIG_STATUS <<\_ACEOF
19215 # Split the substitutions into bite-sized pieces for seds with
19216 # small command number limits, like on Digital OSF/1 and HP-UX.
19217 ac_max_sed_lines=48
19218 ac_sed_frag=1 # Number of current file.
19219 ac_beg=1 # First line for current file.
19220 ac_end=$ac_max_sed_lines # Line after last line for current file.
19221 ac_more_lines=:
19222 ac_sed_cmds=
19223 while $ac_more_lines; do
19224 if test $ac_beg -gt 1; then
19225 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19226 else
19227 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19228 fi
19229 if test ! -s $tmp/subs.frag; then
19230 ac_more_lines=false
19231 else
19232 # The purpose of the label and of the branching condition is to
19233 # speed up the sed processing (if there are no `@' at all, there
19234 # is no need to browse any of the substitutions).
19235 # These are the two extra sed commands mentioned above.
19236 (echo ':t
19237 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
19238 if test -z "$ac_sed_cmds"; then
19239 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
19240 else
19241 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
19242 fi
19243 ac_sed_frag=`expr $ac_sed_frag + 1`
19244 ac_beg=$ac_end
19245 ac_end=`expr $ac_end + $ac_max_sed_lines`
19246 fi
19247 done
19248 if test -z "$ac_sed_cmds"; then
19249 ac_sed_cmds=cat
19250 fi
19251fi # test -n "$CONFIG_FILES"
19252
19253_ACEOF
19254cat >>$CONFIG_STATUS <<\_ACEOF
19255for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
19256 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
19257 case $ac_file in
19258 - | *:- | *:-:* ) # input from stdin
19259 cat >$tmp/stdin
19260 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19261 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19262 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19263 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19264 * ) ac_file_in=$ac_file.in ;;
19265 esac
19266
19267 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
19268 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19269$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19270 X"$ac_file" : 'X\(//\)[^/]' \| \
19271 X"$ac_file" : 'X\(//\)$' \| \
19272 X"$ac_file" : 'X\(/\)' \| \
19273 . : '\(.\)' 2>/dev/null ||
19274echo X"$ac_file" |
19275 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19276 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19277 /^X\(\/\/\)$/{ s//\1/; q; }
19278 /^X\(\/\).*/{ s//\1/; q; }
19279 s/.*/./; q'`
Skip Montanarod8d39a02003-07-10 20:44:10 +000019280 { if $as_mkdir_p; then
19281 mkdir -p "$ac_dir"
19282 else
19283 as_dir="$ac_dir"
19284 as_dirs=
19285 while test ! -d "$as_dir"; do
19286 as_dirs="$as_dir $as_dirs"
19287 as_dir=`(dirname "$as_dir") 2>/dev/null ||
19288$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19289 X"$as_dir" : 'X\(//\)[^/]' \| \
19290 X"$as_dir" : 'X\(//\)$' \| \
19291 X"$as_dir" : 'X\(/\)' \| \
19292 . : '\(.\)' 2>/dev/null ||
19293echo X"$as_dir" |
19294 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19295 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19296 /^X\(\/\/\)$/{ s//\1/; q; }
19297 /^X\(\/\).*/{ s//\1/; q; }
19298 s/.*/./; q'`
19299 done
19300 test ! -n "$as_dirs" || mkdir $as_dirs
19301 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
19302echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
19303 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019304
19305 ac_builddir=.
19306
19307if test "$ac_dir" != .; then
19308 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
19309 # A "../" for each directory in $ac_dir_suffix.
19310 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19311else
19312 ac_dir_suffix= ac_top_builddir=
19313fi
19314
19315case $srcdir in
19316 .) # No --srcdir option. We are building in place.
19317 ac_srcdir=.
19318 if test -z "$ac_top_builddir"; then
19319 ac_top_srcdir=.
19320 else
19321 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19322 fi ;;
19323 [\\/]* | ?:[\\/]* ) # Absolute path.
19324 ac_srcdir=$srcdir$ac_dir_suffix;
19325 ac_top_srcdir=$srcdir ;;
19326 *) # Relative path.
19327 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19328 ac_top_srcdir=$ac_top_builddir$srcdir ;;
19329esac
19330# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
19331# absolute.
19332ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwisd6640d42003-07-06 09:29:52 +000019333ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +000019334ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
19335ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
19336
19337
19338 case $INSTALL in
19339 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
19340 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
19341 esac
19342
19343 if test x"$ac_file" != x-; then
19344 { echo "$as_me:$LINENO: creating $ac_file" >&5
19345echo "$as_me: creating $ac_file" >&6;}
19346 rm -f "$ac_file"
19347 fi
19348 # Let's still pretend it is `configure' which instantiates (i.e., don't
19349 # use $as_me), people would be surprised to read:
19350 # /* config.h. Generated by config.status. */
19351 if test x"$ac_file" = x-; then
19352 configure_input=
19353 else
19354 configure_input="$ac_file. "
19355 fi
19356 configure_input=$configure_input"Generated from `echo $ac_file_in |
19357 sed 's,.*/,,'` by configure."
19358
19359 # First look for the input files in the build tree, otherwise in the
19360 # src tree.
19361 ac_file_inputs=`IFS=:
19362 for f in $ac_file_in; do
19363 case $f in
19364 -) echo $tmp/stdin ;;
19365 [\\/$]*)
19366 # Absolute (can't be DOS-style, as IFS=:)
19367 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19368echo "$as_me: error: cannot find input file: $f" >&2;}
19369 { (exit 1); exit 1; }; }
19370 echo $f;;
19371 *) # Relative
19372 if test -f "$f"; then
19373 # Build tree
19374 echo $f
19375 elif test -f "$srcdir/$f"; then
19376 # Source tree
19377 echo $srcdir/$f
19378 else
19379 # /dev/null tree
19380 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19381echo "$as_me: error: cannot find input file: $f" >&2;}
19382 { (exit 1); exit 1; }; }
19383 fi;;
19384 esac
19385 done` || { (exit 1); exit 1; }
19386_ACEOF
19387cat >>$CONFIG_STATUS <<_ACEOF
19388 sed "$ac_vpsub
19389$extrasub
19390_ACEOF
19391cat >>$CONFIG_STATUS <<\_ACEOF
19392:t
19393/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
19394s,@configure_input@,$configure_input,;t t
19395s,@srcdir@,$ac_srcdir,;t t
19396s,@abs_srcdir@,$ac_abs_srcdir,;t t
19397s,@top_srcdir@,$ac_top_srcdir,;t t
19398s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
19399s,@builddir@,$ac_builddir,;t t
19400s,@abs_builddir@,$ac_abs_builddir,;t t
19401s,@top_builddir@,$ac_top_builddir,;t t
19402s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
19403s,@INSTALL@,$ac_INSTALL,;t t
19404" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
19405 rm -f $tmp/stdin
19406 if test x"$ac_file" != x-; then
19407 mv $tmp/out $ac_file
19408 else
19409 cat $tmp/out
19410 rm -f $tmp/out
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019411 fi
19412
Martin v. Löwis11437992002-04-12 09:54:03 +000019413done
19414_ACEOF
19415cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019416
Martin v. Löwis11437992002-04-12 09:54:03 +000019417#
19418# CONFIG_HEADER section.
19419#
Guido van Rossum627b2d71993-12-24 10:39:16 +000019420
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019421# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
19422# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +000019423#
19424# ac_d sets the value in "#define NAME VALUE" lines.
Martin v. Löwis11437992002-04-12 09:54:03 +000019425ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
19426ac_dB='[ ].*$,\1#\2'
19427ac_dC=' '
19428ac_dD=',;t'
19429# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
19430ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
19431ac_uB='$,\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +000019432ac_uC=' '
Martin v. Löwis11437992002-04-12 09:54:03 +000019433ac_uD=',;t'
Guido van Rossum7f43da71994-08-01 12:15:30 +000019434
Martin v. Löwis11437992002-04-12 09:54:03 +000019435for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
Guido van Rossumf78abae1997-01-21 22:02:36 +000019436 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Martin v. Löwis11437992002-04-12 09:54:03 +000019437 case $ac_file in
19438 - | *:- | *:-:* ) # input from stdin
19439 cat >$tmp/stdin
19440 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19441 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19442 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19443 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19444 * ) ac_file_in=$ac_file.in ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019445 esac
19446
Martin v. Löwis11437992002-04-12 09:54:03 +000019447 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
19448echo "$as_me: creating $ac_file" >&6;}
Guido van Rossum7f43da71994-08-01 12:15:30 +000019449
Martin v. Löwis11437992002-04-12 09:54:03 +000019450 # First look for the input files in the build tree, otherwise in the
19451 # src tree.
19452 ac_file_inputs=`IFS=:
19453 for f in $ac_file_in; do
19454 case $f in
19455 -) echo $tmp/stdin ;;
19456 [\\/$]*)
19457 # Absolute (can't be DOS-style, as IFS=:)
19458 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19459echo "$as_me: error: cannot find input file: $f" >&2;}
19460 { (exit 1); exit 1; }; }
19461 echo $f;;
19462 *) # Relative
19463 if test -f "$f"; then
19464 # Build tree
19465 echo $f
19466 elif test -f "$srcdir/$f"; then
19467 # Source tree
19468 echo $srcdir/$f
19469 else
19470 # /dev/null tree
19471 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19472echo "$as_me: error: cannot find input file: $f" >&2;}
19473 { (exit 1); exit 1; }; }
19474 fi;;
19475 esac
19476 done` || { (exit 1); exit 1; }
19477 # Remove the trailing spaces.
19478 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019479
Martin v. Löwis11437992002-04-12 09:54:03 +000019480_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019481
Martin v. Löwis11437992002-04-12 09:54:03 +000019482# Transform confdefs.h into two sed scripts, `conftest.defines' and
19483# `conftest.undefs', that substitutes the proper values into
19484# config.h.in to produce config.h. The first handles `#define'
19485# templates, and the second `#undef' templates.
19486# And first: Protect against being on the right side of a sed subst in
19487# config.status. Protect against being in an unquoted here document
19488# in config.status.
19489rm -f conftest.defines conftest.undefs
19490# Using a here document instead of a string reduces the quoting nightmare.
19491# Putting comments in sed scripts is not portable.
19492#
19493# `end' is used to avoid that the second main sed command (meant for
19494# 0-ary CPP macros) applies to n-ary macro definitions.
19495# See the Autoconf documentation for `clear'.
19496cat >confdef2sed.sed <<\_ACEOF
19497s/[\\&,]/\\&/g
19498s,[\\$`],\\&,g
19499t clear
19500: clear
19501s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
19502t end
19503s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
19504: end
19505_ACEOF
19506# If some macros were called several times there might be several times
19507# the same #defines, which is useless. Nevertheless, we may not want to
19508# sort them, since we want the *last* AC-DEFINE to be honored.
19509uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
19510sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
19511rm -f confdef2sed.sed
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019512
19513# This sed command replaces #undef with comments. This is necessary, for
19514# example, in the case of _POSIX_SOURCE, which is predefined and required
19515# on some systems where configure will not decide to define it.
Martin v. Löwis11437992002-04-12 09:54:03 +000019516cat >>conftest.undefs <<\_ACEOF
19517s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
19518_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019519
Martin v. Löwis11437992002-04-12 09:54:03 +000019520# Break up conftest.defines because some shells have a limit on the size
19521# of here documents, and old seds have small limits too (100 cmds).
19522echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
Skip Montanarod8d39a02003-07-10 20:44:10 +000019523echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000019524echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
19525echo ' :' >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000019526rm -f conftest.tail
Martin v. Löwis11437992002-04-12 09:54:03 +000019527while grep . conftest.defines >/dev/null
Jack Jansendd19cf82001-12-06 22:36:17 +000019528do
Martin v. Löwis11437992002-04-12 09:54:03 +000019529 # Write a limited-size here document to $tmp/defines.sed.
19530 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
19531 # Speed up: don't consider the non `#define' lines.
19532 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
19533 # Work around the forget-to-reset-the-flag bug.
19534 echo 't clr' >>$CONFIG_STATUS
19535 echo ': clr' >>$CONFIG_STATUS
19536 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000019537 echo 'CEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000019538 sed -f $tmp/defines.sed $tmp/in >$tmp/out
19539 rm -f $tmp/in
19540 mv $tmp/out $tmp/in
19541' >>$CONFIG_STATUS
19542 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
19543 rm -f conftest.defines
19544 mv conftest.tail conftest.defines
Jack Jansendd19cf82001-12-06 22:36:17 +000019545done
Martin v. Löwis11437992002-04-12 09:54:03 +000019546rm -f conftest.defines
Skip Montanarod8d39a02003-07-10 20:44:10 +000019547echo ' fi # grep' >>$CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000019548echo >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000019549
Martin v. Löwis11437992002-04-12 09:54:03 +000019550# Break up conftest.undefs because some shells have a limit on the size
19551# of here documents, and old seds have small limits too (100 cmds).
19552echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
19553rm -f conftest.tail
19554while grep . conftest.undefs >/dev/null
19555do
19556 # Write a limited-size here document to $tmp/undefs.sed.
19557 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
19558 # Speed up: don't consider the non `#undef'
19559 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
19560 # Work around the forget-to-reset-the-flag bug.
19561 echo 't clr' >>$CONFIG_STATUS
19562 echo ': clr' >>$CONFIG_STATUS
19563 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
19564 echo 'CEOF
19565 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
19566 rm -f $tmp/in
19567 mv $tmp/out $tmp/in
19568' >>$CONFIG_STATUS
19569 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
19570 rm -f conftest.undefs
19571 mv conftest.tail conftest.undefs
19572done
19573rm -f conftest.undefs
19574
19575cat >>$CONFIG_STATUS <<\_ACEOF
19576 # Let's still pretend it is `configure' which instantiates (i.e., don't
19577 # use $as_me), people would be surprised to read:
19578 # /* config.h. Generated by config.status. */
19579 if test x"$ac_file" = x-; then
19580 echo "/* Generated by configure. */" >$tmp/config.h
Guido van Rossum7f43da71994-08-01 12:15:30 +000019581 else
Martin v. Löwis11437992002-04-12 09:54:03 +000019582 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
Jack Jansendd19cf82001-12-06 22:36:17 +000019583 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000019584 cat $tmp/in >>$tmp/config.h
19585 rm -f $tmp/in
19586 if test x"$ac_file" != x-; then
Skip Montanarod8d39a02003-07-10 20:44:10 +000019587 if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019588 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
19589echo "$as_me: $ac_file is unchanged" >&6;}
19590 else
19591 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19592$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19593 X"$ac_file" : 'X\(//\)[^/]' \| \
19594 X"$ac_file" : 'X\(//\)$' \| \
19595 X"$ac_file" : 'X\(/\)' \| \
19596 . : '\(.\)' 2>/dev/null ||
19597echo X"$ac_file" |
19598 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19599 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19600 /^X\(\/\/\)$/{ s//\1/; q; }
19601 /^X\(\/\).*/{ s//\1/; q; }
19602 s/.*/./; q'`
Skip Montanarod8d39a02003-07-10 20:44:10 +000019603 { if $as_mkdir_p; then
19604 mkdir -p "$ac_dir"
19605 else
19606 as_dir="$ac_dir"
19607 as_dirs=
19608 while test ! -d "$as_dir"; do
19609 as_dirs="$as_dir $as_dirs"
19610 as_dir=`(dirname "$as_dir") 2>/dev/null ||
19611$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19612 X"$as_dir" : 'X\(//\)[^/]' \| \
19613 X"$as_dir" : 'X\(//\)$' \| \
19614 X"$as_dir" : 'X\(/\)' \| \
19615 . : '\(.\)' 2>/dev/null ||
19616echo X"$as_dir" |
19617 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19618 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19619 /^X\(\/\/\)$/{ s//\1/; q; }
19620 /^X\(\/\).*/{ s//\1/; q; }
19621 s/.*/./; q'`
19622 done
19623 test ! -n "$as_dirs" || mkdir $as_dirs
19624 fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
19625echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
19626 { (exit 1); exit 1; }; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000019627
Martin v. Löwis11437992002-04-12 09:54:03 +000019628 rm -f $ac_file
19629 mv $tmp/config.h $ac_file
19630 fi
19631 else
19632 cat $tmp/config.h
19633 rm -f $tmp/config.h
19634 fi
19635done
19636_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000019637
Martin v. Löwis11437992002-04-12 09:54:03 +000019638cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000019639
Martin v. Löwis11437992002-04-12 09:54:03 +000019640{ (exit 0); exit 0; }
19641_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019642chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000019643ac_clean_files=$ac_clean_files_save
19644
19645
19646# configure is writing to config.log, and then calls config.status.
19647# config.status does its own redirection, appending to config.log.
19648# Unfortunately, on DOS this fails, as config.log is still kept open
19649# by configure, so config.status won't be able to write to it; its
19650# output is simply discarded. So we exec the FD to /dev/null,
19651# effectively closing config.log, so it can be properly (re)opened and
19652# appended to by config.status. When coming back to configure, we
19653# need to make the FD available again.
19654if test "$no_create" != yes; then
19655 ac_cs_success=:
Skip Montanarod8d39a02003-07-10 20:44:10 +000019656 ac_config_status_args=
19657 test "$silent" = yes &&
19658 ac_config_status_args="$ac_config_status_args --quiet"
Martin v. Löwis11437992002-04-12 09:54:03 +000019659 exec 5>/dev/null
Skip Montanarod8d39a02003-07-10 20:44:10 +000019660 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
Martin v. Löwis11437992002-04-12 09:54:03 +000019661 exec 5>>config.log
19662 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
19663 # would make configure fail if this is the last instruction.
19664 $ac_cs_success || { (exit 1); exit 1; }
19665fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000019666
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000019667
19668echo "creating Setup"
19669if test ! -f Modules/Setup
19670then
19671 cp $srcdir/Modules/Setup.dist Modules/Setup
19672fi
19673
19674echo "creating Setup.local"
19675if test ! -f Modules/Setup.local
19676then
19677 echo "# Edit this file for local setup changes" >Modules/Setup.local
19678fi
19679
19680echo "creating Makefile"
19681$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
19682 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000019683 Modules/Setup.local Modules/Setup
Neil Schemenauerc761fc82001-02-19 04:50:49 +000019684mv config.c Modules