blob: a5e51b3ff39eed783febde9116f3f4167f63b75b [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Martin v. Löwis7e4cfcb2002-12-19 16:21:49 +00002# From configure.in Revision: 1.375 .
Guido van Rossum627b2d71993-12-24 10:39:16 +00003# Guess values for system-dependent variables and create Makefiles.
Martin v. Löwis88afe662002-10-26 13:47:44 +00004# Generated by GNU Autoconf 2.53 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.
Guido van Rossum627b2d71993-12-24 10:39:16 +000010
Martin v. Löwis11437992002-04-12 09:54:03 +000011if expr a : '\(a\)' >/dev/null 2>&1; then
12 as_expr=expr
13else
14 as_expr=false
15fi
16
17
18## --------------------- ##
19## M4sh Initialization. ##
20## --------------------- ##
21
22# Be Bourne compatible
23if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
24 emulate sh
25 NULLCMD=:
26elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
27 set -o posix
28fi
29
30# NLS nuisances.
31# Support unset when possible.
32if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
33 as_unset=unset
34else
35 as_unset=false
36fi
37
38(set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
39 { $as_unset LANG || test "${LANG+set}" != set; } ||
40 { LANG=C; export LANG; }
41(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
42 { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
43 { LC_ALL=C; export LC_ALL; }
44(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
45 { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
46 { LC_TIME=C; export LC_TIME; }
47(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
48 { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
49 { LC_CTYPE=C; export LC_CTYPE; }
50(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
51 { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
52 { LANGUAGE=C; export LANGUAGE; }
53(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
54 { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
55 { LC_COLLATE=C; export LC_COLLATE; }
56(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
57 { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
58 { LC_NUMERIC=C; export LC_NUMERIC; }
59(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
60 { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
61 { LC_MESSAGES=C; export LC_MESSAGES; }
62
63
64# Name of the executable.
65as_me=`(basename "$0") 2>/dev/null ||
66$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
67 X"$0" : 'X\(//\)$' \| \
68 X"$0" : 'X\(/\)$' \| \
69 . : '\(.\)' 2>/dev/null ||
70echo X/"$0" |
71 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
72 /^X\/\(\/\/\)$/{ s//\1/; q; }
73 /^X\/\(\/\).*/{ s//\1/; q; }
74 s/.*/./; q'`
75
76# PATH needs CR, and LINENO needs CR and PATH.
77# Avoid depending upon Character Ranges.
78as_cr_letters='abcdefghijklmnopqrstuvwxyz'
79as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
80as_cr_Letters=$as_cr_letters$as_cr_LETTERS
81as_cr_digits='0123456789'
82as_cr_alnum=$as_cr_Letters$as_cr_digits
83
84# The user is always right.
85if test "${PATH_SEPARATOR+set}" != set; then
86 echo "#! /bin/sh" >conftest.sh
87 echo "exit 0" >>conftest.sh
88 chmod +x conftest.sh
89 if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
90 PATH_SEPARATOR=';'
91 else
92 PATH_SEPARATOR=:
93 fi
94 rm -f conftest.sh
95fi
96
97
98 as_lineno_1=$LINENO
99 as_lineno_2=$LINENO
100 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
101 test "x$as_lineno_1" != "x$as_lineno_2" &&
102 test "x$as_lineno_3" = "x$as_lineno_2" || {
103 # Find who we are. Look in the path if we contain no path at all
104 # relative or not.
105 case $0 in
106 *[\\/]* ) as_myself=$0 ;;
107 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
108for as_dir in $PATH
109do
110 IFS=$as_save_IFS
111 test -z "$as_dir" && as_dir=.
112 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
113done
114
115 ;;
116 esac
117 # We did not find ourselves, most probably we were run as `sh COMMAND'
118 # in which case we are not to be found in the path.
119 if test "x$as_myself" = x; then
120 as_myself=$0
121 fi
122 if test ! -f "$as_myself"; then
123 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
124 { (exit 1); exit 1; }; }
125 fi
126 case $CONFIG_SHELL in
127 '')
128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
129for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
130do
131 IFS=$as_save_IFS
132 test -z "$as_dir" && as_dir=.
133 for as_base in sh bash ksh sh5; do
134 case $as_dir in
135 /*)
136 if ("$as_dir/$as_base" -c '
137 as_lineno_1=$LINENO
138 as_lineno_2=$LINENO
139 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
140 test "x$as_lineno_1" != "x$as_lineno_2" &&
141 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
142 CONFIG_SHELL=$as_dir/$as_base
143 export CONFIG_SHELL
144 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
145 fi;;
146 esac
147 done
148done
149;;
150 esac
151
152 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
153 # uniformly replaced by the line number. The first 'sed' inserts a
154 # line-number line before each line; the second 'sed' does the real
155 # work. The second script uses 'N' to pair each line-number line
156 # with the numbered line, and appends trailing '-' during
157 # substitution so that $LINENO is not a special case at line end.
158 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
159 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
160 sed '=' <$as_myself |
161 sed '
162 N
163 s,$,-,
164 : loop
165 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
166 t loop
167 s,-$,,
168 s,^['$as_cr_digits']*\n,,
169 ' >$as_me.lineno &&
170 chmod +x $as_me.lineno ||
171 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
172 { (exit 1); exit 1; }; }
173
174 # Don't try to exec as it changes $[0], causing all sort of problems
175 # (the dirname of $[0] is not the place where we might find the
176 # original and so on. Autoconf is especially sensible to this).
177 . ./$as_me.lineno
178 # Exit status is that of the last command.
179 exit
180}
181
182
183case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
184 *c*,-n*) ECHO_N= ECHO_C='
185' ECHO_T=' ' ;;
186 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
187 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
188esac
189
190if expr a : '\(a\)' >/dev/null 2>&1; then
191 as_expr=expr
192else
193 as_expr=false
194fi
195
196rm -f conf$$ conf$$.exe conf$$.file
197echo >conf$$.file
198if ln -s conf$$.file conf$$ 2>/dev/null; then
199 # We could just check for DJGPP; but this test a) works b) is more generic
200 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
201 if test -f conf$$.exe; then
202 # Don't use ln at all; we don't have any links
203 as_ln_s='cp -p'
204 else
205 as_ln_s='ln -s'
206 fi
207elif ln conf$$.file conf$$ 2>/dev/null; then
208 as_ln_s=ln
209else
210 as_ln_s='cp -p'
211fi
212rm -f conf$$ conf$$.exe conf$$.file
213
214as_executable_p="test -f"
215
216# Sed expression to map a string onto a valid CPP name.
217as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
218
219# Sed expression to map a string onto a valid variable name.
220as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
221
222
223# IFS
224# We need space, tab and new line, in precisely that order.
225as_nl='
226'
227IFS=" $as_nl"
228
229# CDPATH.
230$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
231
232
233# Name of the host.
234# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
235# so uname gets run too.
236ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
237
238exec 6>&1
239
240#
241# Initializations.
242#
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000243ac_default_prefix=/usr/local
Martin v. Löwis11437992002-04-12 09:54:03 +0000244cross_compiling=no
245subdirs=
246MFLAGS=
247MAKEFLAGS=
248SHELL=${CONFIG_SHELL-/bin/sh}
249
250# Maximum number of lines to put in a shell here document.
251# This variable seems obsolete. It should probably be removed, and
252# only ac_max_sed_lines should be used.
253: ${ac_max_here_lines=38}
254
255# Identity of this package.
Martin v. Löwis88afe662002-10-26 13:47:44 +0000256PACKAGE_NAME='python'
257PACKAGE_TARNAME='python'
258PACKAGE_VERSION='2.3'
259PACKAGE_STRING='python 2.3'
260PACKAGE_BUGREPORT=''
Martin v. Löwis11437992002-04-12 09:54:03 +0000261
262ac_unique_file="Include/object.h"
263# Factoring default headers for most tests.
264ac_includes_default="\
265#include <stdio.h>
266#if HAVE_SYS_TYPES_H
267# include <sys/types.h>
268#endif
269#if HAVE_SYS_STAT_H
270# include <sys/stat.h>
271#endif
272#if STDC_HEADERS
273# include <stdlib.h>
274# include <stddef.h>
275#else
276# if HAVE_STDLIB_H
277# include <stdlib.h>
278# endif
279#endif
280#if HAVE_STRING_H
281# if !STDC_HEADERS && HAVE_MEMORY_H
282# include <memory.h>
283# endif
284# include <string.h>
285#endif
286#if HAVE_STRINGS_H
287# include <strings.h>
288#endif
289#if HAVE_INTTYPES_H
290# include <inttypes.h>
291#else
292# if HAVE_STDINT_H
293# include <stdint.h>
294# endif
295#endif
296#if HAVE_UNISTD_H
297# include <unistd.h>
298#endif"
299
Guido van Rossum627b2d71993-12-24 10:39:16 +0000300
Guido van Rossum7f43da71994-08-01 12:15:30 +0000301# Initialize some variables set by options.
Martin v. Löwis11437992002-04-12 09:54:03 +0000302ac_init_help=
303ac_init_version=false
Guido van Rossum7f43da71994-08-01 12:15:30 +0000304# The variables have the same names as the options, with
305# dashes changed to underlines.
Martin v. Löwis11437992002-04-12 09:54:03 +0000306cache_file=/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000307exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +0000308no_create=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000309no_recursion=
310prefix=NONE
311program_prefix=NONE
312program_suffix=NONE
313program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +0000314silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000315site=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000316srcdir=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000317verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000318x_includes=NONE
319x_libraries=NONE
Martin v. Löwis11437992002-04-12 09:54:03 +0000320
321# Installation directory options.
322# These are left unexpanded so users can "make install exec_prefix=/foo"
323# and all the variables that are supposed to be based on exec_prefix
324# by default will actually change.
325# Use braces instead of parens because sh, perl, etc. also accept them.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000326bindir='${exec_prefix}/bin'
327sbindir='${exec_prefix}/sbin'
328libexecdir='${exec_prefix}/libexec'
329datadir='${prefix}/share'
330sysconfdir='${prefix}/etc'
331sharedstatedir='${prefix}/com'
332localstatedir='${prefix}/var'
333libdir='${exec_prefix}/lib'
334includedir='${prefix}/include'
335oldincludedir='/usr/include'
336infodir='${prefix}/info'
337mandir='${prefix}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000338
Guido van Rossum7f43da71994-08-01 12:15:30 +0000339ac_prev=
340for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +0000341do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000342 # If the previous option needs an argument, assign it.
343 if test -n "$ac_prev"; then
344 eval "$ac_prev=\$ac_option"
345 ac_prev=
346 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +0000347 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000348
Martin v. Löwis11437992002-04-12 09:54:03 +0000349 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000350
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000351 # Accept the important Cygnus configure options, so we can diagnose typos.
352
Martin v. Löwis11437992002-04-12 09:54:03 +0000353 case $ac_option in
Guido van Rossum7f43da71994-08-01 12:15:30 +0000354
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000355 -bindir | --bindir | --bindi | --bind | --bin | --bi)
356 ac_prev=bindir ;;
357 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000358 bindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000359
360 -build | --build | --buil | --bui | --bu)
Martin v. Löwis11437992002-04-12 09:54:03 +0000361 ac_prev=build_alias ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000362 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000363 build_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000364
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000365 -cache-file | --cache-file | --cache-fil | --cache-fi \
366 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
367 ac_prev=cache_file ;;
368 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
369 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000370 cache_file=$ac_optarg ;;
371
372 --config-cache | -C)
373 cache_file=config.cache ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000374
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000375 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
376 ac_prev=datadir ;;
377 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
378 | --da=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000379 datadir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000380
Guido van Rossum7f43da71994-08-01 12:15:30 +0000381 -disable-* | --disable-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000382 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000383 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000384 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
385 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
386 { (exit 1); exit 1; }; }
387 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
388 eval "enable_$ac_feature=no" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000389
390 -enable-* | --enable-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000391 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000392 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000393 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
394 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
395 { (exit 1); exit 1; }; }
396 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
397 case $ac_option in
398 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000399 *) ac_optarg=yes ;;
400 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000401 eval "enable_$ac_feature='$ac_optarg'" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000402
Guido van Rossum7f43da71994-08-01 12:15:30 +0000403 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
404 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
405 | --exec | --exe | --ex)
406 ac_prev=exec_prefix ;;
407 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
408 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
409 | --exec=* | --exe=* | --ex=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000410 exec_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000411
412 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000413 # Obsolete; use --with-gas.
414 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000415
Martin v. Löwis11437992002-04-12 09:54:03 +0000416 -help | --help | --hel | --he | -h)
417 ac_init_help=long ;;
418 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
419 ac_init_help=recursive ;;
420 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
421 ac_init_help=short ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000422
423 -host | --host | --hos | --ho)
Martin v. Löwis11437992002-04-12 09:54:03 +0000424 ac_prev=host_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000425 -host=* | --host=* | --hos=* | --ho=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000426 host_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000427
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000428 -includedir | --includedir | --includedi | --included | --include \
429 | --includ | --inclu | --incl | --inc)
430 ac_prev=includedir ;;
431 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
432 | --includ=* | --inclu=* | --incl=* | --inc=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000433 includedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000434
435 -infodir | --infodir | --infodi | --infod | --info | --inf)
436 ac_prev=infodir ;;
437 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000438 infodir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000439
440 -libdir | --libdir | --libdi | --libd)
441 ac_prev=libdir ;;
442 -libdir=* | --libdir=* | --libdi=* | --libd=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000443 libdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000444
445 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
446 | --libexe | --libex | --libe)
447 ac_prev=libexecdir ;;
448 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
449 | --libexe=* | --libex=* | --libe=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000450 libexecdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000451
452 -localstatedir | --localstatedir | --localstatedi | --localstated \
453 | --localstate | --localstat | --localsta | --localst \
454 | --locals | --local | --loca | --loc | --lo)
455 ac_prev=localstatedir ;;
456 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
457 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
458 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000459 localstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000460
461 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
462 ac_prev=mandir ;;
463 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000464 mandir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000465
Guido van Rossum7f43da71994-08-01 12:15:30 +0000466 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000467 # Obsolete; use --without-fp.
468 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000469
470 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
Martin v. Löwis11437992002-04-12 09:54:03 +0000471 | --no-cr | --no-c | -n)
Guido van Rossum7f43da71994-08-01 12:15:30 +0000472 no_create=yes ;;
473
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000474 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
475 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
476 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000477
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000478 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
479 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
480 | --oldin | --oldi | --old | --ol | --o)
481 ac_prev=oldincludedir ;;
482 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
483 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
484 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000485 oldincludedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000486
Guido van Rossum7f43da71994-08-01 12:15:30 +0000487 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
488 ac_prev=prefix ;;
489 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000490 prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000491
492 -program-prefix | --program-prefix | --program-prefi | --program-pref \
493 | --program-pre | --program-pr | --program-p)
494 ac_prev=program_prefix ;;
495 -program-prefix=* | --program-prefix=* | --program-prefi=* \
496 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000497 program_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000498
499 -program-suffix | --program-suffix | --program-suffi | --program-suff \
500 | --program-suf | --program-su | --program-s)
501 ac_prev=program_suffix ;;
502 -program-suffix=* | --program-suffix=* | --program-suffi=* \
503 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000504 program_suffix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000505
506 -program-transform-name | --program-transform-name \
507 | --program-transform-nam | --program-transform-na \
508 | --program-transform-n | --program-transform- \
509 | --program-transform | --program-transfor \
510 | --program-transfo | --program-transf \
511 | --program-trans | --program-tran \
512 | --progr-tra | --program-tr | --program-t)
513 ac_prev=program_transform_name ;;
514 -program-transform-name=* | --program-transform-name=* \
515 | --program-transform-nam=* | --program-transform-na=* \
516 | --program-transform-n=* | --program-transform-=* \
517 | --program-transform=* | --program-transfor=* \
518 | --program-transfo=* | --program-transf=* \
519 | --program-trans=* | --program-tran=* \
520 | --progr-tra=* | --program-tr=* | --program-t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000521 program_transform_name=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000522
523 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
524 | -silent | --silent | --silen | --sile | --sil)
525 silent=yes ;;
526
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000527 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
528 ac_prev=sbindir ;;
529 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
530 | --sbi=* | --sb=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000531 sbindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000532
533 -sharedstatedir | --sharedstatedir | --sharedstatedi \
534 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
535 | --sharedst | --shareds | --shared | --share | --shar \
536 | --sha | --sh)
537 ac_prev=sharedstatedir ;;
538 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
539 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
540 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
541 | --sha=* | --sh=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000542 sharedstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000543
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000544 -site | --site | --sit)
545 ac_prev=site ;;
546 -site=* | --site=* | --sit=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000547 site=$ac_optarg ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000548
Guido van Rossum7f43da71994-08-01 12:15:30 +0000549 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
550 ac_prev=srcdir ;;
551 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000552 srcdir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000553
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000554 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
555 | --syscon | --sysco | --sysc | --sys | --sy)
556 ac_prev=sysconfdir ;;
557 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
558 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000559 sysconfdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000560
Guido van Rossum7f43da71994-08-01 12:15:30 +0000561 -target | --target | --targe | --targ | --tar | --ta | --t)
Martin v. Löwis11437992002-04-12 09:54:03 +0000562 ac_prev=target_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000563 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000564 target_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000565
566 -v | -verbose | --verbose | --verbos | --verbo | --verb)
567 verbose=yes ;;
568
Martin v. Löwis11437992002-04-12 09:54:03 +0000569 -version | --version | --versio | --versi | --vers | -V)
570 ac_init_version=: ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000571
572 -with-* | --with-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000573 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000574 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000575 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
576 { echo "$as_me: error: invalid package name: $ac_package" >&2
577 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000578 ac_package=`echo $ac_package| sed 's/-/_/g'`
Martin v. Löwis11437992002-04-12 09:54:03 +0000579 case $ac_option in
580 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000581 *) ac_optarg=yes ;;
582 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000583 eval "with_$ac_package='$ac_optarg'" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000584
585 -without-* | --without-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000586 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000587 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000588 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
589 { echo "$as_me: error: invalid package name: $ac_package" >&2
590 { (exit 1); exit 1; }; }
591 ac_package=`echo $ac_package | sed 's/-/_/g'`
592 eval "with_$ac_package=no" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000593
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000594 --x)
595 # Obsolete; use --with-x.
596 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000597
598 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
599 | --x-incl | --x-inc | --x-in | --x-i)
600 ac_prev=x_includes ;;
601 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
602 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000603 x_includes=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000604
605 -x-libraries | --x-libraries | --x-librarie | --x-librari \
606 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
607 ac_prev=x_libraries ;;
608 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
609 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000610 x_libraries=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000611
Martin v. Löwis11437992002-04-12 09:54:03 +0000612 -*) { echo "$as_me: error: unrecognized option: $ac_option
613Try \`$0 --help' for more information." >&2
614 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000615 ;;
616
Martin v. Löwis11437992002-04-12 09:54:03 +0000617 *=*)
618 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
619 # Reject names that are not valid shell variable names.
620 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
621 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
622 { (exit 1); exit 1; }; }
623 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
624 eval "$ac_envvar='$ac_optarg'"
625 export $ac_envvar ;;
626
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000627 *)
Martin v. Löwis11437992002-04-12 09:54:03 +0000628 # FIXME: should be removed in autoconf 3.0.
629 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
630 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
631 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
632 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
Guido van Rossum7f43da71994-08-01 12:15:30 +0000633 ;;
634
635 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +0000636done
637
Guido van Rossum7f43da71994-08-01 12:15:30 +0000638if test -n "$ac_prev"; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000639 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
640 { echo "$as_me: error: missing argument to $ac_option" >&2
641 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000642fi
643
Martin v. Löwis11437992002-04-12 09:54:03 +0000644# Be sure to have absolute paths.
645for ac_var in exec_prefix prefix
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000646do
Martin v. Löwis11437992002-04-12 09:54:03 +0000647 eval ac_val=$`echo $ac_var`
648 case $ac_val in
649 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
650 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
651 { (exit 1); exit 1; }; };;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000652 esac
653done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000654
Martin v. Löwis11437992002-04-12 09:54:03 +0000655# Be sure to have absolute paths.
656for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
657 localstatedir libdir includedir oldincludedir infodir mandir
658do
659 eval ac_val=$`echo $ac_var`
660 case $ac_val in
661 [\\/$]* | ?:[\\/]* ) ;;
662 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
663 { (exit 1); exit 1; }; };;
664 esac
665done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000666
Martin v. Löwis11437992002-04-12 09:54:03 +0000667# There might be people who depend on the old broken behavior: `$host'
668# used to hold the argument of --host etc.
669# FIXME: To remove some day.
670build=$build_alias
671host=$host_alias
672target=$target_alias
Guido van Rossum627b2d71993-12-24 10:39:16 +0000673
Martin v. Löwis11437992002-04-12 09:54:03 +0000674# FIXME: To remove some day.
675if test "x$host_alias" != x; then
676 if test "x$build_alias" = x; then
677 cross_compiling=maybe
678 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
679 If a cross compiler is detected then cross compile mode will be used." >&2
680 elif test "x$build_alias" != "x$host_alias"; then
681 cross_compiling=yes
682 fi
683fi
684
685ac_tool_prefix=
686test -n "$host_alias" && ac_tool_prefix=$host_alias-
687
688test "$silent" = yes && exec 6>/dev/null
689
Guido van Rossum627b2d71993-12-24 10:39:16 +0000690
691# Find the source files, if location was not specified.
692if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +0000693 ac_srcdir_defaulted=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000694 # Try the directory containing this script, then its parent.
Martin v. Löwis11437992002-04-12 09:54:03 +0000695 ac_confdir=`(dirname "$0") 2>/dev/null ||
696$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
697 X"$0" : 'X\(//\)[^/]' \| \
698 X"$0" : 'X\(//\)$' \| \
699 X"$0" : 'X\(/\)' \| \
700 . : '\(.\)' 2>/dev/null ||
701echo X"$0" |
702 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
703 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
704 /^X\(\/\/\)$/{ s//\1/; q; }
705 /^X\(\/\).*/{ s//\1/; q; }
706 s/.*/./; q'`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000707 srcdir=$ac_confdir
708 if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum627b2d71993-12-24 10:39:16 +0000709 srcdir=..
710 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000711else
712 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +0000713fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000714if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000715 if test "$ac_srcdir_defaulted" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000716 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
717 { (exit 1); exit 1; }; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000718 else
Martin v. Löwis11437992002-04-12 09:54:03 +0000719 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
720 { (exit 1); exit 1; }; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000721 fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000722fi
Martin v. Löwis11437992002-04-12 09:54:03 +0000723srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
724ac_env_build_alias_set=${build_alias+set}
725ac_env_build_alias_value=$build_alias
726ac_cv_env_build_alias_set=${build_alias+set}
727ac_cv_env_build_alias_value=$build_alias
728ac_env_host_alias_set=${host_alias+set}
729ac_env_host_alias_value=$host_alias
730ac_cv_env_host_alias_set=${host_alias+set}
731ac_cv_env_host_alias_value=$host_alias
732ac_env_target_alias_set=${target_alias+set}
733ac_env_target_alias_value=$target_alias
734ac_cv_env_target_alias_set=${target_alias+set}
735ac_cv_env_target_alias_value=$target_alias
736ac_env_CC_set=${CC+set}
737ac_env_CC_value=$CC
738ac_cv_env_CC_set=${CC+set}
739ac_cv_env_CC_value=$CC
740ac_env_CFLAGS_set=${CFLAGS+set}
741ac_env_CFLAGS_value=$CFLAGS
742ac_cv_env_CFLAGS_set=${CFLAGS+set}
743ac_cv_env_CFLAGS_value=$CFLAGS
744ac_env_LDFLAGS_set=${LDFLAGS+set}
745ac_env_LDFLAGS_value=$LDFLAGS
746ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
747ac_cv_env_LDFLAGS_value=$LDFLAGS
748ac_env_CPPFLAGS_set=${CPPFLAGS+set}
749ac_env_CPPFLAGS_value=$CPPFLAGS
750ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
751ac_cv_env_CPPFLAGS_value=$CPPFLAGS
752ac_env_CPP_set=${CPP+set}
753ac_env_CPP_value=$CPP
754ac_cv_env_CPP_set=${CPP+set}
755ac_cv_env_CPP_value=$CPP
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000756
Martin v. Löwis11437992002-04-12 09:54:03 +0000757#
758# Report the --help message.
759#
760if test "$ac_init_help" = "long"; then
761 # Omit some internal or obsolete options to make the list less imposing.
762 # This message is too long to be a string in the A/UX 3.1 sh.
763 cat <<_ACEOF
Martin v. Löwis88afe662002-10-26 13:47:44 +0000764\`configure' configures python 2.3 to adapt to many kinds of systems.
Martin v. Löwis11437992002-04-12 09:54:03 +0000765
766Usage: $0 [OPTION]... [VAR=VALUE]...
767
768To assign environment variables (e.g., CC, CFLAGS...), specify them as
769VAR=VALUE. See below for descriptions of some of the useful variables.
770
771Defaults for the options are specified in brackets.
772
773Configuration:
774 -h, --help display this help and exit
775 --help=short display options specific to this package
776 --help=recursive display the short help of all the included packages
777 -V, --version display version information and exit
778 -q, --quiet, --silent do not print \`checking...' messages
779 --cache-file=FILE cache test results in FILE [disabled]
780 -C, --config-cache alias for \`--cache-file=config.cache'
781 -n, --no-create do not create output files
782 --srcdir=DIR find the sources in DIR [configure dir or \`..']
783
784_ACEOF
785
786 cat <<_ACEOF
787Installation directories:
788 --prefix=PREFIX install architecture-independent files in PREFIX
789 [$ac_default_prefix]
790 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
791 [PREFIX]
792
793By default, \`make install' will install all the files in
794\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
795an installation prefix other than \`$ac_default_prefix' using \`--prefix',
796for instance \`--prefix=\$HOME'.
797
798For better control, use the options below.
799
800Fine tuning of the installation directories:
801 --bindir=DIR user executables [EPREFIX/bin]
802 --sbindir=DIR system admin executables [EPREFIX/sbin]
803 --libexecdir=DIR program executables [EPREFIX/libexec]
804 --datadir=DIR read-only architecture-independent data [PREFIX/share]
805 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
806 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
807 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
808 --libdir=DIR object code libraries [EPREFIX/lib]
809 --includedir=DIR C header files [PREFIX/include]
810 --oldincludedir=DIR C header files for non-gcc [/usr/include]
811 --infodir=DIR info documentation [PREFIX/info]
812 --mandir=DIR man documentation [PREFIX/man]
813_ACEOF
814
815 cat <<\_ACEOF
816_ACEOF
817fi
818
819if test -n "$ac_init_help"; then
Martin v. Löwis88afe662002-10-26 13:47:44 +0000820 case $ac_init_help in
821 short | recursive ) echo "Configuration of python 2.3:";;
822 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000823 cat <<\_ACEOF
824
825Optional Features:
826 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
827 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
Martin v. Löwis3e2c6322002-10-29 10:07:43 +0000828 --enable-framework[=INSTALLDIR]
829 Build (MacOSX|Darwin) framework
830 --enable-shared disable/enable building shared python library
831 --enable-toolbox-glue disable/enable MacOSX glue code for extensions
832 --enable-ipv6 Enable ipv6 (with ipv4) support
833 --disable-ipv6 Disable ipv6 support
834 --enable-unicode[=ucs[24]]
835 Enable Unicode strings (default is yes)
Martin v. Löwis11437992002-04-12 09:54:03 +0000836
837Optional Packages:
838 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
839 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Martin v. Löwis3e2c6322002-10-29 10:07:43 +0000840 --without-gcc never use gcc
841 --with-cxx=<compiler> enable C++ support
842 --with-suffix=.exe set executable suffix
843 --with-pydebug build with Py_DEBUG defined
844 --with-libs='lib1 ...' link against additional libs
845 --with-signal-module disable/enable signal module
846 --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries
847 --with(out)-threads[=DIRECTORY]
848 disable/enable thread support
849 --with(out)-thread[=DIRECTORY]
850 deprecated; use --with(out)-threads
851 --with-pth use GNU pth threading libraries
852 --with(out)-universal-newlines
853 disable/enable foreign newlines
854 --with(out)-doc-strings disable/enable documentation strings
855 --with(out)-pymalloc disable/enable specialized mallocs
856 --with-wctype-functions use wctype.h functions
857 --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking
858 --with-dl-dld=DL_DIR GNU dynamic linking
859 --with-fpectl enable SIGFPE catching
860 --with-libm=STRING math library
861 --with-libc=STRING C library
Martin v. Löwis11437992002-04-12 09:54:03 +0000862
863Some influential environment variables:
864 CC C compiler command
865 CFLAGS C compiler flags
866 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
867 nonstandard directory <lib dir>
868 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
869 headers in a nonstandard directory <include dir>
870 CPP C preprocessor
871
872Use these variables to override the choices made by `configure' or to help
873it to find libraries and programs with nonstandard names/locations.
874
875_ACEOF
876fi
877
878if test "$ac_init_help" = "recursive"; then
879 # If there are subdirs, report their specific --help.
880 ac_popdir=`pwd`
881 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
882 test -d $ac_dir || continue
883 ac_builddir=.
884
885if test "$ac_dir" != .; then
886 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
887 # A "../" for each directory in $ac_dir_suffix.
888 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
889else
890 ac_dir_suffix= ac_top_builddir=
891fi
892
893case $srcdir in
894 .) # No --srcdir option. We are building in place.
895 ac_srcdir=.
896 if test -z "$ac_top_builddir"; then
897 ac_top_srcdir=.
898 else
899 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
900 fi ;;
901 [\\/]* | ?:[\\/]* ) # Absolute path.
902 ac_srcdir=$srcdir$ac_dir_suffix;
903 ac_top_srcdir=$srcdir ;;
904 *) # Relative path.
905 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
906 ac_top_srcdir=$ac_top_builddir$srcdir ;;
907esac
908# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
909# absolute.
910ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwise3271202002-11-07 07:42:30 +0000911ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +0000912ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
913ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
914
915 cd $ac_dir
916 # Check for guested configure; otherwise get Cygnus style configure.
917 if test -f $ac_srcdir/configure.gnu; then
918 echo
919 $SHELL $ac_srcdir/configure.gnu --help=recursive
920 elif test -f $ac_srcdir/configure; then
921 echo
922 $SHELL $ac_srcdir/configure --help=recursive
923 elif test -f $ac_srcdir/configure.ac ||
924 test -f $ac_srcdir/configure.in; then
925 echo
926 $ac_configure --help
927 else
928 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
929 fi
930 cd $ac_popdir
931 done
932fi
933
934test -n "$ac_init_help" && exit 0
935if $ac_init_version; then
936 cat <<\_ACEOF
Martin v. Löwis88afe662002-10-26 13:47:44 +0000937python configure 2.3
938generated by GNU Autoconf 2.53
Martin v. Löwis11437992002-04-12 09:54:03 +0000939
940Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
941Free Software Foundation, Inc.
942This configure script is free software; the Free Software Foundation
943gives unlimited permission to copy, distribute and modify it.
944_ACEOF
945 exit 0
946fi
947exec 5>config.log
948cat >&5 <<_ACEOF
949This file contains any messages produced by compilers while
950running configure, to aid debugging if configure makes a mistake.
951
Martin v. Löwis88afe662002-10-26 13:47:44 +0000952It was created by python $as_me 2.3, which was
Martin v. Löwis11437992002-04-12 09:54:03 +0000953generated by GNU Autoconf 2.53. Invocation command line was
954
955 $ $0 $@
956
957_ACEOF
958{
959cat <<_ASUNAME
960## --------- ##
961## Platform. ##
962## --------- ##
963
964hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
965uname -m = `(uname -m) 2>/dev/null || echo unknown`
966uname -r = `(uname -r) 2>/dev/null || echo unknown`
967uname -s = `(uname -s) 2>/dev/null || echo unknown`
968uname -v = `(uname -v) 2>/dev/null || echo unknown`
969
970/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
971/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
972
973/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
974/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
975/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
976hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
977/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
978/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
979/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
980
981_ASUNAME
982
983as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
984for as_dir in $PATH
985do
986 IFS=$as_save_IFS
987 test -z "$as_dir" && as_dir=.
988 echo "PATH: $as_dir"
989done
990
991} >&5
992
993cat >&5 <<_ACEOF
994
995
996## ----------- ##
997## Core tests. ##
998## ----------- ##
999
1000_ACEOF
1001
1002
1003# Keep a trace of the command line.
1004# Strip out --no-create and --no-recursion so they do not pile up.
1005# Also quote any args containing shell meta-characters.
1006ac_configure_args=
1007ac_sep=
1008for ac_arg
1009do
1010 case $ac_arg in
1011 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1012 | --no-cr | --no-c | -n ) continue ;;
1013 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1014 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1015 continue ;;
1016 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1017 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1018 esac
1019 case " $ac_configure_args " in
1020 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1021 *) ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1022 ac_sep=" " ;;
1023 esac
1024 # Get rid of the leading space.
1025done
1026
1027# When interrupted or exit'd, cleanup temporary files, and complete
1028# config.log. We remove comments because anyway the quotes in there
1029# would cause problems or look ugly.
1030# WARNING: Be sure not to use single quotes in there, as some shells,
1031# such as our DU 5.0 friend, will then `close' the trap.
1032trap 'exit_status=$?
1033 # Save into config.log some information that might help in debugging.
1034 {
1035 echo
1036 cat <<\_ASBOX
1037## ---------------- ##
1038## Cache variables. ##
1039## ---------------- ##
1040_ASBOX
1041 echo
1042 # The following way of writing the cache mishandles newlines in values,
1043{
1044 (set) 2>&1 |
1045 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1046 *ac_space=\ *)
1047 sed -n \
1048 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1049 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1050 ;;
1051 *)
1052 sed -n \
1053 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1054 ;;
1055 esac;
1056}
1057 echo
1058 if test -s confdefs.h; then
1059 cat <<\_ASBOX
1060## ----------- ##
1061## confdefs.h. ##
1062## ----------- ##
1063_ASBOX
1064 echo
1065 sed "/^$/d" confdefs.h
1066 echo
1067 fi
1068 test "$ac_signal" != 0 &&
1069 echo "$as_me: caught signal $ac_signal"
1070 echo "$as_me: exit $exit_status"
1071 } >&5
1072 rm -f core core.* *.core &&
1073 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1074 exit $exit_status
1075 ' 0
1076for ac_signal in 1 2 13 15; do
1077 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1078done
1079ac_signal=0
1080
1081# confdefs.h avoids OS command line length limits that DEFS can exceed.
1082rm -rf conftest* confdefs.h
1083# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1084echo >confdefs.h
1085
1086# Predefined preprocessor variables.
1087
1088cat >>confdefs.h <<_ACEOF
1089#define PACKAGE_NAME "$PACKAGE_NAME"
1090_ACEOF
1091
1092
1093cat >>confdefs.h <<_ACEOF
1094#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1095_ACEOF
1096
1097
1098cat >>confdefs.h <<_ACEOF
1099#define PACKAGE_VERSION "$PACKAGE_VERSION"
1100_ACEOF
1101
1102
1103cat >>confdefs.h <<_ACEOF
1104#define PACKAGE_STRING "$PACKAGE_STRING"
1105_ACEOF
1106
1107
1108cat >>confdefs.h <<_ACEOF
1109#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1110_ACEOF
1111
1112
1113# Let the site file select an alternate cache file if it wants to.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001114# Prefer explicitly selected file to automatically selected ones.
1115if test -z "$CONFIG_SITE"; then
1116 if test "x$prefix" != xNONE; then
1117 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1118 else
1119 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1120 fi
1121fi
1122for ac_site_file in $CONFIG_SITE; do
1123 if test -r "$ac_site_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001124 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1125echo "$as_me: loading site script $ac_site_file" >&6;}
1126 sed 's/^/| /' "$ac_site_file" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001127 . "$ac_site_file"
1128 fi
1129done
1130
1131if test -r "$cache_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001132 # Some versions of bash will fail to source /dev/null (special
1133 # files actually), so we avoid doing that.
1134 if test -f "$cache_file"; then
1135 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1136echo "$as_me: loading cache $cache_file" >&6;}
1137 case $cache_file in
1138 [\\/]* | ?:[\\/]* ) . $cache_file;;
1139 *) . ./$cache_file;;
1140 esac
1141 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001142else
Martin v. Löwis11437992002-04-12 09:54:03 +00001143 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1144echo "$as_me: creating cache $cache_file" >&6;}
1145 >$cache_file
1146fi
1147
1148# Check that the precious variables saved in the cache have kept the same
1149# value.
1150ac_cache_corrupted=false
1151for ac_var in `(set) 2>&1 |
1152 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1153 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1154 eval ac_new_set=\$ac_env_${ac_var}_set
1155 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1156 eval ac_new_val="\$ac_env_${ac_var}_value"
1157 case $ac_old_set,$ac_new_set in
1158 set,)
1159 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1160echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1161 ac_cache_corrupted=: ;;
1162 ,set)
1163 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1164echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1165 ac_cache_corrupted=: ;;
1166 ,);;
1167 *)
1168 if test "x$ac_old_val" != "x$ac_new_val"; then
1169 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1170echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1171 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
1172echo "$as_me: former value: $ac_old_val" >&2;}
1173 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
1174echo "$as_me: current value: $ac_new_val" >&2;}
1175 ac_cache_corrupted=:
1176 fi;;
1177 esac
1178 # Pass precious variables to config.status.
1179 if test "$ac_new_set" = set; then
1180 case $ac_new_val in
1181 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1182 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1183 *) ac_arg=$ac_var=$ac_new_val ;;
1184 esac
1185 case " $ac_configure_args " in
1186 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1187 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1188 esac
1189 fi
1190done
1191if $ac_cache_corrupted; then
1192 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1193echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1194 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1195echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1196 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001197fi
1198
Guido van Rossum7f43da71994-08-01 12:15:30 +00001199ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001200ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001201ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1202ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1203ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001204
Guido van Rossum627b2d71993-12-24 10:39:16 +00001205
Michael W. Hudson54241132001-12-07 15:38:26 +00001206
1207
Guido van Rossum627b2d71993-12-24 10:39:16 +00001208
Martin v. Löwis11437992002-04-12 09:54:03 +00001209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
Martin v. Löwis88afe662002-10-26 13:47:44 +00001222
1223
1224
1225
1226
1227
1228
1229
1230
Martin v. Löwis11437992002-04-12 09:54:03 +00001231ac_config_headers="$ac_config_headers pyconfig.h"
1232
1233
1234# This is for stuff that absolutely must end up in pyconfig.h.
1235# Please use pyport.h instead, if possible.
1236
1237
1238
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001239
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001240
1241
Andrew M. Kuchlingf2f219d2002-02-11 16:31:10 +00001242VERSION=2.3
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001243
Martin v. Löwis1142de32002-03-29 16:28:31 +00001244
1245SOVERSION=1.0
1246
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001247# The later defininition of _XOPEN_SOURCE disables certain features
1248# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1249
1250cat >>confdefs.h <<\_ACEOF
1251#define _GNU_SOURCE 1
1252_ACEOF
1253
1254
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001255define_xopen_source=yes
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001256
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00001257# Arguments passed to configure.
1258
1259CONFIG_ARGS="$ac_configure_args"
1260
Jack Jansene578a632001-08-15 01:27:14 +00001261# Check whether --enable-framework or --disable-framework was given.
1262if test "${enable_framework+set}" = set; then
1263 enableval="$enable_framework"
Martin v. Löwis11437992002-04-12 09:54:03 +00001264
Jack Jansene578a632001-08-15 01:27:14 +00001265 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00001266 yes)
Jack Jansene578a632001-08-15 01:27:14 +00001267 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00001268 esac
1269 case $enableval in
1270 no)
1271 PYTHONFRAMEWORK=
1272 PYTHONFRAMEWORKDIR=no-framework
1273 PYTHONFRAMEWORKPREFIX=
1274 PYTHONFRAMEWORKINSTALLDIR=
1275 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00001276 ;;
1277 *)
Jack Jansen127e56e2001-09-11 14:41:54 +00001278 PYTHONFRAMEWORK=Python
1279 PYTHONFRAMEWORKDIR=Python.framework
Jack Jansene578a632001-08-15 01:27:14 +00001280 PYTHONFRAMEWORKPREFIX=$enableval
Jack Jansen127e56e2001-09-11 14:41:54 +00001281 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
1282 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Jack Jansene578a632001-08-15 01:27:14 +00001283 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001284
Guido van Rossum563e7081996-09-10 18:20:48 +00001285else
Martin v. Löwis11437992002-04-12 09:54:03 +00001286
Jack Jansene578a632001-08-15 01:27:14 +00001287 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00001288 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00001289 PYTHONFRAMEWORKPREFIX=
1290 PYTHONFRAMEWORKINSTALLDIR=
1291 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001292
Martin v. Löwis11437992002-04-12 09:54:03 +00001293fi;
Michael W. Hudson54241132001-12-07 15:38:26 +00001294
1295
1296
1297
Jack Jansene578a632001-08-15 01:27:14 +00001298
1299##AC_ARG_WITH(dyld,
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001300## AC_HELP_STRING(--with-dyld,
1301## Use (OpenStep|Rhapsody) dynamic linker))
Jack Jansene578a632001-08-15 01:27:14 +00001302##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001303# Set name for machine-dependent library files
1304
Martin v. Löwis11437992002-04-12 09:54:03 +00001305echo "$as_me:$LINENO: checking MACHDEP" >&5
1306echo $ECHO_N "checking MACHDEP... $ECHO_C" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001307if test -z "$MACHDEP"
1308then
Guido van Rossum563e7081996-09-10 18:20:48 +00001309 ac_sys_system=`uname -s`
Martin v. Löwis21ee4092002-09-30 16:19:48 +00001310 if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64" \
1311 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00001312 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001313 else
Guido van Rossum563e7081996-09-10 18:20:48 +00001314 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001315 fi
Guido van Rossum563e7081996-09-10 18:20:48 +00001316 ac_md_system=`echo $ac_sys_system |
1317 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
1318 ac_md_release=`echo $ac_sys_release |
Guido van Rossum67b26592001-10-20 14:21:45 +00001319 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +00001320 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00001321
Guido van Rossum07397971997-04-29 21:49:50 +00001322 case $MACHDEP in
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00001323 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00001324 darwin*) MACHDEP="darwin";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00001325 atheos*) MACHDEP="atheos";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00001326 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001327 esac
1328fi
Guido van Rossum91922671997-10-09 20:24:13 +00001329
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001330# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
1331# disable features if it is defined, without any means to access these
1332# features as extensions. For these systems, we skip the definition of
1333# _XOPEN_SOURCE. Before adding a system to the list to gain access to
1334# some feature, make sure there is no alternative way to access this
1335# feature. Also, when using wildcards, make sure you have verified the
1336# need for not defining _XOPEN_SOURCE on all systems matching the
1337# wildcard, and that the wildcard does not include future systems
1338# (which may remove their limitations).
1339case $ac_sys_system/$ac_sys_release in
1340 # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
1341 # even though select is a POSIX function. Reported by J. Ribbens.
1342 OpenBSD/2.* | OpenBSD/3.[012])
1343 define_xopen_source=no;;
1344esac
1345
1346if test $define_xopen_source = yes
1347then
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00001348
1349cat >>confdefs.h <<\_ACEOF
1350#define _XOPEN_SOURCE 600
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001351_ACEOF
1352
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00001353
1354 # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
1355 # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
1356 # several APIs are not declared. Since this is also needed in some
1357 # cases for HP-UX, we define it globally.
1358
1359
1360cat >>confdefs.h <<\_ACEOF
1361#define _XOPEN_SOURCE_EXTENDED 1
1362_ACEOF
1363
1364
1365cat >>confdefs.h <<\_ACEOF
1366#define _POSIX_C_SOURCE 200112L
1367_ACEOF
1368
1369
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001370fi
1371
Guido van Rossum91922671997-10-09 20:24:13 +00001372#
1373# SGI compilers allow the specification of the both the ABI and the
1374# ISA on the command line. Depending on the values of these switches,
1375# different and often incompatable code will be generated.
1376#
1377# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
1378# thus supply support for various ABI/ISA combinations. The MACHDEP
1379# variable is also adjusted.
1380#
1381
1382if test ! -z "$SGI_ABI"
1383then
1384 CC="cc $SGI_ABI"
1385 LDFLAGS="$SGI_ABI $LDFLAGS"
1386 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
1387fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001388echo "$as_me:$LINENO: result: $MACHDEP" >&5
1389echo "${ECHO_T}$MACHDEP" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001390
Guido van Rossum627b2d71993-12-24 10:39:16 +00001391# checks for alternative programs
Martin v. Löwis11437992002-04-12 09:54:03 +00001392echo "$as_me:$LINENO: checking for --without-gcc" >&5
1393echo $ECHO_N "checking for --without-gcc... $ECHO_C" >&6
1394
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001395# Check whether --with-gcc or --without-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001396if test "${with_gcc+set}" = set; then
1397 withval="$with_gcc"
Martin v. Löwis11437992002-04-12 09:54:03 +00001398
Guido van Rossum7f43da71994-08-01 12:15:30 +00001399 case $withval in
Guido van Rossumda88dad1995-01-26 00:46:29 +00001400 no) CC=cc
1401 without_gcc=yes;;
1402 yes) CC=gcc
1403 without_gcc=no;;
1404 *) CC=$withval
1405 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001406 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +00001407else
Martin v. Löwis11437992002-04-12 09:54:03 +00001408
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001409 case $ac_sys_system in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001410 AIX*) CC=cc_r
1411 without_gcc=;;
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001412 BeOS*)
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001413 case $BE_HOST_CPU in
1414 ppc)
Fred Drake5790be12000-10-09 17:06:13 +00001415 CC=mwcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001416 without_gcc=yes
Mark Hammond8235ea12002-07-19 06:55:41 +00001417 OPT="-O -export pragma"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001418 LDFLAGS="$LDFLAGS -nodup"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001419 ;;
1420 x86)
Fred Drake5790be12000-10-09 17:06:13 +00001421 CC=gcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001422 without_gcc=no
Fred Drake5790be12000-10-09 17:06:13 +00001423 OPT=-O
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001424 ;;
1425 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001426 { { echo "$as_me:$LINENO: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&5
1427echo "$as_me: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&2;}
1428 { (exit 1); exit 1; }; }
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001429 ;;
1430 esac
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001431 AR="\$(srcdir)/Modules/ar_beos"
1432 RANLIB=:
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001433 ;;
Trent Mick635f6fb2000-08-23 21:33:05 +00001434 Monterey*)
1435 RANLIB=:
Martin v. Löwis130fb172001-07-19 11:00:41 +00001436 without_gcc=;;
1437 *) without_gcc=no;;
Guido van Rossume77438c1995-09-13 18:59:59 +00001438 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001439fi;
1440echo "$as_me:$LINENO: result: $without_gcc" >&5
1441echo "${ECHO_T}$without_gcc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001442
1443
Guido van Rossum95012191999-12-16 17:50:52 +00001444
Fred Drakea1a84e72001-03-06 05:52:16 +00001445MAINOBJ=python.o
Martin v. Löwis11437992002-04-12 09:54:03 +00001446echo "$as_me:$LINENO: checking for --with-cxx=<compiler>" >&5
1447echo $ECHO_N "checking for --with-cxx=<compiler>... $ECHO_C" >&6
1448
Guido van Rossum95012191999-12-16 17:50:52 +00001449# Check whether --with-cxx or --without-cxx was given.
1450if test "${with_cxx+set}" = set; then
1451 withval="$with_cxx"
Martin v. Löwis11437992002-04-12 09:54:03 +00001452
Martin v. Löwis22352952000-12-13 17:37:02 +00001453 check_cxx=no
Guido van Rossum95012191999-12-16 17:50:52 +00001454 case $withval in
1455 no) CXX=
1456 with_cxx=no;;
1457 *) CXX=$withval
Fred Drakea1a84e72001-03-06 05:52:16 +00001458 MAINOBJ=ccpython.o
Guido van Rossum95012191999-12-16 17:50:52 +00001459 with_cxx=$withval;;
1460 esac
1461else
Martin v. Löwis11437992002-04-12 09:54:03 +00001462
Guido van Rossum95012191999-12-16 17:50:52 +00001463 with_cxx=no
Martin v. Löwis22352952000-12-13 17:37:02 +00001464 check_cxx=yes
Guido van Rossum95012191999-12-16 17:50:52 +00001465
Martin v. Löwis11437992002-04-12 09:54:03 +00001466fi;
1467echo "$as_me:$LINENO: result: $with_cxx" >&5
1468echo "${ECHO_T}$with_cxx" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001469
1470if test "$with_cxx" = "yes"
1471then
Martin v. Löwis11437992002-04-12 09:54:03 +00001472 { { echo "$as_me:$LINENO: error: must supply a compiler when using --with-cxx" >&5
1473echo "$as_me: error: must supply a compiler when using --with-cxx" >&2;}
1474 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001475fi
1476
1477
1478
1479
Martin v. Löwis11437992002-04-12 09:54:03 +00001480if test "$check_cxx" = "yes"
Martin v. Löwis22352952000-12-13 17:37:02 +00001481then
1482 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
1483do
Martin v. Löwis11437992002-04-12 09:54:03 +00001484 # 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 +00001485set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00001486echo "$as_me:$LINENO: checking for $ac_word" >&5
1487echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1488if test "${ac_cv_prog_CXX+set}" = set; then
1489 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001490else
1491 if test -n "$CXX"; then
1492 ac_cv_prog_CXX="$CXX" # Let the user override the test.
1493else
Martin v. Löwis11437992002-04-12 09:54:03 +00001494as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1495for as_dir in $PATH
1496do
1497 IFS=$as_save_IFS
1498 test -z "$as_dir" && as_dir=.
1499 for ac_exec_ext in '' $ac_executable_extensions; do
1500 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1501 ac_cv_prog_CXX="$ac_prog"
1502 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1503 break 2
1504 fi
1505done
1506done
1507
Martin v. Löwis22352952000-12-13 17:37:02 +00001508fi
1509fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001510CXX=$ac_cv_prog_CXX
Martin v. Löwis22352952000-12-13 17:37:02 +00001511if test -n "$CXX"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001512 echo "$as_me:$LINENO: result: $CXX" >&5
1513echo "${ECHO_T}$CXX" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001514else
Martin v. Löwis11437992002-04-12 09:54:03 +00001515 echo "$as_me:$LINENO: result: no" >&5
1516echo "${ECHO_T}no" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001517fi
1518
Martin v. Löwis11437992002-04-12 09:54:03 +00001519 test -n "$CXX" && break
Martin v. Löwis22352952000-12-13 17:37:02 +00001520done
1521test -n "$CXX" || CXX="notfound"
1522
1523 if test "$CXX" = "notfound"
1524 then
1525 CXX=
1526 else
Martin v. Löwis11437992002-04-12 09:54:03 +00001527 ac_ext=cc
Martin v. Löwis22352952000-12-13 17:37:02 +00001528ac_cpp='$CXXCPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001529ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1530ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1531ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
1532 cat >conftest.$ac_ext <<_ACEOF
1533#line $LINENO "configure"
Martin v. Löwis22352952000-12-13 17:37:02 +00001534#include "confdefs.h"
1535
Martin v. Löwis11437992002-04-12 09:54:03 +00001536#ifdef F77_DUMMY_MAIN
1537# ifdef __cplusplus
1538 extern "C"
1539# endif
1540 int F77_DUMMY_MAIN() { return 1; }
1541#endif
1542int
1543main ()
1544{
Michael W. Hudson54241132001-12-07 15:38:26 +00001545
Martin v. Löwis11437992002-04-12 09:54:03 +00001546 ;
1547 return 0;
1548}
1549_ACEOF
1550ac_clean_files_save=$ac_clean_files
1551ac_clean_files="$ac_clean_files a.out a.exe"
1552# Try to create an executable without -o first, disregard a.out.
1553# It will help us diagnose broken compilers, and finding out an intuition
1554# of exeext.
1555echo "$as_me:$LINENO: checking for C++ compiler default output" >&5
1556echo $ECHO_N "checking for C++ compiler default output... $ECHO_C" >&6
1557ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1558if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1559 (eval $ac_link_default) 2>&5
1560 ac_status=$?
1561 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1562 (exit $ac_status); }; then
1563 # Find the output, starting from the most likely. This scheme is
1564# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1565# resort.
1566
1567# Be careful to initialize this variable, since it used to be cached.
1568# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1569ac_cv_exeext=
1570for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
1571 ls a.out conftest 2>/dev/null;
1572 ls a.* conftest.* 2>/dev/null`; do
1573 case $ac_file in
1574 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
1575 a.out ) # We found the default executable, but exeext='' is most
1576 # certainly right.
1577 break;;
1578 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1579 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1580 export ac_cv_exeext
1581 break;;
1582 * ) break;;
1583 esac
1584done
1585else
1586 echo "$as_me: failed program was:" >&5
1587cat conftest.$ac_ext >&5
1588{ { echo "$as_me:$LINENO: error: C++ compiler cannot create executables" >&5
1589echo "$as_me: error: C++ compiler cannot create executables" >&2;}
1590 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001591fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001592
1593ac_exeext=$ac_cv_exeext
1594echo "$as_me:$LINENO: result: $ac_file" >&5
1595echo "${ECHO_T}$ac_file" >&6
1596
1597# Check the compiler produces executables we can run. If not, either
1598# the compiler is broken, or we cross compile.
1599echo "$as_me:$LINENO: checking whether the C++ compiler works" >&5
1600echo $ECHO_N "checking whether the C++ compiler works... $ECHO_C" >&6
1601# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1602# If not cross compiling, check that we can run a simple program.
1603if test "$cross_compiling" != yes; then
1604 if { ac_try='./$ac_file'
1605 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1606 (eval $ac_try) 2>&5
1607 ac_status=$?
1608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1609 (exit $ac_status); }; }; then
1610 cross_compiling=no
1611 else
1612 if test "$cross_compiling" = maybe; then
1613 cross_compiling=yes
1614 else
1615 { { echo "$as_me:$LINENO: error: cannot run C++ compiled programs.
1616If you meant to cross compile, use \`--host'." >&5
1617echo "$as_me: error: cannot run C++ compiled programs.
1618If you meant to cross compile, use \`--host'." >&2;}
1619 { (exit 1); exit 1; }; }
1620 fi
1621 fi
1622fi
1623echo "$as_me:$LINENO: result: yes" >&5
1624echo "${ECHO_T}yes" >&6
1625
1626rm -f a.out a.exe conftest$ac_cv_exeext
1627ac_clean_files=$ac_clean_files_save
1628# Check the compiler produces executables we can run. If not, either
1629# the compiler is broken, or we cross compile.
1630echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1631echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1632echo "$as_me:$LINENO: result: $cross_compiling" >&5
1633echo "${ECHO_T}$cross_compiling" >&6
1634
1635echo "$as_me:$LINENO: checking for suffix of executables" >&5
1636echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1637if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1638 (eval $ac_link) 2>&5
1639 ac_status=$?
1640 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1641 (exit $ac_status); }; then
1642 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1643# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1644# work properly (i.e., refer to `conftest.exe'), while it won't with
1645# `rm'.
1646for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1647 case $ac_file in
1648 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1649 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1650 export ac_cv_exeext
1651 break;;
1652 * ) break;;
1653 esac
1654done
1655else
1656 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
1657echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
1658 { (exit 1); exit 1; }; }
1659fi
1660
1661rm -f conftest$ac_cv_exeext
1662echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1663echo "${ECHO_T}$ac_cv_exeext" >&6
1664
1665rm -f conftest.$ac_ext
1666EXEEXT=$ac_cv_exeext
1667ac_exeext=$EXEEXT
1668
1669 ac_ext=c
1670ac_cpp='$CPP $CPPFLAGS'
1671ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1672ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1673ac_compiler_gnu=$ac_cv_c_compiler_gnu
1674
1675
Martin v. Löwis22352952000-12-13 17:37:02 +00001676
1677 fi
1678fi
1679
Guido van Rossum8b131c51995-03-09 14:10:13 +00001680# If the user switches compilers, we can't believe the cache
1681if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
1682then
Martin v. Löwis11437992002-04-12 09:54:03 +00001683 { { echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file
1684(it is also a good idea to do 'make clean' before compiling)" >&5
1685echo "$as_me: error: cached CC is different -- throw away $cache_file
1686(it is also a good idea to do 'make clean' before compiling)" >&2;}
1687 { (exit 1); exit 1; }; }
Guido van Rossum8b131c51995-03-09 14:10:13 +00001688fi
1689
Martin v. Löwis11437992002-04-12 09:54:03 +00001690ac_ext=c
1691ac_cpp='$CPP $CPPFLAGS'
1692ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1693ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1694ac_compiler_gnu=$ac_cv_c_compiler_gnu
1695if test -n "$ac_tool_prefix"; then
1696 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1697set dummy ${ac_tool_prefix}gcc; ac_word=$2
1698echo "$as_me:$LINENO: checking for $ac_word" >&5
1699echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1700if test "${ac_cv_prog_CC+set}" = set; then
1701 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001702else
1703 if test -n "$CC"; then
1704 ac_cv_prog_CC="$CC" # Let the user override the test.
1705else
Martin v. Löwis11437992002-04-12 09:54:03 +00001706as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1707for as_dir in $PATH
1708do
1709 IFS=$as_save_IFS
1710 test -z "$as_dir" && as_dir=.
1711 for ac_exec_ext in '' $ac_executable_extensions; do
1712 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1713 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1714 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1715 break 2
1716 fi
1717done
1718done
1719
Jack Jansendd19cf82001-12-06 22:36:17 +00001720fi
1721fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001722CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00001723if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001724 echo "$as_me:$LINENO: result: $CC" >&5
1725echo "${ECHO_T}$CC" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001726else
Martin v. Löwis11437992002-04-12 09:54:03 +00001727 echo "$as_me:$LINENO: result: no" >&5
1728echo "${ECHO_T}no" >&6
1729fi
1730
1731fi
1732if test -z "$ac_cv_prog_CC"; then
1733 ac_ct_CC=$CC
1734 # Extract the first word of "gcc", so it can be a program name with args.
1735set dummy gcc; ac_word=$2
1736echo "$as_me:$LINENO: checking for $ac_word" >&5
1737echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1738if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1739 echo $ECHO_N "(cached) $ECHO_C" >&6
1740else
1741 if test -n "$ac_ct_CC"; then
1742 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1743else
1744as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1745for as_dir in $PATH
1746do
1747 IFS=$as_save_IFS
1748 test -z "$as_dir" && as_dir=.
1749 for ac_exec_ext in '' $ac_executable_extensions; do
1750 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1751 ac_cv_prog_ac_ct_CC="gcc"
1752 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1753 break 2
1754 fi
1755done
1756done
1757
1758fi
1759fi
1760ac_ct_CC=$ac_cv_prog_ac_ct_CC
1761if test -n "$ac_ct_CC"; then
1762 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1763echo "${ECHO_T}$ac_ct_CC" >&6
1764else
1765 echo "$as_me:$LINENO: result: no" >&5
1766echo "${ECHO_T}no" >&6
1767fi
1768
1769 CC=$ac_ct_CC
1770else
1771 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00001772fi
1773
Jack Jansendd19cf82001-12-06 22:36:17 +00001774if test -z "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001775 if test -n "$ac_tool_prefix"; then
1776 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1777set dummy ${ac_tool_prefix}cc; ac_word=$2
1778echo "$as_me:$LINENO: checking for $ac_word" >&5
1779echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1780if test "${ac_cv_prog_CC+set}" = set; then
1781 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001782else
1783 if test -n "$CC"; then
1784 ac_cv_prog_CC="$CC" # Let the user override the test.
1785else
Martin v. Löwis11437992002-04-12 09:54:03 +00001786as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1787for as_dir in $PATH
1788do
1789 IFS=$as_save_IFS
1790 test -z "$as_dir" && as_dir=.
1791 for ac_exec_ext in '' $ac_executable_extensions; do
1792 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1793 ac_cv_prog_CC="${ac_tool_prefix}cc"
1794 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1795 break 2
1796 fi
1797done
1798done
1799
1800fi
1801fi
1802CC=$ac_cv_prog_CC
1803if test -n "$CC"; then
1804 echo "$as_me:$LINENO: result: $CC" >&5
1805echo "${ECHO_T}$CC" >&6
1806else
1807 echo "$as_me:$LINENO: result: no" >&5
1808echo "${ECHO_T}no" >&6
1809fi
1810
1811fi
1812if test -z "$ac_cv_prog_CC"; then
1813 ac_ct_CC=$CC
1814 # Extract the first word of "cc", so it can be a program name with args.
1815set dummy cc; ac_word=$2
1816echo "$as_me:$LINENO: checking for $ac_word" >&5
1817echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1818if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1819 echo $ECHO_N "(cached) $ECHO_C" >&6
1820else
1821 if test -n "$ac_ct_CC"; then
1822 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1823else
1824as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1825for as_dir in $PATH
1826do
1827 IFS=$as_save_IFS
1828 test -z "$as_dir" && as_dir=.
1829 for ac_exec_ext in '' $ac_executable_extensions; do
1830 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1831 ac_cv_prog_ac_ct_CC="cc"
1832 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1833 break 2
1834 fi
1835done
1836done
1837
1838fi
1839fi
1840ac_ct_CC=$ac_cv_prog_ac_ct_CC
1841if test -n "$ac_ct_CC"; then
1842 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1843echo "${ECHO_T}$ac_ct_CC" >&6
1844else
1845 echo "$as_me:$LINENO: result: no" >&5
1846echo "${ECHO_T}no" >&6
1847fi
1848
1849 CC=$ac_ct_CC
1850else
1851 CC="$ac_cv_prog_CC"
1852fi
1853
1854fi
1855if test -z "$CC"; then
1856 # Extract the first word of "cc", so it can be a program name with args.
1857set dummy cc; ac_word=$2
1858echo "$as_me:$LINENO: checking for $ac_word" >&5
1859echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1860if test "${ac_cv_prog_CC+set}" = set; then
1861 echo $ECHO_N "(cached) $ECHO_C" >&6
1862else
1863 if test -n "$CC"; then
1864 ac_cv_prog_CC="$CC" # Let the user override the test.
1865else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001866 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00001867as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1868for as_dir in $PATH
1869do
1870 IFS=$as_save_IFS
1871 test -z "$as_dir" && as_dir=.
1872 for ac_exec_ext in '' $ac_executable_extensions; do
1873 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1874 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1875 ac_prog_rejected=yes
1876 continue
1877 fi
1878 ac_cv_prog_CC="cc"
1879 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1880 break 2
1881 fi
1882done
1883done
1884
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001885if test $ac_prog_rejected = yes; then
1886 # We found a bogon in the path, so make sure we never use it.
1887 set dummy $ac_cv_prog_CC
1888 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00001889 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001890 # We chose a different compiler from the bogus one.
1891 # However, it has the same basename, so the bogon will be chosen
1892 # first if we set CC to just the basename; use the full file name.
1893 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00001894 set dummy "$as_dir/$ac_word" ${1+"$@"}
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001895 shift
1896 ac_cv_prog_CC="$@"
1897 fi
1898fi
1899fi
1900fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001901CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001902if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001903 echo "$as_me:$LINENO: result: $CC" >&5
1904echo "${ECHO_T}$CC" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001905else
Martin v. Löwis11437992002-04-12 09:54:03 +00001906 echo "$as_me:$LINENO: result: no" >&5
1907echo "${ECHO_T}no" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001908fi
1909
Martin v. Löwis11437992002-04-12 09:54:03 +00001910fi
1911if test -z "$CC"; then
1912 if test -n "$ac_tool_prefix"; then
1913 for ac_prog in cl
1914 do
1915 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1916set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1917echo "$as_me:$LINENO: checking for $ac_word" >&5
1918echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1919if test "${ac_cv_prog_CC+set}" = set; then
1920 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00001921else
1922 if test -n "$CC"; then
1923 ac_cv_prog_CC="$CC" # Let the user override the test.
1924else
Martin v. Löwis11437992002-04-12 09:54:03 +00001925as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1926for as_dir in $PATH
1927do
1928 IFS=$as_save_IFS
1929 test -z "$as_dir" && as_dir=.
1930 for ac_exec_ext in '' $ac_executable_extensions; do
1931 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1932 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1933 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1934 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00001935 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001936done
1937done
1938
1939fi
1940fi
1941CC=$ac_cv_prog_CC
1942if test -n "$CC"; then
1943 echo "$as_me:$LINENO: result: $CC" >&5
1944echo "${ECHO_T}$CC" >&6
1945else
1946 echo "$as_me:$LINENO: result: no" >&5
1947echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001948fi
1949
Martin v. Löwis11437992002-04-12 09:54:03 +00001950 test -n "$CC" && break
1951 done
1952fi
1953if test -z "$CC"; then
1954 ac_ct_CC=$CC
1955 for ac_prog in cl
1956do
1957 # Extract the first word of "$ac_prog", so it can be a program name with args.
1958set dummy $ac_prog; ac_word=$2
1959echo "$as_me:$LINENO: checking for $ac_word" >&5
1960echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1961if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1962 echo $ECHO_N "(cached) $ECHO_C" >&6
1963else
1964 if test -n "$ac_ct_CC"; then
1965 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1966else
1967as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1968for as_dir in $PATH
1969do
1970 IFS=$as_save_IFS
1971 test -z "$as_dir" && as_dir=.
1972 for ac_exec_ext in '' $ac_executable_extensions; do
1973 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1974 ac_cv_prog_ac_ct_CC="$ac_prog"
1975 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1976 break 2
1977 fi
1978done
1979done
Jack Jansendd19cf82001-12-06 22:36:17 +00001980
Martin v. Löwis11437992002-04-12 09:54:03 +00001981fi
1982fi
1983ac_ct_CC=$ac_cv_prog_ac_ct_CC
1984if test -n "$ac_ct_CC"; then
1985 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1986echo "${ECHO_T}$ac_ct_CC" >&6
1987else
1988 echo "$as_me:$LINENO: result: no" >&5
1989echo "${ECHO_T}no" >&6
1990fi
Michael W. Hudson54241132001-12-07 15:38:26 +00001991
Martin v. Löwis11437992002-04-12 09:54:03 +00001992 test -n "$ac_ct_CC" && break
1993done
Michael W. Hudson54241132001-12-07 15:38:26 +00001994
Martin v. Löwis11437992002-04-12 09:54:03 +00001995 CC=$ac_ct_CC
1996fi
1997
1998fi
1999
2000
2001test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH" >&5
2002echo "$as_me: error: no acceptable C compiler found in \$PATH" >&2;}
2003 { (exit 1); exit 1; }; }
2004
2005# Provide some information about the compiler.
2006echo "$as_me:$LINENO:" \
2007 "checking for C compiler version" >&5
2008ac_compiler=`set X $ac_compile; echo $2`
2009{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2010 (eval $ac_compiler --version </dev/null >&5) 2>&5
2011 ac_status=$?
2012 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2013 (exit $ac_status); }
2014{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2015 (eval $ac_compiler -v </dev/null >&5) 2>&5
2016 ac_status=$?
2017 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2018 (exit $ac_status); }
2019{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2020 (eval $ac_compiler -V </dev/null >&5) 2>&5
2021 ac_status=$?
2022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2023 (exit $ac_status); }
2024
2025cat >conftest.$ac_ext <<_ACEOF
2026#line $LINENO "configure"
Jack Jansendd19cf82001-12-06 22:36:17 +00002027#include "confdefs.h"
2028
Martin v. Löwis11437992002-04-12 09:54:03 +00002029#ifdef F77_DUMMY_MAIN
2030# ifdef __cplusplus
2031 extern "C"
2032# endif
2033 int F77_DUMMY_MAIN() { return 1; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002034#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00002035int
2036main ()
2037{
2038
2039 ;
2040 return 0;
2041}
2042_ACEOF
2043ac_clean_files_save=$ac_clean_files
2044ac_clean_files="$ac_clean_files a.out a.exe"
2045# Try to create an executable without -o first, disregard a.out.
2046# It will help us diagnose broken compilers, and finding out an intuition
2047# of exeext.
2048echo "$as_me:$LINENO: checking for C compiler default output" >&5
2049echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2050ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2051if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2052 (eval $ac_link_default) 2>&5
2053 ac_status=$?
2054 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2055 (exit $ac_status); }; then
2056 # Find the output, starting from the most likely. This scheme is
2057# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2058# resort.
2059
2060# Be careful to initialize this variable, since it used to be cached.
2061# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2062ac_cv_exeext=
2063for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
2064 ls a.out conftest 2>/dev/null;
2065 ls a.* conftest.* 2>/dev/null`; do
2066 case $ac_file in
2067 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
2068 a.out ) # We found the default executable, but exeext='' is most
2069 # certainly right.
2070 break;;
2071 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2072 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
2073 export ac_cv_exeext
2074 break;;
2075 * ) break;;
2076 esac
2077done
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002078else
Martin v. Löwis11437992002-04-12 09:54:03 +00002079 echo "$as_me: failed program was:" >&5
2080cat conftest.$ac_ext >&5
2081{ { echo "$as_me:$LINENO: error: C compiler cannot create executables" >&5
2082echo "$as_me: error: C compiler cannot create executables" >&2;}
2083 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002084fi
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002085
Martin v. Löwis11437992002-04-12 09:54:03 +00002086ac_exeext=$ac_cv_exeext
2087echo "$as_me:$LINENO: result: $ac_file" >&5
2088echo "${ECHO_T}$ac_file" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002089
Martin v. Löwis11437992002-04-12 09:54:03 +00002090# Check the compiler produces executables we can run. If not, either
2091# the compiler is broken, or we cross compile.
2092echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2093echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2094# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2095# If not cross compiling, check that we can run a simple program.
2096if test "$cross_compiling" != yes; then
2097 if { ac_try='./$ac_file'
2098 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2099 (eval $ac_try) 2>&5
2100 ac_status=$?
2101 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2102 (exit $ac_status); }; }; then
2103 cross_compiling=no
2104 else
2105 if test "$cross_compiling" = maybe; then
2106 cross_compiling=yes
2107 else
2108 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2109If you meant to cross compile, use \`--host'." >&5
2110echo "$as_me: error: cannot run C compiled programs.
2111If you meant to cross compile, use \`--host'." >&2;}
2112 { (exit 1); exit 1; }; }
2113 fi
2114 fi
2115fi
2116echo "$as_me:$LINENO: result: yes" >&5
2117echo "${ECHO_T}yes" >&6
2118
2119rm -f a.out a.exe conftest$ac_cv_exeext
2120ac_clean_files=$ac_clean_files_save
2121# Check the compiler produces executables we can run. If not, either
2122# the compiler is broken, or we cross compile.
2123echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2124echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2125echo "$as_me:$LINENO: result: $cross_compiling" >&5
2126echo "${ECHO_T}$cross_compiling" >&6
2127
2128echo "$as_me:$LINENO: checking for suffix of executables" >&5
2129echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2130if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2131 (eval $ac_link) 2>&5
2132 ac_status=$?
2133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2134 (exit $ac_status); }; then
2135 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2136# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2137# work properly (i.e., refer to `conftest.exe'), while it won't with
2138# `rm'.
2139for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
2140 case $ac_file in
2141 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
2142 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2143 export ac_cv_exeext
2144 break;;
2145 * ) break;;
2146 esac
2147done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002148else
Martin v. Löwis11437992002-04-12 09:54:03 +00002149 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
2150echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
2151 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002152fi
Jack Jansendd19cf82001-12-06 22:36:17 +00002153
Martin v. Löwis11437992002-04-12 09:54:03 +00002154rm -f conftest$ac_cv_exeext
2155echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2156echo "${ECHO_T}$ac_cv_exeext" >&6
2157
2158rm -f conftest.$ac_ext
2159EXEEXT=$ac_cv_exeext
2160ac_exeext=$EXEEXT
2161echo "$as_me:$LINENO: checking for suffix of object files" >&5
2162echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2163if test "${ac_cv_objext+set}" = set; then
2164 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002165else
Martin v. Löwis11437992002-04-12 09:54:03 +00002166 cat >conftest.$ac_ext <<_ACEOF
2167#line $LINENO "configure"
2168#include "confdefs.h"
2169
2170#ifdef F77_DUMMY_MAIN
2171# ifdef __cplusplus
2172 extern "C"
2173# endif
2174 int F77_DUMMY_MAIN() { return 1; }
2175#endif
2176int
2177main ()
2178{
2179
2180 ;
2181 return 0;
2182}
2183_ACEOF
2184rm -f conftest.o conftest.obj
2185if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2186 (eval $ac_compile) 2>&5
2187 ac_status=$?
2188 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2189 (exit $ac_status); }; then
2190 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2191 case $ac_file in
2192 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
2193 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2194 break;;
2195 esac
2196done
2197else
2198 echo "$as_me: failed program was:" >&5
2199cat conftest.$ac_ext >&5
2200{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile" >&5
2201echo "$as_me: error: cannot compute suffix of object files: cannot compile" >&2;}
2202 { (exit 1); exit 1; }; }
2203fi
2204
2205rm -f conftest.$ac_cv_objext conftest.$ac_ext
2206fi
2207echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2208echo "${ECHO_T}$ac_cv_objext" >&6
2209OBJEXT=$ac_cv_objext
2210ac_objext=$OBJEXT
2211echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2212echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2213if test "${ac_cv_c_compiler_gnu+set}" = set; then
2214 echo $ECHO_N "(cached) $ECHO_C" >&6
2215else
2216 cat >conftest.$ac_ext <<_ACEOF
2217#line $LINENO "configure"
2218#include "confdefs.h"
2219
2220#ifdef F77_DUMMY_MAIN
2221# ifdef __cplusplus
2222 extern "C"
2223# endif
2224 int F77_DUMMY_MAIN() { return 1; }
2225#endif
2226int
2227main ()
2228{
2229#ifndef __GNUC__
2230 choke me
2231#endif
2232
2233 ;
2234 return 0;
2235}
2236_ACEOF
2237rm -f conftest.$ac_objext
2238if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2239 (eval $ac_compile) 2>&5
2240 ac_status=$?
2241 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2242 (exit $ac_status); } &&
2243 { ac_try='test -s conftest.$ac_objext'
2244 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2245 (eval $ac_try) 2>&5
2246 ac_status=$?
2247 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2248 (exit $ac_status); }; }; then
2249 ac_compiler_gnu=yes
2250else
2251 echo "$as_me: failed program was:" >&5
2252cat conftest.$ac_ext >&5
2253ac_compiler_gnu=no
2254fi
2255rm -f conftest.$ac_objext conftest.$ac_ext
2256ac_cv_c_compiler_gnu=$ac_compiler_gnu
2257
2258fi
2259echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2260echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2261GCC=`test $ac_compiler_gnu = yes && echo yes`
2262ac_test_CFLAGS=${CFLAGS+set}
2263ac_save_CFLAGS=$CFLAGS
2264CFLAGS="-g"
2265echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2266echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2267if test "${ac_cv_prog_cc_g+set}" = set; then
2268 echo $ECHO_N "(cached) $ECHO_C" >&6
2269else
2270 cat >conftest.$ac_ext <<_ACEOF
2271#line $LINENO "configure"
2272#include "confdefs.h"
2273
2274#ifdef F77_DUMMY_MAIN
2275# ifdef __cplusplus
2276 extern "C"
2277# endif
2278 int F77_DUMMY_MAIN() { return 1; }
2279#endif
2280int
2281main ()
2282{
2283
2284 ;
2285 return 0;
2286}
2287_ACEOF
2288rm -f conftest.$ac_objext
2289if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2290 (eval $ac_compile) 2>&5
2291 ac_status=$?
2292 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2293 (exit $ac_status); } &&
2294 { ac_try='test -s conftest.$ac_objext'
2295 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2296 (eval $ac_try) 2>&5
2297 ac_status=$?
2298 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2299 (exit $ac_status); }; }; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002300 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002301else
Martin v. Löwis11437992002-04-12 09:54:03 +00002302 echo "$as_me: failed program was:" >&5
2303cat conftest.$ac_ext >&5
2304ac_cv_prog_cc_g=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002305fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002306rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002307fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002308echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2309echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002310if test "$ac_test_CFLAGS" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002311 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002312elif test $ac_cv_prog_cc_g = yes; then
2313 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002314 CFLAGS="-g -O2"
2315 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002316 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002317 fi
2318else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002319 if test "$GCC" = yes; then
2320 CFLAGS="-O2"
2321 else
2322 CFLAGS=
2323 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002324fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002325# Some people use a C++ compiler to compile C. Since we use `exit',
2326# in C++ we need to declare it. In case someone uses the same compiler
2327# for both compiling C and C++ we need to have the C++ compiler decide
2328# the declaration of exit, since it's the most demanding environment.
2329cat >conftest.$ac_ext <<_ACEOF
2330#ifndef __cplusplus
2331 choke me
2332#endif
2333_ACEOF
2334rm -f conftest.$ac_objext
2335if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2336 (eval $ac_compile) 2>&5
2337 ac_status=$?
2338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2339 (exit $ac_status); } &&
2340 { ac_try='test -s conftest.$ac_objext'
2341 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2342 (eval $ac_try) 2>&5
2343 ac_status=$?
2344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2345 (exit $ac_status); }; }; then
2346 for ac_declaration in \
2347 ''\
2348 '#include <stdlib.h>' \
2349 'extern "C" void std::exit (int) throw (); using std::exit;' \
2350 'extern "C" void std::exit (int); using std::exit;' \
2351 'extern "C" void exit (int) throw ();' \
2352 'extern "C" void exit (int);' \
2353 'void exit (int);'
2354do
2355 cat >conftest.$ac_ext <<_ACEOF
2356#line $LINENO "configure"
2357#include "confdefs.h"
2358#include <stdlib.h>
2359$ac_declaration
2360#ifdef F77_DUMMY_MAIN
2361# ifdef __cplusplus
2362 extern "C"
2363# endif
2364 int F77_DUMMY_MAIN() { return 1; }
2365#endif
2366int
2367main ()
2368{
2369exit (42);
2370 ;
2371 return 0;
2372}
2373_ACEOF
2374rm -f conftest.$ac_objext
2375if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2376 (eval $ac_compile) 2>&5
2377 ac_status=$?
2378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2379 (exit $ac_status); } &&
2380 { ac_try='test -s conftest.$ac_objext'
2381 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2382 (eval $ac_try) 2>&5
2383 ac_status=$?
2384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2385 (exit $ac_status); }; }; then
2386 :
2387else
2388 echo "$as_me: failed program was:" >&5
2389cat conftest.$ac_ext >&5
2390continue
2391fi
2392rm -f conftest.$ac_objext conftest.$ac_ext
2393 cat >conftest.$ac_ext <<_ACEOF
2394#line $LINENO "configure"
2395#include "confdefs.h"
2396$ac_declaration
2397#ifdef F77_DUMMY_MAIN
2398# ifdef __cplusplus
2399 extern "C"
2400# endif
2401 int F77_DUMMY_MAIN() { return 1; }
2402#endif
2403int
2404main ()
2405{
2406exit (42);
2407 ;
2408 return 0;
2409}
2410_ACEOF
2411rm -f conftest.$ac_objext
2412if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2413 (eval $ac_compile) 2>&5
2414 ac_status=$?
2415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2416 (exit $ac_status); } &&
2417 { ac_try='test -s conftest.$ac_objext'
2418 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2419 (eval $ac_try) 2>&5
2420 ac_status=$?
2421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2422 (exit $ac_status); }; }; then
2423 break
2424else
2425 echo "$as_me: failed program was:" >&5
2426cat conftest.$ac_ext >&5
2427fi
2428rm -f conftest.$ac_objext conftest.$ac_ext
2429done
2430rm -f conftest*
2431if test -n "$ac_declaration"; then
2432 echo '#ifdef __cplusplus' >>confdefs.h
2433 echo $ac_declaration >>confdefs.h
2434 echo '#endif' >>confdefs.h
2435fi
2436
2437else
2438 echo "$as_me: failed program was:" >&5
2439cat conftest.$ac_ext >&5
2440fi
2441rm -f conftest.$ac_objext conftest.$ac_ext
2442ac_ext=c
2443ac_cpp='$CPP $CPPFLAGS'
2444ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2445ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2446ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002447
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002448
2449# checks for UNIX variants that set C preprocessor variables
Martin v. Löwis11437992002-04-12 09:54:03 +00002450
2451ac_ext=c
2452ac_cpp='$CPP $CPPFLAGS'
2453ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2454ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2455ac_compiler_gnu=$ac_cv_c_compiler_gnu
2456echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2457echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002458# On Suns, sometimes $CPP names a directory.
2459if test -n "$CPP" && test -d "$CPP"; then
2460 CPP=
2461fi
2462if test -z "$CPP"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002463 if test "${ac_cv_prog_CPP+set}" = set; then
2464 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002465else
Martin v. Löwis11437992002-04-12 09:54:03 +00002466 # Double quotes because CPP needs to be expanded
2467 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2468 do
2469 ac_preproc_ok=false
2470for ac_c_preproc_warn_flag in '' yes
2471do
2472 # Use a header file that comes with gcc, so configuring glibc
2473 # with a fresh cross-compiler works.
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002474 # On the NeXT, cc -E runs the code through the compiler's parser,
Martin v. Löwis11437992002-04-12 09:54:03 +00002475 # not just through cpp. "Syntax error" is here to catch this case.
2476 cat >conftest.$ac_ext <<_ACEOF
2477#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002478#include "confdefs.h"
2479#include <assert.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00002480 Syntax error
2481_ACEOF
2482if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2483 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2484 ac_status=$?
2485 egrep -v '^ *\+' conftest.er1 >conftest.err
2486 rm -f conftest.er1
2487 cat conftest.err >&5
2488 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2489 (exit $ac_status); } >/dev/null; then
2490 if test -s conftest.err; then
2491 ac_cpp_err=$ac_c_preproc_warn_flag
2492 else
2493 ac_cpp_err=
2494 fi
2495else
2496 ac_cpp_err=yes
2497fi
2498if test -z "$ac_cpp_err"; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002499 :
2500else
Martin v. Löwis11437992002-04-12 09:54:03 +00002501 echo "$as_me: failed program was:" >&5
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002502 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002503 # Broken: fails on valid input.
2504continue
Jack Jansendd19cf82001-12-06 22:36:17 +00002505fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002506rm -f conftest.err conftest.$ac_ext
Jack Jansendd19cf82001-12-06 22:36:17 +00002507
Martin v. Löwis11437992002-04-12 09:54:03 +00002508 # OK, works on sane cases. Now check whether non-existent headers
2509 # can be detected and how.
2510 cat >conftest.$ac_ext <<_ACEOF
2511#line $LINENO "configure"
2512#include "confdefs.h"
2513#include <ac_nonexistent.h>
2514_ACEOF
2515if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2516 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2517 ac_status=$?
2518 egrep -v '^ *\+' conftest.er1 >conftest.err
2519 rm -f conftest.er1
2520 cat conftest.err >&5
2521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2522 (exit $ac_status); } >/dev/null; then
2523 if test -s conftest.err; then
2524 ac_cpp_err=$ac_c_preproc_warn_flag
2525 else
2526 ac_cpp_err=
2527 fi
2528else
2529 ac_cpp_err=yes
2530fi
2531if test -z "$ac_cpp_err"; then
2532 # Broken: success on invalid input.
2533continue
2534else
2535 echo "$as_me: failed program was:" >&5
2536 cat conftest.$ac_ext >&5
2537 # Passes both tests.
2538ac_preproc_ok=:
2539break
2540fi
2541rm -f conftest.err conftest.$ac_ext
2542
2543done
2544# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2545rm -f conftest.err conftest.$ac_ext
2546if $ac_preproc_ok; then
2547 break
2548fi
2549
2550 done
2551 ac_cv_prog_CPP=$CPP
2552
2553fi
2554 CPP=$ac_cv_prog_CPP
2555else
2556 ac_cv_prog_CPP=$CPP
2557fi
2558echo "$as_me:$LINENO: result: $CPP" >&5
2559echo "${ECHO_T}$CPP" >&6
2560ac_preproc_ok=false
2561for ac_c_preproc_warn_flag in '' yes
2562do
2563 # Use a header file that comes with gcc, so configuring glibc
2564 # with a fresh cross-compiler works.
2565 # On the NeXT, cc -E runs the code through the compiler's parser,
2566 # not just through cpp. "Syntax error" is here to catch this case.
2567 cat >conftest.$ac_ext <<_ACEOF
2568#line $LINENO "configure"
2569#include "confdefs.h"
2570#include <assert.h>
2571 Syntax error
2572_ACEOF
2573if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2574 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2575 ac_status=$?
2576 egrep -v '^ *\+' conftest.er1 >conftest.err
2577 rm -f conftest.er1
2578 cat conftest.err >&5
2579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2580 (exit $ac_status); } >/dev/null; then
2581 if test -s conftest.err; then
2582 ac_cpp_err=$ac_c_preproc_warn_flag
2583 else
2584 ac_cpp_err=
2585 fi
2586else
2587 ac_cpp_err=yes
2588fi
2589if test -z "$ac_cpp_err"; then
2590 :
2591else
2592 echo "$as_me: failed program was:" >&5
2593 cat conftest.$ac_ext >&5
2594 # Broken: fails on valid input.
2595continue
2596fi
2597rm -f conftest.err conftest.$ac_ext
2598
2599 # OK, works on sane cases. Now check whether non-existent headers
2600 # can be detected and how.
2601 cat >conftest.$ac_ext <<_ACEOF
2602#line $LINENO "configure"
2603#include "confdefs.h"
2604#include <ac_nonexistent.h>
2605_ACEOF
2606if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2607 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2608 ac_status=$?
2609 egrep -v '^ *\+' conftest.er1 >conftest.err
2610 rm -f conftest.er1
2611 cat conftest.err >&5
2612 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2613 (exit $ac_status); } >/dev/null; then
2614 if test -s conftest.err; then
2615 ac_cpp_err=$ac_c_preproc_warn_flag
2616 else
2617 ac_cpp_err=
2618 fi
2619else
2620 ac_cpp_err=yes
2621fi
2622if test -z "$ac_cpp_err"; then
2623 # Broken: success on invalid input.
2624continue
2625else
2626 echo "$as_me: failed program was:" >&5
2627 cat conftest.$ac_ext >&5
2628 # Passes both tests.
2629ac_preproc_ok=:
2630break
2631fi
2632rm -f conftest.err conftest.$ac_ext
2633
2634done
2635# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2636rm -f conftest.err conftest.$ac_ext
2637if $ac_preproc_ok; then
2638 :
2639else
2640 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check" >&5
2641echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2642 { (exit 1); exit 1; }; }
2643fi
2644
2645ac_ext=c
2646ac_cpp='$CPP $CPPFLAGS'
2647ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2648ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2649ac_compiler_gnu=$ac_cv_c_compiler_gnu
2650
2651
2652
2653echo "$as_me:$LINENO: checking for AIX" >&5
2654echo $ECHO_N "checking for AIX... $ECHO_C" >&6
2655cat >conftest.$ac_ext <<_ACEOF
2656#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002657#include "confdefs.h"
2658#ifdef _AIX
2659 yes
2660#endif
2661
Martin v. Löwis11437992002-04-12 09:54:03 +00002662_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002663if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2664 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002665 echo "$as_me:$LINENO: result: yes" >&5
2666echo "${ECHO_T}yes" >&6
2667cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002668#define _ALL_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002669_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002670
2671else
Martin v. Löwis11437992002-04-12 09:54:03 +00002672 echo "$as_me:$LINENO: result: no" >&5
2673echo "${ECHO_T}no" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002674fi
2675rm -f conftest*
2676
Michael W. Hudson54241132001-12-07 15:38:26 +00002677
Martin v. Löwis11437992002-04-12 09:54:03 +00002678echo "$as_me:$LINENO: checking for ANSI C header files" >&5
2679echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2680if test "${ac_cv_header_stdc+set}" = set; then
2681 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002682else
Martin v. Löwis11437992002-04-12 09:54:03 +00002683 cat >conftest.$ac_ext <<_ACEOF
2684#line $LINENO "configure"
2685#include "confdefs.h"
2686#include <stdlib.h>
2687#include <stdarg.h>
2688#include <string.h>
2689#include <float.h>
2690
2691_ACEOF
2692if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2693 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2694 ac_status=$?
2695 egrep -v '^ *\+' conftest.er1 >conftest.err
2696 rm -f conftest.er1
2697 cat conftest.err >&5
2698 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2699 (exit $ac_status); } >/dev/null; then
2700 if test -s conftest.err; then
2701 ac_cpp_err=$ac_c_preproc_warn_flag
2702 else
2703 ac_cpp_err=
2704 fi
2705else
2706 ac_cpp_err=yes
2707fi
2708if test -z "$ac_cpp_err"; then
2709 ac_cv_header_stdc=yes
2710else
2711 echo "$as_me: failed program was:" >&5
2712 cat conftest.$ac_ext >&5
2713 ac_cv_header_stdc=no
2714fi
2715rm -f conftest.err conftest.$ac_ext
2716
2717if test $ac_cv_header_stdc = yes; then
2718 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2719 cat >conftest.$ac_ext <<_ACEOF
2720#line $LINENO "configure"
2721#include "confdefs.h"
2722#include <string.h>
2723
2724_ACEOF
2725if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2726 egrep "memchr" >/dev/null 2>&1; then
2727 :
2728else
2729 ac_cv_header_stdc=no
2730fi
2731rm -f conftest*
2732
2733fi
2734
2735if test $ac_cv_header_stdc = yes; then
2736 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2737 cat >conftest.$ac_ext <<_ACEOF
2738#line $LINENO "configure"
2739#include "confdefs.h"
2740#include <stdlib.h>
2741
2742_ACEOF
2743if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2744 egrep "free" >/dev/null 2>&1; then
2745 :
2746else
2747 ac_cv_header_stdc=no
2748fi
2749rm -f conftest*
2750
2751fi
2752
2753if test $ac_cv_header_stdc = yes; then
2754 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2755 if test "$cross_compiling" = yes; then
2756 :
2757else
2758 cat >conftest.$ac_ext <<_ACEOF
2759#line $LINENO "configure"
2760#include "confdefs.h"
2761#include <ctype.h>
2762#if ((' ' & 0x0FF) == 0x020)
2763# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2764# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2765#else
2766# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2767 || ('j' <= (c) && (c) <= 'r') \
2768 || ('s' <= (c) && (c) <= 'z'))
2769# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2770#endif
2771
2772#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2773int
2774main ()
2775{
2776 int i;
2777 for (i = 0; i < 256; i++)
2778 if (XOR (islower (i), ISLOWER (i))
2779 || toupper (i) != TOUPPER (i))
2780 exit(2);
2781 exit (0);
2782}
2783_ACEOF
2784rm -f conftest$ac_exeext
2785if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2786 (eval $ac_link) 2>&5
2787 ac_status=$?
2788 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2789 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2790 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2791 (eval $ac_try) 2>&5
2792 ac_status=$?
2793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2794 (exit $ac_status); }; }; then
2795 :
2796else
2797 echo "$as_me: program exited with status $ac_status" >&5
2798echo "$as_me: failed program was:" >&5
2799cat conftest.$ac_ext >&5
2800( exit $ac_status )
2801ac_cv_header_stdc=no
2802fi
2803rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2804fi
2805fi
2806fi
2807echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
2808echo "${ECHO_T}$ac_cv_header_stdc" >&6
2809if test $ac_cv_header_stdc = yes; then
2810
2811cat >>confdefs.h <<\_ACEOF
2812#define STDC_HEADERS 1
2813_ACEOF
2814
2815fi
2816
2817# On IRIX 5.3, sys/types and inttypes.h are conflicting.
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
2828 inttypes.h stdint.h unistd.h
2829do
2830as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
2831echo "$as_me:$LINENO: checking for $ac_header" >&5
2832echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
2833if eval "test \"\${$as_ac_Header+set}\" = set"; then
2834 echo $ECHO_N "(cached) $ECHO_C" >&6
2835else
2836 cat >conftest.$ac_ext <<_ACEOF
2837#line $LINENO "configure"
2838#include "confdefs.h"
2839$ac_includes_default
2840
2841#include <$ac_header>
2842_ACEOF
2843rm -f conftest.$ac_objext
2844if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2845 (eval $ac_compile) 2>&5
2846 ac_status=$?
2847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2848 (exit $ac_status); } &&
2849 { ac_try='test -s conftest.$ac_objext'
2850 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2851 (eval $ac_try) 2>&5
2852 ac_status=$?
2853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2854 (exit $ac_status); }; }; then
2855 eval "$as_ac_Header=yes"
2856else
2857 echo "$as_me: failed program was:" >&5
2858cat conftest.$ac_ext >&5
2859eval "$as_ac_Header=no"
2860fi
2861rm -f conftest.$ac_objext conftest.$ac_ext
2862fi
2863echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
2864echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2865if test `eval echo '${'$as_ac_Header'}'` = yes; then
2866 cat >>confdefs.h <<_ACEOF
2867#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
2868_ACEOF
2869
2870fi
2871
2872done
2873
2874
2875if test "${ac_cv_header_minix_config_h+set}" = set; then
2876 echo "$as_me:$LINENO: checking for minix/config.h" >&5
2877echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2878if test "${ac_cv_header_minix_config_h+set}" = set; then
2879 echo $ECHO_N "(cached) $ECHO_C" >&6
2880fi
2881echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
2882echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2883else
2884 # Is the header compilable?
2885echo "$as_me:$LINENO: checking minix/config.h usability" >&5
2886echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6
2887cat >conftest.$ac_ext <<_ACEOF
2888#line $LINENO "configure"
2889#include "confdefs.h"
2890$ac_includes_default
2891#include <minix/config.h>
2892_ACEOF
2893rm -f conftest.$ac_objext
2894if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2895 (eval $ac_compile) 2>&5
2896 ac_status=$?
2897 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2898 (exit $ac_status); } &&
2899 { ac_try='test -s conftest.$ac_objext'
2900 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2901 (eval $ac_try) 2>&5
2902 ac_status=$?
2903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2904 (exit $ac_status); }; }; then
2905 ac_header_compiler=yes
2906else
2907 echo "$as_me: failed program was:" >&5
2908cat conftest.$ac_ext >&5
2909ac_header_compiler=no
2910fi
2911rm -f conftest.$ac_objext conftest.$ac_ext
2912echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
2913echo "${ECHO_T}$ac_header_compiler" >&6
2914
2915# Is the header present?
2916echo "$as_me:$LINENO: checking minix/config.h presence" >&5
2917echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6
2918cat >conftest.$ac_ext <<_ACEOF
2919#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002920#include "confdefs.h"
2921#include <minix/config.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00002922_ACEOF
2923if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2924 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2925 ac_status=$?
2926 egrep -v '^ *\+' conftest.er1 >conftest.err
2927 rm -f conftest.er1
2928 cat conftest.err >&5
2929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2930 (exit $ac_status); } >/dev/null; then
2931 if test -s conftest.err; then
2932 ac_cpp_err=$ac_c_preproc_warn_flag
2933 else
2934 ac_cpp_err=
2935 fi
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002936else
Martin v. Löwis11437992002-04-12 09:54:03 +00002937 ac_cpp_err=yes
2938fi
2939if test -z "$ac_cpp_err"; then
2940 ac_header_preproc=yes
2941else
2942 echo "$as_me: failed program was:" >&5
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002943 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002944 ac_header_preproc=no
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002945fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002946rm -f conftest.err conftest.$ac_ext
2947echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
2948echo "${ECHO_T}$ac_header_preproc" >&6
2949
2950# So? What about this header?
2951case $ac_header_compiler:$ac_header_preproc in
2952 yes:no )
2953 { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
2954echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
2955 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
2956echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;};;
2957 no:yes )
2958 { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
2959echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
2960 { echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5
2961echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;}
2962 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
2963echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;};;
2964esac
2965echo "$as_me:$LINENO: checking for minix/config.h" >&5
2966echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2967if test "${ac_cv_header_minix_config_h+set}" = set; then
2968 echo $ECHO_N "(cached) $ECHO_C" >&6
2969else
2970 ac_cv_header_minix_config_h=$ac_header_preproc
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002971fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002972echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
2973echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2974
2975fi
2976if test $ac_cv_header_minix_config_h = yes; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002977 MINIX=yes
2978else
Martin v. Löwis11437992002-04-12 09:54:03 +00002979 MINIX=
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002980fi
2981
Martin v. Löwis11437992002-04-12 09:54:03 +00002982
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002983if test "$MINIX" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002984
2985cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002986#define _POSIX_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002987_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002988
Martin v. Löwis11437992002-04-12 09:54:03 +00002989
2990cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002991#define _POSIX_1_SOURCE 2
Martin v. Löwis11437992002-04-12 09:54:03 +00002992_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002993
Martin v. Löwis11437992002-04-12 09:54:03 +00002994
2995cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002996#define _MINIX 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002997_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002998
2999fi
3000
3001
Martin v. Löwis779ffc02002-12-02 22:17:01 +00003002# Check for unsupported systems
3003case $ac_sys_system/$ac_sys_release in
3004SunOS/4*|DYNIX/*|dgux*/*|IRIX/4*|Linux*/1*)
3005 echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
3006 echo See README for details.
3007 exit 1;;
3008esac
3009
3010if test "$MINIX" = yes; then
3011 echo This system \(MINIX\) is no longer supported.
3012 echo Read README for details.
3013 exit 1
3014fi
3015
Michael W. Hudson54241132001-12-07 15:38:26 +00003016
Martin v. Löwis11437992002-04-12 09:54:03 +00003017echo "$as_me:$LINENO: checking for --with-suffix" >&5
3018echo $ECHO_N "checking for --with-suffix... $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00003019
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00003020# Check whether --with-suffix or --without-suffix was given.
3021if test "${with_suffix+set}" = set; then
3022 withval="$with_suffix"
Martin v. Löwis11437992002-04-12 09:54:03 +00003023
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00003024 case $withval in
3025 no) EXEEXT=;;
3026 yes) EXEEXT=.exe;;
3027 *) EXEEXT=$withval;;
3028 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00003029fi;
3030echo "$as_me:$LINENO: result: $EXEEXT" >&5
3031echo "${ECHO_T}$EXEEXT" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00003032
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003033# Test whether we're running on a non-case-sensitive system, in which
3034# case we give a warning if no ext is given
Jack Jansen1999ef42001-12-06 21:47:20 +00003035
Martin v. Löwis11437992002-04-12 09:54:03 +00003036echo "$as_me:$LINENO: checking for case-insensitive build directory" >&5
3037echo $ECHO_N "checking for case-insensitive build directory... $ECHO_C" >&6
Jack Jansen3c2c4332002-11-06 13:33:32 +00003038if test ! -d CaseSensitiveTestDir; then
3039mkdir CaseSensitiveTestDir
3040fi
3041
3042if test -d casesensitivetestdir
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003043then
Martin v. Löwis11437992002-04-12 09:54:03 +00003044 echo "$as_me:$LINENO: result: yes" >&5
3045echo "${ECHO_T}yes" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00003046 BUILDEXEEXT=.exe
3047else
Martin v. Löwis11437992002-04-12 09:54:03 +00003048 echo "$as_me:$LINENO: result: no" >&5
3049echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00003050 BUILDEXEEXT=$EXEEXT
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003051fi
Jack Jansen3c2c4332002-11-06 13:33:32 +00003052rmdir CaseSensitiveTestDir
Guido van Rossumff555e32000-09-22 15:38:21 +00003053
Guido van Rossumdd997f71998-10-07 19:58:26 +00003054case $MACHDEP in
3055bsdos*)
3056 case $CC in
3057 gcc) CC="$CC -D_HAVE_BSDI";;
3058 esac;;
3059esac
3060
Guido van Rossum24b1e751997-08-21 02:29:16 +00003061case $ac_sys_system in
3062hp*|HP*)
3063 case $CC in
Guido van Rossumcd5ff9f2000-09-22 16:15:54 +00003064 cc|*/cc) CC="$CC -Ae";;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003065 esac;;
Trent Mick635f6fb2000-08-23 21:33:05 +00003066Monterey*)
3067 case $CC in
3068 cc) CC="$CC -Wl,-Bexport";;
3069 esac;;
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003070SunOS*)
3071 # Some functions have a prototype only with that define, e.g. confstr
Martin v. Löwis11437992002-04-12 09:54:03 +00003072
3073cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003074#define __EXTENSIONS__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003075_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003076
3077 ;;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003078esac
3079
Michael W. Hudson54241132001-12-07 15:38:26 +00003080
3081
Martin v. Löwis11437992002-04-12 09:54:03 +00003082echo "$as_me:$LINENO: checking LIBRARY" >&5
3083echo $ECHO_N "checking LIBRARY... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003084if test -z "$LIBRARY"
3085then
3086 LIBRARY='libpython$(VERSION).a'
3087fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003088echo "$as_me:$LINENO: result: $LIBRARY" >&5
3089echo "${ECHO_T}$LIBRARY" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003090
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003091# LDLIBRARY is the name of the library to link against (as opposed to the
Jack Jansene578a632001-08-15 01:27:14 +00003092# name of the library into which to insert object files). BLDLIBRARY is also
3093# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
3094# is blank as the main program is not linked directly against LDLIBRARY.
3095# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
3096# systems without shared libraries, LDLIBRARY is the same as LIBRARY
3097# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
3098# DLLLIBRARY is the shared (i.e., DLL) library.
Martin v. Löwis11437992002-04-12 09:54:03 +00003099#
Martin v. Löwis1142de32002-03-29 16:28:31 +00003100# RUNSHARED is used to run shared python without installed libraries
3101#
3102# INSTSONAME is the name of the shared library that will be use to install
3103# on the system - some systems like version suffix, others don't
3104
3105
Michael W. Hudson54241132001-12-07 15:38:26 +00003106
3107
3108
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003109
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003110LDLIBRARY="$LIBRARY"
Jack Jansene578a632001-08-15 01:27:14 +00003111BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis09bdf722002-05-08 08:51:29 +00003112INSTSONAME='$(LDLIBRARY)'
Guido van Rossumca563f22001-01-23 01:52:44 +00003113DLLLIBRARY=''
Jack Jansene578a632001-08-15 01:27:14 +00003114LDLIBRARYDIR=''
Martin v. Löwis1142de32002-03-29 16:28:31 +00003115RUNSHARED=''
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003116
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003117# LINKCC is the command that links the python executable -- default is $(CC).
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003118# If CXX is set, and if it is needed to link a main function that was
3119# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
3120# python might then depend on the C++ runtime
Martin v. Löwis11437992002-04-12 09:54:03 +00003121# This is altered for AIX in order to build the export list before
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003122# linking.
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003123
Martin v. Löwis11437992002-04-12 09:54:03 +00003124echo "$as_me:$LINENO: checking LINKCC" >&5
3125echo $ECHO_N "checking LINKCC... $ECHO_C" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003126if test -z "$LINKCC"
3127then
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003128 if test -z "$CXX"; then
3129 LINKCC="\$(PURIFY) \$(CC)"
3130 else
Martin v. Löwis1931ca72002-06-01 21:39:58 +00003131 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003132 $CXX -c conftest.$ac_ext 2>&5
3133 if $CC -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
3134 && test -s conftest$ac_exeext && ./conftest$ac_exeext
3135 then
3136 LINKCC="\$(PURIFY) \$(CC)"
3137 else
3138 LINKCC="\$(PURIFY) \$(CXX)"
3139 fi
3140 rm -fr conftest*
3141 fi
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003142 case $ac_sys_system in
3143 AIX*)
Jack Jansen524a0982002-03-12 15:25:52 +00003144 LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp \"\" \$(LIBRARY); $LINKCC";;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00003145 dgux*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003146 LINKCC="LD_RUN_PATH=$libdir $LINKCC";;
Trent Mick635f6fb2000-08-23 21:33:05 +00003147 Monterey64*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003148 LINKCC="$LINKCC -L/usr/lib/ia64l64";;
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003149 esac
3150fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003151echo "$as_me:$LINENO: result: $LINKCC" >&5
3152echo "${ECHO_T}$LINKCC" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003153
Martin v. Löwis11437992002-04-12 09:54:03 +00003154echo "$as_me:$LINENO: checking for --enable-shared" >&5
3155echo $ECHO_N "checking for --enable-shared... $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003156# Check whether --enable-shared or --disable-shared was given.
3157if test "${enable_shared+set}" = set; then
3158 enableval="$enable_shared"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003159
Martin v. Löwis11437992002-04-12 09:54:03 +00003160fi;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003161
3162if test -z "$enable_shared"
Martin v. Löwis11437992002-04-12 09:54:03 +00003163then
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003164 case $ac_sys_system in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003165 CYGWIN* | atheos*)
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003166 enable_shared="yes";;
3167 *)
3168 enable_shared="no";;
3169 esac
Martin v. Löwis1142de32002-03-29 16:28:31 +00003170fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003171echo "$as_me:$LINENO: result: $enable_shared" >&5
3172echo "${ECHO_T}$enable_shared" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003173
3174
Martin v. Löwis11437992002-04-12 09:54:03 +00003175echo "$as_me:$LINENO: checking LDLIBRARY" >&5
3176echo $ECHO_N "checking LDLIBRARY... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00003177
Guido van Rossumb8552162001-09-05 14:58:11 +00003178# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
3179# library that we build, but we do not want to link against it (we
3180# will find it with a -framework option). For this reason there is an
3181# extra variable BLDLIBRARY against which Python and the extension
3182# modules are linked, BLDLIBRARY. This is normally the same as
3183# LDLIBRARY, but empty for MacOSX framework builds.
Jack Jansene578a632001-08-15 01:27:14 +00003184if test "$enable_framework"
3185then
3186 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
3187 LDLIBRARYDIR='$(PYTHONFRAMEWORKDIR)'
3188 BLDLIBRARY=''
3189else
3190 BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis11437992002-04-12 09:54:03 +00003191fi
Jack Jansene578a632001-08-15 01:27:14 +00003192
Martin v. Löwis1142de32002-03-29 16:28:31 +00003193# Other platforms follow
3194if test $enable_shared = "yes"; then
Mark Hammond8235ea12002-07-19 06:55:41 +00003195
3196cat >>confdefs.h <<\_ACEOF
3197#define Py_ENABLE_SHARED 1
3198_ACEOF
3199
Martin v. Löwis1142de32002-03-29 16:28:31 +00003200 case $ac_sys_system in
3201 BeOS*)
3202 LDLIBRARY='libpython$(VERSION).so'
3203 ;;
3204 CYGWIN*)
3205 LDLIBRARY='libpython$(VERSION).dll.a'
3206 DLLLIBRARY='libpython$(VERSION).dll'
3207 ;;
3208 SunOS*)
3209 LDLIBRARY='libpython$(VERSION).so'
3210 BLDLIBRARY='-Wl,-rpath,$(LIBDIR) -L. -lpython$(VERSION)'
3211 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3212 ;;
Martin v. Löwis1bc894b2002-07-30 20:19:58 +00003213 Linux*|GNU*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00003214 LDLIBRARY='libpython$(VERSION).so'
3215 BLDLIBRARY='-L. -lpython$(VERSION)'
3216 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3217 INSTSONAME="$LDLIBRARY".$SOVERSION
3218 ;;
3219 hp*|HP*)
3220 LDLIBRARY='libpython$(VERSION).sl'
3221 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
3222 RUNSHARED=SHLIB_PATH=`pwd`:$SHLIB_PATH
3223 ;;
3224 OSF*)
3225 LDLIBRARY='libpython$(VERSION).so'
3226 BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
3227 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3228 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003229 atheos*)
3230 LDLIBRARY='libpython$(VERSION).so'
3231 BLDLIBRARY='-L. -lpython$(VERSION)'
3232 RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
3233 ;;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003234 esac
3235 # DG/UX requires some fancy ld contortions to produce a .so from an .a
3236 case $MACHDEP in
3237 dguxR4)
3238 LDLIBRARY='libpython$(VERSION).so'
3239 OPT="$OPT -pic"
3240 ;;
3241 esac
3242fi
3243
Martin v. Löwis11437992002-04-12 09:54:03 +00003244echo "$as_me:$LINENO: result: $LDLIBRARY" >&5
3245echo "${ECHO_T}$LDLIBRARY" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003246
Martin v. Löwis11437992002-04-12 09:54:03 +00003247if test -n "$ac_tool_prefix"; then
3248 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3249set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3250echo "$as_me:$LINENO: checking for $ac_word" >&5
3251echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3252if test "${ac_cv_prog_RANLIB+set}" = set; then
3253 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003254else
3255 if test -n "$RANLIB"; then
3256 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3257else
Martin v. Löwis11437992002-04-12 09:54:03 +00003258as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3259for as_dir in $PATH
3260do
3261 IFS=$as_save_IFS
3262 test -z "$as_dir" && as_dir=.
3263 for ac_exec_ext in '' $ac_executable_extensions; do
3264 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3265 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3266 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3267 break 2
3268 fi
3269done
3270done
3271
Guido van Rossum627b2d71993-12-24 10:39:16 +00003272fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003273fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003274RANLIB=$ac_cv_prog_RANLIB
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003275if test -n "$RANLIB"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003276 echo "$as_me:$LINENO: result: $RANLIB" >&5
3277echo "${ECHO_T}$RANLIB" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003278else
Martin v. Löwis11437992002-04-12 09:54:03 +00003279 echo "$as_me:$LINENO: result: no" >&5
3280echo "${ECHO_T}no" >&6
3281fi
3282
3283fi
3284if test -z "$ac_cv_prog_RANLIB"; then
3285 ac_ct_RANLIB=$RANLIB
3286 # Extract the first word of "ranlib", so it can be a program name with args.
3287set dummy ranlib; ac_word=$2
3288echo "$as_me:$LINENO: checking for $ac_word" >&5
3289echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3290if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3291 echo $ECHO_N "(cached) $ECHO_C" >&6
3292else
3293 if test -n "$ac_ct_RANLIB"; then
3294 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3295else
3296as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3297for as_dir in $PATH
3298do
3299 IFS=$as_save_IFS
3300 test -z "$as_dir" && as_dir=.
3301 for ac_exec_ext in '' $ac_executable_extensions; do
3302 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3303 ac_cv_prog_ac_ct_RANLIB="ranlib"
3304 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3305 break 2
3306 fi
3307done
3308done
3309
3310 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3311fi
3312fi
3313ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3314if test -n "$ac_ct_RANLIB"; then
3315 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3316echo "${ECHO_T}$ac_ct_RANLIB" >&6
3317else
3318 echo "$as_me:$LINENO: result: no" >&5
3319echo "${ECHO_T}no" >&6
3320fi
3321
3322 RANLIB=$ac_ct_RANLIB
3323else
3324 RANLIB="$ac_cv_prog_RANLIB"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003325fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003326
3327
Guido van Rossum7f43da71994-08-01 12:15:30 +00003328for ac_prog in ar aal
3329do
Martin v. Löwis11437992002-04-12 09:54:03 +00003330 # Extract the first word of "$ac_prog", so it can be a program name with args.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003331set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00003332echo "$as_me:$LINENO: checking for $ac_word" >&5
3333echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3334if test "${ac_cv_prog_AR+set}" = set; then
3335 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003336else
3337 if test -n "$AR"; then
3338 ac_cv_prog_AR="$AR" # Let the user override the test.
3339else
Martin v. Löwis11437992002-04-12 09:54:03 +00003340as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3341for as_dir in $PATH
3342do
3343 IFS=$as_save_IFS
3344 test -z "$as_dir" && as_dir=.
3345 for ac_exec_ext in '' $ac_executable_extensions; do
3346 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3347 ac_cv_prog_AR="$ac_prog"
3348 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3349 break 2
3350 fi
3351done
3352done
3353
Guido van Rossum7f43da71994-08-01 12:15:30 +00003354fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003355fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003356AR=$ac_cv_prog_AR
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003357if test -n "$AR"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003358 echo "$as_me:$LINENO: result: $AR" >&5
3359echo "${ECHO_T}$AR" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003360else
Martin v. Löwis11437992002-04-12 09:54:03 +00003361 echo "$as_me:$LINENO: result: no" >&5
3362echo "${ECHO_T}no" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003363fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003364
Martin v. Löwis11437992002-04-12 09:54:03 +00003365 test -n "$AR" && break
Guido van Rossum7f43da71994-08-01 12:15:30 +00003366done
3367test -n "$AR" || AR="ar"
3368
Michael W. Hudson54241132001-12-07 15:38:26 +00003369
Neil Schemenauera42c8272001-03-31 00:01:55 +00003370case $MACHDEP in
Neil Schemenaueraf5567f2001-10-21 22:32:04 +00003371bsdos*|hp*|HP*)
3372 # install -d does not work on BSDI or HP-UX
Neil Schemenauera42c8272001-03-31 00:01:55 +00003373 if test -z "$INSTALL"
3374 then
3375 INSTALL="${srcdir}/install-sh -c"
3376 fi
3377esac
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003378ac_aux_dir=
3379for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
3380 if test -f $ac_dir/install-sh; then
3381 ac_aux_dir=$ac_dir
3382 ac_install_sh="$ac_aux_dir/install-sh -c"
3383 break
3384 elif test -f $ac_dir/install.sh; then
3385 ac_aux_dir=$ac_dir
3386 ac_install_sh="$ac_aux_dir/install.sh -c"
3387 break
Martin v. Löwis11437992002-04-12 09:54:03 +00003388 elif test -f $ac_dir/shtool; then
3389 ac_aux_dir=$ac_dir
3390 ac_install_sh="$ac_aux_dir/shtool install -c"
3391 break
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003392 fi
3393done
3394if test -z "$ac_aux_dir"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003395 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
3396echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
3397 { (exit 1); exit 1; }; }
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003398fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003399ac_config_guess="$SHELL $ac_aux_dir/config.guess"
3400ac_config_sub="$SHELL $ac_aux_dir/config.sub"
3401ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003402
3403# Find a good install program. We prefer a C program (faster),
3404# so one script is as good as another. But avoid the broken or
3405# incompatible versions:
3406# SysV /etc/install, /usr/sbin/install
3407# SunOS /usr/etc/install
3408# IRIX /sbin/install
3409# AIX /bin/install
Martin v. Löwis11437992002-04-12 09:54:03 +00003410# AmigaOS /C/install, which installs bootblocks on floppy discs
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003411# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3412# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3413# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3414# ./install, which can be erroneously created by make from ./install.sh.
Martin v. Löwis11437992002-04-12 09:54:03 +00003415echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3416echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003417if test -z "$INSTALL"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003418if test "${ac_cv_path_install+set}" = set; then
3419 echo $ECHO_N "(cached) $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003420else
Martin v. Löwis11437992002-04-12 09:54:03 +00003421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3422for as_dir in $PATH
3423do
3424 IFS=$as_save_IFS
3425 test -z "$as_dir" && as_dir=.
3426 # Account for people who put trailing slashes in PATH elements.
3427case $as_dir/ in
3428 ./ | .// | /cC/* | \
3429 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3430 /usr/ucb/* ) ;;
3431 *)
3432 # OSF1 and SCO ODT 3.0 have their own names for install.
3433 # Don't use installbsd from OSF since it installs stuff as root
3434 # by default.
3435 for ac_prog in ginstall scoinst install; do
3436 for ac_exec_ext in '' $ac_executable_extensions; do
3437 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3438 if test $ac_prog = install &&
3439 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3440 # AIX install. It has an incompatible calling convention.
3441 :
3442 elif test $ac_prog = install &&
3443 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3444 # program-specific install script used by HP pwplus--don't use.
3445 :
3446 else
3447 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3448 break 3
3449 fi
3450 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003451 done
Martin v. Löwis11437992002-04-12 09:54:03 +00003452 done
3453 ;;
3454esac
3455done
3456
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003457
3458fi
3459 if test "${ac_cv_path_install+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003460 INSTALL=$ac_cv_path_install
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003461 else
3462 # As a last resort, use the slow shell script. We don't cache a
3463 # path for INSTALL within a source directory, because that will
3464 # break other packages using the cache if that directory is
3465 # removed, or if the path is relative.
Martin v. Löwis11437992002-04-12 09:54:03 +00003466 INSTALL=$ac_install_sh
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003467 fi
3468fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003469echo "$as_me:$LINENO: result: $INSTALL" >&5
3470echo "${ECHO_T}$INSTALL" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003471
3472# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3473# It thinks the first close brace ends the variable substitution.
3474test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3475
Martin v. Löwis11437992002-04-12 09:54:03 +00003476test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003477
3478test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3479
Michael W. Hudson54241132001-12-07 15:38:26 +00003480
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003481# Not every filesystem supports hard links
3482
3483if test -z "$LN" ; then
3484 case $ac_sys_system in
3485 BeOS*) LN="ln -s";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00003486 CYGWIN*) LN="ln -s";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003487 atheos*) LN="ln -s";;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003488 *) LN=ln;;
3489 esac
3490fi
3491
Fred Drake109d9862001-07-11 06:27:56 +00003492# Check for --with-pydebug
Martin v. Löwis11437992002-04-12 09:54:03 +00003493echo "$as_me:$LINENO: checking for --with-pydebug" >&5
3494echo $ECHO_N "checking for --with-pydebug... $ECHO_C" >&6
3495
Fred Drake109d9862001-07-11 06:27:56 +00003496# Check whether --with-pydebug or --without-pydebug was given.
3497if test "${with_pydebug+set}" = set; then
3498 withval="$with_pydebug"
Martin v. Löwis11437992002-04-12 09:54:03 +00003499
Fred Drake109d9862001-07-11 06:27:56 +00003500if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +00003501then
3502
3503cat >>confdefs.h <<\_ACEOF
Fred Drake109d9862001-07-11 06:27:56 +00003504#define Py_DEBUG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003505_ACEOF
3506
3507 echo "$as_me:$LINENO: result: yes" >&5
3508echo "${ECHO_T}yes" >&6;
Martin v. Löwisc45929e2002-04-06 10:10:49 +00003509 Py_DEBUG='true'
Martin v. Löwis11437992002-04-12 09:54:03 +00003510else echo "$as_me:$LINENO: result: no" >&5
3511echo "${ECHO_T}no" >&6; Py_DEBUG='false'
Fred Drake109d9862001-07-11 06:27:56 +00003512fi
3513else
Martin v. Löwis11437992002-04-12 09:54:03 +00003514 echo "$as_me:$LINENO: result: no" >&5
3515echo "${ECHO_T}no" >&6
3516fi;
Fred Drake109d9862001-07-11 06:27:56 +00003517
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003518# Optimizer/debugger flags
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003519
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003520if test -z "$OPT"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003521then
Neal Norwitzd957f392002-09-25 21:26:19 +00003522 case $GCC in
Guido van Rossumedca74a1997-07-18 23:29:40 +00003523 yes)
3524 case $ac_cv_prog_cc_g in
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003525 yes)
Fred Drake109d9862001-07-11 06:27:56 +00003526 if test "$Py_DEBUG" = 'true' ; then
3527 # Optimization messes up debuggers, so turn it off for
3528 # debug builds.
3529 OPT="-g -Wall -Wstrict-prototypes"
3530 else
3531 OPT="-g -O3 -Wall -Wstrict-prototypes"
3532 fi;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003533 *)
Fred Drake109d9862001-07-11 06:27:56 +00003534 OPT="-O3 -Wall -Wstrict-prototypes";;
3535 esac
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003536 case $ac_sys_system in
3537 SCO_SV*) OPT="$OPT -m486 -DSCO5";;
3538 esac
Fred Drake109d9862001-07-11 06:27:56 +00003539 ;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003540 *)
3541 case $ac_sys_system in
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00003542 OpenUNIX*|UnixWare*)
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003543 OPT="-O -K pentium,host,inline,loop_unroll,alloca ";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003544 SCO_SV*)
3545 CFLAGS="$CFLAGS -belf"
3546 OPT="-belf -O -Ki486 -DSCO5";;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003547 *)
3548 OPT="-O";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003549 esac
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003550 esac
Jack Jansenca06bc62001-08-03 15:32:23 +00003551 case $ac_sys_system in
3552 Darwin*)
Jack Jansen524a0982002-03-12 15:25:52 +00003553 OPT="$OPT -Wno-long-double -no-cpp-precomp";;
Jack Jansenca06bc62001-08-03 15:32:23 +00003554 esac
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003555fi
3556
Fred Drakee1ceaa02001-12-04 20:55:47 +00003557if test "$Py_DEBUG" = 'true'; then
3558 :
3559else
3560 OPT="-DNDEBUG $OPT"
3561fi
3562
Trent Mick635f6fb2000-08-23 21:33:05 +00003563# The current (beta) Monterey compiler dies with optimizations
3564case $ac_sys_system in
3565Monterey*) OPT="";;
3566esac
3567
Guido van Rossum563e7081996-09-10 18:20:48 +00003568if test "$ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +00003569then
3570 OPT="$OPT $ac_arch_flags"
3571fi
Guido van Rossumda88dad1995-01-26 00:46:29 +00003572
Martin v. Löwis11437992002-04-12 09:54:03 +00003573echo "$as_me:$LINENO: checking whether $CC accepts -OPT:Olimit=0" >&5
3574echo $ECHO_N "checking whether $CC accepts -OPT:Olimit=0... $ECHO_C" >&6
3575if test "${ac_cv_opt_olimit_ok+set}" = set; then
3576 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum91922671997-10-09 20:24:13 +00003577else
3578 ac_save_cc="$CC"
3579CC="$CC -OPT:Olimit=0"
3580if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00003581 ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00003582else
Martin v. Löwis11437992002-04-12 09:54:03 +00003583 cat >conftest.$ac_ext <<_ACEOF
3584#line $LINENO "configure"
Guido van Rossum91922671997-10-09 20:24:13 +00003585#include "confdefs.h"
3586int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003587_ACEOF
3588rm -f conftest$ac_exeext
3589if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3590 (eval $ac_link) 2>&5
3591 ac_status=$?
3592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3593 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3594 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3595 (eval $ac_try) 2>&5
3596 ac_status=$?
3597 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3598 (exit $ac_status); }; }; then
Guido van Rossum91922671997-10-09 20:24:13 +00003599 ac_cv_opt_olimit_ok=yes
3600else
Martin v. Löwis11437992002-04-12 09:54:03 +00003601 echo "$as_me: program exited with status $ac_status" >&5
3602echo "$as_me: failed program was:" >&5
3603cat conftest.$ac_ext >&5
3604( exit $ac_status )
3605ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00003606fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003607rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum91922671997-10-09 20:24:13 +00003608fi
Guido van Rossum91922671997-10-09 20:24:13 +00003609CC="$ac_save_cc"
3610fi
3611
Martin v. Löwis11437992002-04-12 09:54:03 +00003612echo "$as_me:$LINENO: result: $ac_cv_opt_olimit_ok" >&5
3613echo "${ECHO_T}$ac_cv_opt_olimit_ok" >&6
Guido van Rossum2efa34b1997-10-23 17:43:11 +00003614if test $ac_cv_opt_olimit_ok = yes; then
Guido van Rossum5839e582000-10-09 19:52:35 +00003615 case $ac_sys_system in
3616 Darwin*) OPT="$OPT" ;;
3617 *) OPT="$OPT -OPT:Olimit=0";;
3618 esac
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003619else
Martin v. Löwis11437992002-04-12 09:54:03 +00003620 echo "$as_me:$LINENO: checking whether $CC accepts -Olimit 1500" >&5
3621echo $ECHO_N "checking whether $CC accepts -Olimit 1500... $ECHO_C" >&6
3622 if test "${ac_cv_olimit_ok+set}" = set; then
3623 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003624else
3625 ac_save_cc="$CC"
3626 CC="$CC -Olimit 1500"
3627 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00003628 ac_cv_olimit_ok=no
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003629else
Martin v. Löwis11437992002-04-12 09:54:03 +00003630 cat >conftest.$ac_ext <<_ACEOF
3631#line $LINENO "configure"
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003632#include "confdefs.h"
3633int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003634_ACEOF
3635rm -f conftest$ac_exeext
3636if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3637 (eval $ac_link) 2>&5
3638 ac_status=$?
3639 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3640 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3641 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3642 (eval $ac_try) 2>&5
3643 ac_status=$?
3644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3645 (exit $ac_status); }; }; then
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003646 ac_cv_olimit_ok=yes
3647else
Martin v. Löwis11437992002-04-12 09:54:03 +00003648 echo "$as_me: program exited with status $ac_status" >&5
3649echo "$as_me: failed program was:" >&5
3650cat conftest.$ac_ext >&5
3651( exit $ac_status )
3652ac_cv_olimit_ok=no
Guido van Rossum201afe51997-05-14 21:14:44 +00003653fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003654rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003655fi
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003656 CC="$ac_save_cc"
3657fi
3658
Martin v. Löwis11437992002-04-12 09:54:03 +00003659 echo "$as_me:$LINENO: result: $ac_cv_olimit_ok" >&5
3660echo "${ECHO_T}$ac_cv_olimit_ok" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003661 if test $ac_cv_olimit_ok = yes; then
3662 OPT="$OPT -Olimit 1500"
3663 fi
3664fi
3665
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003666# On some compilers, pthreads are available without further options
3667# (e.g. MacOS X). On some of these systems, the compiler will not
3668# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
3669# So we have to see first whether pthreads are available without
3670# options before we can check whether -Kpthread improves anything.
Martin v. Löwis11437992002-04-12 09:54:03 +00003671echo "$as_me:$LINENO: checking whether pthreads are available without options" >&5
3672echo $ECHO_N "checking whether pthreads are available without options... $ECHO_C" >&6
3673if test "${ac_cv_pthread_is_default+set}" = set; then
3674 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis130fb172001-07-19 11:00:41 +00003675else
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003676 if test "$cross_compiling" = yes; then
3677 ac_cv_pthread_is_default=no
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003678else
Martin v. Löwis11437992002-04-12 09:54:03 +00003679 cat >conftest.$ac_ext <<_ACEOF
3680#line $LINENO "configure"
Martin v. Löwis130fb172001-07-19 11:00:41 +00003681#include "confdefs.h"
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003682
Martin v. Löwis130fb172001-07-19 11:00:41 +00003683#include <pthread.h>
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003684
3685void* routine(void* p){return NULL;}
3686
3687int main(){
3688 pthread_t p;
3689 if(pthread_create(&p,NULL,routine,NULL)!=0)
3690 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00003691 (void)pthread_detach(p);
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003692 return 0;
3693}
3694
Martin v. Löwis11437992002-04-12 09:54:03 +00003695_ACEOF
3696rm -f conftest$ac_exeext
3697if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3698 (eval $ac_link) 2>&5
3699 ac_status=$?
3700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3701 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3702 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3703 (eval $ac_try) 2>&5
3704 ac_status=$?
3705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3706 (exit $ac_status); }; }; then
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003707 ac_cv_pthread_is_default=yes
3708else
Martin v. Löwis11437992002-04-12 09:54:03 +00003709 echo "$as_me: program exited with status $ac_status" >&5
3710echo "$as_me: failed program was:" >&5
3711cat conftest.$ac_ext >&5
3712( exit $ac_status )
3713ac_cv_pthread_is_default=no
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003714fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003715rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003716fi
3717
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003718fi
3719
Martin v. Löwis11437992002-04-12 09:54:03 +00003720echo "$as_me:$LINENO: result: $ac_cv_pthread_is_default" >&5
3721echo "${ECHO_T}$ac_cv_pthread_is_default" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003722
Michael W. Hudson54241132001-12-07 15:38:26 +00003723
Martin v. Löwis11437992002-04-12 09:54:03 +00003724if test $ac_cv_pthread_is_default = yes
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003725then
3726 ac_cv_kpthread=no
3727else
3728# -Kpthread, if available, provides the right #defines
3729# and linker options to make pthread_create available
3730# Some compilers won't report that they do not support -Kpthread,
3731# so we need to run a program to see whether it really made the
3732# function available.
Martin v. Löwis11437992002-04-12 09:54:03 +00003733echo "$as_me:$LINENO: checking whether $CC accepts -Kpthread" >&5
3734echo $ECHO_N "checking whether $CC accepts -Kpthread... $ECHO_C" >&6
3735if test "${ac_cv_kpthread+set}" = set; then
3736 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003737else
3738 ac_save_cc="$CC"
3739CC="$CC -Kpthread"
3740if test "$cross_compiling" = yes; then
3741 ac_cv_kpthread=no
3742else
Martin v. Löwis11437992002-04-12 09:54:03 +00003743 cat >conftest.$ac_ext <<_ACEOF
3744#line $LINENO "configure"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003745#include "confdefs.h"
3746
3747#include <pthread.h>
3748
3749void* routine(void* p){return NULL;}
3750
3751int main(){
3752 pthread_t p;
3753 if(pthread_create(&p,NULL,routine,NULL)!=0)
3754 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00003755 (void)pthread_detach(p);
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003756 return 0;
3757}
3758
Martin v. Löwis11437992002-04-12 09:54:03 +00003759_ACEOF
3760rm -f conftest$ac_exeext
3761if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3762 (eval $ac_link) 2>&5
3763 ac_status=$?
3764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3765 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3766 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3767 (eval $ac_try) 2>&5
3768 ac_status=$?
3769 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3770 (exit $ac_status); }; }; then
Martin v. Löwis130fb172001-07-19 11:00:41 +00003771 ac_cv_kpthread=yes
3772else
Martin v. Löwis11437992002-04-12 09:54:03 +00003773 echo "$as_me: program exited with status $ac_status" >&5
3774echo "$as_me: failed program was:" >&5
3775cat conftest.$ac_ext >&5
3776( exit $ac_status )
3777ac_cv_kpthread=no
Martin v. Löwis130fb172001-07-19 11:00:41 +00003778fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003779rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003780fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00003781CC="$ac_save_cc"
3782fi
3783
Martin v. Löwis11437992002-04-12 09:54:03 +00003784echo "$as_me:$LINENO: result: $ac_cv_kpthread" >&5
3785echo "${ECHO_T}$ac_cv_kpthread" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003786fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00003787
Michael W. Hudson54241132001-12-07 15:38:26 +00003788
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003789# checks for header files
Martin v. Löwis11437992002-04-12 09:54:03 +00003790echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3791echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
3792if test "${ac_cv_header_stdc+set}" = set; then
3793 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003794else
Martin v. Löwis11437992002-04-12 09:54:03 +00003795 cat >conftest.$ac_ext <<_ACEOF
3796#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003797#include "confdefs.h"
3798#include <stdlib.h>
3799#include <stdarg.h>
3800#include <string.h>
3801#include <float.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003802
3803_ACEOF
3804if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3805 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3806 ac_status=$?
3807 egrep -v '^ *\+' conftest.er1 >conftest.err
3808 rm -f conftest.er1
3809 cat conftest.err >&5
3810 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3811 (exit $ac_status); } >/dev/null; then
3812 if test -s conftest.err; then
3813 ac_cpp_err=$ac_c_preproc_warn_flag
3814 else
3815 ac_cpp_err=
3816 fi
3817else
3818 ac_cpp_err=yes
3819fi
3820if test -z "$ac_cpp_err"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003821 ac_cv_header_stdc=yes
3822else
Martin v. Löwis11437992002-04-12 09:54:03 +00003823 echo "$as_me: failed program was:" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00003824 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003825 ac_cv_header_stdc=no
3826fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003827rm -f conftest.err conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003828
3829if test $ac_cv_header_stdc = yes; then
3830 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00003831 cat >conftest.$ac_ext <<_ACEOF
3832#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003833#include "confdefs.h"
3834#include <string.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003835
3836_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003837if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3838 egrep "memchr" >/dev/null 2>&1; then
3839 :
3840else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003841 ac_cv_header_stdc=no
3842fi
3843rm -f conftest*
3844
3845fi
3846
3847if test $ac_cv_header_stdc = yes; then
3848 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00003849 cat >conftest.$ac_ext <<_ACEOF
3850#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003851#include "confdefs.h"
3852#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003853
3854_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003855if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3856 egrep "free" >/dev/null 2>&1; then
3857 :
3858else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003859 ac_cv_header_stdc=no
3860fi
3861rm -f conftest*
3862
3863fi
3864
3865if test $ac_cv_header_stdc = yes; then
3866 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
Martin v. Löwis11437992002-04-12 09:54:03 +00003867 if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003868 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003869else
Martin v. Löwis11437992002-04-12 09:54:03 +00003870 cat >conftest.$ac_ext <<_ACEOF
3871#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003872#include "confdefs.h"
3873#include <ctype.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003874#if ((' ' & 0x0FF) == 0x020)
3875# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3876# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3877#else
3878# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
3879 || ('j' <= (c) && (c) <= 'r') \
3880 || ('s' <= (c) && (c) <= 'z'))
3881# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3882#endif
Michael W. Hudson54241132001-12-07 15:38:26 +00003883
Martin v. Löwis11437992002-04-12 09:54:03 +00003884#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3885int
3886main ()
3887{
3888 int i;
3889 for (i = 0; i < 256; i++)
3890 if (XOR (islower (i), ISLOWER (i))
3891 || toupper (i) != TOUPPER (i))
3892 exit(2);
3893 exit (0);
3894}
3895_ACEOF
3896rm -f conftest$ac_exeext
3897if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3898 (eval $ac_link) 2>&5
3899 ac_status=$?
3900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3901 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3902 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3903 (eval $ac_try) 2>&5
3904 ac_status=$?
3905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3906 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003907 :
3908else
Martin v. Löwis11437992002-04-12 09:54:03 +00003909 echo "$as_me: program exited with status $ac_status" >&5
3910echo "$as_me: failed program was:" >&5
3911cat conftest.$ac_ext >&5
3912( exit $ac_status )
3913ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00003914fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003915rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00003916fi
3917fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003918fi
3919echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3920echo "${ECHO_T}$ac_cv_header_stdc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00003921if test $ac_cv_header_stdc = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003922
3923cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003924#define STDC_HEADERS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003925_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00003926
3927fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003928
Martin v. Löwis11437992002-04-12 09:54:03 +00003929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
Martin v. Löwis11437992002-04-12 09:54:03 +00003966for ac_header in dlfcn.h fcntl.h grp.h limits.h langinfo.h \
Martin v. Löwis2e64c342002-03-27 18:49:02 +00003967libintl.h locale.h ncurses.h poll.h pthread.h \
Eric S. Raymondd2d75d32001-01-16 15:26:34 +00003968signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h termios.h \
Skip Montanaro57454e52002-06-14 20:30:31 +00003969sys/audioio.h sys/file.h sys/lock.h sys/mkdev.h sys/modem.h \
Andrew M. Kuchling881fd902001-07-14 20:55:52 +00003970sys/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 +00003971sys/un.h sys/utsname.h sys/wait.h pty.h term.h libutil.h \
Skip Montanaro8345f712002-06-25 05:53:48 +00003972sys/resource.h netpacket/packet.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00003973do
Martin v. Löwis11437992002-04-12 09:54:03 +00003974as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3975if eval "test \"\${$as_ac_Header+set}\" = set"; then
3976 echo "$as_me:$LINENO: checking for $ac_header" >&5
3977echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3978if eval "test \"\${$as_ac_Header+set}\" = set"; then
3979 echo $ECHO_N "(cached) $ECHO_C" >&6
3980fi
3981echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3982echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003983else
Martin v. Löwis11437992002-04-12 09:54:03 +00003984 # Is the header compilable?
3985echo "$as_me:$LINENO: checking $ac_header usability" >&5
3986echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
3987cat >conftest.$ac_ext <<_ACEOF
3988#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003989#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00003990$ac_includes_default
3991#include <$ac_header>
3992_ACEOF
3993rm -f conftest.$ac_objext
3994if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3995 (eval $ac_compile) 2>&5
3996 ac_status=$?
3997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3998 (exit $ac_status); } &&
3999 { ac_try='test -s conftest.$ac_objext'
4000 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4001 (eval $ac_try) 2>&5
4002 ac_status=$?
4003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4004 (exit $ac_status); }; }; then
4005 ac_header_compiler=yes
Michael W. Hudson54241132001-12-07 15:38:26 +00004006else
Martin v. Löwis11437992002-04-12 09:54:03 +00004007 echo "$as_me: failed program was:" >&5
4008cat conftest.$ac_ext >&5
4009ac_header_compiler=no
4010fi
4011rm -f conftest.$ac_objext conftest.$ac_ext
4012echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4013echo "${ECHO_T}$ac_header_compiler" >&6
4014
4015# Is the header present?
4016echo "$as_me:$LINENO: checking $ac_header presence" >&5
4017echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
4018cat >conftest.$ac_ext <<_ACEOF
4019#line $LINENO "configure"
4020#include "confdefs.h"
4021#include <$ac_header>
4022_ACEOF
4023if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4024 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4025 ac_status=$?
4026 egrep -v '^ *\+' conftest.er1 >conftest.err
4027 rm -f conftest.er1
4028 cat conftest.err >&5
4029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4030 (exit $ac_status); } >/dev/null; then
4031 if test -s conftest.err; then
4032 ac_cpp_err=$ac_c_preproc_warn_flag
4033 else
4034 ac_cpp_err=
4035 fi
4036else
4037 ac_cpp_err=yes
4038fi
4039if test -z "$ac_cpp_err"; then
4040 ac_header_preproc=yes
4041else
4042 echo "$as_me: failed program was:" >&5
Michael W. Hudson54241132001-12-07 15:38:26 +00004043 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004044 ac_header_preproc=no
Michael W. Hudson54241132001-12-07 15:38:26 +00004045fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004046rm -f conftest.err conftest.$ac_ext
4047echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4048echo "${ECHO_T}$ac_header_preproc" >&6
4049
4050# So? What about this header?
4051case $ac_header_compiler:$ac_header_preproc in
4052 yes:no )
4053 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4054echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4055 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4056echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
4057 no:yes )
4058 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4059echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4060 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
4061echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
4062 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4063echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
4064esac
4065echo "$as_me:$LINENO: checking for $ac_header" >&5
4066echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4067if eval "test \"\${$as_ac_Header+set}\" = set"; then
4068 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00004069else
Martin v. Löwis11437992002-04-12 09:54:03 +00004070 eval "$as_ac_Header=$ac_header_preproc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004071fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004072echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4073echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4074
4075fi
4076if test `eval echo '${'$as_ac_Header'}'` = yes; then
4077 cat >>confdefs.h <<_ACEOF
4078#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4079_ACEOF
4080
4081fi
4082
Guido van Rossum627b2d71993-12-24 10:39:16 +00004083done
4084
Martin v. Löwis11437992002-04-12 09:54:03 +00004085
4086
4087
4088
4089
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004090ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004091for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
4092 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
4093echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
4094echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
4095if eval "test \"\${$as_ac_Header+set}\" = set"; then
4096 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00004097else
Martin v. Löwis11437992002-04-12 09:54:03 +00004098 cat >conftest.$ac_ext <<_ACEOF
4099#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004100#include "confdefs.h"
4101#include <sys/types.h>
4102#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00004103
4104#ifdef F77_DUMMY_MAIN
4105# ifdef __cplusplus
4106 extern "C"
4107# endif
4108 int F77_DUMMY_MAIN() { return 1; }
4109#endif
4110int
4111main ()
4112{
4113if ((DIR *) 0)
4114return 0;
4115 ;
4116 return 0;
4117}
4118_ACEOF
4119rm -f conftest.$ac_objext
4120if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4121 (eval $ac_compile) 2>&5
4122 ac_status=$?
4123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4124 (exit $ac_status); } &&
4125 { ac_try='test -s conftest.$ac_objext'
4126 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4127 (eval $ac_try) 2>&5
4128 ac_status=$?
4129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4130 (exit $ac_status); }; }; then
4131 eval "$as_ac_Header=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +00004132else
Martin v. Löwis11437992002-04-12 09:54:03 +00004133 echo "$as_me: failed program was:" >&5
4134cat conftest.$ac_ext >&5
4135eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004136fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004137rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004138fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004139echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4140echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4141if test `eval echo '${'$as_ac_Header'}'` = yes; then
4142 cat >>confdefs.h <<_ACEOF
4143#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
4144_ACEOF
4145
4146ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00004147fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004148
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004149done
4150# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4151if test $ac_header_dirent = dirent.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004152 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4153echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4154if test "${ac_cv_search_opendir+set}" = set; then
4155 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004156else
Martin v. Löwis11437992002-04-12 09:54:03 +00004157 ac_func_search_save_LIBS=$LIBS
4158ac_cv_search_opendir=no
4159cat >conftest.$ac_ext <<_ACEOF
4160#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004161#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004162
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004163/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004164#ifdef __cplusplus
4165extern "C"
4166#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004167/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004168 builtin and then its argument prototype would still apply. */
4169char opendir ();
4170#ifdef F77_DUMMY_MAIN
4171# ifdef __cplusplus
4172 extern "C"
4173# endif
4174 int F77_DUMMY_MAIN() { return 1; }
4175#endif
4176int
4177main ()
4178{
4179opendir ();
4180 ;
4181 return 0;
4182}
4183_ACEOF
4184rm -f conftest.$ac_objext 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); } &&
4190 { ac_try='test -s conftest$ac_exeext'
4191 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4192 (eval $ac_try) 2>&5
4193 ac_status=$?
4194 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4195 (exit $ac_status); }; }; then
4196 ac_cv_search_opendir="none required"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004197else
Martin v. Löwis11437992002-04-12 09:54:03 +00004198 echo "$as_me: failed program was:" >&5
4199cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004200fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004201rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4202if test "$ac_cv_search_opendir" = no; then
4203 for ac_lib in dir; do
4204 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4205 cat >conftest.$ac_ext <<_ACEOF
4206#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004207#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004208
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004209/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004210#ifdef __cplusplus
4211extern "C"
4212#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004213/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004214 builtin and then its argument prototype would still apply. */
4215char opendir ();
4216#ifdef F77_DUMMY_MAIN
4217# ifdef __cplusplus
4218 extern "C"
4219# endif
4220 int F77_DUMMY_MAIN() { return 1; }
4221#endif
4222int
4223main ()
4224{
4225opendir ();
4226 ;
4227 return 0;
4228}
4229_ACEOF
4230rm -f conftest.$ac_objext conftest$ac_exeext
4231if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4232 (eval $ac_link) 2>&5
4233 ac_status=$?
4234 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4235 (exit $ac_status); } &&
4236 { ac_try='test -s conftest$ac_exeext'
4237 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4238 (eval $ac_try) 2>&5
4239 ac_status=$?
4240 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4241 (exit $ac_status); }; }; then
4242 ac_cv_search_opendir="-l$ac_lib"
4243break
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004244else
Martin v. Löwis11437992002-04-12 09:54:03 +00004245 echo "$as_me: failed program was:" >&5
4246cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004247fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004248rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4249 done
4250fi
4251LIBS=$ac_func_search_save_LIBS
4252fi
4253echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4254echo "${ECHO_T}$ac_cv_search_opendir" >&6
4255if test "$ac_cv_search_opendir" != no; then
4256 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00004257
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004258fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004259
Michael W. Hudson54241132001-12-07 15:38:26 +00004260else
Martin v. Löwis11437992002-04-12 09:54:03 +00004261 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4262echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4263if test "${ac_cv_search_opendir+set}" = set; then
4264 echo $ECHO_N "(cached) $ECHO_C" >&6
4265else
4266 ac_func_search_save_LIBS=$LIBS
4267ac_cv_search_opendir=no
4268cat >conftest.$ac_ext <<_ACEOF
4269#line $LINENO "configure"
4270#include "confdefs.h"
4271
4272/* Override any gcc2 internal prototype to avoid an error. */
4273#ifdef __cplusplus
4274extern "C"
4275#endif
4276/* We use char because int might match the return type of a gcc2
4277 builtin and then its argument prototype would still apply. */
4278char opendir ();
4279#ifdef F77_DUMMY_MAIN
4280# ifdef __cplusplus
4281 extern "C"
4282# endif
4283 int F77_DUMMY_MAIN() { return 1; }
4284#endif
4285int
4286main ()
4287{
4288opendir ();
4289 ;
4290 return 0;
4291}
4292_ACEOF
4293rm -f conftest.$ac_objext conftest$ac_exeext
4294if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4295 (eval $ac_link) 2>&5
4296 ac_status=$?
4297 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4298 (exit $ac_status); } &&
4299 { ac_try='test -s conftest$ac_exeext'
4300 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4301 (eval $ac_try) 2>&5
4302 ac_status=$?
4303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4304 (exit $ac_status); }; }; then
4305 ac_cv_search_opendir="none required"
4306else
4307 echo "$as_me: failed program was:" >&5
4308cat conftest.$ac_ext >&5
4309fi
4310rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4311if test "$ac_cv_search_opendir" = no; then
4312 for ac_lib in x; do
4313 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4314 cat >conftest.$ac_ext <<_ACEOF
4315#line $LINENO "configure"
4316#include "confdefs.h"
4317
4318/* Override any gcc2 internal prototype to avoid an error. */
4319#ifdef __cplusplus
4320extern "C"
4321#endif
4322/* We use char because int might match the return type of a gcc2
4323 builtin and then its argument prototype would still apply. */
4324char opendir ();
4325#ifdef F77_DUMMY_MAIN
4326# ifdef __cplusplus
4327 extern "C"
4328# endif
4329 int F77_DUMMY_MAIN() { return 1; }
4330#endif
4331int
4332main ()
4333{
4334opendir ();
4335 ;
4336 return 0;
4337}
4338_ACEOF
4339rm -f conftest.$ac_objext conftest$ac_exeext
4340if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4341 (eval $ac_link) 2>&5
4342 ac_status=$?
4343 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4344 (exit $ac_status); } &&
4345 { ac_try='test -s conftest$ac_exeext'
4346 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4347 (eval $ac_try) 2>&5
4348 ac_status=$?
4349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4350 (exit $ac_status); }; }; then
4351 ac_cv_search_opendir="-l$ac_lib"
4352break
4353else
4354 echo "$as_me: failed program was:" >&5
4355cat conftest.$ac_ext >&5
4356fi
4357rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4358 done
4359fi
4360LIBS=$ac_func_search_save_LIBS
4361fi
4362echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4363echo "${ECHO_T}$ac_cv_search_opendir" >&6
4364if test "$ac_cv_search_opendir" != no; then
4365 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
4366
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004367fi
4368
4369fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00004370
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00004371echo "$as_me:$LINENO: checking whether sys/types.h defines makedev" >&5
4372echo $ECHO_N "checking whether sys/types.h defines makedev... $ECHO_C" >&6
4373if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then
4374 echo $ECHO_N "(cached) $ECHO_C" >&6
4375else
4376 cat >conftest.$ac_ext <<_ACEOF
4377#line $LINENO "configure"
4378#include "confdefs.h"
4379#include <sys/types.h>
4380#ifdef F77_DUMMY_MAIN
4381# ifdef __cplusplus
4382 extern "C"
4383# endif
4384 int F77_DUMMY_MAIN() { return 1; }
4385#endif
4386int
4387main ()
4388{
4389return makedev(0, 0);
4390 ;
4391 return 0;
4392}
4393_ACEOF
4394rm -f conftest.$ac_objext conftest$ac_exeext
4395if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4396 (eval $ac_link) 2>&5
4397 ac_status=$?
4398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4399 (exit $ac_status); } &&
4400 { ac_try='test -s conftest$ac_exeext'
4401 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4402 (eval $ac_try) 2>&5
4403 ac_status=$?
4404 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4405 (exit $ac_status); }; }; then
4406 ac_cv_header_sys_types_h_makedev=yes
4407else
4408 echo "$as_me: failed program was:" >&5
4409cat conftest.$ac_ext >&5
4410ac_cv_header_sys_types_h_makedev=no
4411fi
4412rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4413
4414fi
4415echo "$as_me:$LINENO: result: $ac_cv_header_sys_types_h_makedev" >&5
4416echo "${ECHO_T}$ac_cv_header_sys_types_h_makedev" >&6
4417
4418if test $ac_cv_header_sys_types_h_makedev = no; then
4419if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
4420 echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
4421echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6
4422if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
4423 echo $ECHO_N "(cached) $ECHO_C" >&6
4424fi
4425echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
4426echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6
4427else
4428 # Is the header compilable?
4429echo "$as_me:$LINENO: checking sys/mkdev.h usability" >&5
4430echo $ECHO_N "checking sys/mkdev.h usability... $ECHO_C" >&6
4431cat >conftest.$ac_ext <<_ACEOF
4432#line $LINENO "configure"
4433#include "confdefs.h"
4434$ac_includes_default
4435#include <sys/mkdev.h>
4436_ACEOF
4437rm -f conftest.$ac_objext
4438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4439 (eval $ac_compile) 2>&5
4440 ac_status=$?
4441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4442 (exit $ac_status); } &&
4443 { ac_try='test -s conftest.$ac_objext'
4444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4445 (eval $ac_try) 2>&5
4446 ac_status=$?
4447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4448 (exit $ac_status); }; }; then
4449 ac_header_compiler=yes
4450else
4451 echo "$as_me: failed program was:" >&5
4452cat conftest.$ac_ext >&5
4453ac_header_compiler=no
4454fi
4455rm -f conftest.$ac_objext conftest.$ac_ext
4456echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4457echo "${ECHO_T}$ac_header_compiler" >&6
4458
4459# Is the header present?
4460echo "$as_me:$LINENO: checking sys/mkdev.h presence" >&5
4461echo $ECHO_N "checking sys/mkdev.h presence... $ECHO_C" >&6
4462cat >conftest.$ac_ext <<_ACEOF
4463#line $LINENO "configure"
4464#include "confdefs.h"
4465#include <sys/mkdev.h>
4466_ACEOF
4467if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4468 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4469 ac_status=$?
4470 egrep -v '^ *\+' conftest.er1 >conftest.err
4471 rm -f conftest.er1
4472 cat conftest.err >&5
4473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4474 (exit $ac_status); } >/dev/null; then
4475 if test -s conftest.err; then
4476 ac_cpp_err=$ac_c_preproc_warn_flag
4477 else
4478 ac_cpp_err=
4479 fi
4480else
4481 ac_cpp_err=yes
4482fi
4483if test -z "$ac_cpp_err"; then
4484 ac_header_preproc=yes
4485else
4486 echo "$as_me: failed program was:" >&5
4487 cat conftest.$ac_ext >&5
4488 ac_header_preproc=no
4489fi
4490rm -f conftest.err conftest.$ac_ext
4491echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4492echo "${ECHO_T}$ac_header_preproc" >&6
4493
4494# So? What about this header?
4495case $ac_header_compiler:$ac_header_preproc in
4496 yes:no )
4497 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&5
4498echo "$as_me: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
4499 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
4500echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;};;
4501 no:yes )
4502 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: present but cannot be compiled" >&5
4503echo "$as_me: WARNING: sys/mkdev.h: present but cannot be compiled" >&2;}
4504 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&5
4505echo "$as_me: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&2;}
4506 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
4507echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;};;
4508esac
4509echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
4510echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6
4511if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
4512 echo $ECHO_N "(cached) $ECHO_C" >&6
4513else
4514 ac_cv_header_sys_mkdev_h=$ac_header_preproc
4515fi
4516echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
4517echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6
4518
4519fi
4520if test $ac_cv_header_sys_mkdev_h = yes; then
4521
4522cat >>confdefs.h <<\_ACEOF
4523#define MAJOR_IN_MKDEV 1
4524_ACEOF
4525
4526fi
4527
4528
4529
4530 if test $ac_cv_header_sys_mkdev_h = no; then
4531 if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
4532 echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
4533echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6
4534if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
4535 echo $ECHO_N "(cached) $ECHO_C" >&6
4536fi
4537echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
4538echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6
4539else
4540 # Is the header compilable?
4541echo "$as_me:$LINENO: checking sys/sysmacros.h usability" >&5
4542echo $ECHO_N "checking sys/sysmacros.h usability... $ECHO_C" >&6
4543cat >conftest.$ac_ext <<_ACEOF
4544#line $LINENO "configure"
4545#include "confdefs.h"
4546$ac_includes_default
4547#include <sys/sysmacros.h>
4548_ACEOF
4549rm -f conftest.$ac_objext
4550if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4551 (eval $ac_compile) 2>&5
4552 ac_status=$?
4553 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4554 (exit $ac_status); } &&
4555 { ac_try='test -s conftest.$ac_objext'
4556 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4557 (eval $ac_try) 2>&5
4558 ac_status=$?
4559 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4560 (exit $ac_status); }; }; then
4561 ac_header_compiler=yes
4562else
4563 echo "$as_me: failed program was:" >&5
4564cat conftest.$ac_ext >&5
4565ac_header_compiler=no
4566fi
4567rm -f conftest.$ac_objext conftest.$ac_ext
4568echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4569echo "${ECHO_T}$ac_header_compiler" >&6
4570
4571# Is the header present?
4572echo "$as_me:$LINENO: checking sys/sysmacros.h presence" >&5
4573echo $ECHO_N "checking sys/sysmacros.h presence... $ECHO_C" >&6
4574cat >conftest.$ac_ext <<_ACEOF
4575#line $LINENO "configure"
4576#include "confdefs.h"
4577#include <sys/sysmacros.h>
4578_ACEOF
4579if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4580 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4581 ac_status=$?
4582 egrep -v '^ *\+' conftest.er1 >conftest.err
4583 rm -f conftest.er1
4584 cat conftest.err >&5
4585 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4586 (exit $ac_status); } >/dev/null; then
4587 if test -s conftest.err; then
4588 ac_cpp_err=$ac_c_preproc_warn_flag
4589 else
4590 ac_cpp_err=
4591 fi
4592else
4593 ac_cpp_err=yes
4594fi
4595if test -z "$ac_cpp_err"; then
4596 ac_header_preproc=yes
4597else
4598 echo "$as_me: failed program was:" >&5
4599 cat conftest.$ac_ext >&5
4600 ac_header_preproc=no
4601fi
4602rm -f conftest.err conftest.$ac_ext
4603echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4604echo "${ECHO_T}$ac_header_preproc" >&6
4605
4606# So? What about this header?
4607case $ac_header_compiler:$ac_header_preproc in
4608 yes:no )
4609 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&5
4610echo "$as_me: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
4611 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
4612echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;};;
4613 no:yes )
4614 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: present but cannot be compiled" >&5
4615echo "$as_me: WARNING: sys/sysmacros.h: present but cannot be compiled" >&2;}
4616 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&5
4617echo "$as_me: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&2;}
4618 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
4619echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;};;
4620esac
4621echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
4622echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6
4623if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
4624 echo $ECHO_N "(cached) $ECHO_C" >&6
4625else
4626 ac_cv_header_sys_sysmacros_h=$ac_header_preproc
4627fi
4628echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
4629echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6
4630
4631fi
4632if test $ac_cv_header_sys_sysmacros_h = yes; then
4633
4634cat >>confdefs.h <<\_ACEOF
4635#define MAJOR_IN_SYSMACROS 1
4636_ACEOF
4637
4638fi
4639
4640
4641 fi
4642fi
4643
Michael W. Hudson54241132001-12-07 15:38:26 +00004644
Guido van Rossum627b2d71993-12-24 10:39:16 +00004645# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00004646was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004647echo "$as_me:$LINENO: checking for clock_t in time.h" >&5
4648echo $ECHO_N "checking for clock_t in time.h... $ECHO_C" >&6
4649cat >conftest.$ac_ext <<_ACEOF
4650#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004651#include "confdefs.h"
4652#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004653
4654_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004655if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4656 egrep "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00004657 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004658else
Martin v. Löwis11437992002-04-12 09:54:03 +00004659
4660
4661cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004662#define clock_t long
Martin v. Löwis11437992002-04-12 09:54:03 +00004663_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004664
Martin v. Löwisc45929e2002-04-06 10:10:49 +00004665
Guido van Rossum627b2d71993-12-24 10:39:16 +00004666fi
4667rm -f conftest*
4668
Martin v. Löwis11437992002-04-12 09:54:03 +00004669echo "$as_me:$LINENO: result: $was_it_defined" >&5
4670echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00004671
Neal Norwitz11690112002-07-30 01:08:28 +00004672# Check whether using makedev requires defining _OSF_SOURCE
4673echo "$as_me:$LINENO: checking for makedev" >&5
4674echo $ECHO_N "checking for makedev... $ECHO_C" >&6
4675cat >conftest.$ac_ext <<_ACEOF
4676#line $LINENO "configure"
4677#include "confdefs.h"
4678 #include <sys/types.h>
4679#ifdef F77_DUMMY_MAIN
4680# ifdef __cplusplus
4681 extern "C"
4682# endif
4683 int F77_DUMMY_MAIN() { return 1; }
4684#endif
4685int
4686main ()
4687{
4688 makedev(0, 0)
4689 ;
4690 return 0;
4691}
4692_ACEOF
4693rm -f conftest.$ac_objext conftest$ac_exeext
4694if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4695 (eval $ac_link) 2>&5
4696 ac_status=$?
4697 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4698 (exit $ac_status); } &&
4699 { ac_try='test -s conftest$ac_exeext'
4700 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4701 (eval $ac_try) 2>&5
4702 ac_status=$?
4703 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4704 (exit $ac_status); }; }; then
4705 ac_cv_has_makedev=yes
4706else
4707 echo "$as_me: failed program was:" >&5
4708cat conftest.$ac_ext >&5
4709ac_cv_has_makedev=no
4710fi
4711rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4712if test "$ac_cv_has_makedev" = "no"; then
4713 # we didn't link, try if _OSF_SOURCE will allow us to link
4714 cat >conftest.$ac_ext <<_ACEOF
4715#line $LINENO "configure"
4716#include "confdefs.h"
4717
4718 #define _OSF_SOURCE 1
4719 #include <sys/types.h>
4720
4721#ifdef F77_DUMMY_MAIN
4722# ifdef __cplusplus
4723 extern "C"
4724# endif
4725 int F77_DUMMY_MAIN() { return 1; }
4726#endif
4727int
4728main ()
4729{
4730 makedev(0, 0)
4731 ;
4732 return 0;
4733}
4734_ACEOF
4735rm -f conftest.$ac_objext conftest$ac_exeext
4736if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4737 (eval $ac_link) 2>&5
4738 ac_status=$?
4739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4740 (exit $ac_status); } &&
4741 { ac_try='test -s conftest$ac_exeext'
4742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4743 (eval $ac_try) 2>&5
4744 ac_status=$?
4745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4746 (exit $ac_status); }; }; then
4747 ac_cv_has_makedev=yes
4748else
4749 echo "$as_me: failed program was:" >&5
4750cat conftest.$ac_ext >&5
4751ac_cv_has_makedev=no
4752fi
4753rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4754 if test "$ac_cv_has_makedev" = "yes"; then
4755
4756cat >>confdefs.h <<\_ACEOF
4757#define _OSF_SOURCE 1
4758_ACEOF
4759
4760 fi
4761fi
4762echo "$as_me:$LINENO: result: $ac_cv_has_makedev" >&5
4763echo "${ECHO_T}$ac_cv_has_makedev" >&6
4764if test "$ac_cv_has_makedev" = "yes"; then
4765
4766cat >>confdefs.h <<\_ACEOF
4767#define HAVE_MAKEDEV 1
4768_ACEOF
4769
4770fi
4771
Martin v. Löwis399a6892002-10-04 10:22:02 +00004772# Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in
4773# the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are
4774# defined, but the compiler does not support pragma redefine_extname,
4775# and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit
4776# structures (such as rlimit64) without declaring them. As a
4777# work-around, disable LFS on such configurations
4778
4779use_lfs=yes
4780echo "$as_me:$LINENO: checking Solaris LFS bug" >&5
4781echo $ECHO_N "checking Solaris LFS bug... $ECHO_C" >&6
4782cat >conftest.$ac_ext <<_ACEOF
4783#line $LINENO "configure"
4784#include "confdefs.h"
4785
4786#define _LARGEFILE_SOURCE 1
4787#define _FILE_OFFSET_BITS 64
4788#include <sys/resource.h>
4789
4790#ifdef F77_DUMMY_MAIN
4791# ifdef __cplusplus
4792 extern "C"
4793# endif
4794 int F77_DUMMY_MAIN() { return 1; }
4795#endif
4796int
4797main ()
4798{
4799struct rlimit foo;
4800 ;
4801 return 0;
4802}
4803_ACEOF
4804rm -f conftest.$ac_objext
4805if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4806 (eval $ac_compile) 2>&5
4807 ac_status=$?
4808 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4809 (exit $ac_status); } &&
4810 { ac_try='test -s conftest.$ac_objext'
4811 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4812 (eval $ac_try) 2>&5
4813 ac_status=$?
4814 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4815 (exit $ac_status); }; }; then
4816 sol_lfs_bug=no
4817else
4818 echo "$as_me: failed program was:" >&5
4819cat conftest.$ac_ext >&5
4820sol_lfs_bug=yes
4821fi
4822rm -f conftest.$ac_objext conftest.$ac_ext
4823echo "$as_me:$LINENO: result: $sol_lfs_bug" >&5
4824echo "${ECHO_T}$sol_lfs_bug" >&6
4825if test "$sol_lfs_bug" = "yes"; then
4826 use_lfs=no
4827fi
4828
4829if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00004830# Two defines needed to enable largefile support on various platforms
4831# These may affect some typedefs
Guido van Rossum810cc512001-09-09 23:51:39 +00004832
Martin v. Löwis11437992002-04-12 09:54:03 +00004833cat >>confdefs.h <<\_ACEOF
4834#define _LARGEFILE_SOURCE 1
4835_ACEOF
4836
4837
4838cat >>confdefs.h <<\_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00004839#define _FILE_OFFSET_BITS 64
Martin v. Löwis11437992002-04-12 09:54:03 +00004840_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00004841
Martin v. Löwis399a6892002-10-04 10:22:02 +00004842fi
Michael W. Hudson54241132001-12-07 15:38:26 +00004843
Guido van Rossum84e7b241996-08-19 21:59:00 +00004844# Add some code to confdefs.h so that the test for off_t works on SCO
4845cat >> confdefs.h <<\EOF
4846#if defined(SCO_DS)
4847#undef _OFF_T
4848#endif
4849EOF
4850
Guido van Rossumef2255b2000-03-10 22:30:29 +00004851# Type availability checks
Martin v. Löwis11437992002-04-12 09:54:03 +00004852echo "$as_me:$LINENO: checking for mode_t" >&5
4853echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
4854if test "${ac_cv_type_mode_t+set}" = set; then
4855 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004856else
Martin v. Löwis11437992002-04-12 09:54:03 +00004857 cat >conftest.$ac_ext <<_ACEOF
4858#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004859#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004860$ac_includes_default
4861#ifdef F77_DUMMY_MAIN
4862# ifdef __cplusplus
4863 extern "C"
4864# endif
4865 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004866#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004867int
4868main ()
4869{
4870if ((mode_t *) 0)
4871 return 0;
4872if (sizeof (mode_t))
4873 return 0;
4874 ;
4875 return 0;
4876}
4877_ACEOF
4878rm -f conftest.$ac_objext
4879if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4880 (eval $ac_compile) 2>&5
4881 ac_status=$?
4882 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4883 (exit $ac_status); } &&
4884 { ac_try='test -s conftest.$ac_objext'
4885 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4886 (eval $ac_try) 2>&5
4887 ac_status=$?
4888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4889 (exit $ac_status); }; }; then
Jack Jansendd19cf82001-12-06 22:36:17 +00004890 ac_cv_type_mode_t=yes
4891else
Martin v. Löwis11437992002-04-12 09:54:03 +00004892 echo "$as_me: failed program was:" >&5
4893cat conftest.$ac_ext >&5
4894ac_cv_type_mode_t=no
Jack Jansendd19cf82001-12-06 22:36:17 +00004895fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004896rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004897fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004898echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
4899echo "${ECHO_T}$ac_cv_type_mode_t" >&6
4900if test $ac_cv_type_mode_t = yes; then
4901 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004902else
Martin v. Löwis11437992002-04-12 09:54:03 +00004903
4904cat >>confdefs.h <<_ACEOF
4905#define mode_t int
4906_ACEOF
4907
4908fi
4909
4910echo "$as_me:$LINENO: checking for off_t" >&5
4911echo $ECHO_N "checking for off_t... $ECHO_C" >&6
4912if test "${ac_cv_type_off_t+set}" = set; then
4913 echo $ECHO_N "(cached) $ECHO_C" >&6
4914else
4915 cat >conftest.$ac_ext <<_ACEOF
4916#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004917#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004918$ac_includes_default
4919#ifdef F77_DUMMY_MAIN
4920# ifdef __cplusplus
4921 extern "C"
4922# endif
4923 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004924#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004925int
4926main ()
4927{
4928if ((off_t *) 0)
4929 return 0;
4930if (sizeof (off_t))
4931 return 0;
4932 ;
4933 return 0;
4934}
4935_ACEOF
4936rm -f conftest.$ac_objext
4937if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4938 (eval $ac_compile) 2>&5
4939 ac_status=$?
4940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4941 (exit $ac_status); } &&
4942 { ac_try='test -s conftest.$ac_objext'
4943 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4944 (eval $ac_try) 2>&5
4945 ac_status=$?
4946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4947 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00004948 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004949else
Martin v. Löwis11437992002-04-12 09:54:03 +00004950 echo "$as_me: failed program was:" >&5
4951cat conftest.$ac_ext >&5
4952ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004953fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004954rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004955fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004956echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
4957echo "${ECHO_T}$ac_cv_type_off_t" >&6
4958if test $ac_cv_type_off_t = yes; then
4959 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004960else
Martin v. Löwis11437992002-04-12 09:54:03 +00004961
4962cat >>confdefs.h <<_ACEOF
4963#define off_t long
4964_ACEOF
4965
4966fi
4967
4968echo "$as_me:$LINENO: checking for pid_t" >&5
4969echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
4970if test "${ac_cv_type_pid_t+set}" = set; then
4971 echo $ECHO_N "(cached) $ECHO_C" >&6
4972else
4973 cat >conftest.$ac_ext <<_ACEOF
4974#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004975#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004976$ac_includes_default
4977#ifdef F77_DUMMY_MAIN
4978# ifdef __cplusplus
4979 extern "C"
4980# endif
4981 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004982#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004983int
4984main ()
4985{
4986if ((pid_t *) 0)
4987 return 0;
4988if (sizeof (pid_t))
4989 return 0;
4990 ;
4991 return 0;
4992}
4993_ACEOF
4994rm -f conftest.$ac_objext
4995if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4996 (eval $ac_compile) 2>&5
4997 ac_status=$?
4998 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4999 (exit $ac_status); } &&
5000 { ac_try='test -s conftest.$ac_objext'
5001 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5002 (eval $ac_try) 2>&5
5003 ac_status=$?
5004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5005 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00005006 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005007else
Martin v. Löwis11437992002-04-12 09:54:03 +00005008 echo "$as_me: failed program was:" >&5
5009cat conftest.$ac_ext >&5
5010ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00005011fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005012rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005013fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005014echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
5015echo "${ECHO_T}$ac_cv_type_pid_t" >&6
5016if test $ac_cv_type_pid_t = yes; then
5017 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005018else
Martin v. Löwis11437992002-04-12 09:54:03 +00005019
5020cat >>confdefs.h <<_ACEOF
5021#define pid_t int
5022_ACEOF
5023
5024fi
5025
5026echo "$as_me:$LINENO: checking return type of signal handlers" >&5
5027echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
5028if test "${ac_cv_type_signal+set}" = set; then
5029 echo $ECHO_N "(cached) $ECHO_C" >&6
5030else
5031 cat >conftest.$ac_ext <<_ACEOF
5032#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00005033#include "confdefs.h"
5034#include <sys/types.h>
5035#include <signal.h>
5036#ifdef signal
Martin v. Löwis11437992002-04-12 09:54:03 +00005037# undef signal
Guido van Rossum627b2d71993-12-24 10:39:16 +00005038#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00005039#ifdef __cplusplus
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005040extern "C" void (*signal (int, void (*)(int)))(int);
5041#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00005042void (*signal ()) ();
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005043#endif
5044
Martin v. Löwis11437992002-04-12 09:54:03 +00005045#ifdef F77_DUMMY_MAIN
5046# ifdef __cplusplus
5047 extern "C"
5048# endif
5049 int F77_DUMMY_MAIN() { return 1; }
5050#endif
5051int
5052main ()
5053{
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005054int i;
Martin v. Löwis11437992002-04-12 09:54:03 +00005055 ;
5056 return 0;
5057}
5058_ACEOF
5059rm -f conftest.$ac_objext
5060if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5061 (eval $ac_compile) 2>&5
5062 ac_status=$?
5063 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5064 (exit $ac_status); } &&
5065 { ac_try='test -s conftest.$ac_objext'
5066 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5067 (eval $ac_try) 2>&5
5068 ac_status=$?
5069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5070 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005071 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00005072else
Martin v. Löwis11437992002-04-12 09:54:03 +00005073 echo "$as_me: failed program was:" >&5
5074cat conftest.$ac_ext >&5
5075ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00005076fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005077rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005078fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005079echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
5080echo "${ECHO_T}$ac_cv_type_signal" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005081
Martin v. Löwis11437992002-04-12 09:54:03 +00005082cat >>confdefs.h <<_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005083#define RETSIGTYPE $ac_cv_type_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00005084_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00005085
Michael W. Hudson54241132001-12-07 15:38:26 +00005086
Martin v. Löwis11437992002-04-12 09:54:03 +00005087echo "$as_me:$LINENO: checking for size_t" >&5
5088echo $ECHO_N "checking for size_t... $ECHO_C" >&6
5089if test "${ac_cv_type_size_t+set}" = set; then
5090 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005091else
Martin v. Löwis11437992002-04-12 09:54:03 +00005092 cat >conftest.$ac_ext <<_ACEOF
5093#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005094#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005095$ac_includes_default
5096#ifdef F77_DUMMY_MAIN
5097# ifdef __cplusplus
5098 extern "C"
5099# endif
5100 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00005101#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00005102int
5103main ()
5104{
5105if ((size_t *) 0)
5106 return 0;
5107if (sizeof (size_t))
5108 return 0;
5109 ;
5110 return 0;
5111}
5112_ACEOF
5113rm -f conftest.$ac_objext
5114if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5115 (eval $ac_compile) 2>&5
5116 ac_status=$?
5117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5118 (exit $ac_status); } &&
5119 { ac_try='test -s conftest.$ac_objext'
5120 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5121 (eval $ac_try) 2>&5
5122 ac_status=$?
5123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5124 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00005125 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005126else
Martin v. Löwis11437992002-04-12 09:54:03 +00005127 echo "$as_me: failed program was:" >&5
5128cat conftest.$ac_ext >&5
5129ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00005130fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005131rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005132fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005133echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
5134echo "${ECHO_T}$ac_cv_type_size_t" >&6
5135if test $ac_cv_type_size_t = yes; then
5136 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005137else
Martin v. Löwis11437992002-04-12 09:54:03 +00005138
5139cat >>confdefs.h <<_ACEOF
5140#define size_t unsigned
5141_ACEOF
5142
5143fi
5144
5145echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
5146echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
5147if test "${ac_cv_type_uid_t+set}" = set; then
5148 echo $ECHO_N "(cached) $ECHO_C" >&6
5149else
5150 cat >conftest.$ac_ext <<_ACEOF
5151#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005152#include "confdefs.h"
5153#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005154
5155_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005156if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5157 egrep "uid_t" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005158 ac_cv_type_uid_t=yes
5159else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005160 ac_cv_type_uid_t=no
5161fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00005162rm -f conftest*
5163
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005164fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005165echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
5166echo "${ECHO_T}$ac_cv_type_uid_t" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00005167if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005168
Martin v. Löwis11437992002-04-12 09:54:03 +00005169cat >>confdefs.h <<\_ACEOF
5170#define uid_t int
5171_ACEOF
5172
5173
5174cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005175#define gid_t int
Martin v. Löwis11437992002-04-12 09:54:03 +00005176_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005177
5178fi
5179
Jack Jansendd19cf82001-12-06 22:36:17 +00005180
Michael W. Hudson54241132001-12-07 15:38:26 +00005181# Sizes of various common basic types
Martin v. Löwis11437992002-04-12 09:54:03 +00005182echo "$as_me:$LINENO: checking for int" >&5
5183echo $ECHO_N "checking for int... $ECHO_C" >&6
5184if test "${ac_cv_type_int+set}" = set; then
5185 echo $ECHO_N "(cached) $ECHO_C" >&6
5186else
5187 cat >conftest.$ac_ext <<_ACEOF
5188#line $LINENO "configure"
5189#include "confdefs.h"
5190$ac_includes_default
5191#ifdef F77_DUMMY_MAIN
5192# ifdef __cplusplus
5193 extern "C"
5194# endif
5195 int F77_DUMMY_MAIN() { return 1; }
5196#endif
5197int
5198main ()
5199{
5200if ((int *) 0)
5201 return 0;
5202if (sizeof (int))
5203 return 0;
5204 ;
5205 return 0;
5206}
5207_ACEOF
5208rm -f conftest.$ac_objext
5209if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5210 (eval $ac_compile) 2>&5
5211 ac_status=$?
5212 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5213 (exit $ac_status); } &&
5214 { ac_try='test -s conftest.$ac_objext'
5215 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5216 (eval $ac_try) 2>&5
5217 ac_status=$?
5218 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5219 (exit $ac_status); }; }; then
5220 ac_cv_type_int=yes
5221else
5222 echo "$as_me: failed program was:" >&5
5223cat conftest.$ac_ext >&5
5224ac_cv_type_int=no
5225fi
5226rm -f conftest.$ac_objext conftest.$ac_ext
5227fi
5228echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
5229echo "${ECHO_T}$ac_cv_type_int" >&6
5230
5231echo "$as_me:$LINENO: checking size of int" >&5
5232echo $ECHO_N "checking size of int... $ECHO_C" >&6
5233if test "${ac_cv_sizeof_int+set}" = set; then
5234 echo $ECHO_N "(cached) $ECHO_C" >&6
5235else
5236 if test "$ac_cv_type_int" = yes; then
5237 # The cast to unsigned long works around a bug in the HP C Compiler
5238 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5239 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5240 # This bug is HP SR number 8606223364.
5241 if test "$cross_compiling" = yes; then
5242 # Depending upon the size, compute the lo and hi bounds.
5243cat >conftest.$ac_ext <<_ACEOF
5244#line $LINENO "configure"
5245#include "confdefs.h"
5246$ac_includes_default
5247#ifdef F77_DUMMY_MAIN
5248# ifdef __cplusplus
5249 extern "C"
5250# endif
5251 int F77_DUMMY_MAIN() { return 1; }
5252#endif
5253int
5254main ()
5255{
5256static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
5257test_array [0] = 0
5258
5259 ;
5260 return 0;
5261}
5262_ACEOF
5263rm -f conftest.$ac_objext
5264if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5265 (eval $ac_compile) 2>&5
5266 ac_status=$?
5267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5268 (exit $ac_status); } &&
5269 { ac_try='test -s conftest.$ac_objext'
5270 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5271 (eval $ac_try) 2>&5
5272 ac_status=$?
5273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5274 (exit $ac_status); }; }; then
5275 ac_lo=0 ac_mid=0
5276 while :; do
5277 cat >conftest.$ac_ext <<_ACEOF
5278#line $LINENO "configure"
5279#include "confdefs.h"
5280$ac_includes_default
5281#ifdef F77_DUMMY_MAIN
5282# ifdef __cplusplus
5283 extern "C"
5284# endif
5285 int F77_DUMMY_MAIN() { return 1; }
5286#endif
5287int
5288main ()
5289{
5290static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
5291test_array [0] = 0
5292
5293 ;
5294 return 0;
5295}
5296_ACEOF
5297rm -f conftest.$ac_objext
5298if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5299 (eval $ac_compile) 2>&5
5300 ac_status=$?
5301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5302 (exit $ac_status); } &&
5303 { ac_try='test -s conftest.$ac_objext'
5304 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5305 (eval $ac_try) 2>&5
5306 ac_status=$?
5307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5308 (exit $ac_status); }; }; then
5309 ac_hi=$ac_mid; break
5310else
5311 echo "$as_me: failed program was:" >&5
5312cat conftest.$ac_ext >&5
5313ac_lo=`expr $ac_mid + 1`
5314 if test $ac_lo -le $ac_mid; then
5315 ac_lo= ac_hi=
5316 break
5317 fi
5318 ac_mid=`expr 2 '*' $ac_mid + 1`
5319fi
5320rm -f conftest.$ac_objext conftest.$ac_ext
5321 done
5322else
5323 echo "$as_me: failed program was:" >&5
5324cat conftest.$ac_ext >&5
5325cat >conftest.$ac_ext <<_ACEOF
5326#line $LINENO "configure"
5327#include "confdefs.h"
5328$ac_includes_default
5329#ifdef F77_DUMMY_MAIN
5330# ifdef __cplusplus
5331 extern "C"
5332# endif
5333 int F77_DUMMY_MAIN() { return 1; }
5334#endif
5335int
5336main ()
5337{
5338static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
5339test_array [0] = 0
5340
5341 ;
5342 return 0;
5343}
5344_ACEOF
5345rm -f conftest.$ac_objext
5346if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5347 (eval $ac_compile) 2>&5
5348 ac_status=$?
5349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5350 (exit $ac_status); } &&
5351 { ac_try='test -s conftest.$ac_objext'
5352 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5353 (eval $ac_try) 2>&5
5354 ac_status=$?
5355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5356 (exit $ac_status); }; }; then
5357 ac_hi=-1 ac_mid=-1
5358 while :; do
5359 cat >conftest.$ac_ext <<_ACEOF
5360#line $LINENO "configure"
5361#include "confdefs.h"
5362$ac_includes_default
5363#ifdef F77_DUMMY_MAIN
5364# ifdef __cplusplus
5365 extern "C"
5366# endif
5367 int F77_DUMMY_MAIN() { return 1; }
5368#endif
5369int
5370main ()
5371{
5372static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
5373test_array [0] = 0
5374
5375 ;
5376 return 0;
5377}
5378_ACEOF
5379rm -f conftest.$ac_objext
5380if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5381 (eval $ac_compile) 2>&5
5382 ac_status=$?
5383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5384 (exit $ac_status); } &&
5385 { ac_try='test -s conftest.$ac_objext'
5386 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5387 (eval $ac_try) 2>&5
5388 ac_status=$?
5389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5390 (exit $ac_status); }; }; then
5391 ac_lo=$ac_mid; break
5392else
5393 echo "$as_me: failed program was:" >&5
5394cat conftest.$ac_ext >&5
5395ac_hi=`expr '(' $ac_mid ')' - 1`
5396 if test $ac_mid -le $ac_hi; then
5397 ac_lo= ac_hi=
5398 break
5399 fi
5400 ac_mid=`expr 2 '*' $ac_mid`
5401fi
5402rm -f conftest.$ac_objext conftest.$ac_ext
5403 done
5404else
5405 echo "$as_me: failed program was:" >&5
5406cat conftest.$ac_ext >&5
5407ac_lo= ac_hi=
5408fi
5409rm -f conftest.$ac_objext conftest.$ac_ext
5410fi
5411rm -f conftest.$ac_objext conftest.$ac_ext
5412# Binary search between lo and hi bounds.
5413while test "x$ac_lo" != "x$ac_hi"; do
5414 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5415 cat >conftest.$ac_ext <<_ACEOF
5416#line $LINENO "configure"
5417#include "confdefs.h"
5418$ac_includes_default
5419#ifdef F77_DUMMY_MAIN
5420# ifdef __cplusplus
5421 extern "C"
5422# endif
5423 int F77_DUMMY_MAIN() { return 1; }
5424#endif
5425int
5426main ()
5427{
5428static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
5429test_array [0] = 0
5430
5431 ;
5432 return 0;
5433}
5434_ACEOF
5435rm -f conftest.$ac_objext
5436if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5437 (eval $ac_compile) 2>&5
5438 ac_status=$?
5439 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5440 (exit $ac_status); } &&
5441 { ac_try='test -s conftest.$ac_objext'
5442 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5443 (eval $ac_try) 2>&5
5444 ac_status=$?
5445 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5446 (exit $ac_status); }; }; then
5447 ac_hi=$ac_mid
5448else
5449 echo "$as_me: failed program was:" >&5
5450cat conftest.$ac_ext >&5
5451ac_lo=`expr '(' $ac_mid ')' + 1`
5452fi
5453rm -f conftest.$ac_objext conftest.$ac_ext
5454done
5455case $ac_lo in
5456?*) ac_cv_sizeof_int=$ac_lo;;
5457'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77" >&5
5458echo "$as_me: error: cannot compute sizeof (int), 77" >&2;}
5459 { (exit 1); exit 1; }; } ;;
5460esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005461else
5462 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005463 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5464echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5465 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005466else
Martin v. Löwis11437992002-04-12 09:54:03 +00005467 cat >conftest.$ac_ext <<_ACEOF
5468#line $LINENO "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005469#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005470$ac_includes_default
5471long longval () { return (long) (sizeof (int)); }
5472unsigned long ulongval () { return (long) (sizeof (int)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005473#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005474#include <stdlib.h>
5475#ifdef F77_DUMMY_MAIN
5476# ifdef __cplusplus
5477 extern "C"
5478# endif
5479 int F77_DUMMY_MAIN() { return 1; }
5480#endif
5481int
5482main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005483{
Martin v. Löwis11437992002-04-12 09:54:03 +00005484
5485 FILE *f = fopen ("conftest.val", "w");
5486 if (! f)
5487 exit (1);
5488 if (((long) (sizeof (int))) < 0)
5489 {
5490 long i = longval ();
5491 if (i != ((long) (sizeof (int))))
5492 exit (1);
5493 fprintf (f, "%ld\n", i);
5494 }
5495 else
5496 {
5497 unsigned long i = ulongval ();
5498 if (i != ((long) (sizeof (int))))
5499 exit (1);
5500 fprintf (f, "%lu\n", i);
5501 }
5502 exit (ferror (f) || fclose (f) != 0);
5503
5504 ;
5505 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005506}
Martin v. Löwis11437992002-04-12 09:54:03 +00005507_ACEOF
5508rm -f conftest$ac_exeext
5509if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5510 (eval $ac_link) 2>&5
5511 ac_status=$?
5512 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5513 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5514 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5515 (eval $ac_try) 2>&5
5516 ac_status=$?
5517 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5518 (exit $ac_status); }; }; then
5519 ac_cv_sizeof_int=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005520else
Martin v. Löwis11437992002-04-12 09:54:03 +00005521 echo "$as_me: program exited with status $ac_status" >&5
5522echo "$as_me: failed program was:" >&5
5523cat conftest.$ac_ext >&5
5524( exit $ac_status )
5525{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77" >&5
5526echo "$as_me: error: cannot compute sizeof (int), 77" >&2;}
5527 { (exit 1); exit 1; }; }
5528fi
5529rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5530fi
5531fi
5532rm -f conftest.val
5533else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005534 ac_cv_sizeof_int=0
5535fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005536fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005537echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
5538echo "${ECHO_T}$ac_cv_sizeof_int" >&6
5539cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005540#define SIZEOF_INT $ac_cv_sizeof_int
Martin v. Löwis11437992002-04-12 09:54:03 +00005541_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005542
5543
Martin v. Löwis11437992002-04-12 09:54:03 +00005544echo "$as_me:$LINENO: checking for long" >&5
5545echo $ECHO_N "checking for long... $ECHO_C" >&6
5546if test "${ac_cv_type_long+set}" = set; then
5547 echo $ECHO_N "(cached) $ECHO_C" >&6
5548else
5549 cat >conftest.$ac_ext <<_ACEOF
5550#line $LINENO "configure"
5551#include "confdefs.h"
5552$ac_includes_default
5553#ifdef F77_DUMMY_MAIN
5554# ifdef __cplusplus
5555 extern "C"
5556# endif
5557 int F77_DUMMY_MAIN() { return 1; }
5558#endif
5559int
5560main ()
5561{
5562if ((long *) 0)
5563 return 0;
5564if (sizeof (long))
5565 return 0;
5566 ;
5567 return 0;
5568}
5569_ACEOF
5570rm -f conftest.$ac_objext
5571if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5572 (eval $ac_compile) 2>&5
5573 ac_status=$?
5574 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5575 (exit $ac_status); } &&
5576 { ac_try='test -s conftest.$ac_objext'
5577 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5578 (eval $ac_try) 2>&5
5579 ac_status=$?
5580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5581 (exit $ac_status); }; }; then
5582 ac_cv_type_long=yes
5583else
5584 echo "$as_me: failed program was:" >&5
5585cat conftest.$ac_ext >&5
5586ac_cv_type_long=no
5587fi
5588rm -f conftest.$ac_objext conftest.$ac_ext
5589fi
5590echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
5591echo "${ECHO_T}$ac_cv_type_long" >&6
5592
5593echo "$as_me:$LINENO: checking size of long" >&5
5594echo $ECHO_N "checking size of long... $ECHO_C" >&6
5595if test "${ac_cv_sizeof_long+set}" = set; then
5596 echo $ECHO_N "(cached) $ECHO_C" >&6
5597else
5598 if test "$ac_cv_type_long" = yes; then
5599 # The cast to unsigned long works around a bug in the HP C Compiler
5600 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5601 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5602 # This bug is HP SR number 8606223364.
5603 if test "$cross_compiling" = yes; then
5604 # Depending upon the size, compute the lo and hi bounds.
5605cat >conftest.$ac_ext <<_ACEOF
5606#line $LINENO "configure"
5607#include "confdefs.h"
5608$ac_includes_default
5609#ifdef F77_DUMMY_MAIN
5610# ifdef __cplusplus
5611 extern "C"
5612# endif
5613 int F77_DUMMY_MAIN() { return 1; }
5614#endif
5615int
5616main ()
5617{
5618static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
5619test_array [0] = 0
5620
5621 ;
5622 return 0;
5623}
5624_ACEOF
5625rm -f conftest.$ac_objext
5626if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5627 (eval $ac_compile) 2>&5
5628 ac_status=$?
5629 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5630 (exit $ac_status); } &&
5631 { ac_try='test -s conftest.$ac_objext'
5632 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5633 (eval $ac_try) 2>&5
5634 ac_status=$?
5635 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5636 (exit $ac_status); }; }; then
5637 ac_lo=0 ac_mid=0
5638 while :; do
5639 cat >conftest.$ac_ext <<_ACEOF
5640#line $LINENO "configure"
5641#include "confdefs.h"
5642$ac_includes_default
5643#ifdef F77_DUMMY_MAIN
5644# ifdef __cplusplus
5645 extern "C"
5646# endif
5647 int F77_DUMMY_MAIN() { return 1; }
5648#endif
5649int
5650main ()
5651{
5652static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5653test_array [0] = 0
5654
5655 ;
5656 return 0;
5657}
5658_ACEOF
5659rm -f conftest.$ac_objext
5660if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5661 (eval $ac_compile) 2>&5
5662 ac_status=$?
5663 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5664 (exit $ac_status); } &&
5665 { ac_try='test -s conftest.$ac_objext'
5666 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5667 (eval $ac_try) 2>&5
5668 ac_status=$?
5669 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5670 (exit $ac_status); }; }; then
5671 ac_hi=$ac_mid; break
5672else
5673 echo "$as_me: failed program was:" >&5
5674cat conftest.$ac_ext >&5
5675ac_lo=`expr $ac_mid + 1`
5676 if test $ac_lo -le $ac_mid; then
5677 ac_lo= ac_hi=
5678 break
5679 fi
5680 ac_mid=`expr 2 '*' $ac_mid + 1`
5681fi
5682rm -f conftest.$ac_objext conftest.$ac_ext
5683 done
5684else
5685 echo "$as_me: failed program was:" >&5
5686cat conftest.$ac_ext >&5
5687cat >conftest.$ac_ext <<_ACEOF
5688#line $LINENO "configure"
5689#include "confdefs.h"
5690$ac_includes_default
5691#ifdef F77_DUMMY_MAIN
5692# ifdef __cplusplus
5693 extern "C"
5694# endif
5695 int F77_DUMMY_MAIN() { return 1; }
5696#endif
5697int
5698main ()
5699{
5700static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
5701test_array [0] = 0
5702
5703 ;
5704 return 0;
5705}
5706_ACEOF
5707rm -f conftest.$ac_objext
5708if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5709 (eval $ac_compile) 2>&5
5710 ac_status=$?
5711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5712 (exit $ac_status); } &&
5713 { ac_try='test -s conftest.$ac_objext'
5714 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5715 (eval $ac_try) 2>&5
5716 ac_status=$?
5717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5718 (exit $ac_status); }; }; then
5719 ac_hi=-1 ac_mid=-1
5720 while :; do
5721 cat >conftest.$ac_ext <<_ACEOF
5722#line $LINENO "configure"
5723#include "confdefs.h"
5724$ac_includes_default
5725#ifdef F77_DUMMY_MAIN
5726# ifdef __cplusplus
5727 extern "C"
5728# endif
5729 int F77_DUMMY_MAIN() { return 1; }
5730#endif
5731int
5732main ()
5733{
5734static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
5735test_array [0] = 0
5736
5737 ;
5738 return 0;
5739}
5740_ACEOF
5741rm -f conftest.$ac_objext
5742if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5743 (eval $ac_compile) 2>&5
5744 ac_status=$?
5745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5746 (exit $ac_status); } &&
5747 { ac_try='test -s conftest.$ac_objext'
5748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5749 (eval $ac_try) 2>&5
5750 ac_status=$?
5751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5752 (exit $ac_status); }; }; then
5753 ac_lo=$ac_mid; break
5754else
5755 echo "$as_me: failed program was:" >&5
5756cat conftest.$ac_ext >&5
5757ac_hi=`expr '(' $ac_mid ')' - 1`
5758 if test $ac_mid -le $ac_hi; then
5759 ac_lo= ac_hi=
5760 break
5761 fi
5762 ac_mid=`expr 2 '*' $ac_mid`
5763fi
5764rm -f conftest.$ac_objext conftest.$ac_ext
5765 done
5766else
5767 echo "$as_me: failed program was:" >&5
5768cat conftest.$ac_ext >&5
5769ac_lo= ac_hi=
5770fi
5771rm -f conftest.$ac_objext conftest.$ac_ext
5772fi
5773rm -f conftest.$ac_objext conftest.$ac_ext
5774# Binary search between lo and hi bounds.
5775while test "x$ac_lo" != "x$ac_hi"; do
5776 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5777 cat >conftest.$ac_ext <<_ACEOF
5778#line $LINENO "configure"
5779#include "confdefs.h"
5780$ac_includes_default
5781#ifdef F77_DUMMY_MAIN
5782# ifdef __cplusplus
5783 extern "C"
5784# endif
5785 int F77_DUMMY_MAIN() { return 1; }
5786#endif
5787int
5788main ()
5789{
5790static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5791test_array [0] = 0
5792
5793 ;
5794 return 0;
5795}
5796_ACEOF
5797rm -f conftest.$ac_objext
5798if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5799 (eval $ac_compile) 2>&5
5800 ac_status=$?
5801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5802 (exit $ac_status); } &&
5803 { ac_try='test -s conftest.$ac_objext'
5804 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5805 (eval $ac_try) 2>&5
5806 ac_status=$?
5807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5808 (exit $ac_status); }; }; then
5809 ac_hi=$ac_mid
5810else
5811 echo "$as_me: failed program was:" >&5
5812cat conftest.$ac_ext >&5
5813ac_lo=`expr '(' $ac_mid ')' + 1`
5814fi
5815rm -f conftest.$ac_objext conftest.$ac_ext
5816done
5817case $ac_lo in
5818?*) ac_cv_sizeof_long=$ac_lo;;
5819'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77" >&5
5820echo "$as_me: error: cannot compute sizeof (long), 77" >&2;}
5821 { (exit 1); exit 1; }; } ;;
5822esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005823else
5824 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005825 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5826echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5827 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005828else
Martin v. Löwis11437992002-04-12 09:54:03 +00005829 cat >conftest.$ac_ext <<_ACEOF
5830#line $LINENO "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005831#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005832$ac_includes_default
5833long longval () { return (long) (sizeof (long)); }
5834unsigned long ulongval () { return (long) (sizeof (long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005835#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005836#include <stdlib.h>
5837#ifdef F77_DUMMY_MAIN
5838# ifdef __cplusplus
5839 extern "C"
5840# endif
5841 int F77_DUMMY_MAIN() { return 1; }
5842#endif
5843int
5844main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005845{
Martin v. Löwis11437992002-04-12 09:54:03 +00005846
5847 FILE *f = fopen ("conftest.val", "w");
5848 if (! f)
5849 exit (1);
5850 if (((long) (sizeof (long))) < 0)
5851 {
5852 long i = longval ();
5853 if (i != ((long) (sizeof (long))))
5854 exit (1);
5855 fprintf (f, "%ld\n", i);
5856 }
5857 else
5858 {
5859 unsigned long i = ulongval ();
5860 if (i != ((long) (sizeof (long))))
5861 exit (1);
5862 fprintf (f, "%lu\n", i);
5863 }
5864 exit (ferror (f) || fclose (f) != 0);
5865
5866 ;
5867 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005868}
Martin v. Löwis11437992002-04-12 09:54:03 +00005869_ACEOF
5870rm -f conftest$ac_exeext
5871if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5872 (eval $ac_link) 2>&5
5873 ac_status=$?
5874 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5875 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5876 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5877 (eval $ac_try) 2>&5
5878 ac_status=$?
5879 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5880 (exit $ac_status); }; }; then
5881 ac_cv_sizeof_long=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005882else
Martin v. Löwis11437992002-04-12 09:54:03 +00005883 echo "$as_me: program exited with status $ac_status" >&5
5884echo "$as_me: failed program was:" >&5
5885cat conftest.$ac_ext >&5
5886( exit $ac_status )
5887{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77" >&5
5888echo "$as_me: error: cannot compute sizeof (long), 77" >&2;}
5889 { (exit 1); exit 1; }; }
5890fi
5891rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5892fi
5893fi
5894rm -f conftest.val
5895else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005896 ac_cv_sizeof_long=0
5897fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005898fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005899echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
5900echo "${ECHO_T}$ac_cv_sizeof_long" >&6
5901cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005902#define SIZEOF_LONG $ac_cv_sizeof_long
Martin v. Löwis11437992002-04-12 09:54:03 +00005903_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005904
5905
Martin v. Löwis11437992002-04-12 09:54:03 +00005906echo "$as_me:$LINENO: checking for void *" >&5
5907echo $ECHO_N "checking for void *... $ECHO_C" >&6
5908if test "${ac_cv_type_void_p+set}" = set; then
5909 echo $ECHO_N "(cached) $ECHO_C" >&6
5910else
5911 cat >conftest.$ac_ext <<_ACEOF
5912#line $LINENO "configure"
5913#include "confdefs.h"
5914$ac_includes_default
5915#ifdef F77_DUMMY_MAIN
5916# ifdef __cplusplus
5917 extern "C"
5918# endif
5919 int F77_DUMMY_MAIN() { return 1; }
5920#endif
5921int
5922main ()
5923{
5924if ((void * *) 0)
5925 return 0;
5926if (sizeof (void *))
5927 return 0;
5928 ;
5929 return 0;
5930}
5931_ACEOF
5932rm -f conftest.$ac_objext
5933if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5934 (eval $ac_compile) 2>&5
5935 ac_status=$?
5936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5937 (exit $ac_status); } &&
5938 { ac_try='test -s conftest.$ac_objext'
5939 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5940 (eval $ac_try) 2>&5
5941 ac_status=$?
5942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5943 (exit $ac_status); }; }; then
5944 ac_cv_type_void_p=yes
5945else
5946 echo "$as_me: failed program was:" >&5
5947cat conftest.$ac_ext >&5
5948ac_cv_type_void_p=no
5949fi
5950rm -f conftest.$ac_objext conftest.$ac_ext
5951fi
5952echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
5953echo "${ECHO_T}$ac_cv_type_void_p" >&6
5954
5955echo "$as_me:$LINENO: checking size of void *" >&5
5956echo $ECHO_N "checking size of void *... $ECHO_C" >&6
5957if test "${ac_cv_sizeof_void_p+set}" = set; then
5958 echo $ECHO_N "(cached) $ECHO_C" >&6
5959else
5960 if test "$ac_cv_type_void_p" = yes; then
5961 # The cast to unsigned long works around a bug in the HP C Compiler
5962 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5963 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5964 # This bug is HP SR number 8606223364.
5965 if test "$cross_compiling" = yes; then
5966 # Depending upon the size, compute the lo and hi bounds.
5967cat >conftest.$ac_ext <<_ACEOF
5968#line $LINENO "configure"
5969#include "confdefs.h"
5970$ac_includes_default
5971#ifdef F77_DUMMY_MAIN
5972# ifdef __cplusplus
5973 extern "C"
5974# endif
5975 int F77_DUMMY_MAIN() { return 1; }
5976#endif
5977int
5978main ()
5979{
5980static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
5981test_array [0] = 0
5982
5983 ;
5984 return 0;
5985}
5986_ACEOF
5987rm -f conftest.$ac_objext
5988if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5989 (eval $ac_compile) 2>&5
5990 ac_status=$?
5991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5992 (exit $ac_status); } &&
5993 { ac_try='test -s conftest.$ac_objext'
5994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5995 (eval $ac_try) 2>&5
5996 ac_status=$?
5997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5998 (exit $ac_status); }; }; then
5999 ac_lo=0 ac_mid=0
6000 while :; do
6001 cat >conftest.$ac_ext <<_ACEOF
6002#line $LINENO "configure"
6003#include "confdefs.h"
6004$ac_includes_default
6005#ifdef F77_DUMMY_MAIN
6006# ifdef __cplusplus
6007 extern "C"
6008# endif
6009 int F77_DUMMY_MAIN() { return 1; }
6010#endif
6011int
6012main ()
6013{
6014static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
6015test_array [0] = 0
6016
6017 ;
6018 return 0;
6019}
6020_ACEOF
6021rm -f conftest.$ac_objext
6022if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6023 (eval $ac_compile) 2>&5
6024 ac_status=$?
6025 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6026 (exit $ac_status); } &&
6027 { ac_try='test -s conftest.$ac_objext'
6028 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6029 (eval $ac_try) 2>&5
6030 ac_status=$?
6031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6032 (exit $ac_status); }; }; then
6033 ac_hi=$ac_mid; break
6034else
6035 echo "$as_me: failed program was:" >&5
6036cat conftest.$ac_ext >&5
6037ac_lo=`expr $ac_mid + 1`
6038 if test $ac_lo -le $ac_mid; then
6039 ac_lo= ac_hi=
6040 break
6041 fi
6042 ac_mid=`expr 2 '*' $ac_mid + 1`
6043fi
6044rm -f conftest.$ac_objext conftest.$ac_ext
6045 done
6046else
6047 echo "$as_me: failed program was:" >&5
6048cat conftest.$ac_ext >&5
6049cat >conftest.$ac_ext <<_ACEOF
6050#line $LINENO "configure"
6051#include "confdefs.h"
6052$ac_includes_default
6053#ifdef F77_DUMMY_MAIN
6054# ifdef __cplusplus
6055 extern "C"
6056# endif
6057 int F77_DUMMY_MAIN() { return 1; }
6058#endif
6059int
6060main ()
6061{
6062static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
6063test_array [0] = 0
6064
6065 ;
6066 return 0;
6067}
6068_ACEOF
6069rm -f conftest.$ac_objext
6070if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6071 (eval $ac_compile) 2>&5
6072 ac_status=$?
6073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6074 (exit $ac_status); } &&
6075 { ac_try='test -s conftest.$ac_objext'
6076 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6077 (eval $ac_try) 2>&5
6078 ac_status=$?
6079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6080 (exit $ac_status); }; }; then
6081 ac_hi=-1 ac_mid=-1
6082 while :; do
6083 cat >conftest.$ac_ext <<_ACEOF
6084#line $LINENO "configure"
6085#include "confdefs.h"
6086$ac_includes_default
6087#ifdef F77_DUMMY_MAIN
6088# ifdef __cplusplus
6089 extern "C"
6090# endif
6091 int F77_DUMMY_MAIN() { return 1; }
6092#endif
6093int
6094main ()
6095{
6096static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
6097test_array [0] = 0
6098
6099 ;
6100 return 0;
6101}
6102_ACEOF
6103rm -f conftest.$ac_objext
6104if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6105 (eval $ac_compile) 2>&5
6106 ac_status=$?
6107 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6108 (exit $ac_status); } &&
6109 { ac_try='test -s conftest.$ac_objext'
6110 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6111 (eval $ac_try) 2>&5
6112 ac_status=$?
6113 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6114 (exit $ac_status); }; }; then
6115 ac_lo=$ac_mid; break
6116else
6117 echo "$as_me: failed program was:" >&5
6118cat conftest.$ac_ext >&5
6119ac_hi=`expr '(' $ac_mid ')' - 1`
6120 if test $ac_mid -le $ac_hi; then
6121 ac_lo= ac_hi=
6122 break
6123 fi
6124 ac_mid=`expr 2 '*' $ac_mid`
6125fi
6126rm -f conftest.$ac_objext conftest.$ac_ext
6127 done
6128else
6129 echo "$as_me: failed program was:" >&5
6130cat conftest.$ac_ext >&5
6131ac_lo= ac_hi=
6132fi
6133rm -f conftest.$ac_objext conftest.$ac_ext
6134fi
6135rm -f conftest.$ac_objext conftest.$ac_ext
6136# Binary search between lo and hi bounds.
6137while test "x$ac_lo" != "x$ac_hi"; do
6138 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6139 cat >conftest.$ac_ext <<_ACEOF
6140#line $LINENO "configure"
6141#include "confdefs.h"
6142$ac_includes_default
6143#ifdef F77_DUMMY_MAIN
6144# ifdef __cplusplus
6145 extern "C"
6146# endif
6147 int F77_DUMMY_MAIN() { return 1; }
6148#endif
6149int
6150main ()
6151{
6152static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
6153test_array [0] = 0
6154
6155 ;
6156 return 0;
6157}
6158_ACEOF
6159rm -f conftest.$ac_objext
6160if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6161 (eval $ac_compile) 2>&5
6162 ac_status=$?
6163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6164 (exit $ac_status); } &&
6165 { ac_try='test -s conftest.$ac_objext'
6166 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6167 (eval $ac_try) 2>&5
6168 ac_status=$?
6169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6170 (exit $ac_status); }; }; then
6171 ac_hi=$ac_mid
6172else
6173 echo "$as_me: failed program was:" >&5
6174cat conftest.$ac_ext >&5
6175ac_lo=`expr '(' $ac_mid ')' + 1`
6176fi
6177rm -f conftest.$ac_objext conftest.$ac_ext
6178done
6179case $ac_lo in
6180?*) ac_cv_sizeof_void_p=$ac_lo;;
6181'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77" >&5
6182echo "$as_me: error: cannot compute sizeof (void *), 77" >&2;}
6183 { (exit 1); exit 1; }; } ;;
6184esac
Guido van Rossumad678af1998-10-02 14:42:15 +00006185else
6186 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006187 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6188echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6189 { (exit 1); exit 1; }; }
Guido van Rossumad678af1998-10-02 14:42:15 +00006190else
Martin v. Löwis11437992002-04-12 09:54:03 +00006191 cat >conftest.$ac_ext <<_ACEOF
6192#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +00006193#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006194$ac_includes_default
6195long longval () { return (long) (sizeof (void *)); }
6196unsigned long ulongval () { return (long) (sizeof (void *)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006197#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006198#include <stdlib.h>
6199#ifdef F77_DUMMY_MAIN
6200# ifdef __cplusplus
6201 extern "C"
6202# endif
6203 int F77_DUMMY_MAIN() { return 1; }
6204#endif
6205int
6206main ()
Guido van Rossumad678af1998-10-02 14:42:15 +00006207{
Martin v. Löwis11437992002-04-12 09:54:03 +00006208
6209 FILE *f = fopen ("conftest.val", "w");
6210 if (! f)
6211 exit (1);
6212 if (((long) (sizeof (void *))) < 0)
6213 {
6214 long i = longval ();
6215 if (i != ((long) (sizeof (void *))))
6216 exit (1);
6217 fprintf (f, "%ld\n", i);
6218 }
6219 else
6220 {
6221 unsigned long i = ulongval ();
6222 if (i != ((long) (sizeof (void *))))
6223 exit (1);
6224 fprintf (f, "%lu\n", i);
6225 }
6226 exit (ferror (f) || fclose (f) != 0);
6227
6228 ;
6229 return 0;
Guido van Rossumad678af1998-10-02 14:42:15 +00006230}
Martin v. Löwis11437992002-04-12 09:54:03 +00006231_ACEOF
6232rm -f conftest$ac_exeext
6233if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6234 (eval $ac_link) 2>&5
6235 ac_status=$?
6236 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6237 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6238 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6239 (eval $ac_try) 2>&5
6240 ac_status=$?
6241 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6242 (exit $ac_status); }; }; then
6243 ac_cv_sizeof_void_p=`cat conftest.val`
Guido van Rossumad678af1998-10-02 14:42:15 +00006244else
Martin v. Löwis11437992002-04-12 09:54:03 +00006245 echo "$as_me: program exited with status $ac_status" >&5
6246echo "$as_me: failed program was:" >&5
6247cat conftest.$ac_ext >&5
6248( exit $ac_status )
6249{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77" >&5
6250echo "$as_me: error: cannot compute sizeof (void *), 77" >&2;}
6251 { (exit 1); exit 1; }; }
6252fi
6253rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6254fi
6255fi
6256rm -f conftest.val
6257else
Guido van Rossumad678af1998-10-02 14:42:15 +00006258 ac_cv_sizeof_void_p=0
6259fi
Guido van Rossumad678af1998-10-02 14:42:15 +00006260fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006261echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
6262echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
6263cat >>confdefs.h <<_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00006264#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
Martin v. Löwis11437992002-04-12 09:54:03 +00006265_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00006266
6267
Martin v. Löwis11437992002-04-12 09:54:03 +00006268echo "$as_me:$LINENO: checking for char" >&5
6269echo $ECHO_N "checking for char... $ECHO_C" >&6
6270if test "${ac_cv_type_char+set}" = set; then
6271 echo $ECHO_N "(cached) $ECHO_C" >&6
6272else
6273 cat >conftest.$ac_ext <<_ACEOF
6274#line $LINENO "configure"
6275#include "confdefs.h"
6276$ac_includes_default
6277#ifdef F77_DUMMY_MAIN
6278# ifdef __cplusplus
6279 extern "C"
6280# endif
6281 int F77_DUMMY_MAIN() { return 1; }
6282#endif
6283int
6284main ()
6285{
6286if ((char *) 0)
6287 return 0;
6288if (sizeof (char))
6289 return 0;
6290 ;
6291 return 0;
6292}
6293_ACEOF
6294rm -f conftest.$ac_objext
6295if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6296 (eval $ac_compile) 2>&5
6297 ac_status=$?
6298 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6299 (exit $ac_status); } &&
6300 { ac_try='test -s conftest.$ac_objext'
6301 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6302 (eval $ac_try) 2>&5
6303 ac_status=$?
6304 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6305 (exit $ac_status); }; }; then
6306 ac_cv_type_char=yes
6307else
6308 echo "$as_me: failed program was:" >&5
6309cat conftest.$ac_ext >&5
6310ac_cv_type_char=no
6311fi
6312rm -f conftest.$ac_objext conftest.$ac_ext
6313fi
6314echo "$as_me:$LINENO: result: $ac_cv_type_char" >&5
6315echo "${ECHO_T}$ac_cv_type_char" >&6
6316
6317echo "$as_me:$LINENO: checking size of char" >&5
6318echo $ECHO_N "checking size of char... $ECHO_C" >&6
6319if test "${ac_cv_sizeof_char+set}" = set; then
6320 echo $ECHO_N "(cached) $ECHO_C" >&6
6321else
6322 if test "$ac_cv_type_char" = yes; then
6323 # The cast to unsigned long works around a bug in the HP C Compiler
6324 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6325 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6326 # This bug is HP SR number 8606223364.
6327 if test "$cross_compiling" = yes; then
6328 # Depending upon the size, compute the lo and hi bounds.
6329cat >conftest.$ac_ext <<_ACEOF
6330#line $LINENO "configure"
6331#include "confdefs.h"
6332$ac_includes_default
6333#ifdef F77_DUMMY_MAIN
6334# ifdef __cplusplus
6335 extern "C"
6336# endif
6337 int F77_DUMMY_MAIN() { return 1; }
6338#endif
6339int
6340main ()
6341{
6342static int test_array [1 - 2 * !(((long) (sizeof (char))) >= 0)];
6343test_array [0] = 0
6344
6345 ;
6346 return 0;
6347}
6348_ACEOF
6349rm -f conftest.$ac_objext
6350if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6351 (eval $ac_compile) 2>&5
6352 ac_status=$?
6353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6354 (exit $ac_status); } &&
6355 { ac_try='test -s conftest.$ac_objext'
6356 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6357 (eval $ac_try) 2>&5
6358 ac_status=$?
6359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6360 (exit $ac_status); }; }; then
6361 ac_lo=0 ac_mid=0
6362 while :; do
6363 cat >conftest.$ac_ext <<_ACEOF
6364#line $LINENO "configure"
6365#include "confdefs.h"
6366$ac_includes_default
6367#ifdef F77_DUMMY_MAIN
6368# ifdef __cplusplus
6369 extern "C"
6370# endif
6371 int F77_DUMMY_MAIN() { return 1; }
6372#endif
6373int
6374main ()
6375{
6376static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
6377test_array [0] = 0
6378
6379 ;
6380 return 0;
6381}
6382_ACEOF
6383rm -f conftest.$ac_objext
6384if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6385 (eval $ac_compile) 2>&5
6386 ac_status=$?
6387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6388 (exit $ac_status); } &&
6389 { ac_try='test -s conftest.$ac_objext'
6390 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6391 (eval $ac_try) 2>&5
6392 ac_status=$?
6393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6394 (exit $ac_status); }; }; then
6395 ac_hi=$ac_mid; break
6396else
6397 echo "$as_me: failed program was:" >&5
6398cat conftest.$ac_ext >&5
6399ac_lo=`expr $ac_mid + 1`
6400 if test $ac_lo -le $ac_mid; then
6401 ac_lo= ac_hi=
6402 break
6403 fi
6404 ac_mid=`expr 2 '*' $ac_mid + 1`
6405fi
6406rm -f conftest.$ac_objext conftest.$ac_ext
6407 done
6408else
6409 echo "$as_me: failed program was:" >&5
6410cat conftest.$ac_ext >&5
6411cat >conftest.$ac_ext <<_ACEOF
6412#line $LINENO "configure"
6413#include "confdefs.h"
6414$ac_includes_default
6415#ifdef F77_DUMMY_MAIN
6416# ifdef __cplusplus
6417 extern "C"
6418# endif
6419 int F77_DUMMY_MAIN() { return 1; }
6420#endif
6421int
6422main ()
6423{
6424static int test_array [1 - 2 * !(((long) (sizeof (char))) < 0)];
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=-1 ac_mid=-1
6444 while :; do
6445 cat >conftest.$ac_ext <<_ACEOF
6446#line $LINENO "configure"
6447#include "confdefs.h"
6448$ac_includes_default
6449#ifdef F77_DUMMY_MAIN
6450# ifdef __cplusplus
6451 extern "C"
6452# endif
6453 int F77_DUMMY_MAIN() { return 1; }
6454#endif
6455int
6456main ()
6457{
6458static int test_array [1 - 2 * !(((long) (sizeof (char))) >= $ac_mid)];
6459test_array [0] = 0
6460
6461 ;
6462 return 0;
6463}
6464_ACEOF
6465rm -f conftest.$ac_objext
6466if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6467 (eval $ac_compile) 2>&5
6468 ac_status=$?
6469 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6470 (exit $ac_status); } &&
6471 { ac_try='test -s conftest.$ac_objext'
6472 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6473 (eval $ac_try) 2>&5
6474 ac_status=$?
6475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6476 (exit $ac_status); }; }; then
6477 ac_lo=$ac_mid; break
6478else
6479 echo "$as_me: failed program was:" >&5
6480cat conftest.$ac_ext >&5
6481ac_hi=`expr '(' $ac_mid ')' - 1`
6482 if test $ac_mid -le $ac_hi; then
6483 ac_lo= ac_hi=
6484 break
6485 fi
6486 ac_mid=`expr 2 '*' $ac_mid`
6487fi
6488rm -f conftest.$ac_objext conftest.$ac_ext
6489 done
6490else
6491 echo "$as_me: failed program was:" >&5
6492cat conftest.$ac_ext >&5
6493ac_lo= ac_hi=
6494fi
6495rm -f conftest.$ac_objext conftest.$ac_ext
6496fi
6497rm -f conftest.$ac_objext conftest.$ac_ext
6498# Binary search between lo and hi bounds.
6499while test "x$ac_lo" != "x$ac_hi"; do
6500 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6501 cat >conftest.$ac_ext <<_ACEOF
6502#line $LINENO "configure"
6503#include "confdefs.h"
6504$ac_includes_default
6505#ifdef F77_DUMMY_MAIN
6506# ifdef __cplusplus
6507 extern "C"
6508# endif
6509 int F77_DUMMY_MAIN() { return 1; }
6510#endif
6511int
6512main ()
6513{
6514static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
6515test_array [0] = 0
6516
6517 ;
6518 return 0;
6519}
6520_ACEOF
6521rm -f conftest.$ac_objext
6522if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6523 (eval $ac_compile) 2>&5
6524 ac_status=$?
6525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6526 (exit $ac_status); } &&
6527 { ac_try='test -s conftest.$ac_objext'
6528 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6529 (eval $ac_try) 2>&5
6530 ac_status=$?
6531 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6532 (exit $ac_status); }; }; then
6533 ac_hi=$ac_mid
6534else
6535 echo "$as_me: failed program was:" >&5
6536cat conftest.$ac_ext >&5
6537ac_lo=`expr '(' $ac_mid ')' + 1`
6538fi
6539rm -f conftest.$ac_objext conftest.$ac_ext
6540done
6541case $ac_lo in
6542?*) ac_cv_sizeof_char=$ac_lo;;
6543'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77" >&5
6544echo "$as_me: error: cannot compute sizeof (char), 77" >&2;}
6545 { (exit 1); exit 1; }; } ;;
6546esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006547else
6548 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006549 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6550echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6551 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006552else
Martin v. Löwis11437992002-04-12 09:54:03 +00006553 cat >conftest.$ac_ext <<_ACEOF
6554#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006555#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006556$ac_includes_default
6557long longval () { return (long) (sizeof (char)); }
6558unsigned long ulongval () { return (long) (sizeof (char)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006559#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006560#include <stdlib.h>
6561#ifdef F77_DUMMY_MAIN
6562# ifdef __cplusplus
6563 extern "C"
6564# endif
6565 int F77_DUMMY_MAIN() { return 1; }
6566#endif
6567int
6568main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006569{
Martin v. Löwis11437992002-04-12 09:54:03 +00006570
6571 FILE *f = fopen ("conftest.val", "w");
6572 if (! f)
6573 exit (1);
6574 if (((long) (sizeof (char))) < 0)
6575 {
6576 long i = longval ();
6577 if (i != ((long) (sizeof (char))))
6578 exit (1);
6579 fprintf (f, "%ld\n", i);
6580 }
6581 else
6582 {
6583 unsigned long i = ulongval ();
6584 if (i != ((long) (sizeof (char))))
6585 exit (1);
6586 fprintf (f, "%lu\n", i);
6587 }
6588 exit (ferror (f) || fclose (f) != 0);
6589
6590 ;
6591 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006592}
Martin v. Löwis11437992002-04-12 09:54:03 +00006593_ACEOF
6594rm -f conftest$ac_exeext
6595if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6596 (eval $ac_link) 2>&5
6597 ac_status=$?
6598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6599 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6600 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6601 (eval $ac_try) 2>&5
6602 ac_status=$?
6603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6604 (exit $ac_status); }; }; then
6605 ac_cv_sizeof_char=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006606else
Martin v. Löwis11437992002-04-12 09:54:03 +00006607 echo "$as_me: program exited with status $ac_status" >&5
6608echo "$as_me: failed program was:" >&5
6609cat conftest.$ac_ext >&5
6610( exit $ac_status )
6611{ { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77" >&5
6612echo "$as_me: error: cannot compute sizeof (char), 77" >&2;}
6613 { (exit 1); exit 1; }; }
6614fi
6615rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6616fi
6617fi
6618rm -f conftest.val
6619else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006620 ac_cv_sizeof_char=0
6621fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00006622fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006623echo "$as_me:$LINENO: result: $ac_cv_sizeof_char" >&5
6624echo "${ECHO_T}$ac_cv_sizeof_char" >&6
6625cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006626#define SIZEOF_CHAR $ac_cv_sizeof_char
Martin v. Löwis11437992002-04-12 09:54:03 +00006627_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006628
6629
Martin v. Löwis11437992002-04-12 09:54:03 +00006630echo "$as_me:$LINENO: checking for short" >&5
6631echo $ECHO_N "checking for short... $ECHO_C" >&6
6632if test "${ac_cv_type_short+set}" = set; then
6633 echo $ECHO_N "(cached) $ECHO_C" >&6
6634else
6635 cat >conftest.$ac_ext <<_ACEOF
6636#line $LINENO "configure"
6637#include "confdefs.h"
6638$ac_includes_default
6639#ifdef F77_DUMMY_MAIN
6640# ifdef __cplusplus
6641 extern "C"
6642# endif
6643 int F77_DUMMY_MAIN() { return 1; }
6644#endif
6645int
6646main ()
6647{
6648if ((short *) 0)
6649 return 0;
6650if (sizeof (short))
6651 return 0;
6652 ;
6653 return 0;
6654}
6655_ACEOF
6656rm -f conftest.$ac_objext
6657if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6658 (eval $ac_compile) 2>&5
6659 ac_status=$?
6660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6661 (exit $ac_status); } &&
6662 { ac_try='test -s conftest.$ac_objext'
6663 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6664 (eval $ac_try) 2>&5
6665 ac_status=$?
6666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6667 (exit $ac_status); }; }; then
6668 ac_cv_type_short=yes
6669else
6670 echo "$as_me: failed program was:" >&5
6671cat conftest.$ac_ext >&5
6672ac_cv_type_short=no
6673fi
6674rm -f conftest.$ac_objext conftest.$ac_ext
6675fi
6676echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
6677echo "${ECHO_T}$ac_cv_type_short" >&6
6678
6679echo "$as_me:$LINENO: checking size of short" >&5
6680echo $ECHO_N "checking size of short... $ECHO_C" >&6
6681if test "${ac_cv_sizeof_short+set}" = set; then
6682 echo $ECHO_N "(cached) $ECHO_C" >&6
6683else
6684 if test "$ac_cv_type_short" = yes; then
6685 # The cast to unsigned long works around a bug in the HP C Compiler
6686 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6687 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6688 # This bug is HP SR number 8606223364.
6689 if test "$cross_compiling" = yes; then
6690 # Depending upon the size, compute the lo and hi bounds.
6691cat >conftest.$ac_ext <<_ACEOF
6692#line $LINENO "configure"
6693#include "confdefs.h"
6694$ac_includes_default
6695#ifdef F77_DUMMY_MAIN
6696# ifdef __cplusplus
6697 extern "C"
6698# endif
6699 int F77_DUMMY_MAIN() { return 1; }
6700#endif
6701int
6702main ()
6703{
6704static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
6705test_array [0] = 0
6706
6707 ;
6708 return 0;
6709}
6710_ACEOF
6711rm -f conftest.$ac_objext
6712if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6713 (eval $ac_compile) 2>&5
6714 ac_status=$?
6715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6716 (exit $ac_status); } &&
6717 { ac_try='test -s conftest.$ac_objext'
6718 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6719 (eval $ac_try) 2>&5
6720 ac_status=$?
6721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6722 (exit $ac_status); }; }; then
6723 ac_lo=0 ac_mid=0
6724 while :; do
6725 cat >conftest.$ac_ext <<_ACEOF
6726#line $LINENO "configure"
6727#include "confdefs.h"
6728$ac_includes_default
6729#ifdef F77_DUMMY_MAIN
6730# ifdef __cplusplus
6731 extern "C"
6732# endif
6733 int F77_DUMMY_MAIN() { return 1; }
6734#endif
6735int
6736main ()
6737{
6738static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
6739test_array [0] = 0
6740
6741 ;
6742 return 0;
6743}
6744_ACEOF
6745rm -f conftest.$ac_objext
6746if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6747 (eval $ac_compile) 2>&5
6748 ac_status=$?
6749 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6750 (exit $ac_status); } &&
6751 { ac_try='test -s conftest.$ac_objext'
6752 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6753 (eval $ac_try) 2>&5
6754 ac_status=$?
6755 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6756 (exit $ac_status); }; }; then
6757 ac_hi=$ac_mid; break
6758else
6759 echo "$as_me: failed program was:" >&5
6760cat conftest.$ac_ext >&5
6761ac_lo=`expr $ac_mid + 1`
6762 if test $ac_lo -le $ac_mid; then
6763 ac_lo= ac_hi=
6764 break
6765 fi
6766 ac_mid=`expr 2 '*' $ac_mid + 1`
6767fi
6768rm -f conftest.$ac_objext conftest.$ac_ext
6769 done
6770else
6771 echo "$as_me: failed program was:" >&5
6772cat conftest.$ac_ext >&5
6773cat >conftest.$ac_ext <<_ACEOF
6774#line $LINENO "configure"
6775#include "confdefs.h"
6776$ac_includes_default
6777#ifdef F77_DUMMY_MAIN
6778# ifdef __cplusplus
6779 extern "C"
6780# endif
6781 int F77_DUMMY_MAIN() { return 1; }
6782#endif
6783int
6784main ()
6785{
6786static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
6787test_array [0] = 0
6788
6789 ;
6790 return 0;
6791}
6792_ACEOF
6793rm -f conftest.$ac_objext
6794if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6795 (eval $ac_compile) 2>&5
6796 ac_status=$?
6797 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6798 (exit $ac_status); } &&
6799 { ac_try='test -s conftest.$ac_objext'
6800 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6801 (eval $ac_try) 2>&5
6802 ac_status=$?
6803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6804 (exit $ac_status); }; }; then
6805 ac_hi=-1 ac_mid=-1
6806 while :; do
6807 cat >conftest.$ac_ext <<_ACEOF
6808#line $LINENO "configure"
6809#include "confdefs.h"
6810$ac_includes_default
6811#ifdef F77_DUMMY_MAIN
6812# ifdef __cplusplus
6813 extern "C"
6814# endif
6815 int F77_DUMMY_MAIN() { return 1; }
6816#endif
6817int
6818main ()
6819{
6820static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
6821test_array [0] = 0
6822
6823 ;
6824 return 0;
6825}
6826_ACEOF
6827rm -f conftest.$ac_objext
6828if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6829 (eval $ac_compile) 2>&5
6830 ac_status=$?
6831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6832 (exit $ac_status); } &&
6833 { ac_try='test -s conftest.$ac_objext'
6834 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6835 (eval $ac_try) 2>&5
6836 ac_status=$?
6837 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6838 (exit $ac_status); }; }; then
6839 ac_lo=$ac_mid; break
6840else
6841 echo "$as_me: failed program was:" >&5
6842cat conftest.$ac_ext >&5
6843ac_hi=`expr '(' $ac_mid ')' - 1`
6844 if test $ac_mid -le $ac_hi; then
6845 ac_lo= ac_hi=
6846 break
6847 fi
6848 ac_mid=`expr 2 '*' $ac_mid`
6849fi
6850rm -f conftest.$ac_objext conftest.$ac_ext
6851 done
6852else
6853 echo "$as_me: failed program was:" >&5
6854cat conftest.$ac_ext >&5
6855ac_lo= ac_hi=
6856fi
6857rm -f conftest.$ac_objext conftest.$ac_ext
6858fi
6859rm -f conftest.$ac_objext conftest.$ac_ext
6860# Binary search between lo and hi bounds.
6861while test "x$ac_lo" != "x$ac_hi"; do
6862 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6863 cat >conftest.$ac_ext <<_ACEOF
6864#line $LINENO "configure"
6865#include "confdefs.h"
6866$ac_includes_default
6867#ifdef F77_DUMMY_MAIN
6868# ifdef __cplusplus
6869 extern "C"
6870# endif
6871 int F77_DUMMY_MAIN() { return 1; }
6872#endif
6873int
6874main ()
6875{
6876static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
6877test_array [0] = 0
6878
6879 ;
6880 return 0;
6881}
6882_ACEOF
6883rm -f conftest.$ac_objext
6884if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6885 (eval $ac_compile) 2>&5
6886 ac_status=$?
6887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6888 (exit $ac_status); } &&
6889 { ac_try='test -s conftest.$ac_objext'
6890 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6891 (eval $ac_try) 2>&5
6892 ac_status=$?
6893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6894 (exit $ac_status); }; }; then
6895 ac_hi=$ac_mid
6896else
6897 echo "$as_me: failed program was:" >&5
6898cat conftest.$ac_ext >&5
6899ac_lo=`expr '(' $ac_mid ')' + 1`
6900fi
6901rm -f conftest.$ac_objext conftest.$ac_ext
6902done
6903case $ac_lo in
6904?*) ac_cv_sizeof_short=$ac_lo;;
6905'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77" >&5
6906echo "$as_me: error: cannot compute sizeof (short), 77" >&2;}
6907 { (exit 1); exit 1; }; } ;;
6908esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006909else
6910 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006911 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6912echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6913 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006914else
Martin v. Löwis11437992002-04-12 09:54:03 +00006915 cat >conftest.$ac_ext <<_ACEOF
6916#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006917#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006918$ac_includes_default
6919long longval () { return (long) (sizeof (short)); }
6920unsigned long ulongval () { return (long) (sizeof (short)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006921#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006922#include <stdlib.h>
6923#ifdef F77_DUMMY_MAIN
6924# ifdef __cplusplus
6925 extern "C"
6926# endif
6927 int F77_DUMMY_MAIN() { return 1; }
6928#endif
6929int
6930main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006931{
Martin v. Löwis11437992002-04-12 09:54:03 +00006932
6933 FILE *f = fopen ("conftest.val", "w");
6934 if (! f)
6935 exit (1);
6936 if (((long) (sizeof (short))) < 0)
6937 {
6938 long i = longval ();
6939 if (i != ((long) (sizeof (short))))
6940 exit (1);
6941 fprintf (f, "%ld\n", i);
6942 }
6943 else
6944 {
6945 unsigned long i = ulongval ();
6946 if (i != ((long) (sizeof (short))))
6947 exit (1);
6948 fprintf (f, "%lu\n", i);
6949 }
6950 exit (ferror (f) || fclose (f) != 0);
6951
6952 ;
6953 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006954}
Martin v. Löwis11437992002-04-12 09:54:03 +00006955_ACEOF
6956rm -f conftest$ac_exeext
6957if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6958 (eval $ac_link) 2>&5
6959 ac_status=$?
6960 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6961 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6962 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6963 (eval $ac_try) 2>&5
6964 ac_status=$?
6965 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6966 (exit $ac_status); }; }; then
6967 ac_cv_sizeof_short=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006968else
Martin v. Löwis11437992002-04-12 09:54:03 +00006969 echo "$as_me: program exited with status $ac_status" >&5
6970echo "$as_me: failed program was:" >&5
6971cat conftest.$ac_ext >&5
6972( exit $ac_status )
6973{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77" >&5
6974echo "$as_me: error: cannot compute sizeof (short), 77" >&2;}
6975 { (exit 1); exit 1; }; }
6976fi
6977rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6978fi
6979fi
6980rm -f conftest.val
6981else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006982 ac_cv_sizeof_short=0
6983fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00006984fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006985echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
6986echo "${ECHO_T}$ac_cv_sizeof_short" >&6
6987cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006988#define SIZEOF_SHORT $ac_cv_sizeof_short
Martin v. Löwis11437992002-04-12 09:54:03 +00006989_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006990
6991
Martin v. Löwis11437992002-04-12 09:54:03 +00006992echo "$as_me:$LINENO: checking for float" >&5
6993echo $ECHO_N "checking for float... $ECHO_C" >&6
6994if test "${ac_cv_type_float+set}" = set; then
6995 echo $ECHO_N "(cached) $ECHO_C" >&6
6996else
6997 cat >conftest.$ac_ext <<_ACEOF
6998#line $LINENO "configure"
6999#include "confdefs.h"
7000$ac_includes_default
7001#ifdef F77_DUMMY_MAIN
7002# ifdef __cplusplus
7003 extern "C"
7004# endif
7005 int F77_DUMMY_MAIN() { return 1; }
7006#endif
7007int
7008main ()
7009{
7010if ((float *) 0)
7011 return 0;
7012if (sizeof (float))
7013 return 0;
7014 ;
7015 return 0;
7016}
7017_ACEOF
7018rm -f conftest.$ac_objext
7019if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7020 (eval $ac_compile) 2>&5
7021 ac_status=$?
7022 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7023 (exit $ac_status); } &&
7024 { ac_try='test -s conftest.$ac_objext'
7025 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7026 (eval $ac_try) 2>&5
7027 ac_status=$?
7028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7029 (exit $ac_status); }; }; then
7030 ac_cv_type_float=yes
7031else
7032 echo "$as_me: failed program was:" >&5
7033cat conftest.$ac_ext >&5
7034ac_cv_type_float=no
7035fi
7036rm -f conftest.$ac_objext conftest.$ac_ext
7037fi
7038echo "$as_me:$LINENO: result: $ac_cv_type_float" >&5
7039echo "${ECHO_T}$ac_cv_type_float" >&6
7040
7041echo "$as_me:$LINENO: checking size of float" >&5
7042echo $ECHO_N "checking size of float... $ECHO_C" >&6
7043if test "${ac_cv_sizeof_float+set}" = set; then
7044 echo $ECHO_N "(cached) $ECHO_C" >&6
7045else
7046 if test "$ac_cv_type_float" = yes; then
7047 # The cast to unsigned long works around a bug in the HP C Compiler
7048 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7049 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7050 # This bug is HP SR number 8606223364.
7051 if test "$cross_compiling" = yes; then
7052 # Depending upon the size, compute the lo and hi bounds.
7053cat >conftest.$ac_ext <<_ACEOF
7054#line $LINENO "configure"
7055#include "confdefs.h"
7056$ac_includes_default
7057#ifdef F77_DUMMY_MAIN
7058# ifdef __cplusplus
7059 extern "C"
7060# endif
7061 int F77_DUMMY_MAIN() { return 1; }
7062#endif
7063int
7064main ()
7065{
7066static int test_array [1 - 2 * !(((long) (sizeof (float))) >= 0)];
7067test_array [0] = 0
7068
7069 ;
7070 return 0;
7071}
7072_ACEOF
7073rm -f conftest.$ac_objext
7074if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7075 (eval $ac_compile) 2>&5
7076 ac_status=$?
7077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7078 (exit $ac_status); } &&
7079 { ac_try='test -s conftest.$ac_objext'
7080 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7081 (eval $ac_try) 2>&5
7082 ac_status=$?
7083 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7084 (exit $ac_status); }; }; then
7085 ac_lo=0 ac_mid=0
7086 while :; do
7087 cat >conftest.$ac_ext <<_ACEOF
7088#line $LINENO "configure"
7089#include "confdefs.h"
7090$ac_includes_default
7091#ifdef F77_DUMMY_MAIN
7092# ifdef __cplusplus
7093 extern "C"
7094# endif
7095 int F77_DUMMY_MAIN() { return 1; }
7096#endif
7097int
7098main ()
7099{
7100static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
7101test_array [0] = 0
7102
7103 ;
7104 return 0;
7105}
7106_ACEOF
7107rm -f conftest.$ac_objext
7108if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7109 (eval $ac_compile) 2>&5
7110 ac_status=$?
7111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7112 (exit $ac_status); } &&
7113 { ac_try='test -s conftest.$ac_objext'
7114 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7115 (eval $ac_try) 2>&5
7116 ac_status=$?
7117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7118 (exit $ac_status); }; }; then
7119 ac_hi=$ac_mid; break
7120else
7121 echo "$as_me: failed program was:" >&5
7122cat conftest.$ac_ext >&5
7123ac_lo=`expr $ac_mid + 1`
7124 if test $ac_lo -le $ac_mid; then
7125 ac_lo= ac_hi=
7126 break
7127 fi
7128 ac_mid=`expr 2 '*' $ac_mid + 1`
7129fi
7130rm -f conftest.$ac_objext conftest.$ac_ext
7131 done
7132else
7133 echo "$as_me: failed program was:" >&5
7134cat conftest.$ac_ext >&5
7135cat >conftest.$ac_ext <<_ACEOF
7136#line $LINENO "configure"
7137#include "confdefs.h"
7138$ac_includes_default
7139#ifdef F77_DUMMY_MAIN
7140# ifdef __cplusplus
7141 extern "C"
7142# endif
7143 int F77_DUMMY_MAIN() { return 1; }
7144#endif
7145int
7146main ()
7147{
7148static int test_array [1 - 2 * !(((long) (sizeof (float))) < 0)];
7149test_array [0] = 0
7150
7151 ;
7152 return 0;
7153}
7154_ACEOF
7155rm -f conftest.$ac_objext
7156if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7157 (eval $ac_compile) 2>&5
7158 ac_status=$?
7159 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7160 (exit $ac_status); } &&
7161 { ac_try='test -s conftest.$ac_objext'
7162 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7163 (eval $ac_try) 2>&5
7164 ac_status=$?
7165 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7166 (exit $ac_status); }; }; then
7167 ac_hi=-1 ac_mid=-1
7168 while :; do
7169 cat >conftest.$ac_ext <<_ACEOF
7170#line $LINENO "configure"
7171#include "confdefs.h"
7172$ac_includes_default
7173#ifdef F77_DUMMY_MAIN
7174# ifdef __cplusplus
7175 extern "C"
7176# endif
7177 int F77_DUMMY_MAIN() { return 1; }
7178#endif
7179int
7180main ()
7181{
7182static int test_array [1 - 2 * !(((long) (sizeof (float))) >= $ac_mid)];
7183test_array [0] = 0
7184
7185 ;
7186 return 0;
7187}
7188_ACEOF
7189rm -f conftest.$ac_objext
7190if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7191 (eval $ac_compile) 2>&5
7192 ac_status=$?
7193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7194 (exit $ac_status); } &&
7195 { ac_try='test -s conftest.$ac_objext'
7196 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7197 (eval $ac_try) 2>&5
7198 ac_status=$?
7199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7200 (exit $ac_status); }; }; then
7201 ac_lo=$ac_mid; break
7202else
7203 echo "$as_me: failed program was:" >&5
7204cat conftest.$ac_ext >&5
7205ac_hi=`expr '(' $ac_mid ')' - 1`
7206 if test $ac_mid -le $ac_hi; then
7207 ac_lo= ac_hi=
7208 break
7209 fi
7210 ac_mid=`expr 2 '*' $ac_mid`
7211fi
7212rm -f conftest.$ac_objext conftest.$ac_ext
7213 done
7214else
7215 echo "$as_me: failed program was:" >&5
7216cat conftest.$ac_ext >&5
7217ac_lo= ac_hi=
7218fi
7219rm -f conftest.$ac_objext conftest.$ac_ext
7220fi
7221rm -f conftest.$ac_objext conftest.$ac_ext
7222# Binary search between lo and hi bounds.
7223while test "x$ac_lo" != "x$ac_hi"; do
7224 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7225 cat >conftest.$ac_ext <<_ACEOF
7226#line $LINENO "configure"
7227#include "confdefs.h"
7228$ac_includes_default
7229#ifdef F77_DUMMY_MAIN
7230# ifdef __cplusplus
7231 extern "C"
7232# endif
7233 int F77_DUMMY_MAIN() { return 1; }
7234#endif
7235int
7236main ()
7237{
7238static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
7239test_array [0] = 0
7240
7241 ;
7242 return 0;
7243}
7244_ACEOF
7245rm -f conftest.$ac_objext
7246if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7247 (eval $ac_compile) 2>&5
7248 ac_status=$?
7249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7250 (exit $ac_status); } &&
7251 { ac_try='test -s conftest.$ac_objext'
7252 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7253 (eval $ac_try) 2>&5
7254 ac_status=$?
7255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7256 (exit $ac_status); }; }; then
7257 ac_hi=$ac_mid
7258else
7259 echo "$as_me: failed program was:" >&5
7260cat conftest.$ac_ext >&5
7261ac_lo=`expr '(' $ac_mid ')' + 1`
7262fi
7263rm -f conftest.$ac_objext conftest.$ac_ext
7264done
7265case $ac_lo in
7266?*) ac_cv_sizeof_float=$ac_lo;;
7267'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77" >&5
7268echo "$as_me: error: cannot compute sizeof (float), 77" >&2;}
7269 { (exit 1); exit 1; }; } ;;
7270esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007271else
7272 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007273 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7274echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7275 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007276else
Martin v. Löwis11437992002-04-12 09:54:03 +00007277 cat >conftest.$ac_ext <<_ACEOF
7278#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00007279#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007280$ac_includes_default
7281long longval () { return (long) (sizeof (float)); }
7282unsigned long ulongval () { return (long) (sizeof (float)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007283#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007284#include <stdlib.h>
7285#ifdef F77_DUMMY_MAIN
7286# ifdef __cplusplus
7287 extern "C"
7288# endif
7289 int F77_DUMMY_MAIN() { return 1; }
7290#endif
7291int
7292main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007293{
Martin v. Löwis11437992002-04-12 09:54:03 +00007294
7295 FILE *f = fopen ("conftest.val", "w");
7296 if (! f)
7297 exit (1);
7298 if (((long) (sizeof (float))) < 0)
7299 {
7300 long i = longval ();
7301 if (i != ((long) (sizeof (float))))
7302 exit (1);
7303 fprintf (f, "%ld\n", i);
7304 }
7305 else
7306 {
7307 unsigned long i = ulongval ();
7308 if (i != ((long) (sizeof (float))))
7309 exit (1);
7310 fprintf (f, "%lu\n", i);
7311 }
7312 exit (ferror (f) || fclose (f) != 0);
7313
7314 ;
7315 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007316}
Martin v. Löwis11437992002-04-12 09:54:03 +00007317_ACEOF
7318rm -f conftest$ac_exeext
7319if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7320 (eval $ac_link) 2>&5
7321 ac_status=$?
7322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7323 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7324 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7325 (eval $ac_try) 2>&5
7326 ac_status=$?
7327 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7328 (exit $ac_status); }; }; then
7329 ac_cv_sizeof_float=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007330else
Martin v. Löwis11437992002-04-12 09:54:03 +00007331 echo "$as_me: program exited with status $ac_status" >&5
7332echo "$as_me: failed program was:" >&5
7333cat conftest.$ac_ext >&5
7334( exit $ac_status )
7335{ { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77" >&5
7336echo "$as_me: error: cannot compute sizeof (float), 77" >&2;}
7337 { (exit 1); exit 1; }; }
7338fi
7339rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7340fi
7341fi
7342rm -f conftest.val
7343else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007344 ac_cv_sizeof_float=0
7345fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007346fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007347echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5
7348echo "${ECHO_T}$ac_cv_sizeof_float" >&6
7349cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007350#define SIZEOF_FLOAT $ac_cv_sizeof_float
Martin v. Löwis11437992002-04-12 09:54:03 +00007351_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007352
7353
Martin v. Löwis11437992002-04-12 09:54:03 +00007354echo "$as_me:$LINENO: checking for double" >&5
7355echo $ECHO_N "checking for double... $ECHO_C" >&6
7356if test "${ac_cv_type_double+set}" = set; then
7357 echo $ECHO_N "(cached) $ECHO_C" >&6
7358else
7359 cat >conftest.$ac_ext <<_ACEOF
7360#line $LINENO "configure"
7361#include "confdefs.h"
7362$ac_includes_default
7363#ifdef F77_DUMMY_MAIN
7364# ifdef __cplusplus
7365 extern "C"
7366# endif
7367 int F77_DUMMY_MAIN() { return 1; }
7368#endif
7369int
7370main ()
7371{
7372if ((double *) 0)
7373 return 0;
7374if (sizeof (double))
7375 return 0;
7376 ;
7377 return 0;
7378}
7379_ACEOF
7380rm -f conftest.$ac_objext
7381if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7382 (eval $ac_compile) 2>&5
7383 ac_status=$?
7384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7385 (exit $ac_status); } &&
7386 { ac_try='test -s conftest.$ac_objext'
7387 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7388 (eval $ac_try) 2>&5
7389 ac_status=$?
7390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7391 (exit $ac_status); }; }; then
7392 ac_cv_type_double=yes
7393else
7394 echo "$as_me: failed program was:" >&5
7395cat conftest.$ac_ext >&5
7396ac_cv_type_double=no
7397fi
7398rm -f conftest.$ac_objext conftest.$ac_ext
7399fi
7400echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
7401echo "${ECHO_T}$ac_cv_type_double" >&6
7402
7403echo "$as_me:$LINENO: checking size of double" >&5
7404echo $ECHO_N "checking size of double... $ECHO_C" >&6
7405if test "${ac_cv_sizeof_double+set}" = set; then
7406 echo $ECHO_N "(cached) $ECHO_C" >&6
7407else
7408 if test "$ac_cv_type_double" = yes; then
7409 # The cast to unsigned long works around a bug in the HP C Compiler
7410 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7411 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7412 # This bug is HP SR number 8606223364.
7413 if test "$cross_compiling" = yes; then
7414 # Depending upon the size, compute the lo and hi bounds.
7415cat >conftest.$ac_ext <<_ACEOF
7416#line $LINENO "configure"
7417#include "confdefs.h"
7418$ac_includes_default
7419#ifdef F77_DUMMY_MAIN
7420# ifdef __cplusplus
7421 extern "C"
7422# endif
7423 int F77_DUMMY_MAIN() { return 1; }
7424#endif
7425int
7426main ()
7427{
7428static int test_array [1 - 2 * !(((long) (sizeof (double))) >= 0)];
7429test_array [0] = 0
7430
7431 ;
7432 return 0;
7433}
7434_ACEOF
7435rm -f conftest.$ac_objext
7436if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7437 (eval $ac_compile) 2>&5
7438 ac_status=$?
7439 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7440 (exit $ac_status); } &&
7441 { ac_try='test -s conftest.$ac_objext'
7442 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7443 (eval $ac_try) 2>&5
7444 ac_status=$?
7445 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7446 (exit $ac_status); }; }; then
7447 ac_lo=0 ac_mid=0
7448 while :; do
7449 cat >conftest.$ac_ext <<_ACEOF
7450#line $LINENO "configure"
7451#include "confdefs.h"
7452$ac_includes_default
7453#ifdef F77_DUMMY_MAIN
7454# ifdef __cplusplus
7455 extern "C"
7456# endif
7457 int F77_DUMMY_MAIN() { return 1; }
7458#endif
7459int
7460main ()
7461{
7462static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
7463test_array [0] = 0
7464
7465 ;
7466 return 0;
7467}
7468_ACEOF
7469rm -f conftest.$ac_objext
7470if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7471 (eval $ac_compile) 2>&5
7472 ac_status=$?
7473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7474 (exit $ac_status); } &&
7475 { ac_try='test -s conftest.$ac_objext'
7476 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7477 (eval $ac_try) 2>&5
7478 ac_status=$?
7479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7480 (exit $ac_status); }; }; then
7481 ac_hi=$ac_mid; break
7482else
7483 echo "$as_me: failed program was:" >&5
7484cat conftest.$ac_ext >&5
7485ac_lo=`expr $ac_mid + 1`
7486 if test $ac_lo -le $ac_mid; then
7487 ac_lo= ac_hi=
7488 break
7489 fi
7490 ac_mid=`expr 2 '*' $ac_mid + 1`
7491fi
7492rm -f conftest.$ac_objext conftest.$ac_ext
7493 done
7494else
7495 echo "$as_me: failed program was:" >&5
7496cat conftest.$ac_ext >&5
7497cat >conftest.$ac_ext <<_ACEOF
7498#line $LINENO "configure"
7499#include "confdefs.h"
7500$ac_includes_default
7501#ifdef F77_DUMMY_MAIN
7502# ifdef __cplusplus
7503 extern "C"
7504# endif
7505 int F77_DUMMY_MAIN() { return 1; }
7506#endif
7507int
7508main ()
7509{
7510static int test_array [1 - 2 * !(((long) (sizeof (double))) < 0)];
7511test_array [0] = 0
7512
7513 ;
7514 return 0;
7515}
7516_ACEOF
7517rm -f conftest.$ac_objext
7518if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7519 (eval $ac_compile) 2>&5
7520 ac_status=$?
7521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7522 (exit $ac_status); } &&
7523 { ac_try='test -s conftest.$ac_objext'
7524 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7525 (eval $ac_try) 2>&5
7526 ac_status=$?
7527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7528 (exit $ac_status); }; }; then
7529 ac_hi=-1 ac_mid=-1
7530 while :; do
7531 cat >conftest.$ac_ext <<_ACEOF
7532#line $LINENO "configure"
7533#include "confdefs.h"
7534$ac_includes_default
7535#ifdef F77_DUMMY_MAIN
7536# ifdef __cplusplus
7537 extern "C"
7538# endif
7539 int F77_DUMMY_MAIN() { return 1; }
7540#endif
7541int
7542main ()
7543{
7544static int test_array [1 - 2 * !(((long) (sizeof (double))) >= $ac_mid)];
7545test_array [0] = 0
7546
7547 ;
7548 return 0;
7549}
7550_ACEOF
7551rm -f conftest.$ac_objext
7552if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7553 (eval $ac_compile) 2>&5
7554 ac_status=$?
7555 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7556 (exit $ac_status); } &&
7557 { ac_try='test -s conftest.$ac_objext'
7558 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7559 (eval $ac_try) 2>&5
7560 ac_status=$?
7561 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7562 (exit $ac_status); }; }; then
7563 ac_lo=$ac_mid; break
7564else
7565 echo "$as_me: failed program was:" >&5
7566cat conftest.$ac_ext >&5
7567ac_hi=`expr '(' $ac_mid ')' - 1`
7568 if test $ac_mid -le $ac_hi; then
7569 ac_lo= ac_hi=
7570 break
7571 fi
7572 ac_mid=`expr 2 '*' $ac_mid`
7573fi
7574rm -f conftest.$ac_objext conftest.$ac_ext
7575 done
7576else
7577 echo "$as_me: failed program was:" >&5
7578cat conftest.$ac_ext >&5
7579ac_lo= ac_hi=
7580fi
7581rm -f conftest.$ac_objext conftest.$ac_ext
7582fi
7583rm -f conftest.$ac_objext conftest.$ac_ext
7584# Binary search between lo and hi bounds.
7585while test "x$ac_lo" != "x$ac_hi"; do
7586 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7587 cat >conftest.$ac_ext <<_ACEOF
7588#line $LINENO "configure"
7589#include "confdefs.h"
7590$ac_includes_default
7591#ifdef F77_DUMMY_MAIN
7592# ifdef __cplusplus
7593 extern "C"
7594# endif
7595 int F77_DUMMY_MAIN() { return 1; }
7596#endif
7597int
7598main ()
7599{
7600static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
7601test_array [0] = 0
7602
7603 ;
7604 return 0;
7605}
7606_ACEOF
7607rm -f conftest.$ac_objext
7608if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7609 (eval $ac_compile) 2>&5
7610 ac_status=$?
7611 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7612 (exit $ac_status); } &&
7613 { ac_try='test -s conftest.$ac_objext'
7614 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7615 (eval $ac_try) 2>&5
7616 ac_status=$?
7617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7618 (exit $ac_status); }; }; then
7619 ac_hi=$ac_mid
7620else
7621 echo "$as_me: failed program was:" >&5
7622cat conftest.$ac_ext >&5
7623ac_lo=`expr '(' $ac_mid ')' + 1`
7624fi
7625rm -f conftest.$ac_objext conftest.$ac_ext
7626done
7627case $ac_lo in
7628?*) ac_cv_sizeof_double=$ac_lo;;
7629'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77" >&5
7630echo "$as_me: error: cannot compute sizeof (double), 77" >&2;}
7631 { (exit 1); exit 1; }; } ;;
7632esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007633else
7634 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007635 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7636echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7637 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007638else
Martin v. Löwis11437992002-04-12 09:54:03 +00007639 cat >conftest.$ac_ext <<_ACEOF
7640#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00007641#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007642$ac_includes_default
7643long longval () { return (long) (sizeof (double)); }
7644unsigned long ulongval () { return (long) (sizeof (double)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007645#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007646#include <stdlib.h>
7647#ifdef F77_DUMMY_MAIN
7648# ifdef __cplusplus
7649 extern "C"
7650# endif
7651 int F77_DUMMY_MAIN() { return 1; }
7652#endif
7653int
7654main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007655{
Martin v. Löwis11437992002-04-12 09:54:03 +00007656
7657 FILE *f = fopen ("conftest.val", "w");
7658 if (! f)
7659 exit (1);
7660 if (((long) (sizeof (double))) < 0)
7661 {
7662 long i = longval ();
7663 if (i != ((long) (sizeof (double))))
7664 exit (1);
7665 fprintf (f, "%ld\n", i);
7666 }
7667 else
7668 {
7669 unsigned long i = ulongval ();
7670 if (i != ((long) (sizeof (double))))
7671 exit (1);
7672 fprintf (f, "%lu\n", i);
7673 }
7674 exit (ferror (f) || fclose (f) != 0);
7675
7676 ;
7677 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007678}
Martin v. Löwis11437992002-04-12 09:54:03 +00007679_ACEOF
7680rm -f conftest$ac_exeext
7681if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7682 (eval $ac_link) 2>&5
7683 ac_status=$?
7684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7685 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7687 (eval $ac_try) 2>&5
7688 ac_status=$?
7689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7690 (exit $ac_status); }; }; then
7691 ac_cv_sizeof_double=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007692else
Martin v. Löwis11437992002-04-12 09:54:03 +00007693 echo "$as_me: program exited with status $ac_status" >&5
7694echo "$as_me: failed program was:" >&5
7695cat conftest.$ac_ext >&5
7696( exit $ac_status )
7697{ { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77" >&5
7698echo "$as_me: error: cannot compute sizeof (double), 77" >&2;}
7699 { (exit 1); exit 1; }; }
7700fi
7701rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7702fi
7703fi
7704rm -f conftest.val
7705else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007706 ac_cv_sizeof_double=0
7707fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007708fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007709echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5
7710echo "${ECHO_T}$ac_cv_sizeof_double" >&6
7711cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007712#define SIZEOF_DOUBLE $ac_cv_sizeof_double
Martin v. Löwis11437992002-04-12 09:54:03 +00007713_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007714
7715
Martin v. Löwis11437992002-04-12 09:54:03 +00007716echo "$as_me:$LINENO: checking for fpos_t" >&5
7717echo $ECHO_N "checking for fpos_t... $ECHO_C" >&6
7718if test "${ac_cv_type_fpos_t+set}" = set; then
7719 echo $ECHO_N "(cached) $ECHO_C" >&6
7720else
7721 cat >conftest.$ac_ext <<_ACEOF
7722#line $LINENO "configure"
7723#include "confdefs.h"
7724$ac_includes_default
7725#ifdef F77_DUMMY_MAIN
7726# ifdef __cplusplus
7727 extern "C"
7728# endif
7729 int F77_DUMMY_MAIN() { return 1; }
7730#endif
7731int
7732main ()
7733{
7734if ((fpos_t *) 0)
7735 return 0;
7736if (sizeof (fpos_t))
7737 return 0;
7738 ;
7739 return 0;
7740}
7741_ACEOF
7742rm -f conftest.$ac_objext
7743if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7744 (eval $ac_compile) 2>&5
7745 ac_status=$?
7746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7747 (exit $ac_status); } &&
7748 { ac_try='test -s conftest.$ac_objext'
7749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7750 (eval $ac_try) 2>&5
7751 ac_status=$?
7752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7753 (exit $ac_status); }; }; then
7754 ac_cv_type_fpos_t=yes
7755else
7756 echo "$as_me: failed program was:" >&5
7757cat conftest.$ac_ext >&5
7758ac_cv_type_fpos_t=no
7759fi
7760rm -f conftest.$ac_objext conftest.$ac_ext
7761fi
7762echo "$as_me:$LINENO: result: $ac_cv_type_fpos_t" >&5
7763echo "${ECHO_T}$ac_cv_type_fpos_t" >&6
7764
7765echo "$as_me:$LINENO: checking size of fpos_t" >&5
7766echo $ECHO_N "checking size of fpos_t... $ECHO_C" >&6
7767if test "${ac_cv_sizeof_fpos_t+set}" = set; then
7768 echo $ECHO_N "(cached) $ECHO_C" >&6
7769else
7770 if test "$ac_cv_type_fpos_t" = yes; then
7771 # The cast to unsigned long works around a bug in the HP C Compiler
7772 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7773 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7774 # This bug is HP SR number 8606223364.
7775 if test "$cross_compiling" = yes; then
7776 # Depending upon the size, compute the lo and hi bounds.
7777cat >conftest.$ac_ext <<_ACEOF
7778#line $LINENO "configure"
7779#include "confdefs.h"
7780$ac_includes_default
7781#ifdef F77_DUMMY_MAIN
7782# ifdef __cplusplus
7783 extern "C"
7784# endif
7785 int F77_DUMMY_MAIN() { return 1; }
7786#endif
7787int
7788main ()
7789{
7790static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= 0)];
7791test_array [0] = 0
7792
7793 ;
7794 return 0;
7795}
7796_ACEOF
7797rm -f conftest.$ac_objext
7798if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7799 (eval $ac_compile) 2>&5
7800 ac_status=$?
7801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7802 (exit $ac_status); } &&
7803 { ac_try='test -s conftest.$ac_objext'
7804 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7805 (eval $ac_try) 2>&5
7806 ac_status=$?
7807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7808 (exit $ac_status); }; }; then
7809 ac_lo=0 ac_mid=0
7810 while :; do
7811 cat >conftest.$ac_ext <<_ACEOF
7812#line $LINENO "configure"
7813#include "confdefs.h"
7814$ac_includes_default
7815#ifdef F77_DUMMY_MAIN
7816# ifdef __cplusplus
7817 extern "C"
7818# endif
7819 int F77_DUMMY_MAIN() { return 1; }
7820#endif
7821int
7822main ()
7823{
7824static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
7825test_array [0] = 0
7826
7827 ;
7828 return 0;
7829}
7830_ACEOF
7831rm -f conftest.$ac_objext
7832if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7833 (eval $ac_compile) 2>&5
7834 ac_status=$?
7835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7836 (exit $ac_status); } &&
7837 { ac_try='test -s conftest.$ac_objext'
7838 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7839 (eval $ac_try) 2>&5
7840 ac_status=$?
7841 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7842 (exit $ac_status); }; }; then
7843 ac_hi=$ac_mid; break
7844else
7845 echo "$as_me: failed program was:" >&5
7846cat conftest.$ac_ext >&5
7847ac_lo=`expr $ac_mid + 1`
7848 if test $ac_lo -le $ac_mid; then
7849 ac_lo= ac_hi=
7850 break
7851 fi
7852 ac_mid=`expr 2 '*' $ac_mid + 1`
7853fi
7854rm -f conftest.$ac_objext conftest.$ac_ext
7855 done
7856else
7857 echo "$as_me: failed program was:" >&5
7858cat conftest.$ac_ext >&5
7859cat >conftest.$ac_ext <<_ACEOF
7860#line $LINENO "configure"
7861#include "confdefs.h"
7862$ac_includes_default
7863#ifdef F77_DUMMY_MAIN
7864# ifdef __cplusplus
7865 extern "C"
7866# endif
7867 int F77_DUMMY_MAIN() { return 1; }
7868#endif
7869int
7870main ()
7871{
7872static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) < 0)];
7873test_array [0] = 0
7874
7875 ;
7876 return 0;
7877}
7878_ACEOF
7879rm -f conftest.$ac_objext
7880if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7881 (eval $ac_compile) 2>&5
7882 ac_status=$?
7883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7884 (exit $ac_status); } &&
7885 { ac_try='test -s conftest.$ac_objext'
7886 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7887 (eval $ac_try) 2>&5
7888 ac_status=$?
7889 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7890 (exit $ac_status); }; }; then
7891 ac_hi=-1 ac_mid=-1
7892 while :; do
7893 cat >conftest.$ac_ext <<_ACEOF
7894#line $LINENO "configure"
7895#include "confdefs.h"
7896$ac_includes_default
7897#ifdef F77_DUMMY_MAIN
7898# ifdef __cplusplus
7899 extern "C"
7900# endif
7901 int F77_DUMMY_MAIN() { return 1; }
7902#endif
7903int
7904main ()
7905{
7906static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= $ac_mid)];
7907test_array [0] = 0
7908
7909 ;
7910 return 0;
7911}
7912_ACEOF
7913rm -f conftest.$ac_objext
7914if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7915 (eval $ac_compile) 2>&5
7916 ac_status=$?
7917 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7918 (exit $ac_status); } &&
7919 { ac_try='test -s conftest.$ac_objext'
7920 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7921 (eval $ac_try) 2>&5
7922 ac_status=$?
7923 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7924 (exit $ac_status); }; }; then
7925 ac_lo=$ac_mid; break
7926else
7927 echo "$as_me: failed program was:" >&5
7928cat conftest.$ac_ext >&5
7929ac_hi=`expr '(' $ac_mid ')' - 1`
7930 if test $ac_mid -le $ac_hi; then
7931 ac_lo= ac_hi=
7932 break
7933 fi
7934 ac_mid=`expr 2 '*' $ac_mid`
7935fi
7936rm -f conftest.$ac_objext conftest.$ac_ext
7937 done
7938else
7939 echo "$as_me: failed program was:" >&5
7940cat conftest.$ac_ext >&5
7941ac_lo= ac_hi=
7942fi
7943rm -f conftest.$ac_objext conftest.$ac_ext
7944fi
7945rm -f conftest.$ac_objext conftest.$ac_ext
7946# Binary search between lo and hi bounds.
7947while test "x$ac_lo" != "x$ac_hi"; do
7948 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7949 cat >conftest.$ac_ext <<_ACEOF
7950#line $LINENO "configure"
7951#include "confdefs.h"
7952$ac_includes_default
7953#ifdef F77_DUMMY_MAIN
7954# ifdef __cplusplus
7955 extern "C"
7956# endif
7957 int F77_DUMMY_MAIN() { return 1; }
7958#endif
7959int
7960main ()
7961{
7962static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
7963test_array [0] = 0
7964
7965 ;
7966 return 0;
7967}
7968_ACEOF
7969rm -f conftest.$ac_objext
7970if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7971 (eval $ac_compile) 2>&5
7972 ac_status=$?
7973 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7974 (exit $ac_status); } &&
7975 { ac_try='test -s conftest.$ac_objext'
7976 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7977 (eval $ac_try) 2>&5
7978 ac_status=$?
7979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7980 (exit $ac_status); }; }; then
7981 ac_hi=$ac_mid
7982else
7983 echo "$as_me: failed program was:" >&5
7984cat conftest.$ac_ext >&5
7985ac_lo=`expr '(' $ac_mid ')' + 1`
7986fi
7987rm -f conftest.$ac_objext conftest.$ac_ext
7988done
7989case $ac_lo in
7990?*) ac_cv_sizeof_fpos_t=$ac_lo;;
7991'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77" >&5
7992echo "$as_me: error: cannot compute sizeof (fpos_t), 77" >&2;}
7993 { (exit 1); exit 1; }; } ;;
7994esac
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007995else
7996 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007997 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7998echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7999 { (exit 1); exit 1; }; }
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008000else
Martin v. Löwis11437992002-04-12 09:54:03 +00008001 cat >conftest.$ac_ext <<_ACEOF
8002#line $LINENO "configure"
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008003#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008004$ac_includes_default
8005long longval () { return (long) (sizeof (fpos_t)); }
8006unsigned long ulongval () { return (long) (sizeof (fpos_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008007#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008008#include <stdlib.h>
8009#ifdef F77_DUMMY_MAIN
8010# ifdef __cplusplus
8011 extern "C"
8012# endif
8013 int F77_DUMMY_MAIN() { return 1; }
8014#endif
8015int
8016main ()
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008017{
Martin v. Löwis11437992002-04-12 09:54:03 +00008018
8019 FILE *f = fopen ("conftest.val", "w");
8020 if (! f)
8021 exit (1);
8022 if (((long) (sizeof (fpos_t))) < 0)
8023 {
8024 long i = longval ();
8025 if (i != ((long) (sizeof (fpos_t))))
8026 exit (1);
8027 fprintf (f, "%ld\n", i);
8028 }
8029 else
8030 {
8031 unsigned long i = ulongval ();
8032 if (i != ((long) (sizeof (fpos_t))))
8033 exit (1);
8034 fprintf (f, "%lu\n", i);
8035 }
8036 exit (ferror (f) || fclose (f) != 0);
8037
8038 ;
8039 return 0;
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008040}
Martin v. Löwis11437992002-04-12 09:54:03 +00008041_ACEOF
8042rm -f conftest$ac_exeext
8043if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8044 (eval $ac_link) 2>&5
8045 ac_status=$?
8046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8047 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8048 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8049 (eval $ac_try) 2>&5
8050 ac_status=$?
8051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8052 (exit $ac_status); }; }; then
8053 ac_cv_sizeof_fpos_t=`cat conftest.val`
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008054else
Martin v. Löwis11437992002-04-12 09:54:03 +00008055 echo "$as_me: program exited with status $ac_status" >&5
8056echo "$as_me: failed program was:" >&5
8057cat conftest.$ac_ext >&5
8058( exit $ac_status )
8059{ { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77" >&5
8060echo "$as_me: error: cannot compute sizeof (fpos_t), 77" >&2;}
8061 { (exit 1); exit 1; }; }
8062fi
8063rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8064fi
8065fi
8066rm -f conftest.val
8067else
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008068 ac_cv_sizeof_fpos_t=0
8069fi
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008070fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008071echo "$as_me:$LINENO: result: $ac_cv_sizeof_fpos_t" >&5
8072echo "${ECHO_T}$ac_cv_sizeof_fpos_t" >&6
8073cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008074#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008075_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008076
Michael W. Hudson54241132001-12-07 15:38:26 +00008077
8078
Martin v. Löwis11437992002-04-12 09:54:03 +00008079echo "$as_me:$LINENO: checking for long long support" >&5
8080echo $ECHO_N "checking for long long support... $ECHO_C" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008081have_long_long=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008082cat >conftest.$ac_ext <<_ACEOF
8083#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008084#include "confdefs.h"
8085
Martin v. Löwis11437992002-04-12 09:54:03 +00008086#ifdef F77_DUMMY_MAIN
8087# ifdef __cplusplus
8088 extern "C"
8089# endif
8090 int F77_DUMMY_MAIN() { return 1; }
8091#endif
8092int
8093main ()
8094{
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008095long long x; x = (long long)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008096 ;
8097 return 0;
8098}
8099_ACEOF
8100rm -f conftest.$ac_objext
8101if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8102 (eval $ac_compile) 2>&5
8103 ac_status=$?
8104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8105 (exit $ac_status); } &&
8106 { ac_try='test -s conftest.$ac_objext'
8107 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8108 (eval $ac_try) 2>&5
8109 ac_status=$?
8110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8111 (exit $ac_status); }; }; then
8112
8113
8114cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008115#define HAVE_LONG_LONG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008116_ACEOF
8117
Martin v. Löwisc45929e2002-04-06 10:10:49 +00008118 have_long_long=yes
8119
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008120else
Martin v. Löwis11437992002-04-12 09:54:03 +00008121 echo "$as_me: failed program was:" >&5
8122cat conftest.$ac_ext >&5
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008123fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008124rm -f conftest.$ac_objext conftest.$ac_ext
8125echo "$as_me:$LINENO: result: $have_long_long" >&5
8126echo "${ECHO_T}$have_long_long" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00008127if test "$have_long_long" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008128echo "$as_me:$LINENO: checking for long long" >&5
8129echo $ECHO_N "checking for long long... $ECHO_C" >&6
8130if test "${ac_cv_type_long_long+set}" = set; then
8131 echo $ECHO_N "(cached) $ECHO_C" >&6
8132else
8133 cat >conftest.$ac_ext <<_ACEOF
8134#line $LINENO "configure"
8135#include "confdefs.h"
8136$ac_includes_default
8137#ifdef F77_DUMMY_MAIN
8138# ifdef __cplusplus
8139 extern "C"
8140# endif
8141 int F77_DUMMY_MAIN() { return 1; }
8142#endif
8143int
8144main ()
8145{
8146if ((long long *) 0)
8147 return 0;
8148if (sizeof (long long))
8149 return 0;
8150 ;
8151 return 0;
8152}
8153_ACEOF
8154rm -f conftest.$ac_objext
8155if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8156 (eval $ac_compile) 2>&5
8157 ac_status=$?
8158 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8159 (exit $ac_status); } &&
8160 { ac_try='test -s conftest.$ac_objext'
8161 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8162 (eval $ac_try) 2>&5
8163 ac_status=$?
8164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8165 (exit $ac_status); }; }; then
8166 ac_cv_type_long_long=yes
8167else
8168 echo "$as_me: failed program was:" >&5
8169cat conftest.$ac_ext >&5
8170ac_cv_type_long_long=no
8171fi
8172rm -f conftest.$ac_objext conftest.$ac_ext
8173fi
8174echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
8175echo "${ECHO_T}$ac_cv_type_long_long" >&6
8176
8177echo "$as_me:$LINENO: checking size of long long" >&5
8178echo $ECHO_N "checking size of long long... $ECHO_C" >&6
8179if test "${ac_cv_sizeof_long_long+set}" = set; then
8180 echo $ECHO_N "(cached) $ECHO_C" >&6
8181else
8182 if test "$ac_cv_type_long_long" = yes; then
8183 # The cast to unsigned long works around a bug in the HP C Compiler
8184 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8185 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8186 # This bug is HP SR number 8606223364.
8187 if test "$cross_compiling" = yes; then
8188 # Depending upon the size, compute the lo and hi bounds.
8189cat >conftest.$ac_ext <<_ACEOF
8190#line $LINENO "configure"
8191#include "confdefs.h"
8192$ac_includes_default
8193#ifdef F77_DUMMY_MAIN
8194# ifdef __cplusplus
8195 extern "C"
8196# endif
8197 int F77_DUMMY_MAIN() { return 1; }
8198#endif
8199int
8200main ()
8201{
8202static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
8203test_array [0] = 0
8204
8205 ;
8206 return 0;
8207}
8208_ACEOF
8209rm -f conftest.$ac_objext
8210if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8211 (eval $ac_compile) 2>&5
8212 ac_status=$?
8213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8214 (exit $ac_status); } &&
8215 { ac_try='test -s conftest.$ac_objext'
8216 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8217 (eval $ac_try) 2>&5
8218 ac_status=$?
8219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8220 (exit $ac_status); }; }; then
8221 ac_lo=0 ac_mid=0
8222 while :; do
8223 cat >conftest.$ac_ext <<_ACEOF
8224#line $LINENO "configure"
8225#include "confdefs.h"
8226$ac_includes_default
8227#ifdef F77_DUMMY_MAIN
8228# ifdef __cplusplus
8229 extern "C"
8230# endif
8231 int F77_DUMMY_MAIN() { return 1; }
8232#endif
8233int
8234main ()
8235{
8236static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
8237test_array [0] = 0
8238
8239 ;
8240 return 0;
8241}
8242_ACEOF
8243rm -f conftest.$ac_objext
8244if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8245 (eval $ac_compile) 2>&5
8246 ac_status=$?
8247 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8248 (exit $ac_status); } &&
8249 { ac_try='test -s conftest.$ac_objext'
8250 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8251 (eval $ac_try) 2>&5
8252 ac_status=$?
8253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8254 (exit $ac_status); }; }; then
8255 ac_hi=$ac_mid; break
8256else
8257 echo "$as_me: failed program was:" >&5
8258cat conftest.$ac_ext >&5
8259ac_lo=`expr $ac_mid + 1`
8260 if test $ac_lo -le $ac_mid; then
8261 ac_lo= ac_hi=
8262 break
8263 fi
8264 ac_mid=`expr 2 '*' $ac_mid + 1`
8265fi
8266rm -f conftest.$ac_objext conftest.$ac_ext
8267 done
8268else
8269 echo "$as_me: failed program was:" >&5
8270cat conftest.$ac_ext >&5
8271cat >conftest.$ac_ext <<_ACEOF
8272#line $LINENO "configure"
8273#include "confdefs.h"
8274$ac_includes_default
8275#ifdef F77_DUMMY_MAIN
8276# ifdef __cplusplus
8277 extern "C"
8278# endif
8279 int F77_DUMMY_MAIN() { return 1; }
8280#endif
8281int
8282main ()
8283{
8284static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
8285test_array [0] = 0
8286
8287 ;
8288 return 0;
8289}
8290_ACEOF
8291rm -f conftest.$ac_objext
8292if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8293 (eval $ac_compile) 2>&5
8294 ac_status=$?
8295 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8296 (exit $ac_status); } &&
8297 { ac_try='test -s conftest.$ac_objext'
8298 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8299 (eval $ac_try) 2>&5
8300 ac_status=$?
8301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8302 (exit $ac_status); }; }; then
8303 ac_hi=-1 ac_mid=-1
8304 while :; do
8305 cat >conftest.$ac_ext <<_ACEOF
8306#line $LINENO "configure"
8307#include "confdefs.h"
8308$ac_includes_default
8309#ifdef F77_DUMMY_MAIN
8310# ifdef __cplusplus
8311 extern "C"
8312# endif
8313 int F77_DUMMY_MAIN() { return 1; }
8314#endif
8315int
8316main ()
8317{
8318static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
8319test_array [0] = 0
8320
8321 ;
8322 return 0;
8323}
8324_ACEOF
8325rm -f conftest.$ac_objext
8326if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8327 (eval $ac_compile) 2>&5
8328 ac_status=$?
8329 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8330 (exit $ac_status); } &&
8331 { ac_try='test -s conftest.$ac_objext'
8332 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8333 (eval $ac_try) 2>&5
8334 ac_status=$?
8335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8336 (exit $ac_status); }; }; then
8337 ac_lo=$ac_mid; break
8338else
8339 echo "$as_me: failed program was:" >&5
8340cat conftest.$ac_ext >&5
8341ac_hi=`expr '(' $ac_mid ')' - 1`
8342 if test $ac_mid -le $ac_hi; then
8343 ac_lo= ac_hi=
8344 break
8345 fi
8346 ac_mid=`expr 2 '*' $ac_mid`
8347fi
8348rm -f conftest.$ac_objext conftest.$ac_ext
8349 done
8350else
8351 echo "$as_me: failed program was:" >&5
8352cat conftest.$ac_ext >&5
8353ac_lo= ac_hi=
8354fi
8355rm -f conftest.$ac_objext conftest.$ac_ext
8356fi
8357rm -f conftest.$ac_objext conftest.$ac_ext
8358# Binary search between lo and hi bounds.
8359while test "x$ac_lo" != "x$ac_hi"; do
8360 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8361 cat >conftest.$ac_ext <<_ACEOF
8362#line $LINENO "configure"
8363#include "confdefs.h"
8364$ac_includes_default
8365#ifdef F77_DUMMY_MAIN
8366# ifdef __cplusplus
8367 extern "C"
8368# endif
8369 int F77_DUMMY_MAIN() { return 1; }
8370#endif
8371int
8372main ()
8373{
8374static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
8375test_array [0] = 0
8376
8377 ;
8378 return 0;
8379}
8380_ACEOF
8381rm -f conftest.$ac_objext
8382if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8383 (eval $ac_compile) 2>&5
8384 ac_status=$?
8385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8386 (exit $ac_status); } &&
8387 { ac_try='test -s conftest.$ac_objext'
8388 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8389 (eval $ac_try) 2>&5
8390 ac_status=$?
8391 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8392 (exit $ac_status); }; }; then
8393 ac_hi=$ac_mid
8394else
8395 echo "$as_me: failed program was:" >&5
8396cat conftest.$ac_ext >&5
8397ac_lo=`expr '(' $ac_mid ')' + 1`
8398fi
8399rm -f conftest.$ac_objext conftest.$ac_ext
8400done
8401case $ac_lo in
8402?*) ac_cv_sizeof_long_long=$ac_lo;;
8403'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77" >&5
8404echo "$as_me: error: cannot compute sizeof (long long), 77" >&2;}
8405 { (exit 1); exit 1; }; } ;;
8406esac
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008407else
8408 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008409 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
8410echo "$as_me: error: cannot run test program while cross compiling" >&2;}
8411 { (exit 1); exit 1; }; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008412else
Martin v. Löwis11437992002-04-12 09:54:03 +00008413 cat >conftest.$ac_ext <<_ACEOF
8414#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008415#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008416$ac_includes_default
8417long longval () { return (long) (sizeof (long long)); }
8418unsigned long ulongval () { return (long) (sizeof (long long)); }
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>
8421#ifdef F77_DUMMY_MAIN
8422# ifdef __cplusplus
8423 extern "C"
8424# endif
8425 int F77_DUMMY_MAIN() { return 1; }
8426#endif
8427int
8428main ()
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008429{
Martin v. Löwis11437992002-04-12 09:54:03 +00008430
8431 FILE *f = fopen ("conftest.val", "w");
8432 if (! f)
8433 exit (1);
8434 if (((long) (sizeof (long long))) < 0)
8435 {
8436 long i = longval ();
8437 if (i != ((long) (sizeof (long long))))
8438 exit (1);
8439 fprintf (f, "%ld\n", i);
8440 }
8441 else
8442 {
8443 unsigned long i = ulongval ();
8444 if (i != ((long) (sizeof (long long))))
8445 exit (1);
8446 fprintf (f, "%lu\n", i);
8447 }
8448 exit (ferror (f) || fclose (f) != 0);
8449
8450 ;
8451 return 0;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008452}
Martin v. Löwis11437992002-04-12 09:54:03 +00008453_ACEOF
8454rm -f conftest$ac_exeext
8455if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8456 (eval $ac_link) 2>&5
8457 ac_status=$?
8458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8459 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8460 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8461 (eval $ac_try) 2>&5
8462 ac_status=$?
8463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8464 (exit $ac_status); }; }; then
8465 ac_cv_sizeof_long_long=`cat conftest.val`
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008466else
Martin v. Löwis11437992002-04-12 09:54:03 +00008467 echo "$as_me: program exited with status $ac_status" >&5
8468echo "$as_me: failed program was:" >&5
8469cat conftest.$ac_ext >&5
8470( exit $ac_status )
8471{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77" >&5
8472echo "$as_me: error: cannot compute sizeof (long long), 77" >&2;}
8473 { (exit 1); exit 1; }; }
8474fi
8475rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8476fi
8477fi
8478rm -f conftest.val
8479else
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008480 ac_cv_sizeof_long_long=0
8481fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008482fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008483echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
8484echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
8485cat >>confdefs.h <<_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008486#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
Martin v. Löwis11437992002-04-12 09:54:03 +00008487_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008488
Michael W. Hudson54241132001-12-07 15:38:26 +00008489
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008490fi
8491
Martin v. Löwis11437992002-04-12 09:54:03 +00008492echo "$as_me:$LINENO: checking for uintptr_t support" >&5
8493echo $ECHO_N "checking for uintptr_t support... $ECHO_C" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008494have_uintptr_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008495cat >conftest.$ac_ext <<_ACEOF
8496#line $LINENO "configure"
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008497#include "confdefs.h"
8498
Martin v. Löwis11437992002-04-12 09:54:03 +00008499#ifdef F77_DUMMY_MAIN
8500# ifdef __cplusplus
8501 extern "C"
8502# endif
8503 int F77_DUMMY_MAIN() { return 1; }
8504#endif
8505int
8506main ()
8507{
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008508uintptr_t x; x = (uintptr_t)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008509 ;
8510 return 0;
8511}
8512_ACEOF
8513rm -f conftest.$ac_objext
8514if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8515 (eval $ac_compile) 2>&5
8516 ac_status=$?
8517 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8518 (exit $ac_status); } &&
8519 { ac_try='test -s conftest.$ac_objext'
8520 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8521 (eval $ac_try) 2>&5
8522 ac_status=$?
8523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8524 (exit $ac_status); }; }; then
8525
8526
8527cat >>confdefs.h <<\_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008528#define HAVE_UINTPTR_T 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008529_ACEOF
8530
Martin v. Löwisc45929e2002-04-06 10:10:49 +00008531 have_uintptr_t=yes
8532
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008533else
Martin v. Löwis11437992002-04-12 09:54:03 +00008534 echo "$as_me: failed program was:" >&5
8535cat conftest.$ac_ext >&5
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008536fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008537rm -f conftest.$ac_objext conftest.$ac_ext
8538echo "$as_me:$LINENO: result: $have_uintptr_t" >&5
8539echo "${ECHO_T}$have_uintptr_t" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008540if test "$have_uintptr_t" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008541echo "$as_me:$LINENO: checking for uintptr_t" >&5
8542echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6
8543if test "${ac_cv_type_uintptr_t+set}" = set; then
8544 echo $ECHO_N "(cached) $ECHO_C" >&6
8545else
8546 cat >conftest.$ac_ext <<_ACEOF
8547#line $LINENO "configure"
8548#include "confdefs.h"
8549$ac_includes_default
8550#ifdef F77_DUMMY_MAIN
8551# ifdef __cplusplus
8552 extern "C"
8553# endif
8554 int F77_DUMMY_MAIN() { return 1; }
8555#endif
8556int
8557main ()
8558{
8559if ((uintptr_t *) 0)
8560 return 0;
8561if (sizeof (uintptr_t))
8562 return 0;
8563 ;
8564 return 0;
8565}
8566_ACEOF
8567rm -f conftest.$ac_objext
8568if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8569 (eval $ac_compile) 2>&5
8570 ac_status=$?
8571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8572 (exit $ac_status); } &&
8573 { ac_try='test -s conftest.$ac_objext'
8574 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8575 (eval $ac_try) 2>&5
8576 ac_status=$?
8577 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8578 (exit $ac_status); }; }; then
8579 ac_cv_type_uintptr_t=yes
8580else
8581 echo "$as_me: failed program was:" >&5
8582cat conftest.$ac_ext >&5
8583ac_cv_type_uintptr_t=no
8584fi
8585rm -f conftest.$ac_objext conftest.$ac_ext
8586fi
8587echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
8588echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6
8589
8590echo "$as_me:$LINENO: checking size of uintptr_t" >&5
8591echo $ECHO_N "checking size of uintptr_t... $ECHO_C" >&6
8592if test "${ac_cv_sizeof_uintptr_t+set}" = set; then
8593 echo $ECHO_N "(cached) $ECHO_C" >&6
8594else
8595 if test "$ac_cv_type_uintptr_t" = yes; then
8596 # The cast to unsigned long works around a bug in the HP C Compiler
8597 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8598 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8599 # This bug is HP SR number 8606223364.
8600 if test "$cross_compiling" = yes; then
8601 # Depending upon the size, compute the lo and hi bounds.
8602cat >conftest.$ac_ext <<_ACEOF
8603#line $LINENO "configure"
8604#include "confdefs.h"
8605$ac_includes_default
8606#ifdef F77_DUMMY_MAIN
8607# ifdef __cplusplus
8608 extern "C"
8609# endif
8610 int F77_DUMMY_MAIN() { return 1; }
8611#endif
8612int
8613main ()
8614{
8615static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= 0)];
8616test_array [0] = 0
8617
8618 ;
8619 return 0;
8620}
8621_ACEOF
8622rm -f conftest.$ac_objext
8623if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8624 (eval $ac_compile) 2>&5
8625 ac_status=$?
8626 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8627 (exit $ac_status); } &&
8628 { ac_try='test -s conftest.$ac_objext'
8629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8630 (eval $ac_try) 2>&5
8631 ac_status=$?
8632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8633 (exit $ac_status); }; }; then
8634 ac_lo=0 ac_mid=0
8635 while :; do
8636 cat >conftest.$ac_ext <<_ACEOF
8637#line $LINENO "configure"
8638#include "confdefs.h"
8639$ac_includes_default
8640#ifdef F77_DUMMY_MAIN
8641# ifdef __cplusplus
8642 extern "C"
8643# endif
8644 int F77_DUMMY_MAIN() { return 1; }
8645#endif
8646int
8647main ()
8648{
8649static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
8650test_array [0] = 0
8651
8652 ;
8653 return 0;
8654}
8655_ACEOF
8656rm -f conftest.$ac_objext
8657if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8658 (eval $ac_compile) 2>&5
8659 ac_status=$?
8660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8661 (exit $ac_status); } &&
8662 { ac_try='test -s conftest.$ac_objext'
8663 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8664 (eval $ac_try) 2>&5
8665 ac_status=$?
8666 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8667 (exit $ac_status); }; }; then
8668 ac_hi=$ac_mid; break
8669else
8670 echo "$as_me: failed program was:" >&5
8671cat conftest.$ac_ext >&5
8672ac_lo=`expr $ac_mid + 1`
8673 if test $ac_lo -le $ac_mid; then
8674 ac_lo= ac_hi=
8675 break
8676 fi
8677 ac_mid=`expr 2 '*' $ac_mid + 1`
8678fi
8679rm -f conftest.$ac_objext conftest.$ac_ext
8680 done
8681else
8682 echo "$as_me: failed program was:" >&5
8683cat conftest.$ac_ext >&5
8684cat >conftest.$ac_ext <<_ACEOF
8685#line $LINENO "configure"
8686#include "confdefs.h"
8687$ac_includes_default
8688#ifdef F77_DUMMY_MAIN
8689# ifdef __cplusplus
8690 extern "C"
8691# endif
8692 int F77_DUMMY_MAIN() { return 1; }
8693#endif
8694int
8695main ()
8696{
8697static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) < 0)];
8698test_array [0] = 0
8699
8700 ;
8701 return 0;
8702}
8703_ACEOF
8704rm -f conftest.$ac_objext
8705if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8706 (eval $ac_compile) 2>&5
8707 ac_status=$?
8708 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8709 (exit $ac_status); } &&
8710 { ac_try='test -s conftest.$ac_objext'
8711 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8712 (eval $ac_try) 2>&5
8713 ac_status=$?
8714 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8715 (exit $ac_status); }; }; then
8716 ac_hi=-1 ac_mid=-1
8717 while :; do
8718 cat >conftest.$ac_ext <<_ACEOF
8719#line $LINENO "configure"
8720#include "confdefs.h"
8721$ac_includes_default
8722#ifdef F77_DUMMY_MAIN
8723# ifdef __cplusplus
8724 extern "C"
8725# endif
8726 int F77_DUMMY_MAIN() { return 1; }
8727#endif
8728int
8729main ()
8730{
8731static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= $ac_mid)];
8732test_array [0] = 0
8733
8734 ;
8735 return 0;
8736}
8737_ACEOF
8738rm -f conftest.$ac_objext
8739if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8740 (eval $ac_compile) 2>&5
8741 ac_status=$?
8742 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8743 (exit $ac_status); } &&
8744 { ac_try='test -s conftest.$ac_objext'
8745 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8746 (eval $ac_try) 2>&5
8747 ac_status=$?
8748 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8749 (exit $ac_status); }; }; then
8750 ac_lo=$ac_mid; break
8751else
8752 echo "$as_me: failed program was:" >&5
8753cat conftest.$ac_ext >&5
8754ac_hi=`expr '(' $ac_mid ')' - 1`
8755 if test $ac_mid -le $ac_hi; then
8756 ac_lo= ac_hi=
8757 break
8758 fi
8759 ac_mid=`expr 2 '*' $ac_mid`
8760fi
8761rm -f conftest.$ac_objext conftest.$ac_ext
8762 done
8763else
8764 echo "$as_me: failed program was:" >&5
8765cat conftest.$ac_ext >&5
8766ac_lo= ac_hi=
8767fi
8768rm -f conftest.$ac_objext conftest.$ac_ext
8769fi
8770rm -f conftest.$ac_objext conftest.$ac_ext
8771# Binary search between lo and hi bounds.
8772while test "x$ac_lo" != "x$ac_hi"; do
8773 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8774 cat >conftest.$ac_ext <<_ACEOF
8775#line $LINENO "configure"
8776#include "confdefs.h"
8777$ac_includes_default
8778#ifdef F77_DUMMY_MAIN
8779# ifdef __cplusplus
8780 extern "C"
8781# endif
8782 int F77_DUMMY_MAIN() { return 1; }
8783#endif
8784int
8785main ()
8786{
8787static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
8788test_array [0] = 0
8789
8790 ;
8791 return 0;
8792}
8793_ACEOF
8794rm -f conftest.$ac_objext
8795if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8796 (eval $ac_compile) 2>&5
8797 ac_status=$?
8798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8799 (exit $ac_status); } &&
8800 { ac_try='test -s conftest.$ac_objext'
8801 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8802 (eval $ac_try) 2>&5
8803 ac_status=$?
8804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8805 (exit $ac_status); }; }; then
8806 ac_hi=$ac_mid
8807else
8808 echo "$as_me: failed program was:" >&5
8809cat conftest.$ac_ext >&5
8810ac_lo=`expr '(' $ac_mid ')' + 1`
8811fi
8812rm -f conftest.$ac_objext conftest.$ac_ext
8813done
8814case $ac_lo in
8815?*) ac_cv_sizeof_uintptr_t=$ac_lo;;
8816'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77" >&5
8817echo "$as_me: error: cannot compute sizeof (uintptr_t), 77" >&2;}
8818 { (exit 1); exit 1; }; } ;;
8819esac
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008820else
8821 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008822 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
8823echo "$as_me: error: cannot run test program while cross compiling" >&2;}
8824 { (exit 1); exit 1; }; }
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008825else
Martin v. Löwis11437992002-04-12 09:54:03 +00008826 cat >conftest.$ac_ext <<_ACEOF
8827#line $LINENO "configure"
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008828#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008829$ac_includes_default
8830long longval () { return (long) (sizeof (uintptr_t)); }
8831unsigned long ulongval () { return (long) (sizeof (uintptr_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008832#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008833#include <stdlib.h>
8834#ifdef F77_DUMMY_MAIN
8835# ifdef __cplusplus
8836 extern "C"
8837# endif
8838 int F77_DUMMY_MAIN() { return 1; }
8839#endif
8840int
8841main ()
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008842{
Martin v. Löwis11437992002-04-12 09:54:03 +00008843
8844 FILE *f = fopen ("conftest.val", "w");
8845 if (! f)
8846 exit (1);
8847 if (((long) (sizeof (uintptr_t))) < 0)
8848 {
8849 long i = longval ();
8850 if (i != ((long) (sizeof (uintptr_t))))
8851 exit (1);
8852 fprintf (f, "%ld\n", i);
8853 }
8854 else
8855 {
8856 unsigned long i = ulongval ();
8857 if (i != ((long) (sizeof (uintptr_t))))
8858 exit (1);
8859 fprintf (f, "%lu\n", i);
8860 }
8861 exit (ferror (f) || fclose (f) != 0);
8862
8863 ;
8864 return 0;
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008865}
Martin v. Löwis11437992002-04-12 09:54:03 +00008866_ACEOF
8867rm -f conftest$ac_exeext
8868if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8869 (eval $ac_link) 2>&5
8870 ac_status=$?
8871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8872 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8873 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8874 (eval $ac_try) 2>&5
8875 ac_status=$?
8876 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8877 (exit $ac_status); }; }; then
8878 ac_cv_sizeof_uintptr_t=`cat conftest.val`
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008879else
Martin v. Löwis11437992002-04-12 09:54:03 +00008880 echo "$as_me: program exited with status $ac_status" >&5
8881echo "$as_me: failed program was:" >&5
8882cat conftest.$ac_ext >&5
8883( exit $ac_status )
8884{ { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77" >&5
8885echo "$as_me: error: cannot compute sizeof (uintptr_t), 77" >&2;}
8886 { (exit 1); exit 1; }; }
8887fi
8888rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8889fi
8890fi
8891rm -f conftest.val
8892else
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008893 ac_cv_sizeof_uintptr_t=0
8894fi
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008895fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008896echo "$as_me:$LINENO: result: $ac_cv_sizeof_uintptr_t" >&5
8897echo "${ECHO_T}$ac_cv_sizeof_uintptr_t" >&6
8898cat >>confdefs.h <<_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008899#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008900_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008901
Michael W. Hudson54241132001-12-07 15:38:26 +00008902
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008903fi
8904
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008905# Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008906echo "$as_me:$LINENO: checking size of off_t" >&5
8907echo $ECHO_N "checking size of off_t... $ECHO_C" >&6
8908if test "${ac_cv_sizeof_off_t+set}" = set; then
8909 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008910else
8911 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008912 ac_cv_sizeof_off_t=4
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008913else
Martin v. Löwis11437992002-04-12 09:54:03 +00008914 cat >conftest.$ac_ext <<_ACEOF
8915#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008916#include "confdefs.h"
8917#include <stdio.h>
8918#include <sys/types.h>
8919main()
8920{
8921 FILE *f=fopen("conftestval", "w");
8922 if (!f) exit(1);
8923 fprintf(f, "%d\n", sizeof(off_t));
8924 exit(0);
8925}
Martin v. Löwis11437992002-04-12 09:54:03 +00008926_ACEOF
8927rm -f conftest$ac_exeext
8928if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8929 (eval $ac_link) 2>&5
8930 ac_status=$?
8931 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8932 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8933 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8934 (eval $ac_try) 2>&5
8935 ac_status=$?
8936 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8937 (exit $ac_status); }; }; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008938 ac_cv_sizeof_off_t=`cat conftestval`
8939else
Martin v. Löwis11437992002-04-12 09:54:03 +00008940 echo "$as_me: program exited with status $ac_status" >&5
8941echo "$as_me: failed program was:" >&5
8942cat conftest.$ac_ext >&5
8943( exit $ac_status )
8944ac_cv_sizeof_off_t=0
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008945fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008946rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008947fi
8948
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008949fi
8950
Martin v. Löwis11437992002-04-12 09:54:03 +00008951echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
8952echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6
8953
8954cat >>confdefs.h <<_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008955#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008956_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008957
Michael W. Hudson54241132001-12-07 15:38:26 +00008958
Martin v. Löwis11437992002-04-12 09:54:03 +00008959echo "$as_me:$LINENO: checking whether to enable large file support" >&5
8960echo $ECHO_N "checking whether to enable large file support... $ECHO_C" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00008961if test "$have_long_long" = yes -a \
8962 "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
8963 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008964
Martin v. Löwis11437992002-04-12 09:54:03 +00008965cat >>confdefs.h <<\_ACEOF
8966#define HAVE_LARGEFILE_SUPPORT 1
8967_ACEOF
8968
8969 echo "$as_me:$LINENO: result: yes" >&5
8970echo "${ECHO_T}yes" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008971else
Martin v. Löwis11437992002-04-12 09:54:03 +00008972 echo "$as_me:$LINENO: result: no" >&5
8973echo "${ECHO_T}no" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008974fi
8975
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008976# AC_CHECK_SIZEOF() doesn't include <time.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008977echo "$as_me:$LINENO: checking size of time_t" >&5
8978echo $ECHO_N "checking size of time_t... $ECHO_C" >&6
8979if test "${ac_cv_sizeof_time_t+set}" = set; then
8980 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008981else
8982 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008983 ac_cv_sizeof_time_t=4
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008984else
Martin v. Löwis11437992002-04-12 09:54:03 +00008985 cat >conftest.$ac_ext <<_ACEOF
8986#line $LINENO "configure"
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008987#include "confdefs.h"
8988#include <stdio.h>
8989#include <time.h>
8990main()
8991{
8992 FILE *f=fopen("conftestval", "w");
8993 if (!f) exit(1);
8994 fprintf(f, "%d\n", sizeof(time_t));
8995 exit(0);
8996}
Martin v. Löwis11437992002-04-12 09:54:03 +00008997_ACEOF
8998rm -f conftest$ac_exeext
8999if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9000 (eval $ac_link) 2>&5
9001 ac_status=$?
9002 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9003 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9004 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9005 (eval $ac_try) 2>&5
9006 ac_status=$?
9007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9008 (exit $ac_status); }; }; then
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009009 ac_cv_sizeof_time_t=`cat conftestval`
9010else
Martin v. Löwis11437992002-04-12 09:54:03 +00009011 echo "$as_me: program exited with status $ac_status" >&5
9012echo "$as_me: failed program was:" >&5
9013cat conftest.$ac_ext >&5
9014( exit $ac_status )
9015ac_cv_sizeof_time_t=0
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009016fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009017rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009018fi
9019
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009020fi
9021
Martin v. Löwis11437992002-04-12 09:54:03 +00009022echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5
9023echo "${ECHO_T}$ac_cv_sizeof_time_t" >&6
9024
9025cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009026#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009027_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00009028
Michael W. Hudson54241132001-12-07 15:38:26 +00009029
9030
Trent Mick635f6fb2000-08-23 21:33:05 +00009031# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +00009032ac_save_cc="$CC"
9033if test "$ac_cv_kpthread" = "yes"
9034then CC="$CC -Kpthread"
9035fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009036echo "$as_me:$LINENO: checking for pthread_t" >&5
9037echo $ECHO_N "checking for pthread_t... $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009038have_pthread_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009039cat >conftest.$ac_ext <<_ACEOF
9040#line $LINENO "configure"
Trent Mick635f6fb2000-08-23 21:33:05 +00009041#include "confdefs.h"
9042#include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009043#ifdef F77_DUMMY_MAIN
9044# ifdef __cplusplus
9045 extern "C"
9046# endif
9047 int F77_DUMMY_MAIN() { return 1; }
9048#endif
9049int
9050main ()
9051{
Guido van Rossum12580492000-09-24 16:47:19 +00009052pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009053 ;
9054 return 0;
9055}
9056_ACEOF
9057rm -f conftest.$ac_objext
9058if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9059 (eval $ac_compile) 2>&5
9060 ac_status=$?
9061 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9062 (exit $ac_status); } &&
9063 { ac_try='test -s conftest.$ac_objext'
9064 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9065 (eval $ac_try) 2>&5
9066 ac_status=$?
9067 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9068 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00009069 have_pthread_t=yes
9070else
Martin v. Löwis11437992002-04-12 09:54:03 +00009071 echo "$as_me: failed program was:" >&5
9072cat conftest.$ac_ext >&5
Trent Mick635f6fb2000-08-23 21:33:05 +00009073fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009074rm -f conftest.$ac_objext conftest.$ac_ext
9075echo "$as_me:$LINENO: result: $have_pthread_t" >&5
9076echo "${ECHO_T}$have_pthread_t" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009077if test "$have_pthread_t" = yes ; then
9078 # AC_CHECK_SIZEOF() doesn't include <pthread.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00009079 echo "$as_me:$LINENO: checking size of pthread_t" >&5
9080echo $ECHO_N "checking size of pthread_t... $ECHO_C" >&6
9081 if test "${ac_cv_sizeof_pthread_t+set}" = set; then
9082 echo $ECHO_N "(cached) $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009083else
9084 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00009085 ac_cv_sizeof_pthread_t=4
Trent Mick635f6fb2000-08-23 21:33:05 +00009086else
Martin v. Löwis11437992002-04-12 09:54:03 +00009087 cat >conftest.$ac_ext <<_ACEOF
9088#line $LINENO "configure"
Trent Mick635f6fb2000-08-23 21:33:05 +00009089#include "confdefs.h"
9090#include <stdio.h>
9091 #include <pthread.h>
9092 main()
9093 {
9094 FILE *f=fopen("conftestval", "w");
9095 if (!f) exit(1);
9096 fprintf(f, "%d\n", sizeof(pthread_t));
9097 exit(0);
9098 }
Martin v. Löwis11437992002-04-12 09:54:03 +00009099_ACEOF
9100rm -f conftest$ac_exeext
9101if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9102 (eval $ac_link) 2>&5
9103 ac_status=$?
9104 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9105 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9106 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9107 (eval $ac_try) 2>&5
9108 ac_status=$?
9109 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9110 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00009111 ac_cv_sizeof_pthread_t=`cat conftestval`
9112else
Martin v. Löwis11437992002-04-12 09:54:03 +00009113 echo "$as_me: program exited with status $ac_status" >&5
9114echo "$as_me: failed program was:" >&5
9115cat conftest.$ac_ext >&5
9116( exit $ac_status )
9117ac_cv_sizeof_pthread_t=0
Trent Mick635f6fb2000-08-23 21:33:05 +00009118fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009119rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Trent Mick635f6fb2000-08-23 21:33:05 +00009120fi
9121
Trent Mick635f6fb2000-08-23 21:33:05 +00009122fi
9123
Martin v. Löwis11437992002-04-12 09:54:03 +00009124 echo "$as_me:$LINENO: result: $ac_cv_sizeof_pthread_t" >&5
9125echo "${ECHO_T}$ac_cv_sizeof_pthread_t" >&6
9126
9127cat >>confdefs.h <<_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00009128#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009129_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00009130
9131fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +00009132CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +00009133
Martin v. Löwis11437992002-04-12 09:54:03 +00009134echo "$as_me:$LINENO: checking for --enable-toolbox-glue" >&5
9135echo $ECHO_N "checking for --enable-toolbox-glue... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009136# Check whether --enable-toolbox-glue or --disable-toolbox-glue was given.
9137if test "${enable_toolbox_glue+set}" = set; then
9138 enableval="$enable_toolbox_glue"
Jack Jansene578a632001-08-15 01:27:14 +00009139
Martin v. Löwis11437992002-04-12 09:54:03 +00009140fi;
Jack Jansene578a632001-08-15 01:27:14 +00009141
9142if test -z "$enable_toolbox_glue"
Martin v. Löwis11437992002-04-12 09:54:03 +00009143then
Jack Jansene578a632001-08-15 01:27:14 +00009144 case $ac_sys_system/$ac_sys_release in
9145 Darwin/*)
9146 enable_toolbox_glue="yes";;
9147 *)
9148 enable_toolbox_glue="no";;
9149 esac
9150fi
9151case "$enable_toolbox_glue" in
9152yes)
Jack Jansen666b1e72001-10-31 12:11:48 +00009153 extra_frameworks="-framework CoreServices -framework Foundation"
Jack Jansene578a632001-08-15 01:27:14 +00009154 extra_machdep_objs="Python/mactoolboxglue.o"
Jack Jansen591cbed2001-08-15 13:55:15 +00009155 extra_undefs="-u __dummy -u _PyMac_Error"
Martin v. Löwis11437992002-04-12 09:54:03 +00009156
9157cat >>confdefs.h <<\_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00009158#define USE_TOOLBOX_OBJECT_GLUE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009159_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00009160
9161 ;;
9162*)
9163 extra_frameworks=""
9164 extra_machdep_objs=""
Jack Jansen591cbed2001-08-15 13:55:15 +00009165 extra_undefs=""
Jack Jansene578a632001-08-15 01:27:14 +00009166 ;;
9167esac
Martin v. Löwis11437992002-04-12 09:54:03 +00009168echo "$as_me:$LINENO: result: $enable_toolbox_glue" >&5
9169echo "${ECHO_T}$enable_toolbox_glue" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00009170
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009171
9172case $ac_sys_system/$ac_sys_release in
Jack Jansen418c3b12001-11-14 10:59:57 +00009173 Darwin/1.3*)
Jack Jansenea0c3822002-08-01 21:57:49 +00009174 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00009175 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansena3891ea2001-09-07 14:25:12 +00009176 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Python'
9177 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +00009178 Darwin/*)
Jack Jansenea0c3822002-08-01 21:57:49 +00009179 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00009180 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansene578a632001-08-15 01:27:14 +00009181 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Python'
9182 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009183esac
9184
Martin v. Löwis11437992002-04-12 09:54:03 +00009185echo "$as_me:$LINENO: checking for --enable-framework" >&5
9186echo $ECHO_N "checking for --enable-framework... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009187if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009188then
Jack Jansenca06bc62001-08-03 15:32:23 +00009189 OPT="$OPT -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +00009190 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +00009191 # in the build location.
Jack Jansenea0c3822002-08-01 21:57:49 +00009192 LDFLAGS="$LDFLAGS -Wl,-F."
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009193
Martin v. Löwis11437992002-04-12 09:54:03 +00009194cat >>confdefs.h <<\_ACEOF
9195#define WITH_NEXT_FRAMEWORK 1
9196_ACEOF
9197
9198 echo "$as_me:$LINENO: result: yes" >&5
9199echo "${ECHO_T}yes" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009200else
Martin v. Löwis11437992002-04-12 09:54:03 +00009201 echo "$as_me:$LINENO: result: no" >&5
9202echo "${ECHO_T}no" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009203fi
9204
Martin v. Löwis11437992002-04-12 09:54:03 +00009205echo "$as_me:$LINENO: checking for dyld" >&5
9206echo $ECHO_N "checking for dyld... $ECHO_C" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009207case $ac_sys_system/$ac_sys_release in
9208 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009209
Martin v. Löwis11437992002-04-12 09:54:03 +00009210cat >>confdefs.h <<\_ACEOF
9211#define WITH_DYLD 1
9212_ACEOF
9213
9214 echo "$as_me:$LINENO: result: always on for Darwin" >&5
9215echo "${ECHO_T}always on for Darwin" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009216 ;;
9217 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00009218 echo "$as_me:$LINENO: result: no" >&5
9219echo "${ECHO_T}no" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009220 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009221esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009222
Guido van Rossum0a516c91994-09-12 10:58:40 +00009223# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +00009224
Michael W. Hudson54241132001-12-07 15:38:26 +00009225
9226
9227
9228
Guido van Rossum0a516c91994-09-12 10:58:40 +00009229# SO is the extension of shared libraries `(including the dot!)
Guido van Rossumaef734b2001-01-10 21:09:12 +00009230# -- usually .so, .sl on HP-UX, .dll on Cygwin
Martin v. Löwis11437992002-04-12 09:54:03 +00009231echo "$as_me:$LINENO: checking SO" >&5
9232echo $ECHO_N "checking SO... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009233if test -z "$SO"
9234then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009235 case $ac_sys_system in
Guido van Rossum563e7081996-09-10 18:20:48 +00009236 hp*|HP*) SO=.sl;;
Guido van Rossumaef734b2001-01-10 21:09:12 +00009237 CYGWIN*) SO=.dll;;
Guido van Rossum563e7081996-09-10 18:20:48 +00009238 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009239 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009240fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009241echo "$as_me:$LINENO: result: $SO" >&5
9242echo "${ECHO_T}$SO" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009243# LDSHARED is the ld *command* used to create shared library
Martin v. Löwis5b718fc2001-09-10 15:34:42 +00009244# -- "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 +00009245# (Shared libraries in this instance are shared modules to be loaded into
9246# Python, as opposed to building Python itself as a shared library.)
Martin v. Löwis11437992002-04-12 09:54:03 +00009247echo "$as_me:$LINENO: checking LDSHARED" >&5
9248echo $ECHO_N "checking LDSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009249if test -z "$LDSHARED"
9250then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009251 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009252 AIX*)
9253 BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Guido van Rossumce608b02001-09-28 15:59:38 +00009254 LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009255 ;;
9256 BeOS*)
9257 BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY"
Guido van Rossumce608b02001-09-28 15:59:38 +00009258 LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009259 ;;
Guido van Rossum07397971997-04-29 21:49:50 +00009260 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +00009261 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009262 SunOS/4*) LDSHARED="ld";;
Martin v. Löwis11437992002-04-12 09:54:03 +00009263 SunOS/5*)
Greg Ward57c9a6632000-05-26 12:22:54 +00009264 if test "$GCC" = "yes"
Neil Schemenauer8ba94452001-02-19 18:18:48 +00009265 then LDSHARED='$(CC) -shared'
Martin v. Löwisaa5afe12002-10-07 06:21:41 +00009266 else LDSHARED='$(CC) -G';
Greg Ward57c9a6632000-05-26 12:22:54 +00009267 fi ;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009268 hp*|HP*) LDSHARED="ld -b";;
Guido van Rossumda88dad1995-01-26 00:46:29 +00009269 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
9270 DYNIX/ptx*) LDSHARED="ld -G";;
Jack Jansen418c3b12001-11-14 10:59:57 +00009271 Darwin/1.3*)
Jack Jansena3891ea2001-09-07 14:25:12 +00009272 LDSHARED='$(CC) $(LDFLAGS) -bundle'
9273 if test "$enable_framework" ; then
9274 # Link against the framework. All externals should be defined.
9275 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
9276 else
9277 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +00009278 LDSHARED="$LDSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +00009279 fi ;;
Jack Jansene578a632001-08-15 01:27:14 +00009280 Darwin/*)
9281 LDSHARED='$(CC) $(LDFLAGS) -bundle'
9282 if test "$enable_framework" ; then
9283 # Link against the framework. All externals should be defined.
9284 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
9285 else
Michael W. Hudson594bc802002-03-07 09:59:15 +00009286 # No framework, use the Python app as bundle-loader
9287 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
9288 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/$(PYTHON)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009289 fi ;;
Martin v. Löwis3cba5c02002-09-16 17:50:59 +00009290 Linux*|GNU*) LDSHARED='$(CC) -shared';;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00009291 dgux*) LDSHARED="ld -G";;
Guido van Rossum458e7fa1999-09-17 15:40:40 +00009292 BSD/OS*/4*) LDSHARED="gcc -shared";;
Martin v. Löwisd61888b2002-09-30 11:17:27 +00009293 OpenBSD*|FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +00009294 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +00009295 then
9296 LDSHARED="cc -shared ${LDFLAGS}"
9297 else
9298 LDSHARED="ld -Bshareable ${LDFLAGS}"
9299 fi;;
Martin v. Löwisd61888b2002-09-30 11:17:27 +00009300 NetBSD*) LDSHARED="cc -shared ${LDFLAGS}";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009301 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +00009302 if test "$GCC" = "yes"
Martin v. Löwis79f3c532002-12-11 12:51:58 +00009303 then LDSHARED='$(CC) -shared'
9304 else LDSHARED='$(CC) -G'
Martin v. Löwisbec19582001-03-21 15:57:54 +00009305 fi;;
Martin v. Löwis79f3c532002-12-11 12:51:58 +00009306 SCO_SV*) LDSHARED='$(CC) -Wl,-G,-Bexport';;
Trent Mick635f6fb2000-08-23 21:33:05 +00009307 Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00009308 CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009309 atheos*) LDSHARED="gcc -shared";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009310 *) LDSHARED="ld";;
9311 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009312fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009313echo "$as_me:$LINENO: result: $LDSHARED" >&5
9314echo "${ECHO_T}$LDSHARED" >&6
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009315BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +00009316# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009317# library (module) -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +00009318echo "$as_me:$LINENO: checking CCSHARED" >&5
9319echo $ECHO_N "checking CCSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009320if test -z "$CCSHARED"
9321then
Guido van Rossum07397971997-04-29 21:49:50 +00009322 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +00009323 SunOS*) if test "$GCC" = yes;
9324 then CCSHARED="-fPIC";
9325 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +00009326 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +00009327 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +00009328 else CCSHARED="+z";
9329 fi;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009330 Linux*|GNU*) CCSHARED="-fPIC";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +00009331 BSD/OS*/4*) CCSHARED="-fpic";;
Martin v. Löwis36546db2001-09-05 14:24:43 +00009332 FreeBSD*|NetBSD*|OpenBSD*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009333 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +00009334 if test "$GCC" = "yes"
9335 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009336 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +00009337 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00009338 SCO_SV*)
9339 if test "$GCC" = "yes"
9340 then CCSHARED="-fPIC"
9341 else CCSHARED="-Kpic -belf"
9342 fi;;
Trent Mick635f6fb2000-08-23 21:33:05 +00009343 Monterey*) CCSHARED="-G";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009344 IRIX*/6*) case $CC in
9345 *gcc*) CCSHARED="-shared";;
Guido van Rossumee21f411998-04-20 18:51:54 +00009346 *) CCSHARED="";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009347 esac;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009348 atheos*) CCSHARED="-fPIC";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009349 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009350fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009351echo "$as_me:$LINENO: result: $CCSHARED" >&5
9352echo "${ECHO_T}$CCSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009353# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009354# the python executable -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +00009355echo "$as_me:$LINENO: checking LINKFORSHARED" >&5
9356echo $ECHO_N "checking LINKFORSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009357if test -z "$LINKFORSHARED"
9358then
Guido van Rossum07397971997-04-29 21:49:50 +00009359 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009360 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009361 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00009362 LINKFORSHARED="-Wl,-E -Wl,+s";;
9363# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +00009364 BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009365 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009366 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +00009367 Darwin/*)
Jack Jansene578a632001-08-15 01:27:14 +00009368 # -u __dummy makes the linker aware of the objc runtime
9369 # in System.framework; otherwise, __objcInit (referenced in
9370 # crt1.o) gets erroneously defined as common, which breaks dynamic
9371 # loading of any modules which reference it in System.framework.
9372 # -u _PyMac_Error is needed to pull in the mac toolbox glue, which is
9373 # not used by the core itself but which needs to be in the core so
9374 # that dynamically loaded extension modules have access to it.
Jack Jansen591cbed2001-08-15 13:55:15 +00009375 LINKFORSHARED="$extra_undefs -framework System"
Jack Jansene578a632001-08-15 01:27:14 +00009376 if test "$enable_framework"
9377 then
9378 LINKFORSHARED="$LINKFORSHARED -framework Python"
9379 fi
9380 LINKFORSHARED="$LINKFORSHARED $extra_frameworks";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009381 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00009382 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +00009383 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis11437992002-04-12 09:54:03 +00009384 FreeBSD*|NetBSD*|OpenBSD*)
Guido van Rossumdf693651999-01-07 21:50:41 +00009385 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
9386 then
9387 LINKFORSHARED="-Wl,--export-dynamic"
9388 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009389 SunOS/5*) case $CC in
9390 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +00009391 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +00009392 then
9393 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009394 fi;;
9395 esac;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009396 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009397fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009398echo "$as_me:$LINENO: result: $LINKFORSHARED" >&5
9399echo "${ECHO_T}$LINKFORSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009400
Michael W. Hudson54241132001-12-07 15:38:26 +00009401
Martin v. Löwis11437992002-04-12 09:54:03 +00009402echo "$as_me:$LINENO: checking CFLAGSFORSHARED" >&5
9403echo $ECHO_N "checking CFLAGSFORSHARED... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009404if test ! "$LIBRARY" = "$LDLIBRARY"
9405then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +00009406 case $ac_sys_system in
9407 CYGWIN*)
9408 # Cygwin needs CCSHARED when building extension DLLs
9409 # but not when building the interpreter DLL.
9410 CFLAGSFORSHARED='';;
9411 *)
9412 CFLAGSFORSHARED='$(CCSHARED)'
9413 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009414fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009415echo "$as_me:$LINENO: result: $CFLAGSFORSHARED" >&5
9416echo "${ECHO_T}$CFLAGSFORSHARED" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009417
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009418# SHLIBS are libraries (except -lc and -lm) to link to the python shared
9419# library (with --enable-shared).
9420# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +00009421# symbols, this must be set to $(LIBS) (expanded by make). We do this even
9422# if it is not required, since it creates a dependency of the shared library
9423# to LIBS. This, in turn, means that applications linking the shared libpython
9424# don't need to link LIBS explicitly. The default should be only changed
9425# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009426
9427echo "$as_me:$LINENO: checking SHLIBS" >&5
9428echo $ECHO_N "checking SHLIBS... $ECHO_C" >&6
9429case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009430 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +00009431 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009432esac
9433echo "$as_me:$LINENO: result: $SHLIBS" >&5
9434echo "${ECHO_T}$SHLIBS" >&6
9435
9436
Guido van Rossum627b2d71993-12-24 10:39:16 +00009437# checks for libraries
Martin v. Löwis11437992002-04-12 09:54:03 +00009438
9439echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9440echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9441if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9442 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009443else
Martin v. Löwis11437992002-04-12 09:54:03 +00009444 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009445LIBS="-ldl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009446cat >conftest.$ac_ext <<_ACEOF
9447#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00009448#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009449
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009450/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009451#ifdef __cplusplus
9452extern "C"
9453#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009454/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009455 builtin and then its argument prototype would still apply. */
9456char dlopen ();
9457#ifdef F77_DUMMY_MAIN
9458# ifdef __cplusplus
9459 extern "C"
9460# endif
9461 int F77_DUMMY_MAIN() { return 1; }
9462#endif
9463int
9464main ()
9465{
9466dlopen ();
9467 ;
9468 return 0;
9469}
9470_ACEOF
9471rm -f conftest.$ac_objext conftest$ac_exeext
9472if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9473 (eval $ac_link) 2>&5
9474 ac_status=$?
9475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9476 (exit $ac_status); } &&
9477 { ac_try='test -s conftest$ac_exeext'
9478 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9479 (eval $ac_try) 2>&5
9480 ac_status=$?
9481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9482 (exit $ac_status); }; }; then
9483 ac_cv_lib_dl_dlopen=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009484else
Martin v. Löwis11437992002-04-12 09:54:03 +00009485 echo "$as_me: failed program was:" >&5
9486cat conftest.$ac_ext >&5
9487ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00009488fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009489rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9490LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +00009491fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009492echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9493echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9494if test $ac_cv_lib_dl_dlopen = yes; then
9495 cat >>confdefs.h <<_ACEOF
9496#define HAVE_LIBDL 1
9497_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00009498
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009499 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00009500
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009501fi
9502 # Dynamic linking for SunOS/Solaris and SYSV
Martin v. Löwis11437992002-04-12 09:54:03 +00009503
9504echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9505echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9506if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9507 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009508else
Martin v. Löwis11437992002-04-12 09:54:03 +00009509 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009510LIBS="-ldld $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009511cat >conftest.$ac_ext <<_ACEOF
9512#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00009513#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009514
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009515/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009516#ifdef __cplusplus
9517extern "C"
9518#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009519/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009520 builtin and then its argument prototype would still apply. */
9521char shl_load ();
9522#ifdef F77_DUMMY_MAIN
9523# ifdef __cplusplus
9524 extern "C"
9525# endif
9526 int F77_DUMMY_MAIN() { return 1; }
9527#endif
9528int
9529main ()
9530{
9531shl_load ();
9532 ;
9533 return 0;
9534}
9535_ACEOF
9536rm -f conftest.$ac_objext conftest$ac_exeext
9537if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9538 (eval $ac_link) 2>&5
9539 ac_status=$?
9540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9541 (exit $ac_status); } &&
9542 { ac_try='test -s conftest$ac_exeext'
9543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9544 (eval $ac_try) 2>&5
9545 ac_status=$?
9546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9547 (exit $ac_status); }; }; then
9548 ac_cv_lib_dld_shl_load=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009549else
Martin v. Löwis11437992002-04-12 09:54:03 +00009550 echo "$as_me: failed program was:" >&5
9551cat conftest.$ac_ext >&5
9552ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00009553fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009554rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9555LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +00009556fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009557echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9558echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9559if test $ac_cv_lib_dld_shl_load = yes; then
9560 cat >>confdefs.h <<_ACEOF
9561#define HAVE_LIBDLD 1
9562_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00009563
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009564 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009565
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009566fi
9567 # Dynamic linking for HP-UX
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009568echo "$as_me:$LINENO: checking for library containing sem_init" >&5
9569echo $ECHO_N "checking for library containing sem_init... $ECHO_C" >&6
9570if test "${ac_cv_search_sem_init+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009571 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009572else
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009573 ac_func_search_save_LIBS=$LIBS
9574ac_cv_search_sem_init=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009575cat >conftest.$ac_ext <<_ACEOF
9576#line $LINENO "configure"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009577#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009578
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009579/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009580#ifdef __cplusplus
9581extern "C"
9582#endif
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009583/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009584 builtin and then its argument prototype would still apply. */
9585char sem_init ();
9586#ifdef F77_DUMMY_MAIN
9587# ifdef __cplusplus
9588 extern "C"
9589# endif
9590 int F77_DUMMY_MAIN() { return 1; }
9591#endif
9592int
9593main ()
9594{
9595sem_init ();
9596 ;
9597 return 0;
9598}
9599_ACEOF
9600rm -f conftest.$ac_objext conftest$ac_exeext
9601if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9602 (eval $ac_link) 2>&5
9603 ac_status=$?
9604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9605 (exit $ac_status); } &&
9606 { ac_try='test -s conftest$ac_exeext'
9607 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9608 (eval $ac_try) 2>&5
9609 ac_status=$?
9610 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9611 (exit $ac_status); }; }; then
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009612 ac_cv_search_sem_init="none required"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009613else
Martin v. Löwis11437992002-04-12 09:54:03 +00009614 echo "$as_me: failed program was:" >&5
9615cat conftest.$ac_ext >&5
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009616fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009617rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009618if test "$ac_cv_search_sem_init" = no; then
9619 for ac_lib in rt posix4; do
9620 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9621 cat >conftest.$ac_ext <<_ACEOF
9622#line $LINENO "configure"
9623#include "confdefs.h"
9624
9625/* Override any gcc2 internal prototype to avoid an error. */
9626#ifdef __cplusplus
9627extern "C"
9628#endif
9629/* We use char because int might match the return type of a gcc2
9630 builtin and then its argument prototype would still apply. */
9631char sem_init ();
9632#ifdef F77_DUMMY_MAIN
9633# ifdef __cplusplus
9634 extern "C"
9635# endif
9636 int F77_DUMMY_MAIN() { return 1; }
9637#endif
9638int
9639main ()
9640{
9641sem_init ();
9642 ;
9643 return 0;
9644}
Martin v. Löwis11437992002-04-12 09:54:03 +00009645_ACEOF
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009646rm -f conftest.$ac_objext conftest$ac_exeext
9647if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9648 (eval $ac_link) 2>&5
9649 ac_status=$?
9650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9651 (exit $ac_status); } &&
9652 { ac_try='test -s conftest$ac_exeext'
9653 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9654 (eval $ac_try) 2>&5
9655 ac_status=$?
9656 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9657 (exit $ac_status); }; }; then
9658 ac_cv_search_sem_init="-l$ac_lib"
9659break
9660else
9661 echo "$as_me: failed program was:" >&5
9662cat conftest.$ac_ext >&5
9663fi
9664rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9665 done
9666fi
9667LIBS=$ac_func_search_save_LIBS
9668fi
9669echo "$as_me:$LINENO: result: $ac_cv_search_sem_init" >&5
9670echo "${ECHO_T}$ac_cv_search_sem_init" >&6
9671if test "$ac_cv_search_sem_init" != no; then
9672 test "$ac_cv_search_sem_init" = "none required" || LIBS="$ac_cv_search_sem_init $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009673
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009674fi
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009675 # 'Real Time' functions on Solaris,
9676 # posix4 on Solaris 2.6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009677
9678# checks for system dependent C++ extensions support
9679case "$ac_sys_system" in
Martin v. Löwis11437992002-04-12 09:54:03 +00009680 AIX*) echo "$as_me:$LINENO: checking for genuine AIX C++ extensions support" >&5
9681echo $ECHO_N "checking for genuine AIX C++ extensions support... $ECHO_C" >&6
9682 cat >conftest.$ac_ext <<_ACEOF
9683#line $LINENO "configure"
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009684#include "confdefs.h"
9685#include "/usr/lpp/xlC/include/load.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009686#ifdef F77_DUMMY_MAIN
9687# ifdef __cplusplus
9688 extern "C"
9689# endif
9690 int F77_DUMMY_MAIN() { return 1; }
9691#endif
9692int
9693main ()
9694{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009695loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +00009696 ;
9697 return 0;
9698}
9699_ACEOF
9700rm -f conftest.$ac_objext conftest$ac_exeext
9701if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9702 (eval $ac_link) 2>&5
9703 ac_status=$?
9704 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9705 (exit $ac_status); } &&
9706 { ac_try='test -s conftest$ac_exeext'
9707 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9708 (eval $ac_try) 2>&5
9709 ac_status=$?
9710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9711 (exit $ac_status); }; }; then
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009712
Martin v. Löwis11437992002-04-12 09:54:03 +00009713cat >>confdefs.h <<\_ACEOF
9714#define AIX_GENUINE_CPLUSPLUS 1
9715_ACEOF
9716
9717 echo "$as_me:$LINENO: result: yes" >&5
9718echo "${ECHO_T}yes" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009719else
Martin v. Löwis11437992002-04-12 09:54:03 +00009720 echo "$as_me: failed program was:" >&5
9721cat conftest.$ac_ext >&5
9722echo "$as_me:$LINENO: result: no" >&5
9723echo "${ECHO_T}no" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009724fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009725rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009726 *) ;;
9727esac
9728
Guido van Rossum70c7f481998-03-26 18:44:10 +00009729# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
Martin v. Löwise1172582002-11-13 08:51:19 +00009730# However on SGI IRIX 4, these exist but are broken.
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009731# BeOS' sockets are stashed in libnet.
9732case "$ac_sys_system" in
9733IRIX*) ;;
Guido van Rossumb93a8621998-05-07 13:27:32 +00009734*)
Martin v. Löwis11437992002-04-12 09:54:03 +00009735echo "$as_me:$LINENO: checking for t_open in -lnsl" >&5
9736echo $ECHO_N "checking for t_open in -lnsl... $ECHO_C" >&6
9737if test "${ac_cv_lib_nsl_t_open+set}" = set; then
9738 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009739else
Martin v. Löwis11437992002-04-12 09:54:03 +00009740 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009741LIBS="-lnsl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009742cat >conftest.$ac_ext <<_ACEOF
9743#line $LINENO "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009744#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009745
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009746/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009747#ifdef __cplusplus
9748extern "C"
9749#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009750/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009751 builtin and then its argument prototype would still apply. */
9752char t_open ();
9753#ifdef F77_DUMMY_MAIN
9754# ifdef __cplusplus
9755 extern "C"
9756# endif
9757 int F77_DUMMY_MAIN() { return 1; }
9758#endif
9759int
9760main ()
9761{
9762t_open ();
9763 ;
9764 return 0;
9765}
9766_ACEOF
9767rm -f conftest.$ac_objext conftest$ac_exeext
9768if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9769 (eval $ac_link) 2>&5
9770 ac_status=$?
9771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9772 (exit $ac_status); } &&
9773 { ac_try='test -s conftest$ac_exeext'
9774 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9775 (eval $ac_try) 2>&5
9776 ac_status=$?
9777 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9778 (exit $ac_status); }; }; then
9779 ac_cv_lib_nsl_t_open=yes
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009780else
Martin v. Löwis11437992002-04-12 09:54:03 +00009781 echo "$as_me: failed program was:" >&5
9782cat conftest.$ac_ext >&5
9783ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009784fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009785rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9786LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009787fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009788echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_t_open" >&5
9789echo "${ECHO_T}$ac_cv_lib_nsl_t_open" >&6
9790if test $ac_cv_lib_nsl_t_open = yes; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009791 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009792fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00009793 # SVR4
Martin v. Löwis11437992002-04-12 09:54:03 +00009794echo "$as_me:$LINENO: checking for socket in -lsocket" >&5
9795echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6
9796if test "${ac_cv_lib_socket_socket+set}" = set; then
9797 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009798else
Martin v. Löwis11437992002-04-12 09:54:03 +00009799 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009800LIBS="-lsocket $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009801cat >conftest.$ac_ext <<_ACEOF
9802#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009803#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009804
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009805/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009806#ifdef __cplusplus
9807extern "C"
9808#endif
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009809/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009810 builtin and then its argument prototype would still apply. */
9811char socket ();
9812#ifdef F77_DUMMY_MAIN
9813# ifdef __cplusplus
9814 extern "C"
9815# endif
9816 int F77_DUMMY_MAIN() { return 1; }
9817#endif
9818int
9819main ()
9820{
9821socket ();
9822 ;
9823 return 0;
9824}
9825_ACEOF
9826rm -f conftest.$ac_objext conftest$ac_exeext
9827if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9828 (eval $ac_link) 2>&5
9829 ac_status=$?
9830 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9831 (exit $ac_status); } &&
9832 { ac_try='test -s conftest$ac_exeext'
9833 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9834 (eval $ac_try) 2>&5
9835 ac_status=$?
9836 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9837 (exit $ac_status); }; }; then
9838 ac_cv_lib_socket_socket=yes
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009839else
Martin v. Löwis11437992002-04-12 09:54:03 +00009840 echo "$as_me: failed program was:" >&5
9841cat conftest.$ac_ext >&5
9842ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009843fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009844rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9845LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009846fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009847echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5
9848echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6
9849if test $ac_cv_lib_socket_socket = yes; then
Guido van Rossumad678af1998-10-02 14:42:15 +00009850 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +00009851fi
9852 # SVR4 sockets
Jeremy Hyltoncb25d5e2000-07-27 21:23:28 +00009853;;
9854esac
9855case "$ac_sys_system" in
9856BeOS*)
Martin v. Löwis11437992002-04-12 09:54:03 +00009857echo "$as_me:$LINENO: checking for socket in -lnet" >&5
9858echo $ECHO_N "checking for socket in -lnet... $ECHO_C" >&6
9859if test "${ac_cv_lib_net_socket+set}" = set; then
9860 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +00009861else
Martin v. Löwis11437992002-04-12 09:54:03 +00009862 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +00009863LIBS="-lnet $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009864cat >conftest.$ac_ext <<_ACEOF
9865#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +00009866#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009867
Guido van Rossumad678af1998-10-02 14:42:15 +00009868/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009869#ifdef __cplusplus
9870extern "C"
9871#endif
Guido van Rossumad678af1998-10-02 14:42:15 +00009872/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009873 builtin and then its argument prototype would still apply. */
9874char socket ();
9875#ifdef F77_DUMMY_MAIN
9876# ifdef __cplusplus
9877 extern "C"
9878# endif
9879 int F77_DUMMY_MAIN() { return 1; }
9880#endif
9881int
9882main ()
9883{
9884socket ();
9885 ;
9886 return 0;
9887}
9888_ACEOF
9889rm -f conftest.$ac_objext conftest$ac_exeext
9890if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9891 (eval $ac_link) 2>&5
9892 ac_status=$?
9893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9894 (exit $ac_status); } &&
9895 { ac_try='test -s conftest$ac_exeext'
9896 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9897 (eval $ac_try) 2>&5
9898 ac_status=$?
9899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9900 (exit $ac_status); }; }; then
9901 ac_cv_lib_net_socket=yes
Guido van Rossumad678af1998-10-02 14:42:15 +00009902else
Martin v. Löwis11437992002-04-12 09:54:03 +00009903 echo "$as_me: failed program was:" >&5
9904cat conftest.$ac_ext >&5
9905ac_cv_lib_net_socket=no
Guido van Rossumad678af1998-10-02 14:42:15 +00009906fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009907rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9908LIBS=$ac_check_lib_save_LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +00009909fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009910echo "$as_me:$LINENO: result: $ac_cv_lib_net_socket" >&5
9911echo "${ECHO_T}$ac_cv_lib_net_socket" >&6
9912if test $ac_cv_lib_net_socket = yes; then
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009913 LIBS="-lnet $LIBS"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009914fi
9915 # BeOS
9916;;
9917esac
Guido van Rossum70c7f481998-03-26 18:44:10 +00009918
Martin v. Löwis11437992002-04-12 09:54:03 +00009919echo "$as_me:$LINENO: checking for --with-libs" >&5
9920echo $ECHO_N "checking for --with-libs... $ECHO_C" >&6
9921
Guido van Rossuma68acba1996-07-31 17:36:39 +00009922# Check whether --with-libs or --without-libs was given.
9923if test "${with_libs+set}" = set; then
9924 withval="$with_libs"
Martin v. Löwis11437992002-04-12 09:54:03 +00009925
9926echo "$as_me:$LINENO: result: $withval" >&5
9927echo "${ECHO_T}$withval" >&6
Guido van Rossuma68acba1996-07-31 17:36:39 +00009928LIBS="$withval $LIBS"
9929
9930else
Martin v. Löwis11437992002-04-12 09:54:03 +00009931 echo "$as_me:$LINENO: result: no" >&5
9932echo "${ECHO_T}no" >&6
9933fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +00009934
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00009935# Determine if signalmodule should be used.
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009936
9937
Martin v. Löwis11437992002-04-12 09:54:03 +00009938echo "$as_me:$LINENO: checking for --with-signal-module" >&5
9939echo $ECHO_N "checking for --with-signal-module... $ECHO_C" >&6
9940
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009941# Check whether --with-signal-module or --without-signal-module was given.
9942if test "${with_signal_module+set}" = set; then
9943 withval="$with_signal_module"
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009944
Martin v. Löwis11437992002-04-12 09:54:03 +00009945fi;
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009946
9947if test -z "$with_signal_module"
9948then with_signal_module="yes"
9949fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009950echo "$as_me:$LINENO: result: $with_signal_module" >&5
9951echo "${ECHO_T}$with_signal_module" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009952
9953if test "${with_signal_module}" = "yes"; then
9954 USE_SIGNAL_MODULE=""
9955 SIGNAL_OBJS=""
9956else
9957 USE_SIGNAL_MODULE="#"
9958 SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o"
9959fi
9960
Guido van Rossum3d15bd82001-01-10 18:53:48 +00009961# This is used to generate Setup.config
Guido van Rossum009f7871997-12-04 00:51:42 +00009962
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009963USE_THREAD_MODULE=""
Guido van Rossum009f7871997-12-04 00:51:42 +00009964
Martin v. Löwis11437992002-04-12 09:54:03 +00009965echo "$as_me:$LINENO: checking for --with-dec-threads" >&5
9966echo $ECHO_N "checking for --with-dec-threads... $ECHO_C" >&6
9967
Guido van Rossumec2f0731997-01-22 20:54:01 +00009968
9969# Check whether --with-dec-threads or --without-dec-threads was given.
9970if test "${with_dec_threads+set}" = set; then
9971 withval="$with_dec_threads"
Martin v. Löwis11437992002-04-12 09:54:03 +00009972
9973echo "$as_me:$LINENO: result: $withval" >&5
9974echo "${ECHO_T}$withval" >&6
Guido van Rossumec2f0731997-01-22 20:54:01 +00009975LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +00009976if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +00009977 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +00009978fi
Guido van Rossumec2f0731997-01-22 20:54:01 +00009979else
Martin v. Löwis11437992002-04-12 09:54:03 +00009980 echo "$as_me:$LINENO: result: no" >&5
9981echo "${ECHO_T}no" >&6
9982fi;
9983
9984# Templates for things AC_DEFINEd more than once.
9985# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +00009986
9987
Martin v. Löwis11437992002-04-12 09:54:03 +00009988
9989
9990
9991
9992
9993echo "$as_me:$LINENO: checking for --with-threads" >&5
9994echo $ECHO_N "checking for --with-threads... $ECHO_C" >&6
9995
Guido van Rossumec2f0731997-01-22 20:54:01 +00009996# Check whether --with-threads or --without-threads was given.
9997if test "${with_threads+set}" = set; then
9998 withval="$with_threads"
Guido van Rossumec2f0731997-01-22 20:54:01 +00009999
Martin v. Löwis11437992002-04-12 09:54:03 +000010000fi;
Guido van Rossumec2f0731997-01-22 20:54:01 +000010001
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010002# --with-thread is deprecated, but check for it anyway
Martin v. Löwis11437992002-04-12 09:54:03 +000010003
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010004# Check whether --with-thread or --without-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010005if test "${with_thread+set}" = set; then
10006 withval="$with_thread"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010007 with_threads=$with_thread
Martin v. Löwis11437992002-04-12 09:54:03 +000010008fi;
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010009
10010if test -z "$with_threads"
10011then with_threads="yes"
10012fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010013echo "$as_me:$LINENO: result: $with_threads" >&5
10014echo "${ECHO_T}$with_threads" >&6
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010015
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010016
Barry Warsawc0d24d8b2000-06-29 16:12:00 +000010017if test "$with_threads" = "no"
10018then
10019 USE_THREAD_MODULE="#"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010020elif test "$ac_cv_pthread_is_default" = yes
10021then
Martin v. Löwis11437992002-04-12 09:54:03 +000010022 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010023#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010024_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010025
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010026 # Defining _REENTRANT on system with POSIX threads should not hurt.
Martin v. Löwis11437992002-04-12 09:54:03 +000010027 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010028#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010029_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000010030
10031 posix_threads=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000010032 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010033elif test "$ac_cv_kpthread" = "yes"
10034then
10035 CC="$CC -Kpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000010036 cat >>confdefs.h <<\_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000010037#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010038_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000010039
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010040 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010041 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010042else
10043 if test ! -z "$with_threads" -a -d "$with_threads"
10044 then LDFLAGS="$LDFLAGS -L$with_threads"
10045 fi
10046 if test ! -z "$withval" -a -d "$withval"
10047 then LDFLAGS="$LDFLAGS -L$withval"
10048 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010049
10050 # According to the POSIX spec, a pthreads implementation must
10051 # define _POSIX_THREADS in unistd.h. Some apparently don't (which ones?)
Martin v. Löwis11437992002-04-12 09:54:03 +000010052 echo "$as_me:$LINENO: checking for _POSIX_THREADS in unistd.h" >&5
10053echo $ECHO_N "checking for _POSIX_THREADS in unistd.h... $ECHO_C" >&6
10054 cat >conftest.$ac_ext <<_ACEOF
10055#line $LINENO "configure"
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010056#include "confdefs.h"
10057#include <unistd.h>
10058 #ifdef _POSIX_THREADS
10059 yes
10060 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +000010061
10062_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010063if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10064 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010065 unistd_defines_pthreads=yes
10066else
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010067 unistd_defines_pthreads=no
10068fi
10069rm -f conftest*
10070
Martin v. Löwis11437992002-04-12 09:54:03 +000010071 echo "$as_me:$LINENO: result: $unistd_defines_pthreads" >&5
10072echo "${ECHO_T}$unistd_defines_pthreads" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010073
Martin v. Löwis11437992002-04-12 09:54:03 +000010074 cat >>confdefs.h <<\_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000010075#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010076_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000010077
Martin v. Löwis11437992002-04-12 09:54:03 +000010078 if test "${ac_cv_header_cthreads_h+set}" = set; then
10079 echo "$as_me:$LINENO: checking for cthreads.h" >&5
10080echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
10081if test "${ac_cv_header_cthreads_h+set}" = set; then
10082 echo $ECHO_N "(cached) $ECHO_C" >&6
10083fi
10084echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
10085echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010086else
Martin v. Löwis11437992002-04-12 09:54:03 +000010087 # Is the header compilable?
10088echo "$as_me:$LINENO: checking cthreads.h usability" >&5
10089echo $ECHO_N "checking cthreads.h usability... $ECHO_C" >&6
10090cat >conftest.$ac_ext <<_ACEOF
10091#line $LINENO "configure"
10092#include "confdefs.h"
10093$ac_includes_default
10094#include <cthreads.h>
10095_ACEOF
10096rm -f conftest.$ac_objext
10097if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10098 (eval $ac_compile) 2>&5
10099 ac_status=$?
10100 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10101 (exit $ac_status); } &&
10102 { ac_try='test -s conftest.$ac_objext'
10103 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10104 (eval $ac_try) 2>&5
10105 ac_status=$?
10106 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10107 (exit $ac_status); }; }; then
10108 ac_header_compiler=yes
10109else
10110 echo "$as_me: failed program was:" >&5
10111cat conftest.$ac_ext >&5
10112ac_header_compiler=no
10113fi
10114rm -f conftest.$ac_objext conftest.$ac_ext
10115echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10116echo "${ECHO_T}$ac_header_compiler" >&6
10117
10118# Is the header present?
10119echo "$as_me:$LINENO: checking cthreads.h presence" >&5
10120echo $ECHO_N "checking cthreads.h presence... $ECHO_C" >&6
10121cat >conftest.$ac_ext <<_ACEOF
10122#line $LINENO "configure"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010123#include "confdefs.h"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010124#include <cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010125_ACEOF
10126if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10127 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10128 ac_status=$?
10129 egrep -v '^ *\+' conftest.er1 >conftest.err
10130 rm -f conftest.er1
10131 cat conftest.err >&5
10132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10133 (exit $ac_status); } >/dev/null; then
10134 if test -s conftest.err; then
10135 ac_cpp_err=$ac_c_preproc_warn_flag
10136 else
10137 ac_cpp_err=
10138 fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010139else
Martin v. Löwis11437992002-04-12 09:54:03 +000010140 ac_cpp_err=yes
10141fi
10142if test -z "$ac_cpp_err"; then
10143 ac_header_preproc=yes
10144else
10145 echo "$as_me: failed program was:" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +000010146 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010147 ac_header_preproc=no
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010148fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010149rm -f conftest.err conftest.$ac_ext
10150echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10151echo "${ECHO_T}$ac_header_preproc" >&6
10152
10153# So? What about this header?
10154case $ac_header_compiler:$ac_header_preproc in
10155 yes:no )
10156 { echo "$as_me:$LINENO: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10157echo "$as_me: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10158 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
10159echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;};;
10160 no:yes )
10161 { echo "$as_me:$LINENO: WARNING: cthreads.h: present but cannot be compiled" >&5
10162echo "$as_me: WARNING: cthreads.h: present but cannot be compiled" >&2;}
10163 { echo "$as_me:$LINENO: WARNING: cthreads.h: check for missing prerequisite headers?" >&5
10164echo "$as_me: WARNING: cthreads.h: check for missing prerequisite headers?" >&2;}
10165 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
10166echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;};;
10167esac
10168echo "$as_me:$LINENO: checking for cthreads.h" >&5
10169echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
10170if test "${ac_cv_header_cthreads_h+set}" = set; then
10171 echo $ECHO_N "(cached) $ECHO_C" >&6
10172else
10173 ac_cv_header_cthreads_h=$ac_header_preproc
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010174fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010175echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
10176echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
10177
10178fi
10179if test $ac_cv_header_cthreads_h = yes; then
10180 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010181#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010182_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010183
Martin v. Löwis11437992002-04-12 09:54:03 +000010184 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010185#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010186_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010187
Martin v. Löwis11437992002-04-12 09:54:03 +000010188
10189cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010190#define HURD_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010191_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010192
10193 LIBS="$LIBS -lthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010194 THREADOBJ="Python/thread.o"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010195else
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010196
Martin v. Löwis11437992002-04-12 09:54:03 +000010197 if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
10198 echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
10199echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
10200if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
10201 echo $ECHO_N "(cached) $ECHO_C" >&6
10202fi
10203echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
10204echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010205else
Martin v. Löwis11437992002-04-12 09:54:03 +000010206 # Is the header compilable?
10207echo "$as_me:$LINENO: checking mach/cthreads.h usability" >&5
10208echo $ECHO_N "checking mach/cthreads.h usability... $ECHO_C" >&6
10209cat >conftest.$ac_ext <<_ACEOF
10210#line $LINENO "configure"
10211#include "confdefs.h"
10212$ac_includes_default
10213#include <mach/cthreads.h>
10214_ACEOF
10215rm -f conftest.$ac_objext
10216if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10217 (eval $ac_compile) 2>&5
10218 ac_status=$?
10219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10220 (exit $ac_status); } &&
10221 { ac_try='test -s conftest.$ac_objext'
10222 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10223 (eval $ac_try) 2>&5
10224 ac_status=$?
10225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10226 (exit $ac_status); }; }; then
10227 ac_header_compiler=yes
10228else
10229 echo "$as_me: failed program was:" >&5
10230cat conftest.$ac_ext >&5
10231ac_header_compiler=no
10232fi
10233rm -f conftest.$ac_objext conftest.$ac_ext
10234echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10235echo "${ECHO_T}$ac_header_compiler" >&6
10236
10237# Is the header present?
10238echo "$as_me:$LINENO: checking mach/cthreads.h presence" >&5
10239echo $ECHO_N "checking mach/cthreads.h presence... $ECHO_C" >&6
10240cat >conftest.$ac_ext <<_ACEOF
10241#line $LINENO "configure"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010242#include "confdefs.h"
10243#include <mach/cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010244_ACEOF
10245if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10246 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10247 ac_status=$?
10248 egrep -v '^ *\+' conftest.er1 >conftest.err
10249 rm -f conftest.er1
10250 cat conftest.err >&5
10251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10252 (exit $ac_status); } >/dev/null; then
10253 if test -s conftest.err; then
10254 ac_cpp_err=$ac_c_preproc_warn_flag
10255 else
10256 ac_cpp_err=
10257 fi
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010258else
Martin v. Löwis11437992002-04-12 09:54:03 +000010259 ac_cpp_err=yes
10260fi
10261if test -z "$ac_cpp_err"; then
10262 ac_header_preproc=yes
10263else
10264 echo "$as_me: failed program was:" >&5
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010265 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010266 ac_header_preproc=no
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010267fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010268rm -f conftest.err conftest.$ac_ext
10269echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10270echo "${ECHO_T}$ac_header_preproc" >&6
10271
10272# So? What about this header?
10273case $ac_header_compiler:$ac_header_preproc in
10274 yes:no )
10275 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10276echo "$as_me: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10277 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
10278echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;};;
10279 no:yes )
10280 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: present but cannot be compiled" >&5
10281echo "$as_me: WARNING: mach/cthreads.h: present but cannot be compiled" >&2;}
10282 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&5
10283echo "$as_me: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&2;}
10284 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
10285echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;};;
10286esac
10287echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
10288echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
10289if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
10290 echo $ECHO_N "(cached) $ECHO_C" >&6
10291else
10292 ac_cv_header_mach_cthreads_h=$ac_header_preproc
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010293fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010294echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
10295echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
10296
10297fi
10298if test $ac_cv_header_mach_cthreads_h = yes; then
10299 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010300#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010301_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010302
Martin v. Löwis11437992002-04-12 09:54:03 +000010303 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010304#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010305_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010306
Martin v. Löwis11437992002-04-12 09:54:03 +000010307
10308cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010309#define MACH_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010310_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010311
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010312 THREADOBJ="Python/thread.o"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010313else
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010314
Martin v. Löwis11437992002-04-12 09:54:03 +000010315 echo "$as_me:$LINENO: checking for --with-pth" >&5
10316echo $ECHO_N "checking for --with-pth... $ECHO_C" >&6
10317
10318# Check whether --with-pth or --without-pth was given.
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010319if test "${with_pth+set}" = set; then
10320 withval="$with_pth"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010321 echo "$as_me:$LINENO: result: $withval" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010322echo "${ECHO_T}$withval" >&6
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010323 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000010324#define WITH_THREAD 1
10325_ACEOF
10326
10327
10328cat >>confdefs.h <<\_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010329#define HAVE_PTH 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010330_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010331
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010332 LIBS="-lpth $LIBS"
10333 THREADOBJ="Python/thread.o"
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010334else
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010335 echo "$as_me:$LINENO: result: no" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010336echo "${ECHO_T}no" >&6
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010337
10338 # Just looking for pthread_create in libpthread is not enough:
10339 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
10340 # So we really have to include pthread.h, and then link.
10341 _libs=$LIBS
10342 LIBS="$LIBS -lpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000010343 echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
10344echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6
10345 cat >conftest.$ac_ext <<_ACEOF
10346#line $LINENO "configure"
Guido van Rossum02a1c402000-02-25 19:26:31 +000010347#include "confdefs.h"
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010348#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000010349
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010350void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000010351#ifdef F77_DUMMY_MAIN
10352# ifdef __cplusplus
10353 extern "C"
10354# endif
10355 int F77_DUMMY_MAIN() { return 1; }
10356#endif
10357int
10358main ()
10359{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010360
10361pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000010362 ;
10363 return 0;
10364}
10365_ACEOF
10366rm -f conftest.$ac_objext conftest$ac_exeext
10367if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10368 (eval $ac_link) 2>&5
10369 ac_status=$?
10370 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10371 (exit $ac_status); } &&
10372 { ac_try='test -s conftest$ac_exeext'
10373 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10374 (eval $ac_try) 2>&5
10375 ac_status=$?
10376 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10377 (exit $ac_status); }; }; then
10378
10379 echo "$as_me:$LINENO: result: yes" >&5
10380echo "${ECHO_T}yes" >&6
10381 cat >>confdefs.h <<\_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000010382#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010383_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000010384
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010385 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010386 THREADOBJ="Python/thread.o"
Guido van Rossum02a1c402000-02-25 19:26:31 +000010387else
Martin v. Löwis11437992002-04-12 09:54:03 +000010388 echo "$as_me: failed program was:" >&5
10389cat conftest.$ac_ext >&5
10390
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010391 LIBS=$_libs
Martin v. Löwis11437992002-04-12 09:54:03 +000010392 echo "$as_me:$LINENO: checking for pthread_detach" >&5
10393echo $ECHO_N "checking for pthread_detach... $ECHO_C" >&6
10394if test "${ac_cv_func_pthread_detach+set}" = set; then
10395 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000010396else
Martin v. Löwis11437992002-04-12 09:54:03 +000010397 cat >conftest.$ac_ext <<_ACEOF
10398#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +000010399#include "confdefs.h"
10400/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000010401 which can conflict with char pthread_detach (); below. */
Guido van Rossumad678af1998-10-02 14:42:15 +000010402#include <assert.h>
10403/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010404#ifdef __cplusplus
10405extern "C"
10406#endif
Guido van Rossumad678af1998-10-02 14:42:15 +000010407/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010408 builtin and then its argument prototype would still apply. */
10409char pthread_detach ();
10410char (*f) ();
Guido van Rossumad678af1998-10-02 14:42:15 +000010411
Martin v. Löwis11437992002-04-12 09:54:03 +000010412#ifdef F77_DUMMY_MAIN
10413# ifdef __cplusplus
10414 extern "C"
10415# endif
10416 int F77_DUMMY_MAIN() { return 1; }
10417#endif
10418int
10419main ()
10420{
Guido van Rossumad678af1998-10-02 14:42:15 +000010421/* The GNU C library defines this for functions which it implements
10422 to always fail with ENOSYS. Some functions are actually named
10423 something starting with __ and the normal name is an alias. */
Guido van Rossumea516321998-12-17 18:08:55 +000010424#if defined (__stub_pthread_detach) || defined (__stub___pthread_detach)
Guido van Rossumad678af1998-10-02 14:42:15 +000010425choke me
10426#else
Martin v. Löwis11437992002-04-12 09:54:03 +000010427f = pthread_detach;
Guido van Rossumad678af1998-10-02 14:42:15 +000010428#endif
10429
Martin v. Löwis11437992002-04-12 09:54:03 +000010430 ;
10431 return 0;
10432}
10433_ACEOF
10434rm -f conftest.$ac_objext conftest$ac_exeext
10435if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10436 (eval $ac_link) 2>&5
10437 ac_status=$?
10438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10439 (exit $ac_status); } &&
10440 { ac_try='test -s conftest$ac_exeext'
10441 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10442 (eval $ac_try) 2>&5
10443 ac_status=$?
10444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10445 (exit $ac_status); }; }; then
10446 ac_cv_func_pthread_detach=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000010447else
Martin v. Löwis11437992002-04-12 09:54:03 +000010448 echo "$as_me: failed program was:" >&5
10449cat conftest.$ac_ext >&5
10450ac_cv_func_pthread_detach=no
Guido van Rossumad678af1998-10-02 14:42:15 +000010451fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010452rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumad678af1998-10-02 14:42:15 +000010453fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010454echo "$as_me:$LINENO: result: $ac_cv_func_pthread_detach" >&5
10455echo "${ECHO_T}$ac_cv_func_pthread_detach" >&6
10456if test $ac_cv_func_pthread_detach = yes; then
10457 cat >>confdefs.h <<\_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000010458#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010459_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000010460
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010461 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010462 THREADOBJ="Python/thread.o"
Guido van Rossumad678af1998-10-02 14:42:15 +000010463else
Guido van Rossumad678af1998-10-02 14:42:15 +000010464
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010465 if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10466 echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
10467echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
10468if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10469 echo $ECHO_N "(cached) $ECHO_C" >&6
10470fi
10471echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
10472echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
10473else
10474 # Is the header compilable?
10475echo "$as_me:$LINENO: checking atheos/threads.h usability" >&5
10476echo $ECHO_N "checking atheos/threads.h usability... $ECHO_C" >&6
10477cat >conftest.$ac_ext <<_ACEOF
10478#line $LINENO "configure"
10479#include "confdefs.h"
10480$ac_includes_default
10481#include <atheos/threads.h>
10482_ACEOF
10483rm -f conftest.$ac_objext
10484if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10485 (eval $ac_compile) 2>&5
10486 ac_status=$?
10487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10488 (exit $ac_status); } &&
10489 { ac_try='test -s conftest.$ac_objext'
10490 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10491 (eval $ac_try) 2>&5
10492 ac_status=$?
10493 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10494 (exit $ac_status); }; }; then
10495 ac_header_compiler=yes
10496else
10497 echo "$as_me: failed program was:" >&5
10498cat conftest.$ac_ext >&5
10499ac_header_compiler=no
10500fi
10501rm -f conftest.$ac_objext conftest.$ac_ext
10502echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10503echo "${ECHO_T}$ac_header_compiler" >&6
10504
10505# Is the header present?
10506echo "$as_me:$LINENO: checking atheos/threads.h presence" >&5
10507echo $ECHO_N "checking atheos/threads.h presence... $ECHO_C" >&6
10508cat >conftest.$ac_ext <<_ACEOF
10509#line $LINENO "configure"
10510#include "confdefs.h"
10511#include <atheos/threads.h>
10512_ACEOF
10513if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10514 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10515 ac_status=$?
10516 egrep -v '^ *\+' conftest.er1 >conftest.err
10517 rm -f conftest.er1
10518 cat conftest.err >&5
10519 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10520 (exit $ac_status); } >/dev/null; then
10521 if test -s conftest.err; then
10522 ac_cpp_err=$ac_c_preproc_warn_flag
10523 else
10524 ac_cpp_err=
10525 fi
10526else
10527 ac_cpp_err=yes
10528fi
10529if test -z "$ac_cpp_err"; then
10530 ac_header_preproc=yes
10531else
10532 echo "$as_me: failed program was:" >&5
10533 cat conftest.$ac_ext >&5
10534 ac_header_preproc=no
10535fi
10536rm -f conftest.err conftest.$ac_ext
10537echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10538echo "${ECHO_T}$ac_header_preproc" >&6
10539
10540# So? What about this header?
10541case $ac_header_compiler:$ac_header_preproc in
10542 yes:no )
10543 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10544echo "$as_me: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10545 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
10546echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;};;
10547 no:yes )
10548 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: present but cannot be compiled" >&5
10549echo "$as_me: WARNING: atheos/threads.h: present but cannot be compiled" >&2;}
10550 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&5
10551echo "$as_me: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&2;}
10552 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
10553echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;};;
10554esac
10555echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
10556echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
10557if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10558 echo $ECHO_N "(cached) $ECHO_C" >&6
10559else
10560 ac_cv_header_atheos_threads_h=$ac_header_preproc
10561fi
10562echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
10563echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
10564
10565fi
10566if test $ac_cv_header_atheos_threads_h = yes; then
10567 cat >>confdefs.h <<\_ACEOF
10568#define WITH_THREAD 1
10569_ACEOF
10570
10571
10572cat >>confdefs.h <<\_ACEOF
10573#define ATHEOS_THREADS 1
10574_ACEOF
10575
10576 THREADOBJ="Python/thread.o"
10577else
10578
Martin v. Löwis11437992002-04-12 09:54:03 +000010579 if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10580 echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
10581echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
10582if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10583 echo $ECHO_N "(cached) $ECHO_C" >&6
10584fi
10585echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
10586echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010587else
Martin v. Löwis11437992002-04-12 09:54:03 +000010588 # Is the header compilable?
10589echo "$as_me:$LINENO: checking kernel/OS.h usability" >&5
10590echo $ECHO_N "checking kernel/OS.h usability... $ECHO_C" >&6
10591cat >conftest.$ac_ext <<_ACEOF
10592#line $LINENO "configure"
10593#include "confdefs.h"
10594$ac_includes_default
10595#include <kernel/OS.h>
10596_ACEOF
10597rm -f conftest.$ac_objext
10598if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10599 (eval $ac_compile) 2>&5
10600 ac_status=$?
10601 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10602 (exit $ac_status); } &&
10603 { ac_try='test -s conftest.$ac_objext'
10604 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10605 (eval $ac_try) 2>&5
10606 ac_status=$?
10607 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10608 (exit $ac_status); }; }; then
10609 ac_header_compiler=yes
10610else
10611 echo "$as_me: failed program was:" >&5
10612cat conftest.$ac_ext >&5
10613ac_header_compiler=no
10614fi
10615rm -f conftest.$ac_objext conftest.$ac_ext
10616echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10617echo "${ECHO_T}$ac_header_compiler" >&6
10618
10619# Is the header present?
10620echo "$as_me:$LINENO: checking kernel/OS.h presence" >&5
10621echo $ECHO_N "checking kernel/OS.h presence... $ECHO_C" >&6
10622cat >conftest.$ac_ext <<_ACEOF
10623#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010624#include "confdefs.h"
10625#include <kernel/OS.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010626_ACEOF
10627if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10628 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10629 ac_status=$?
10630 egrep -v '^ *\+' conftest.er1 >conftest.err
10631 rm -f conftest.er1
10632 cat conftest.err >&5
10633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10634 (exit $ac_status); } >/dev/null; then
10635 if test -s conftest.err; then
10636 ac_cpp_err=$ac_c_preproc_warn_flag
10637 else
10638 ac_cpp_err=
10639 fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010640else
Martin v. Löwis11437992002-04-12 09:54:03 +000010641 ac_cpp_err=yes
10642fi
10643if test -z "$ac_cpp_err"; then
10644 ac_header_preproc=yes
10645else
10646 echo "$as_me: failed program was:" >&5
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010647 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010648 ac_header_preproc=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010649fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010650rm -f conftest.err conftest.$ac_ext
10651echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10652echo "${ECHO_T}$ac_header_preproc" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010653
Martin v. Löwis11437992002-04-12 09:54:03 +000010654# So? What about this header?
10655case $ac_header_compiler:$ac_header_preproc in
10656 yes:no )
10657 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&5
10658echo "$as_me: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10659 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
10660echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;};;
10661 no:yes )
10662 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: present but cannot be compiled" >&5
10663echo "$as_me: WARNING: kernel/OS.h: present but cannot be compiled" >&2;}
10664 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&5
10665echo "$as_me: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&2;}
10666 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
10667echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;};;
10668esac
10669echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
10670echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
10671if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10672 echo $ECHO_N "(cached) $ECHO_C" >&6
10673else
10674 ac_cv_header_kernel_OS_h=$ac_header_preproc
10675fi
10676echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
10677echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
10678
10679fi
10680if test $ac_cv_header_kernel_OS_h = yes; then
10681 cat >>confdefs.h <<\_ACEOF
10682#define WITH_THREAD 1
10683_ACEOF
10684
10685
10686cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010687#define BEOS_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010688_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010689
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010690 THREADOBJ="Python/thread.o"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010691else
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010692
Martin v. Löwis11437992002-04-12 09:54:03 +000010693 echo "$as_me:$LINENO: checking for pthread_create in -lpthreads" >&5
10694echo $ECHO_N "checking for pthread_create in -lpthreads... $ECHO_C" >&6
10695if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then
10696 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010697else
Martin v. Löwis11437992002-04-12 09:54:03 +000010698 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010699LIBS="-lpthreads $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010700cat >conftest.$ac_ext <<_ACEOF
10701#line $LINENO "configure"
Greg Steinadf63d62000-07-05 10:38:09 +000010702#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010703
Greg Steinadf63d62000-07-05 10:38:09 +000010704/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010705#ifdef __cplusplus
10706extern "C"
10707#endif
Greg Steinadf63d62000-07-05 10:38:09 +000010708/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010709 builtin and then its argument prototype would still apply. */
10710char pthread_create ();
10711#ifdef F77_DUMMY_MAIN
10712# ifdef __cplusplus
10713 extern "C"
10714# endif
10715 int F77_DUMMY_MAIN() { return 1; }
10716#endif
10717int
10718main ()
10719{
10720pthread_create ();
10721 ;
10722 return 0;
10723}
10724_ACEOF
10725rm -f conftest.$ac_objext conftest$ac_exeext
10726if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10727 (eval $ac_link) 2>&5
10728 ac_status=$?
10729 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10730 (exit $ac_status); } &&
10731 { ac_try='test -s conftest$ac_exeext'
10732 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10733 (eval $ac_try) 2>&5
10734 ac_status=$?
10735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10736 (exit $ac_status); }; }; then
10737 ac_cv_lib_pthreads_pthread_create=yes
Greg Steinadf63d62000-07-05 10:38:09 +000010738else
Martin v. Löwis11437992002-04-12 09:54:03 +000010739 echo "$as_me: failed program was:" >&5
10740cat conftest.$ac_ext >&5
10741ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000010742fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010743rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10744LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010745fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010746echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_create" >&5
10747echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_create" >&6
10748if test $ac_cv_lib_pthreads_pthread_create = yes; then
10749 cat >>confdefs.h <<\_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000010750#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010751_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000010752
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010753 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010754 LIBS="$LIBS -lpthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010755 THREADOBJ="Python/thread.o"
Greg Steinadf63d62000-07-05 10:38:09 +000010756else
Greg Steinadf63d62000-07-05 10:38:09 +000010757
Martin v. Löwis11437992002-04-12 09:54:03 +000010758 echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
10759echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6
10760if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
10761 echo $ECHO_N "(cached) $ECHO_C" >&6
Greg Steinadf63d62000-07-05 10:38:09 +000010762else
Martin v. Löwis11437992002-04-12 09:54:03 +000010763 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010764LIBS="-lc_r $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010765cat >conftest.$ac_ext <<_ACEOF
10766#line $LINENO "configure"
Guido van Rossum49545951997-12-02 19:28:29 +000010767#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010768
Guido van Rossum49545951997-12-02 19:28:29 +000010769/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010770#ifdef __cplusplus
10771extern "C"
10772#endif
Guido van Rossum49545951997-12-02 19:28:29 +000010773/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010774 builtin and then its argument prototype would still apply. */
10775char pthread_create ();
10776#ifdef F77_DUMMY_MAIN
10777# ifdef __cplusplus
10778 extern "C"
10779# endif
10780 int F77_DUMMY_MAIN() { return 1; }
10781#endif
10782int
10783main ()
10784{
10785pthread_create ();
10786 ;
10787 return 0;
10788}
10789_ACEOF
10790rm -f conftest.$ac_objext conftest$ac_exeext
10791if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10792 (eval $ac_link) 2>&5
10793 ac_status=$?
10794 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10795 (exit $ac_status); } &&
10796 { ac_try='test -s conftest$ac_exeext'
10797 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10798 (eval $ac_try) 2>&5
10799 ac_status=$?
10800 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10801 (exit $ac_status); }; }; then
10802 ac_cv_lib_c_r_pthread_create=yes
Guido van Rossum49545951997-12-02 19:28:29 +000010803else
Martin v. Löwis11437992002-04-12 09:54:03 +000010804 echo "$as_me: failed program was:" >&5
10805cat conftest.$ac_ext >&5
10806ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000010807fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010808rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10809LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000010810fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010811echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
10812echo "${ECHO_T}$ac_cv_lib_c_r_pthread_create" >&6
10813if test $ac_cv_lib_c_r_pthread_create = yes; then
10814 cat >>confdefs.h <<\_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000010815#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010816_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000010817
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010818 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010819 LIBS="$LIBS -lc_r"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010820 THREADOBJ="Python/thread.o"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010821else
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010822
Martin v. Löwis11437992002-04-12 09:54:03 +000010823 echo "$as_me:$LINENO: checking for __d6_pthread_create in -lthread" >&5
10824echo $ECHO_N "checking for __d6_pthread_create in -lthread... $ECHO_C" >&6
10825if test "${ac_cv_lib_thread___d6_pthread_create+set}" = set; then
10826 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010827else
Martin v. Löwis11437992002-04-12 09:54:03 +000010828 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010829LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010830cat >conftest.$ac_ext <<_ACEOF
10831#line $LINENO "configure"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010832#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010833
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010834/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010835#ifdef __cplusplus
10836extern "C"
10837#endif
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010838/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010839 builtin and then its argument prototype would still apply. */
10840char __d6_pthread_create ();
10841#ifdef F77_DUMMY_MAIN
10842# ifdef __cplusplus
10843 extern "C"
10844# endif
10845 int F77_DUMMY_MAIN() { return 1; }
10846#endif
10847int
10848main ()
10849{
10850__d6_pthread_create ();
10851 ;
10852 return 0;
10853}
10854_ACEOF
10855rm -f conftest.$ac_objext conftest$ac_exeext
10856if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10857 (eval $ac_link) 2>&5
10858 ac_status=$?
10859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10860 (exit $ac_status); } &&
10861 { ac_try='test -s conftest$ac_exeext'
10862 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10863 (eval $ac_try) 2>&5
10864 ac_status=$?
10865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10866 (exit $ac_status); }; }; then
10867 ac_cv_lib_thread___d6_pthread_create=yes
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010868else
Martin v. Löwis11437992002-04-12 09:54:03 +000010869 echo "$as_me: failed program was:" >&5
10870cat conftest.$ac_ext >&5
10871ac_cv_lib_thread___d6_pthread_create=no
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010872fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010873rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10874LIBS=$ac_check_lib_save_LIBS
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010875fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010876echo "$as_me:$LINENO: result: $ac_cv_lib_thread___d6_pthread_create" >&5
10877echo "${ECHO_T}$ac_cv_lib_thread___d6_pthread_create" >&6
10878if test $ac_cv_lib_thread___d6_pthread_create = yes; then
10879 cat >>confdefs.h <<\_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010880#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010881_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010882
Martin v. Löwis779ffc02002-12-02 22:17:01 +000010883 echo Systems with __d6_pthread_create are not supported anymore.
10884 echo See README
10885 exit 1
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010886 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010887 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010888 THREADOBJ="Python/thread.o"
Guido van Rossum49545951997-12-02 19:28:29 +000010889else
Guido van Rossum49545951997-12-02 19:28:29 +000010890
Martin v. Löwis11437992002-04-12 09:54:03 +000010891 echo "$as_me:$LINENO: checking for __pthread_create_system in -lpthread" >&5
10892echo $ECHO_N "checking for __pthread_create_system in -lpthread... $ECHO_C" >&6
10893if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then
10894 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010895else
Martin v. Löwis11437992002-04-12 09:54:03 +000010896 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010897LIBS="-lpthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010898cat >conftest.$ac_ext <<_ACEOF
10899#line $LINENO "configure"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010900#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010901
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010902/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010903#ifdef __cplusplus
10904extern "C"
10905#endif
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010906/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010907 builtin and then its argument prototype would still apply. */
10908char __pthread_create_system ();
10909#ifdef F77_DUMMY_MAIN
10910# ifdef __cplusplus
10911 extern "C"
10912# endif
10913 int F77_DUMMY_MAIN() { return 1; }
10914#endif
10915int
10916main ()
10917{
10918__pthread_create_system ();
10919 ;
10920 return 0;
10921}
10922_ACEOF
10923rm -f conftest.$ac_objext conftest$ac_exeext
10924if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10925 (eval $ac_link) 2>&5
10926 ac_status=$?
10927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10928 (exit $ac_status); } &&
10929 { ac_try='test -s conftest$ac_exeext'
10930 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10931 (eval $ac_try) 2>&5
10932 ac_status=$?
10933 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10934 (exit $ac_status); }; }; then
10935 ac_cv_lib_pthread___pthread_create_system=yes
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010936else
Martin v. Löwis11437992002-04-12 09:54:03 +000010937 echo "$as_me: failed program was:" >&5
10938cat conftest.$ac_ext >&5
10939ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010940fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010941rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10942LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010943fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010944echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_create_system" >&5
10945echo "${ECHO_T}$ac_cv_lib_pthread___pthread_create_system" >&6
10946if test $ac_cv_lib_pthread___pthread_create_system = yes; then
10947 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010948#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010949_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010950
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010951 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010952 LIBS="$LIBS -lpthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010953 THREADOBJ="Python/thread.o"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010954else
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010955
Martin v. Löwis11437992002-04-12 09:54:03 +000010956 echo "$as_me:$LINENO: checking for pthread_create in -lcma" >&5
10957echo $ECHO_N "checking for pthread_create in -lcma... $ECHO_C" >&6
10958if test "${ac_cv_lib_cma_pthread_create+set}" = set; then
10959 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb93a8621998-05-07 13:27:32 +000010960else
Martin v. Löwis11437992002-04-12 09:54:03 +000010961 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000010962LIBS="-lcma $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010963cat >conftest.$ac_ext <<_ACEOF
10964#line $LINENO "configure"
Guido van Rossumb93a8621998-05-07 13:27:32 +000010965#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010966
Guido van Rossumb93a8621998-05-07 13:27:32 +000010967/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010968#ifdef __cplusplus
10969extern "C"
10970#endif
Guido van Rossumb93a8621998-05-07 13:27:32 +000010971/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010972 builtin and then its argument prototype would still apply. */
10973char pthread_create ();
10974#ifdef F77_DUMMY_MAIN
10975# ifdef __cplusplus
10976 extern "C"
10977# endif
10978 int F77_DUMMY_MAIN() { return 1; }
10979#endif
10980int
10981main ()
10982{
10983pthread_create ();
10984 ;
10985 return 0;
10986}
10987_ACEOF
10988rm -f conftest.$ac_objext conftest$ac_exeext
10989if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10990 (eval $ac_link) 2>&5
10991 ac_status=$?
10992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10993 (exit $ac_status); } &&
10994 { ac_try='test -s conftest$ac_exeext'
10995 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10996 (eval $ac_try) 2>&5
10997 ac_status=$?
10998 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10999 (exit $ac_status); }; }; then
11000 ac_cv_lib_cma_pthread_create=yes
Guido van Rossumb93a8621998-05-07 13:27:32 +000011001else
Martin v. Löwis11437992002-04-12 09:54:03 +000011002 echo "$as_me: failed program was:" >&5
11003cat conftest.$ac_ext >&5
11004ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000011005fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011006rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11007LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000011008fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011009echo "$as_me:$LINENO: result: $ac_cv_lib_cma_pthread_create" >&5
11010echo "${ECHO_T}$ac_cv_lib_cma_pthread_create" >&6
11011if test $ac_cv_lib_cma_pthread_create = yes; then
11012 cat >>confdefs.h <<\_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000011013#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011014_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000011015
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011016 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000011017 LIBS="$LIBS -lcma"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011018 THREADOBJ="Python/thread.o"
Guido van Rossumb93a8621998-05-07 13:27:32 +000011019else
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000011020
Martin v. Löwis130fb172001-07-19 11:00:41 +000011021 USE_THREAD_MODULE="#"
Guido van Rossum2d38f911996-06-26 19:47:01 +000011022fi
11023
Guido van Rossum627b2d71993-12-24 10:39:16 +000011024
Guido van Rossum7b3853f1996-07-30 18:09:35 +000011025fi
11026
Guido van Rossum0be3e491997-05-22 20:33:33 +000011027fi
11028
Guido van Rossum49545951997-12-02 19:28:29 +000011029fi
11030
Guido van Rossumb93a8621998-05-07 13:27:32 +000011031fi
11032
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011033fi
11034
Guido van Rossum07bd90e2000-05-08 13:41:38 +000011035
Michael W. Hudson54241132001-12-07 15:38:26 +000011036fi
11037
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011038
11039fi
11040
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011041fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011042rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11043fi;
11044fi
11045
11046
11047fi
11048
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011049
Michael W. Hudson54241132001-12-07 15:38:26 +000011050
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011051 if test "$posix_threads" = "yes"; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011052 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011053
11054cat >>confdefs.h <<\_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011055#define _POSIX_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011056_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011057
11058 fi
11059
Martin v. Löwis11437992002-04-12 09:54:03 +000011060 echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
11061echo $ECHO_N "checking if PTHREAD_SCOPE_SYSTEM is supported... $ECHO_C" >&6
11062 if test "${ac_cv_pthread_system_supported+set}" = set; then
11063 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011064else
11065 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000011066 ac_cv_pthread_system_supported=no
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011067else
Martin v. Löwis11437992002-04-12 09:54:03 +000011068 cat >conftest.$ac_ext <<_ACEOF
11069#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011070#include "confdefs.h"
11071#include <pthread.h>
11072 void *foo(void *parm) {
11073 return NULL;
11074 }
11075 main() {
11076 pthread_attr_t attr;
Martin v. Löwisa82d3472002-02-24 16:05:05 +000011077 pthread_t id;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011078 if (pthread_attr_init(&attr)) exit(-1);
11079 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1);
Martin v. Löwisa82d3472002-02-24 16:05:05 +000011080 if (pthread_create(&id, &attr, foo, NULL)) exit(-1);
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011081 exit(0);
11082 }
Martin v. Löwis11437992002-04-12 09:54:03 +000011083_ACEOF
11084rm -f conftest$ac_exeext
11085if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11086 (eval $ac_link) 2>&5
11087 ac_status=$?
11088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11089 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11091 (eval $ac_try) 2>&5
11092 ac_status=$?
11093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11094 (exit $ac_status); }; }; then
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011095 ac_cv_pthread_system_supported=yes
11096else
Martin v. Löwis11437992002-04-12 09:54:03 +000011097 echo "$as_me: program exited with status $ac_status" >&5
11098echo "$as_me: failed program was:" >&5
11099cat conftest.$ac_ext >&5
11100( exit $ac_status )
11101ac_cv_pthread_system_supported=no
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011102fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011103rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011104fi
11105
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011106fi
11107
Martin v. Löwis11437992002-04-12 09:54:03 +000011108 echo "$as_me:$LINENO: result: $ac_cv_pthread_system_supported" >&5
11109echo "${ECHO_T}$ac_cv_pthread_system_supported" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011110 if test "$ac_cv_pthread_system_supported" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011111
11112cat >>confdefs.h <<\_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011113#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011114_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011115
11116 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011117
11118for ac_func in pthread_sigmask
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011119do
Martin v. Löwis11437992002-04-12 09:54:03 +000011120as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11121echo "$as_me:$LINENO: checking for $ac_func" >&5
11122echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11123if eval "test \"\${$as_ac_var+set}\" = set"; then
11124 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011125else
Martin v. Löwis11437992002-04-12 09:54:03 +000011126 cat >conftest.$ac_ext <<_ACEOF
11127#line $LINENO "configure"
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011128#include "confdefs.h"
11129/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011130 which can conflict with char $ac_func (); below. */
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011131#include <assert.h>
11132/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011133#ifdef __cplusplus
11134extern "C"
11135#endif
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011136/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011137 builtin and then its argument prototype would still apply. */
11138char $ac_func ();
11139char (*f) ();
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011140
Martin v. Löwis11437992002-04-12 09:54:03 +000011141#ifdef F77_DUMMY_MAIN
11142# ifdef __cplusplus
11143 extern "C"
11144# endif
11145 int F77_DUMMY_MAIN() { return 1; }
11146#endif
11147int
11148main ()
11149{
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011150/* The GNU C library defines this for functions which it implements
11151 to always fail with ENOSYS. Some functions are actually named
11152 something starting with __ and the normal name is an alias. */
11153#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11154choke me
11155#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011156f = $ac_func;
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011157#endif
11158
Martin v. Löwis11437992002-04-12 09:54:03 +000011159 ;
11160 return 0;
11161}
11162_ACEOF
11163rm -f conftest.$ac_objext conftest$ac_exeext
11164if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11165 (eval $ac_link) 2>&5
11166 ac_status=$?
11167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11168 (exit $ac_status); } &&
11169 { ac_try='test -s conftest$ac_exeext'
11170 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11171 (eval $ac_try) 2>&5
11172 ac_status=$?
11173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11174 (exit $ac_status); }; }; then
11175 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011176else
Martin v. Löwis11437992002-04-12 09:54:03 +000011177 echo "$as_me: failed program was:" >&5
11178cat conftest.$ac_ext >&5
11179eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011180fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011181rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011182fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011183echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11184echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11185if test `eval echo '${'$as_ac_var'}'` = yes; then
11186 cat >>confdefs.h <<_ACEOF
11187#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11188_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011189
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011190fi
11191done
11192
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011193 fi
11194
Martin v. Löwis11437992002-04-12 09:54:03 +000011195 echo "$as_me:$LINENO: checking for usconfig in -lmpc" >&5
11196echo $ECHO_N "checking for usconfig in -lmpc... $ECHO_C" >&6
11197if test "${ac_cv_lib_mpc_usconfig+set}" = set; then
11198 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011199else
Martin v. Löwis11437992002-04-12 09:54:03 +000011200 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011201LIBS="-lmpc $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011202cat >conftest.$ac_ext <<_ACEOF
11203#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000011204#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000011205
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011206/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011207#ifdef __cplusplus
11208extern "C"
11209#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011210/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011211 builtin and then its argument prototype would still apply. */
11212char usconfig ();
11213#ifdef F77_DUMMY_MAIN
11214# ifdef __cplusplus
11215 extern "C"
11216# endif
11217 int F77_DUMMY_MAIN() { return 1; }
11218#endif
11219int
11220main ()
11221{
11222usconfig ();
11223 ;
11224 return 0;
11225}
11226_ACEOF
11227rm -f conftest.$ac_objext conftest$ac_exeext
11228if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11229 (eval $ac_link) 2>&5
11230 ac_status=$?
11231 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11232 (exit $ac_status); } &&
11233 { ac_try='test -s conftest$ac_exeext'
11234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11235 (eval $ac_try) 2>&5
11236 ac_status=$?
11237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11238 (exit $ac_status); }; }; then
11239 ac_cv_lib_mpc_usconfig=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011240else
Martin v. Löwis11437992002-04-12 09:54:03 +000011241 echo "$as_me: failed program was:" >&5
11242cat conftest.$ac_ext >&5
11243ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000011244fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011245rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11246LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011247fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011248echo "$as_me:$LINENO: result: $ac_cv_lib_mpc_usconfig" >&5
11249echo "${ECHO_T}$ac_cv_lib_mpc_usconfig" >&6
11250if test $ac_cv_lib_mpc_usconfig = yes; then
11251 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011252#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011253_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000011254
Martin v. Löwis130fb172001-07-19 11:00:41 +000011255 LIBS="$LIBS -lmpc"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011256 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000011257 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000011258fi
11259
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011260
Neal Norwitza978ab02002-11-02 16:58:05 +000011261 if test "$posix_threads" != "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011262 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
11263echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
11264if test "${ac_cv_lib_thread_thr_create+set}" = set; then
11265 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011266else
Martin v. Löwis11437992002-04-12 09:54:03 +000011267 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011268LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011269cat >conftest.$ac_ext <<_ACEOF
11270#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000011271#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000011272
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011273/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011274#ifdef __cplusplus
11275extern "C"
11276#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011277/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011278 builtin and then its argument prototype would still apply. */
11279char thr_create ();
11280#ifdef F77_DUMMY_MAIN
11281# ifdef __cplusplus
11282 extern "C"
11283# endif
11284 int F77_DUMMY_MAIN() { return 1; }
11285#endif
11286int
11287main ()
11288{
11289thr_create ();
11290 ;
11291 return 0;
11292}
11293_ACEOF
11294rm -f conftest.$ac_objext conftest$ac_exeext
11295if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11296 (eval $ac_link) 2>&5
11297 ac_status=$?
11298 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11299 (exit $ac_status); } &&
11300 { ac_try='test -s conftest$ac_exeext'
11301 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11302 (eval $ac_try) 2>&5
11303 ac_status=$?
11304 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11305 (exit $ac_status); }; }; then
11306 ac_cv_lib_thread_thr_create=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011307else
Martin v. Löwis11437992002-04-12 09:54:03 +000011308 echo "$as_me: failed program was:" >&5
11309cat conftest.$ac_ext >&5
11310ac_cv_lib_thread_thr_create=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000011311fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011312rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11313LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011314fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011315echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
11316echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
11317if test $ac_cv_lib_thread_thr_create = yes; then
11318 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011319#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011320_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000011321
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011322 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011323 THREADOBJ="Python/thread.o"
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011324 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000011325fi
11326
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011327 fi
Michael W. Hudson54241132001-12-07 15:38:26 +000011328
Martin v. Löwis130fb172001-07-19 11:00:41 +000011329 if test "$USE_THREAD_MODULE" != "#"
11330 then
11331 # If the above checks didn't disable threads, (at least) OSF1
11332 # needs this '-threads' argument during linking.
11333 case $ac_sys_system in
11334 OSF1) LDLAST=-threads;;
11335 esac
Jeremy Hylton1a2ca862000-10-16 16:59:12 +000011336 fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000011337
11338 if test "$posix_threads" = yes -a \
11339 "$ac_sys_system" = "SunOS" -a \
11340 "$ac_sys_release" = "5.6"; then
11341
11342cat >>confdefs.h <<\_ACEOF
11343#define HAVE_PTHREAD_DESTRUCTOR 1
11344_ACEOF
11345
11346 fi
11347
Guido van Rossum627b2d71993-12-24 10:39:16 +000011348fi
11349
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011350# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000011351
11352
11353echo "$as_me:$LINENO: checking if --enable-ipv6 is specified" >&5
11354echo $ECHO_N "checking if --enable-ipv6 is specified... $ECHO_C" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011355# Check whether --enable-ipv6 or --disable-ipv6 was given.
11356if test "${enable_ipv6+set}" = set; then
11357 enableval="$enable_ipv6"
11358 case "$enableval" in
11359 no)
Martin v. Löwis11437992002-04-12 09:54:03 +000011360 echo "$as_me:$LINENO: result: no" >&5
11361echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011362 ipv6=no
11363 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011364 *) echo "$as_me:$LINENO: result: yes" >&5
11365echo "${ECHO_T}yes" >&6
11366 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011367#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011368_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011369
11370 ipv6=yes
11371 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011372 esac
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011373else
Martin v. Löwis11437992002-04-12 09:54:03 +000011374
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011375 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011376 echo "$as_me:$LINENO: result: no" >&5
11377echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011378 ipv6=no
11379
11380else
Martin v. Löwis11437992002-04-12 09:54:03 +000011381 cat >conftest.$ac_ext <<_ACEOF
11382#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011383#include "confdefs.h"
11384 /* AF_INET6 available check */
11385#include <sys/types.h>
11386#include <sys/socket.h>
11387main()
11388{
11389 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
11390 exit(1);
11391 else
11392 exit(0);
11393}
11394
Martin v. Löwis11437992002-04-12 09:54:03 +000011395_ACEOF
11396rm -f conftest$ac_exeext
11397if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11398 (eval $ac_link) 2>&5
11399 ac_status=$?
11400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11401 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11402 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11403 (eval $ac_try) 2>&5
11404 ac_status=$?
11405 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11406 (exit $ac_status); }; }; then
11407 echo "$as_me:$LINENO: result: yes" >&5
11408echo "${ECHO_T}yes" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011409 ipv6=yes
11410else
Martin v. Löwis11437992002-04-12 09:54:03 +000011411 echo "$as_me: program exited with status $ac_status" >&5
11412echo "$as_me: failed program was:" >&5
11413cat conftest.$ac_ext >&5
11414( exit $ac_status )
11415echo "$as_me:$LINENO: result: no" >&5
11416echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011417 ipv6=no
11418fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011419rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011420fi
11421
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011422if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011423 echo "$as_me:$LINENO: checking if RFC2553 API is available" >&5
11424echo $ECHO_N "checking if RFC2553 API is available... $ECHO_C" >&6
11425 cat >conftest.$ac_ext <<_ACEOF
11426#line $LINENO "configure"
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011427#include "confdefs.h"
11428#include <sys/types.h>
11429#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011430#ifdef F77_DUMMY_MAIN
11431# ifdef __cplusplus
11432 extern "C"
11433# endif
11434 int F77_DUMMY_MAIN() { return 1; }
11435#endif
11436int
11437main ()
11438{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011439struct sockaddr_in6 x;
11440x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000011441 ;
11442 return 0;
11443}
11444_ACEOF
11445rm -f conftest.$ac_objext
11446if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11447 (eval $ac_compile) 2>&5
11448 ac_status=$?
11449 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11450 (exit $ac_status); } &&
11451 { ac_try='test -s conftest.$ac_objext'
11452 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11453 (eval $ac_try) 2>&5
11454 ac_status=$?
11455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11456 (exit $ac_status); }; }; then
11457 echo "$as_me:$LINENO: result: yes" >&5
11458echo "${ECHO_T}yes" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011459 ipv6=yes
11460else
Martin v. Löwis11437992002-04-12 09:54:03 +000011461 echo "$as_me: failed program was:" >&5
11462cat conftest.$ac_ext >&5
11463echo "$as_me:$LINENO: result: no" >&5
11464echo "${ECHO_T}no" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011465 ipv6=no
11466fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011467rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011468fi
11469
11470if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011471 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011472#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011473_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011474
11475fi
11476
Martin v. Löwis11437992002-04-12 09:54:03 +000011477fi;
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011478
11479ipv6type=unknown
11480ipv6lib=none
11481ipv6trylibc=no
11482
11483if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011484 echo "$as_me:$LINENO: checking ipv6 stack type" >&5
11485echo $ECHO_N "checking ipv6 stack type... $ECHO_C" >&6
Guido van Rossumb8552162001-09-05 14:58:11 +000011486 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
11487 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011488 case $i in
11489 inria)
Martin v. Löwis11437992002-04-12 09:54:03 +000011490 cat >conftest.$ac_ext <<_ACEOF
11491#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011492#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011493
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011494#include <netinet/in.h>
11495#ifdef IPV6_INRIA_VERSION
11496yes
11497#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011498_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011499if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11500 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011501 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011502fi
11503rm -f conftest*
11504
11505 ;;
11506 kame)
Martin v. Löwis11437992002-04-12 09:54:03 +000011507 cat >conftest.$ac_ext <<_ACEOF
11508#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011509#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011510
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011511#include <netinet/in.h>
11512#ifdef __KAME__
11513yes
11514#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011515_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011516if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11517 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011518 ipv6type=$i;
11519 ipv6lib=inet6
11520 ipv6libdir=/usr/local/v6/lib
11521 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011522fi
11523rm -f conftest*
11524
11525 ;;
11526 linux-glibc)
Martin v. Löwis11437992002-04-12 09:54:03 +000011527 cat >conftest.$ac_ext <<_ACEOF
11528#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011529#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011530
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011531#include <features.h>
11532#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
11533yes
11534#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011535_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011536if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11537 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011538 ipv6type=$i;
11539 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011540fi
11541rm -f conftest*
11542
11543 ;;
11544 linux-inet6)
11545 if test -d /usr/inet6; then
11546 ipv6type=$i
11547 ipv6lib=inet6
11548 ipv6libdir=/usr/inet6/lib
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011549 OPT="-I/usr/inet6/include $OPT"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011550 fi
11551 ;;
11552 solaris)
11553 if test -f /etc/netconfig; then
11554 if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then
11555 ipv6type=$i
11556 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011557 fi
11558 fi
11559 ;;
11560 toshiba)
Martin v. Löwis11437992002-04-12 09:54:03 +000011561 cat >conftest.$ac_ext <<_ACEOF
11562#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011563#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011564
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011565#include <sys/param.h>
11566#ifdef _TOSHIBA_INET6
11567yes
11568#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011569_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011570if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11571 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011572 ipv6type=$i;
11573 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011574 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011575fi
11576rm -f conftest*
11577
11578 ;;
11579 v6d)
Martin v. Löwis11437992002-04-12 09:54:03 +000011580 cat >conftest.$ac_ext <<_ACEOF
11581#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011582#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011583
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011584#include </usr/local/v6/include/sys/v6config.h>
11585#ifdef __V6D__
11586yes
11587#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011588_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011589if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11590 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011591 ipv6type=$i;
11592 ipv6lib=v6;
11593 ipv6libdir=/usr/local/v6/lib;
11594 OPT="-I/usr/local/v6/include $OPT"
11595fi
11596rm -f conftest*
11597
11598 ;;
11599 zeta)
Martin v. Löwis11437992002-04-12 09:54:03 +000011600 cat >conftest.$ac_ext <<_ACEOF
11601#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011602#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011603
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011604#include <sys/param.h>
11605#ifdef _ZETA_MINAMI_INET6
11606yes
11607#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011608_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011609if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11610 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011611 ipv6type=$i;
11612 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011613 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011614fi
11615rm -f conftest*
11616
11617 ;;
11618 esac
11619 if test "$ipv6type" != "unknown"; then
11620 break
11621 fi
11622 done
Martin v. Löwis11437992002-04-12 09:54:03 +000011623 echo "$as_me:$LINENO: result: $ipv6type" >&5
11624echo "${ECHO_T}$ipv6type" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011625fi
11626
11627if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
11628 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
11629 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
11630 echo "using lib$ipv6lib"
11631 else
11632 if test $ipv6trylibc = "yes"; then
11633 echo "using libc"
11634 else
11635 echo 'Fatal: no $ipv6lib library found. cannot continue.'
11636 echo "You need to fetch lib$ipv6lib.a from appropriate"
11637 echo 'ipv6 kit and compile beforehand.'
11638 exit 1
11639 fi
11640 fi
11641fi
11642
Jack Jansen7b8c7542002-04-14 20:12:41 +000011643# Check for universal newline support
Guido van Rossum402905e2002-08-15 13:56:35 +000011644echo "$as_me:$LINENO: checking for --with-universal-newlines" >&5
11645echo $ECHO_N "checking for --with-universal-newlines... $ECHO_C" >&6
Jack Jansen7b8c7542002-04-14 20:12:41 +000011646
11647# Check whether --with-universal-newlines or --without-universal-newlines was given.
11648if test "${with_universal_newlines+set}" = set; then
11649 withval="$with_universal_newlines"
11650
11651fi;
11652
11653if test -z "$with_universal_newlines"
11654then with_universal_newlines="yes"
11655fi
Martin v. Löwis7e4cfcb2002-12-19 16:21:49 +000011656if test "$with_universal_newlines" = "no"
11657 echo --without-universal-newlines is unsupported, see README
11658 exit 1
Jack Jansen7b8c7542002-04-14 20:12:41 +000011659then
Martin v. Löwise8aea582002-04-16 05:51:02 +000011660
11661cat >>confdefs.h <<\_ACEOF
Jack Jansen7b8c7542002-04-14 20:12:41 +000011662#define WITH_UNIVERSAL_NEWLINES 1
11663_ACEOF
11664
11665fi
11666echo "$as_me:$LINENO: result: $with_universal_newlines" >&5
11667echo "${ECHO_T}$with_universal_newlines" >&6
11668
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000011669# Check for --with-doc-strings
11670echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
11671echo $ECHO_N "checking for --with-doc-strings... $ECHO_C" >&6
11672
11673# Check whether --with-doc-strings or --without-doc-strings was given.
11674if test "${with_doc_strings+set}" = set; then
11675 withval="$with_doc_strings"
11676
11677fi;
11678
11679if test -z "$with_doc_strings"
11680then with_doc_strings="yes"
11681fi
11682if test "$with_doc_strings" != "no"
11683then
11684
11685cat >>confdefs.h <<\_ACEOF
11686#define WITH_DOC_STRINGS 1
11687_ACEOF
11688
11689fi
11690echo "$as_me:$LINENO: result: $with_doc_strings" >&5
11691echo "${ECHO_T}$with_doc_strings" >&6
11692
Neil Schemenauera35c6882001-02-27 04:45:05 +000011693# Check for Python-specific malloc support
Martin v. Löwis11437992002-04-12 09:54:03 +000011694echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
11695echo $ECHO_N "checking for --with-pymalloc... $ECHO_C" >&6
11696
Neil Schemenauera35c6882001-02-27 04:45:05 +000011697# Check whether --with-pymalloc or --without-pymalloc was given.
11698if test "${with_pymalloc+set}" = set; then
11699 withval="$with_pymalloc"
Michael W. Hudson54241132001-12-07 15:38:26 +000011700
Martin v. Löwis11437992002-04-12 09:54:03 +000011701fi;
Neil Schemenauera35c6882001-02-27 04:45:05 +000011702
Neil Schemenauer16c22972002-03-22 15:34:49 +000011703if test -z "$with_pymalloc"
11704then with_pymalloc="yes"
11705fi
11706if test "$with_pymalloc" != "no"
11707then
Martin v. Löwis11437992002-04-12 09:54:03 +000011708
11709cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011710#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011711_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011712
11713fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011714echo "$as_me:$LINENO: result: $with_pymalloc" >&5
11715echo "${ECHO_T}$with_pymalloc" >&6
Neil Schemenauer16c22972002-03-22 15:34:49 +000011716
Barry Warsawef82cd72000-06-30 16:21:01 +000011717# Check for --with-wctype-functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011718echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
11719echo $ECHO_N "checking for --with-wctype-functions... $ECHO_C" >&6
11720
Barry Warsawef82cd72000-06-30 16:21:01 +000011721# Check whether --with-wctype-functions or --without-wctype-functions was given.
11722if test "${with_wctype_functions+set}" = set; then
11723 withval="$with_wctype_functions"
Martin v. Löwis11437992002-04-12 09:54:03 +000011724
Barry Warsawef82cd72000-06-30 16:21:01 +000011725if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000011726then
11727
11728cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000011729#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011730_ACEOF
11731
11732 echo "$as_me:$LINENO: result: yes" >&5
11733echo "${ECHO_T}yes" >&6
11734else echo "$as_me:$LINENO: result: no" >&5
11735echo "${ECHO_T}no" >&6
Barry Warsawef82cd72000-06-30 16:21:01 +000011736fi
11737else
Martin v. Löwis11437992002-04-12 09:54:03 +000011738 echo "$as_me:$LINENO: result: no" >&5
11739echo "${ECHO_T}no" >&6
11740fi;
Barry Warsawef82cd72000-06-30 16:21:01 +000011741
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011742# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000011743
Guido van Rossum98935bf2001-09-05 19:13:16 +000011744DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000011745
Martin v. Löwis11437992002-04-12 09:54:03 +000011746echo "$as_me:$LINENO: checking for --with-sgi-dl" >&5
11747echo $ECHO_N "checking for --with-sgi-dl... $ECHO_C" >&6
11748
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011749# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011750if test "${with_sgi_dl+set}" = set; then
11751 withval="$with_sgi_dl"
Martin v. Löwis11437992002-04-12 09:54:03 +000011752
11753echo "$as_me:$LINENO: result: $withval" >&5
11754echo "${ECHO_T}$withval" >&6
Martin v. Löwis9ef33762002-12-02 22:23:56 +000011755echo --with-sgi-dl is unsupported, see README
Martin v. Löwis779ffc02002-12-02 22:17:01 +000011756exit 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011757
11758cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011759#define WITH_SGI_DL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011760_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011761
Guido van Rossume97ee181999-12-20 21:27:22 +000011762DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011763dldir=$withval
Guido van Rossum40951012000-10-07 16:21:27 +000011764if test ! -z "$dldir" -a -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011765then LDFLAGS="$LDFLAGS -L$dldir"
Martin v. Löwis11437992002-04-12 09:54:03 +000011766else { { echo "$as_me:$LINENO: error: proper usage is --with-sgi-dl=DIRECTORY" >&5
11767echo "$as_me: error: proper usage is --with-sgi-dl=DIRECTORY" >&2;}
11768 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011769fi
11770DLINCLDIR=${dldir}
11771LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011772else
Martin v. Löwis11437992002-04-12 09:54:03 +000011773 echo "$as_me:$LINENO: result: no" >&5
11774echo "${ECHO_T}no" >&6
11775fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011776
Martin v. Löwis11437992002-04-12 09:54:03 +000011777echo "$as_me:$LINENO: checking for --with-dl-dld" >&5
11778echo $ECHO_N "checking for --with-dl-dld... $ECHO_C" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000011779
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011780# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011781if test "${with_dl_dld+set}" = set; then
11782 withval="$with_dl_dld"
Martin v. Löwis11437992002-04-12 09:54:03 +000011783
11784echo "$as_me:$LINENO: result: $withval" >&5
11785echo "${ECHO_T}$withval" >&6
Martin v. Löwis9ef33762002-12-02 22:23:56 +000011786echo --with-dl-dld is unsupported, see README
Martin v. Löwis779ffc02002-12-02 22:17:01 +000011787exit 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011788
11789cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011790#define WITH_DL_DLD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011791_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011792
Guido van Rossume97ee181999-12-20 21:27:22 +000011793DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011794dldir=`echo "$withval" | sed 's/,.*//'`
11795dlddir=`echo "$withval" | sed 's/.*,//'`
Barry Warsaw7d1219d2000-10-05 18:45:53 +000011796if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011797then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011798else { { echo "$as_me:$LINENO: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&5
11799echo "$as_me: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&2;}
11800 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011801fi
11802DLINCLDIR=${dldir}
11803LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011804else
Martin v. Löwis11437992002-04-12 09:54:03 +000011805 echo "$as_me:$LINENO: result: no" >&5
11806echo "${ECHO_T}no" >&6
11807fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011808
Guido van Rossume97ee181999-12-20 21:27:22 +000011809# the dlopen() function means we might want to use dynload_shlib.o. some
11810# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000011811
Thomas Wouters3a584202000-08-05 23:28:51 +000011812for ac_func in dlopen
11813do
Martin v. Löwis11437992002-04-12 09:54:03 +000011814as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11815echo "$as_me:$LINENO: checking for $ac_func" >&5
11816echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11817if eval "test \"\${$as_ac_var+set}\" = set"; then
11818 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011819else
Martin v. Löwis11437992002-04-12 09:54:03 +000011820 cat >conftest.$ac_ext <<_ACEOF
11821#line $LINENO "configure"
Guido van Rossume97ee181999-12-20 21:27:22 +000011822#include "confdefs.h"
11823/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011824 which can conflict with char $ac_func (); below. */
Guido van Rossume97ee181999-12-20 21:27:22 +000011825#include <assert.h>
11826/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011827#ifdef __cplusplus
11828extern "C"
11829#endif
Guido van Rossume97ee181999-12-20 21:27:22 +000011830/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011831 builtin and then its argument prototype would still apply. */
11832char $ac_func ();
11833char (*f) ();
Guido van Rossume97ee181999-12-20 21:27:22 +000011834
Martin v. Löwis11437992002-04-12 09:54:03 +000011835#ifdef F77_DUMMY_MAIN
11836# ifdef __cplusplus
11837 extern "C"
11838# endif
11839 int F77_DUMMY_MAIN() { return 1; }
11840#endif
11841int
11842main ()
11843{
Guido van Rossume97ee181999-12-20 21:27:22 +000011844/* The GNU C library defines this for functions which it implements
11845 to always fail with ENOSYS. Some functions are actually named
11846 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000011847#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossume97ee181999-12-20 21:27:22 +000011848choke me
11849#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011850f = $ac_func;
Guido van Rossume97ee181999-12-20 21:27:22 +000011851#endif
11852
Martin v. Löwis11437992002-04-12 09:54:03 +000011853 ;
11854 return 0;
11855}
11856_ACEOF
11857rm -f conftest.$ac_objext conftest$ac_exeext
11858if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11859 (eval $ac_link) 2>&5
11860 ac_status=$?
11861 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11862 (exit $ac_status); } &&
11863 { ac_try='test -s conftest$ac_exeext'
11864 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11865 (eval $ac_try) 2>&5
11866 ac_status=$?
11867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11868 (exit $ac_status); }; }; then
11869 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011870else
Martin v. Löwis11437992002-04-12 09:54:03 +000011871 echo "$as_me: failed program was:" >&5
11872cat conftest.$ac_ext >&5
11873eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011874fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011875rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011876fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011877echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11878echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11879if test `eval echo '${'$as_ac_var'}'` = yes; then
11880 cat >>confdefs.h <<_ACEOF
11881#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11882_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011883
Guido van Rossume97ee181999-12-20 21:27:22 +000011884fi
Thomas Wouters3a584202000-08-05 23:28:51 +000011885done
Guido van Rossume97ee181999-12-20 21:27:22 +000011886
Michael W. Hudson54241132001-12-07 15:38:26 +000011887
Guido van Rossume97ee181999-12-20 21:27:22 +000011888# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
11889# loading of modules.
11890
Martin v. Löwis11437992002-04-12 09:54:03 +000011891echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
11892echo $ECHO_N "checking DYNLOADFILE... $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011893if test -z "$DYNLOADFILE"
11894then
11895 case $ac_sys_system/$ac_sys_release in
11896 AIX*) DYNLOADFILE="dynload_aix.o";;
11897 BeOS*) DYNLOADFILE="dynload_beos.o";;
11898 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Jack Jansene578a632001-08-15 01:27:14 +000011899 Darwin/*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011900 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000011901 *)
11902 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
11903 # out any dynamic loading
11904 if test "$ac_cv_func_dlopen" = yes
11905 then DYNLOADFILE="dynload_shlib.o"
11906 else DYNLOADFILE="dynload_stub.o"
11907 fi
11908 ;;
11909 esac
11910fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011911echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
11912echo "${ECHO_T}$DYNLOADFILE" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011913if test "$DYNLOADFILE" != "dynload_stub.o"
11914then
Martin v. Löwis11437992002-04-12 09:54:03 +000011915
11916cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011917#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011918_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011919
11920fi
11921
Neil Schemenauer4e425612001-06-19 15:44:15 +000011922# MACHDEP_OBJS can be set to platform-specific object files needed by Python
11923
Michael W. Hudson54241132001-12-07 15:38:26 +000011924
Martin v. Löwis11437992002-04-12 09:54:03 +000011925echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
11926echo $ECHO_N "checking MACHDEP_OBJS... $ECHO_C" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011927if test -z "$MACHDEP_OBJS"
11928then
Jack Jansene578a632001-08-15 01:27:14 +000011929 MACHDEP_OBJS=$extra_machdep_objs
11930else
11931 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000011932fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011933echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
11934echo "${ECHO_T}MACHDEP_OBJS" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011935
Guido van Rossum627b2d71993-12-24 10:39:16 +000011936# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011937
11938
11939
11940
11941
11942
11943
11944
11945
11946
11947
11948
11949
11950
11951
11952
11953
11954
11955
11956
11957
11958
11959
11960
11961
11962
11963
11964
11965
11966
11967
11968
11969
11970
11971
11972
11973
11974
11975
11976
11977
11978
11979
11980
11981
11982
11983
11984
11985
11986
11987
11988
11989
11990
11991
11992
11993
11994
11995
11996
11997
11998
11999
12000
12001
12002
12003
12004
12005
12006
12007
12008
12009
Martin v. Löwisd5843682002-11-21 20:41:28 +000012010for ac_func in alarm chown clock confstr ctermid execv \
Fred Drake6b3cc522002-04-15 19:20:27 +000012011 fchdir flock fork fsync fdatasync fpathconf ftime ftruncate \
Martin v. Löwis606edc12002-06-13 21:09:11 +000012012 gai_strerror getgroups getlogin getpeername getpgid getpid getpwent getwd \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012013 hstrerror inet_pton kill killpg lchown lstat mkfifo mknod mktime \
Martin v. Löwisa5f09072002-10-11 05:37:59 +000012014 mremap nice pathconf pause plock poll pthread_init \
Fred Drake35a092f1999-12-13 16:23:35 +000012015 putenv readlink \
Martin v. Löwisd5843682002-11-21 20:41:28 +000012016 select setegid seteuid setgid \
Martin v. Löwis791bfda2001-07-24 06:33:08 +000012017 setlocale setregid setreuid setsid setpgid setuid setvbuf snprintf \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012018 sigaction siginterrupt sigrelse strftime strptime \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000012019 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Martin v. Löwis6aa9fdb2002-09-10 09:16:13 +000012020 truncate uname unsetenv utimes waitpid _getpty getpriority
Guido van Rossum627b2d71993-12-24 10:39:16 +000012021do
Martin v. Löwis11437992002-04-12 09:54:03 +000012022as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12023echo "$as_me:$LINENO: checking for $ac_func" >&5
12024echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12025if eval "test \"\${$as_ac_var+set}\" = set"; then
12026 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012027else
Martin v. Löwis11437992002-04-12 09:54:03 +000012028 cat >conftest.$ac_ext <<_ACEOF
12029#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012030#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012031/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012032 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012033#include <assert.h>
12034/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012035#ifdef __cplusplus
12036extern "C"
12037#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012038/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012039 builtin and then its argument prototype would still apply. */
12040char $ac_func ();
12041char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012042
Martin v. Löwis11437992002-04-12 09:54:03 +000012043#ifdef F77_DUMMY_MAIN
12044# ifdef __cplusplus
12045 extern "C"
12046# endif
12047 int F77_DUMMY_MAIN() { return 1; }
12048#endif
12049int
12050main ()
12051{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012052/* The GNU C library defines this for functions which it implements
12053 to always fail with ENOSYS. Some functions are actually named
12054 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012055#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012056choke me
12057#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012058f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012059#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012060
Martin v. Löwis11437992002-04-12 09:54:03 +000012061 ;
12062 return 0;
12063}
12064_ACEOF
12065rm -f conftest.$ac_objext conftest$ac_exeext
12066if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12067 (eval $ac_link) 2>&5
12068 ac_status=$?
12069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12070 (exit $ac_status); } &&
12071 { ac_try='test -s conftest$ac_exeext'
12072 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12073 (eval $ac_try) 2>&5
12074 ac_status=$?
12075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12076 (exit $ac_status); }; }; then
12077 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012078else
Martin v. Löwis11437992002-04-12 09:54:03 +000012079 echo "$as_me: failed program was:" >&5
12080cat conftest.$ac_ext >&5
12081eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012082fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012083rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012084fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012085echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12086echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12087if test `eval echo '${'$as_ac_var'}'` = yes; then
12088 cat >>confdefs.h <<_ACEOF
12089#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12090_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012091
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012092fi
12093done
12094
Michael W. Hudson54241132001-12-07 15:38:26 +000012095
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012096# For some functions, having a definition is not sufficient, since
12097# we want to take their address.
12098echo "$as_me:$LINENO: checking for chroot" >&5
12099echo $ECHO_N "checking for chroot... $ECHO_C" >&6
12100cat >conftest.$ac_ext <<_ACEOF
12101#line $LINENO "configure"
12102#include "confdefs.h"
12103#include <unistd.h>
12104#ifdef F77_DUMMY_MAIN
12105# ifdef __cplusplus
12106 extern "C"
12107# endif
12108 int F77_DUMMY_MAIN() { return 1; }
12109#endif
12110int
12111main ()
12112{
12113void *x=chroot
12114 ;
12115 return 0;
12116}
12117_ACEOF
12118rm -f conftest.$ac_objext
12119if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12120 (eval $ac_compile) 2>&5
12121 ac_status=$?
12122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12123 (exit $ac_status); } &&
12124 { ac_try='test -s conftest.$ac_objext'
12125 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12126 (eval $ac_try) 2>&5
12127 ac_status=$?
12128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12129 (exit $ac_status); }; }; then
12130
12131cat >>confdefs.h <<\_ACEOF
12132#define HAVE_CHROOT 1
12133_ACEOF
12134
12135 echo "$as_me:$LINENO: result: yes" >&5
12136echo "${ECHO_T}yes" >&6
12137else
12138 echo "$as_me: failed program was:" >&5
12139cat conftest.$ac_ext >&5
12140echo "$as_me:$LINENO: result: no" >&5
12141echo "${ECHO_T}no" >&6
12142
12143fi
12144rm -f conftest.$ac_objext conftest.$ac_ext
12145echo "$as_me:$LINENO: checking for link" >&5
12146echo $ECHO_N "checking for link... $ECHO_C" >&6
12147cat >conftest.$ac_ext <<_ACEOF
12148#line $LINENO "configure"
12149#include "confdefs.h"
12150#include <unistd.h>
12151#ifdef F77_DUMMY_MAIN
12152# ifdef __cplusplus
12153 extern "C"
12154# endif
12155 int F77_DUMMY_MAIN() { return 1; }
12156#endif
12157int
12158main ()
12159{
12160void *x=link
12161 ;
12162 return 0;
12163}
12164_ACEOF
12165rm -f conftest.$ac_objext
12166if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12167 (eval $ac_compile) 2>&5
12168 ac_status=$?
12169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12170 (exit $ac_status); } &&
12171 { ac_try='test -s conftest.$ac_objext'
12172 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12173 (eval $ac_try) 2>&5
12174 ac_status=$?
12175 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12176 (exit $ac_status); }; }; then
12177
12178cat >>confdefs.h <<\_ACEOF
12179#define HAVE_LINK 1
12180_ACEOF
12181
12182 echo "$as_me:$LINENO: result: yes" >&5
12183echo "${ECHO_T}yes" >&6
12184else
12185 echo "$as_me: failed program was:" >&5
12186cat conftest.$ac_ext >&5
12187echo "$as_me:$LINENO: result: no" >&5
12188echo "${ECHO_T}no" >&6
12189
12190fi
12191rm -f conftest.$ac_objext conftest.$ac_ext
12192echo "$as_me:$LINENO: checking for symlink" >&5
12193echo $ECHO_N "checking for symlink... $ECHO_C" >&6
12194cat >conftest.$ac_ext <<_ACEOF
12195#line $LINENO "configure"
12196#include "confdefs.h"
12197#include <unistd.h>
12198#ifdef F77_DUMMY_MAIN
12199# ifdef __cplusplus
12200 extern "C"
12201# endif
12202 int F77_DUMMY_MAIN() { return 1; }
12203#endif
12204int
12205main ()
12206{
12207void *x=symlink
12208 ;
12209 return 0;
12210}
12211_ACEOF
12212rm -f conftest.$ac_objext
12213if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12214 (eval $ac_compile) 2>&5
12215 ac_status=$?
12216 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12217 (exit $ac_status); } &&
12218 { ac_try='test -s conftest.$ac_objext'
12219 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12220 (eval $ac_try) 2>&5
12221 ac_status=$?
12222 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12223 (exit $ac_status); }; }; then
12224
12225cat >>confdefs.h <<\_ACEOF
12226#define HAVE_SYMLINK 1
12227_ACEOF
12228
12229 echo "$as_me:$LINENO: result: yes" >&5
12230echo "${ECHO_T}yes" >&6
12231else
12232 echo "$as_me: failed program was:" >&5
12233cat conftest.$ac_ext >&5
12234echo "$as_me:$LINENO: result: no" >&5
12235echo "${ECHO_T}no" >&6
12236
12237fi
12238rm -f conftest.$ac_objext conftest.$ac_ext
12239
Martin v. Löwisd5843682002-11-21 20:41:28 +000012240# On some systems (eg. FreeBSD 5), we would find a definition of the
12241# functions ctermid_r, setgroups in the library, but no prototype
12242# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
12243# address to avoid compiler warnings and potential miscompilations
12244# because of the missing prototypes.
12245
12246echo "$as_me:$LINENO: checking for ctermid_r" >&5
12247echo $ECHO_N "checking for ctermid_r... $ECHO_C" >&6
12248cat >conftest.$ac_ext <<_ACEOF
12249#line $LINENO "configure"
12250#include "confdefs.h"
12251
12252#include "confdefs.h"
12253#include <stdio.h>
12254
12255#ifdef F77_DUMMY_MAIN
12256# ifdef __cplusplus
12257 extern "C"
12258# endif
12259 int F77_DUMMY_MAIN() { return 1; }
12260#endif
12261int
12262main ()
12263{
12264void* p = ctermid_r
12265 ;
12266 return 0;
12267}
12268_ACEOF
12269rm -f conftest.$ac_objext
12270if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12271 (eval $ac_compile) 2>&5
12272 ac_status=$?
12273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12274 (exit $ac_status); } &&
12275 { ac_try='test -s conftest.$ac_objext'
12276 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12277 (eval $ac_try) 2>&5
12278 ac_status=$?
12279 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12280 (exit $ac_status); }; }; then
12281
12282cat >>confdefs.h <<\_ACEOF
12283#define HAVE_CTERMID_R 1
12284_ACEOF
12285
12286 echo "$as_me:$LINENO: result: yes" >&5
12287echo "${ECHO_T}yes" >&6
12288else
12289 echo "$as_me: failed program was:" >&5
12290cat conftest.$ac_ext >&5
12291echo "$as_me:$LINENO: result: no" >&5
12292echo "${ECHO_T}no" >&6
12293
12294fi
12295rm -f conftest.$ac_objext conftest.$ac_ext
12296
12297echo "$as_me:$LINENO: checking for setgroups" >&5
12298echo $ECHO_N "checking for setgroups... $ECHO_C" >&6
12299cat >conftest.$ac_ext <<_ACEOF
12300#line $LINENO "configure"
12301#include "confdefs.h"
12302
12303#include "confdefs.h"
12304#include <unistd.h.h>
12305
12306#ifdef F77_DUMMY_MAIN
12307# ifdef __cplusplus
12308 extern "C"
12309# endif
12310 int F77_DUMMY_MAIN() { return 1; }
12311#endif
12312int
12313main ()
12314{
12315void* p = setgroups
12316 ;
12317 return 0;
12318}
12319_ACEOF
12320rm -f conftest.$ac_objext
12321if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12322 (eval $ac_compile) 2>&5
12323 ac_status=$?
12324 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12325 (exit $ac_status); } &&
12326 { ac_try='test -s conftest.$ac_objext'
12327 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12328 (eval $ac_try) 2>&5
12329 ac_status=$?
12330 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12331 (exit $ac_status); }; }; then
12332
12333cat >>confdefs.h <<\_ACEOF
12334#define HAVE_SETGROUPS 1
12335_ACEOF
12336
12337 echo "$as_me:$LINENO: result: yes" >&5
12338echo "${ECHO_T}yes" >&6
12339else
12340 echo "$as_me: failed program was:" >&5
12341cat conftest.$ac_ext >&5
12342echo "$as_me:$LINENO: result: no" >&5
12343echo "${ECHO_T}no" >&6
12344
12345fi
12346rm -f conftest.$ac_objext conftest.$ac_ext
12347
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012348# check for openpty and forkpty
12349
Martin v. Löwis11437992002-04-12 09:54:03 +000012350
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012351for ac_func in openpty
12352do
Martin v. Löwis11437992002-04-12 09:54:03 +000012353as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12354echo "$as_me:$LINENO: checking for $ac_func" >&5
12355echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12356if eval "test \"\${$as_ac_var+set}\" = set"; then
12357 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012358else
Martin v. Löwis11437992002-04-12 09:54:03 +000012359 cat >conftest.$ac_ext <<_ACEOF
12360#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012361#include "confdefs.h"
12362/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012363 which can conflict with char $ac_func (); below. */
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012364#include <assert.h>
12365/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012366#ifdef __cplusplus
12367extern "C"
12368#endif
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012369/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012370 builtin and then its argument prototype would still apply. */
12371char $ac_func ();
12372char (*f) ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012373
Martin v. Löwis11437992002-04-12 09:54:03 +000012374#ifdef F77_DUMMY_MAIN
12375# ifdef __cplusplus
12376 extern "C"
12377# endif
12378 int F77_DUMMY_MAIN() { return 1; }
12379#endif
12380int
12381main ()
12382{
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012383/* The GNU C library defines this for functions which it implements
12384 to always fail with ENOSYS. Some functions are actually named
12385 something starting with __ and the normal name is an alias. */
12386#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12387choke me
12388#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012389f = $ac_func;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012390#endif
12391
Martin v. Löwis11437992002-04-12 09:54:03 +000012392 ;
12393 return 0;
12394}
12395_ACEOF
12396rm -f conftest.$ac_objext conftest$ac_exeext
12397if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12398 (eval $ac_link) 2>&5
12399 ac_status=$?
12400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12401 (exit $ac_status); } &&
12402 { ac_try='test -s conftest$ac_exeext'
12403 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12404 (eval $ac_try) 2>&5
12405 ac_status=$?
12406 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12407 (exit $ac_status); }; }; then
12408 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012409else
Martin v. Löwis11437992002-04-12 09:54:03 +000012410 echo "$as_me: failed program was:" >&5
12411cat conftest.$ac_ext >&5
12412eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012413fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012414rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012415fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012416echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12417echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12418if test `eval echo '${'$as_ac_var'}'` = yes; then
12419 cat >>confdefs.h <<_ACEOF
12420#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12421_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012422
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012423else
Martin v. Löwis11437992002-04-12 09:54:03 +000012424 echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
12425echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
12426if test "${ac_cv_lib_util_openpty+set}" = set; then
12427 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012428else
Martin v. Löwis11437992002-04-12 09:54:03 +000012429 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012430LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012431cat >conftest.$ac_ext <<_ACEOF
12432#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012433#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000012434
Fred Drake8cef4cf2000-06-28 16:40:38 +000012435/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012436#ifdef __cplusplus
12437extern "C"
12438#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012439/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012440 builtin and then its argument prototype would still apply. */
12441char openpty ();
12442#ifdef F77_DUMMY_MAIN
12443# ifdef __cplusplus
12444 extern "C"
12445# endif
12446 int F77_DUMMY_MAIN() { return 1; }
12447#endif
12448int
12449main ()
12450{
12451openpty ();
12452 ;
12453 return 0;
12454}
12455_ACEOF
12456rm -f conftest.$ac_objext conftest$ac_exeext
12457if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12458 (eval $ac_link) 2>&5
12459 ac_status=$?
12460 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12461 (exit $ac_status); } &&
12462 { ac_try='test -s conftest$ac_exeext'
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 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012469else
Martin v. Löwis11437992002-04-12 09:54:03 +000012470 echo "$as_me: failed program was:" >&5
12471cat conftest.$ac_ext >&5
12472ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012473fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012474rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12475LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012476fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012477echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
12478echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
12479if test $ac_cv_lib_util_openpty = yes; then
12480 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012481#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012482_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012483 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012484fi
12485
12486fi
12487done
12488
Martin v. Löwis11437992002-04-12 09:54:03 +000012489
Fred Drake8cef4cf2000-06-28 16:40:38 +000012490for ac_func in forkpty
12491do
Martin v. Löwis11437992002-04-12 09:54:03 +000012492as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12493echo "$as_me:$LINENO: checking for $ac_func" >&5
12494echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12495if eval "test \"\${$as_ac_var+set}\" = set"; then
12496 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012497else
Martin v. Löwis11437992002-04-12 09:54:03 +000012498 cat >conftest.$ac_ext <<_ACEOF
12499#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012500#include "confdefs.h"
12501/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012502 which can conflict with char $ac_func (); below. */
Fred Drake8cef4cf2000-06-28 16:40:38 +000012503#include <assert.h>
12504/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012505#ifdef __cplusplus
12506extern "C"
12507#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012508/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012509 builtin and then its argument prototype would still apply. */
12510char $ac_func ();
12511char (*f) ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000012512
Martin v. Löwis11437992002-04-12 09:54:03 +000012513#ifdef F77_DUMMY_MAIN
12514# ifdef __cplusplus
12515 extern "C"
12516# endif
12517 int F77_DUMMY_MAIN() { return 1; }
12518#endif
12519int
12520main ()
12521{
Fred Drake8cef4cf2000-06-28 16:40:38 +000012522/* The GNU C library defines this for functions which it implements
12523 to always fail with ENOSYS. Some functions are actually named
12524 something starting with __ and the normal name is an alias. */
12525#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12526choke me
12527#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012528f = $ac_func;
Fred Drake8cef4cf2000-06-28 16:40:38 +000012529#endif
12530
Martin v. Löwis11437992002-04-12 09:54:03 +000012531 ;
12532 return 0;
12533}
12534_ACEOF
12535rm -f conftest.$ac_objext conftest$ac_exeext
12536if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12537 (eval $ac_link) 2>&5
12538 ac_status=$?
12539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12540 (exit $ac_status); } &&
12541 { ac_try='test -s conftest$ac_exeext'
12542 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12543 (eval $ac_try) 2>&5
12544 ac_status=$?
12545 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12546 (exit $ac_status); }; }; then
12547 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012548else
Martin v. Löwis11437992002-04-12 09:54:03 +000012549 echo "$as_me: failed program was:" >&5
12550cat conftest.$ac_ext >&5
12551eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012552fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012553rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012554fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012555echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12556echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12557if test `eval echo '${'$as_ac_var'}'` = yes; then
12558 cat >>confdefs.h <<_ACEOF
12559#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12560_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012561
Fred Drake8cef4cf2000-06-28 16:40:38 +000012562else
Martin v. Löwis11437992002-04-12 09:54:03 +000012563 echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
12564echo $ECHO_N "checking for forkpty in -lutil... $ECHO_C" >&6
12565if test "${ac_cv_lib_util_forkpty+set}" = set; then
12566 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012567else
Martin v. Löwis11437992002-04-12 09:54:03 +000012568 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012569LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012570cat >conftest.$ac_ext <<_ACEOF
12571#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012572#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000012573
Fred Drake8cef4cf2000-06-28 16:40:38 +000012574/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012575#ifdef __cplusplus
12576extern "C"
12577#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012578/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012579 builtin and then its argument prototype would still apply. */
12580char forkpty ();
12581#ifdef F77_DUMMY_MAIN
12582# ifdef __cplusplus
12583 extern "C"
12584# endif
12585 int F77_DUMMY_MAIN() { return 1; }
12586#endif
12587int
12588main ()
12589{
12590forkpty ();
12591 ;
12592 return 0;
12593}
12594_ACEOF
12595rm -f conftest.$ac_objext conftest$ac_exeext
12596if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12597 (eval $ac_link) 2>&5
12598 ac_status=$?
12599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12600 (exit $ac_status); } &&
12601 { ac_try='test -s conftest$ac_exeext'
12602 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12603 (eval $ac_try) 2>&5
12604 ac_status=$?
12605 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12606 (exit $ac_status); }; }; then
12607 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012608else
Martin v. Löwis11437992002-04-12 09:54:03 +000012609 echo "$as_me: failed program was:" >&5
12610cat conftest.$ac_ext >&5
12611ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012612fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012613rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12614LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012615fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012616echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
12617echo "${ECHO_T}$ac_cv_lib_util_forkpty" >&6
12618if test $ac_cv_lib_util_forkpty = yes; then
12619 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012620#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012621_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012622 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012623fi
12624
12625fi
12626done
12627
Jack Jansendd19cf82001-12-06 22:36:17 +000012628
Michael W. Hudson54241132001-12-07 15:38:26 +000012629# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000012630
12631
12632
12633
12634
12635
Fred Drake8cef4cf2000-06-28 16:40:38 +000012636for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
12637do
Martin v. Löwis11437992002-04-12 09:54:03 +000012638as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12639echo "$as_me:$LINENO: checking for $ac_func" >&5
12640echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12641if eval "test \"\${$as_ac_var+set}\" = set"; then
12642 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012643else
Martin v. Löwis11437992002-04-12 09:54:03 +000012644 cat >conftest.$ac_ext <<_ACEOF
12645#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012646#include "confdefs.h"
12647/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012648 which can conflict with char $ac_func (); below. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012649#include <assert.h>
12650/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012651#ifdef __cplusplus
12652extern "C"
12653#endif
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012654/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012655 builtin and then its argument prototype would still apply. */
12656char $ac_func ();
12657char (*f) ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012658
Martin v. Löwis11437992002-04-12 09:54:03 +000012659#ifdef F77_DUMMY_MAIN
12660# ifdef __cplusplus
12661 extern "C"
12662# endif
12663 int F77_DUMMY_MAIN() { return 1; }
12664#endif
12665int
12666main ()
12667{
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012668/* The GNU C library defines this for functions which it implements
12669 to always fail with ENOSYS. Some functions are actually named
12670 something starting with __ and the normal name is an alias. */
12671#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12672choke me
12673#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012674f = $ac_func;
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012675#endif
12676
Martin v. Löwis11437992002-04-12 09:54:03 +000012677 ;
12678 return 0;
12679}
12680_ACEOF
12681rm -f conftest.$ac_objext conftest$ac_exeext
12682if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12683 (eval $ac_link) 2>&5
12684 ac_status=$?
12685 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12686 (exit $ac_status); } &&
12687 { ac_try='test -s conftest$ac_exeext'
12688 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12689 (eval $ac_try) 2>&5
12690 ac_status=$?
12691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12692 (exit $ac_status); }; }; then
12693 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012694else
Martin v. Löwis11437992002-04-12 09:54:03 +000012695 echo "$as_me: failed program was:" >&5
12696cat conftest.$ac_ext >&5
12697eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012698fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012699rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012700fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012701echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12702echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12703if test `eval echo '${'$as_ac_var'}'` = yes; then
12704 cat >>confdefs.h <<_ACEOF
12705#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12706_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000012707
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012708fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000012709done
12710
Michael W. Hudson54241132001-12-07 15:38:26 +000012711
Martin v. Löwis11437992002-04-12 09:54:03 +000012712
12713
12714
12715
12716
Martin v. Löwis1142de32002-03-29 16:28:31 +000012717for ac_func in dup2 getcwd strdup strerror memmove
Thomas Wouters3a584202000-08-05 23:28:51 +000012718do
Martin v. Löwis11437992002-04-12 09:54:03 +000012719as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12720echo "$as_me:$LINENO: checking for $ac_func" >&5
12721echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12722if eval "test \"\${$as_ac_var+set}\" = set"; then
12723 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012724else
Martin v. Löwis11437992002-04-12 09:54:03 +000012725 cat >conftest.$ac_ext <<_ACEOF
12726#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012727#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012728/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012729 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012730#include <assert.h>
12731/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012732#ifdef __cplusplus
12733extern "C"
12734#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012735/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012736 builtin and then its argument prototype would still apply. */
12737char $ac_func ();
12738char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012739
Martin v. Löwis11437992002-04-12 09:54:03 +000012740#ifdef F77_DUMMY_MAIN
12741# ifdef __cplusplus
12742 extern "C"
12743# endif
12744 int F77_DUMMY_MAIN() { return 1; }
12745#endif
12746int
12747main ()
12748{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012749/* The GNU C library defines this for functions which it implements
12750 to always fail with ENOSYS. Some functions are actually named
12751 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012752#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012753choke me
12754#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012755f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012756#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012757
Martin v. Löwis11437992002-04-12 09:54:03 +000012758 ;
12759 return 0;
12760}
12761_ACEOF
12762rm -f conftest.$ac_objext conftest$ac_exeext
12763if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12764 (eval $ac_link) 2>&5
12765 ac_status=$?
12766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12767 (exit $ac_status); } &&
12768 { ac_try='test -s conftest$ac_exeext'
12769 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12770 (eval $ac_try) 2>&5
12771 ac_status=$?
12772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12773 (exit $ac_status); }; }; then
12774 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012775else
Martin v. Löwis11437992002-04-12 09:54:03 +000012776 echo "$as_me: failed program was:" >&5
12777cat conftest.$ac_ext >&5
12778eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012779fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012780rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000012781fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012782echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12783echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12784if test `eval echo '${'$as_ac_var'}'` = yes; then
12785 cat >>confdefs.h <<_ACEOF
12786#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12787_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000012788
Martin v. Löwis1142de32002-03-29 16:28:31 +000012789else
Martin v. Löwis11437992002-04-12 09:54:03 +000012790 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012791fi
12792done
12793
12794
Martin v. Löwis11437992002-04-12 09:54:03 +000012795
Martin v. Löwis1142de32002-03-29 16:28:31 +000012796for ac_func in getpgrp
12797do
Martin v. Löwis11437992002-04-12 09:54:03 +000012798as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12799echo "$as_me:$LINENO: checking for $ac_func" >&5
12800echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12801if eval "test \"\${$as_ac_var+set}\" = set"; then
12802 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000012803else
Martin v. Löwis11437992002-04-12 09:54:03 +000012804 cat >conftest.$ac_ext <<_ACEOF
12805#line $LINENO "configure"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012806#include "confdefs.h"
12807/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012808 which can conflict with char $ac_func (); below. */
Martin v. Löwis1142de32002-03-29 16:28:31 +000012809#include <assert.h>
12810/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012811#ifdef __cplusplus
12812extern "C"
12813#endif
Martin v. Löwis1142de32002-03-29 16:28:31 +000012814/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012815 builtin and then its argument prototype would still apply. */
12816char $ac_func ();
12817char (*f) ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000012818
Martin v. Löwis11437992002-04-12 09:54:03 +000012819#ifdef F77_DUMMY_MAIN
12820# ifdef __cplusplus
12821 extern "C"
12822# endif
12823 int F77_DUMMY_MAIN() { return 1; }
12824#endif
12825int
12826main ()
12827{
Martin v. Löwis1142de32002-03-29 16:28:31 +000012828/* The GNU C library defines this for functions which it implements
12829 to always fail with ENOSYS. Some functions are actually named
12830 something starting with __ and the normal name is an alias. */
12831#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12832choke me
12833#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012834f = $ac_func;
Martin v. Löwis1142de32002-03-29 16:28:31 +000012835#endif
12836
Martin v. Löwis11437992002-04-12 09:54:03 +000012837 ;
12838 return 0;
12839}
12840_ACEOF
12841rm -f conftest.$ac_objext conftest$ac_exeext
12842if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12843 (eval $ac_link) 2>&5
12844 ac_status=$?
12845 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12846 (exit $ac_status); } &&
12847 { ac_try='test -s conftest$ac_exeext'
12848 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12849 (eval $ac_try) 2>&5
12850 ac_status=$?
12851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12852 (exit $ac_status); }; }; then
12853 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012854else
Martin v. Löwis11437992002-04-12 09:54:03 +000012855 echo "$as_me: failed program was:" >&5
12856cat conftest.$ac_ext >&5
12857eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012858fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012859rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012860fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012861echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12862echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12863if test `eval echo '${'$as_ac_var'}'` = yes; then
12864 cat >>confdefs.h <<_ACEOF
12865#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12866_ACEOF
12867 cat >conftest.$ac_ext <<_ACEOF
12868#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012869#include "confdefs.h"
12870#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012871#ifdef F77_DUMMY_MAIN
12872# ifdef __cplusplus
12873 extern "C"
12874# endif
12875 int F77_DUMMY_MAIN() { return 1; }
12876#endif
12877int
12878main ()
12879{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012880getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000012881 ;
12882 return 0;
12883}
12884_ACEOF
12885rm -f conftest.$ac_objext
12886if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12887 (eval $ac_compile) 2>&5
12888 ac_status=$?
12889 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12890 (exit $ac_status); } &&
12891 { ac_try='test -s conftest.$ac_objext'
12892 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12893 (eval $ac_try) 2>&5
12894 ac_status=$?
12895 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12896 (exit $ac_status); }; }; then
12897
12898cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012899#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012900_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012901
Martin v. Löwis11437992002-04-12 09:54:03 +000012902
Guido van Rossumf78abae1997-01-21 22:02:36 +000012903else
Martin v. Löwis11437992002-04-12 09:54:03 +000012904 echo "$as_me: failed program was:" >&5
12905cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000012906fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012907rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000012908
Guido van Rossum627b2d71993-12-24 10:39:16 +000012909fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012910done
Guido van Rossum627b2d71993-12-24 10:39:16 +000012911
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012912echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
12913echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
12914if test "${ac_cv_func_setpgrp_void+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012915 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012916else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012917 if test "$cross_compiling" = yes; then
12918 { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5
12919echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;}
12920 { (exit 1); exit 1; }; }
12921else
Martin v. Löwis11437992002-04-12 09:54:03 +000012922 cat >conftest.$ac_ext <<_ACEOF
12923#line $LINENO "configure"
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012924#include "confdefs.h"
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012925#if HAVE_UNISTD_H
12926# include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012927#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012928
Martin v. Löwis11437992002-04-12 09:54:03 +000012929#ifdef F77_DUMMY_MAIN
12930# ifdef __cplusplus
12931 extern "C"
12932# endif
12933 int F77_DUMMY_MAIN() { return 1; }
12934#endif
12935int
12936main ()
12937{
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012938/* If this system has a BSD-style setpgrp which takes arguments,
12939 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
12940 exit successfully. */
12941 exit (setpgrp (1,1) == -1 ? 0 : 1);
Martin v. Löwis11437992002-04-12 09:54:03 +000012942 ;
12943 return 0;
12944}
12945_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012946rm -f conftest$ac_exeext
Martin v. Löwis11437992002-04-12 09:54:03 +000012947if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12948 (eval $ac_link) 2>&5
12949 ac_status=$?
12950 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012951 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwis11437992002-04-12 09:54:03 +000012952 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12953 (eval $ac_try) 2>&5
12954 ac_status=$?
12955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12956 (exit $ac_status); }; }; then
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012957 ac_cv_func_setpgrp_void=no
Michael W. Hudson54241132001-12-07 15:38:26 +000012958else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012959 echo "$as_me: program exited with status $ac_status" >&5
12960echo "$as_me: failed program was:" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012961cat conftest.$ac_ext >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012962( exit $ac_status )
12963ac_cv_func_setpgrp_void=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000012964fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012965rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012966fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012967fi
12968echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
12969echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
12970if test $ac_cv_func_setpgrp_void = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012971
12972cat >>confdefs.h <<\_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012973#define SETPGRP_VOID 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012974_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012975
12976fi
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012977
Martin v. Löwis11437992002-04-12 09:54:03 +000012978
Thomas Wouters3a584202000-08-05 23:28:51 +000012979for ac_func in gettimeofday
12980do
Martin v. Löwis11437992002-04-12 09:54:03 +000012981as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12982echo "$as_me:$LINENO: checking for $ac_func" >&5
12983echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12984if eval "test \"\${$as_ac_var+set}\" = set"; then
12985 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012986else
Martin v. Löwis11437992002-04-12 09:54:03 +000012987 cat >conftest.$ac_ext <<_ACEOF
12988#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012989#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012990/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012991 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012992#include <assert.h>
12993/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012994#ifdef __cplusplus
12995extern "C"
12996#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012997/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012998 builtin and then its argument prototype would still apply. */
12999char $ac_func ();
13000char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013001
Martin v. Löwis11437992002-04-12 09:54:03 +000013002#ifdef F77_DUMMY_MAIN
13003# ifdef __cplusplus
13004 extern "C"
13005# endif
13006 int F77_DUMMY_MAIN() { return 1; }
13007#endif
13008int
13009main ()
13010{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013011/* The GNU C library defines this for functions which it implements
13012 to always fail with ENOSYS. Some functions are actually named
13013 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000013014#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013015choke me
13016#else
Martin v. Löwis11437992002-04-12 09:54:03 +000013017f = $ac_func;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013018#endif
13019
Martin v. Löwis11437992002-04-12 09:54:03 +000013020 ;
13021 return 0;
13022}
13023_ACEOF
13024rm -f conftest.$ac_objext conftest$ac_exeext
13025if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13026 (eval $ac_link) 2>&5
13027 ac_status=$?
13028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13029 (exit $ac_status); } &&
13030 { ac_try='test -s conftest$ac_exeext'
13031 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13032 (eval $ac_try) 2>&5
13033 ac_status=$?
13034 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13035 (exit $ac_status); }; }; then
13036 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013037else
Martin v. Löwis11437992002-04-12 09:54:03 +000013038 echo "$as_me: failed program was:" >&5
13039cat conftest.$ac_ext >&5
13040eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013041fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013042rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013043fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013044echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13045echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13046if test `eval echo '${'$as_ac_var'}'` = yes; then
13047 cat >>confdefs.h <<_ACEOF
13048#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13049_ACEOF
13050 cat >conftest.$ac_ext <<_ACEOF
13051#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013052#include "confdefs.h"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013053#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013054#ifdef F77_DUMMY_MAIN
13055# ifdef __cplusplus
13056 extern "C"
13057# endif
13058 int F77_DUMMY_MAIN() { return 1; }
13059#endif
13060int
13061main ()
13062{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013063gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000013064 ;
13065 return 0;
13066}
13067_ACEOF
13068rm -f conftest.$ac_objext
13069if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13070 (eval $ac_compile) 2>&5
13071 ac_status=$?
13072 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13073 (exit $ac_status); } &&
13074 { ac_try='test -s conftest.$ac_objext'
13075 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13076 (eval $ac_try) 2>&5
13077 ac_status=$?
13078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13079 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000013080 :
13081else
Martin v. Löwis11437992002-04-12 09:54:03 +000013082 echo "$as_me: failed program was:" >&5
13083cat conftest.$ac_ext >&5
13084
13085cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013086#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013087_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013088
Martin v. Löwis11437992002-04-12 09:54:03 +000013089
Guido van Rossum627b2d71993-12-24 10:39:16 +000013090fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013091rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013092
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013093fi
Thomas Wouters3a584202000-08-05 23:28:51 +000013094done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013095
Michael W. Hudson54241132001-12-07 15:38:26 +000013096
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000013097echo "$as_me:$LINENO: checking for major" >&5
13098echo $ECHO_N "checking for major... $ECHO_C" >&6
13099cat >conftest.$ac_ext <<_ACEOF
13100#line $LINENO "configure"
13101#include "confdefs.h"
13102
13103 #if defined(MAJOR_IN_MKDEV)
13104 #include <sys/mkdev.h>
13105 #elif defined(MAJOR_IN_SYSMACROS)
13106 #include <sys/sysmacros.h>
13107 #else
13108 #include <sys/types.h>
13109 #endif
13110
13111#ifdef F77_DUMMY_MAIN
13112# ifdef __cplusplus
13113 extern "C"
13114# endif
13115 int F77_DUMMY_MAIN() { return 1; }
13116#endif
13117int
13118main ()
13119{
13120
13121 makedev(major(0),minor(0));
13122
13123 ;
13124 return 0;
13125}
13126_ACEOF
Martin v. Löwise3271202002-11-07 07:42:30 +000013127rm -f conftest.$ac_objext conftest$ac_exeext
13128if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13129 (eval $ac_link) 2>&5
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000013130 ac_status=$?
13131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13132 (exit $ac_status); } &&
Martin v. Löwise3271202002-11-07 07:42:30 +000013133 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000013134 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13135 (eval $ac_try) 2>&5
13136 ac_status=$?
13137 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13138 (exit $ac_status); }; }; then
13139
13140
13141cat >>confdefs.h <<\_ACEOF
13142#define HAVE_DEVICE_MACROS 1
13143_ACEOF
13144
13145 echo "$as_me:$LINENO: result: yes" >&5
13146echo "${ECHO_T}yes" >&6
13147
13148else
13149 echo "$as_me: failed program was:" >&5
13150cat conftest.$ac_ext >&5
13151
13152 echo "$as_me:$LINENO: result: no" >&5
13153echo "${ECHO_T}no" >&6
13154
13155fi
Martin v. Löwise3271202002-11-07 07:42:30 +000013156rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013157
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013158# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000013159# for [no]getaddrinfo in netdb.h.
13160echo "$as_me:$LINENO: checking for getaddrinfo" >&5
13161echo $ECHO_N "checking for getaddrinfo... $ECHO_C" >&6
13162cat >conftest.$ac_ext <<_ACEOF
13163#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013164#include "confdefs.h"
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013165
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000013166#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013167#include <sys/socket.h>
13168#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000013169#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013170
Martin v. Löwis11437992002-04-12 09:54:03 +000013171#ifdef F77_DUMMY_MAIN
13172# ifdef __cplusplus
13173 extern "C"
13174# endif
13175 int F77_DUMMY_MAIN() { return 1; }
13176#endif
13177int
13178main ()
13179{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013180
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013181getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013182
Martin v. Löwis11437992002-04-12 09:54:03 +000013183 ;
13184 return 0;
13185}
13186_ACEOF
13187rm -f conftest.$ac_objext conftest$ac_exeext
13188if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13189 (eval $ac_link) 2>&5
13190 ac_status=$?
13191 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13192 (exit $ac_status); } &&
13193 { ac_try='test -s conftest$ac_exeext'
13194 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13195 (eval $ac_try) 2>&5
13196 ac_status=$?
13197 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13198 (exit $ac_status); }; }; then
13199
13200echo "$as_me:$LINENO: result: yes" >&5
13201echo "${ECHO_T}yes" >&6
13202echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
13203echo $ECHO_N "checking getaddrinfo bug... $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013204if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013205 echo "$as_me:$LINENO: result: buggy" >&5
13206echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013207buggygetaddrinfo=yes
13208else
Martin v. Löwis11437992002-04-12 09:54:03 +000013209 cat >conftest.$ac_ext <<_ACEOF
13210#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013211#include "confdefs.h"
13212
13213#include <sys/types.h>
13214#include <netdb.h>
13215#include <string.h>
13216#include <sys/socket.h>
13217#include <netinet/in.h>
13218
13219main()
13220{
13221 int passive, gaierr, inet4 = 0, inet6 = 0;
13222 struct addrinfo hints, *ai, *aitop;
13223 char straddr[INET6_ADDRSTRLEN], strport[16];
13224
13225 for (passive = 0; passive <= 1; passive++) {
13226 memset(&hints, 0, sizeof(hints));
13227 hints.ai_family = AF_UNSPEC;
13228 hints.ai_flags = passive ? AI_PASSIVE : 0;
13229 hints.ai_socktype = SOCK_STREAM;
13230 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
13231 (void)gai_strerror(gaierr);
13232 goto bad;
13233 }
13234 for (ai = aitop; ai; ai = ai->ai_next) {
13235 if (ai->ai_addr == NULL ||
13236 ai->ai_addrlen == 0 ||
13237 getnameinfo(ai->ai_addr, ai->ai_addrlen,
13238 straddr, sizeof(straddr), strport, sizeof(strport),
13239 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
13240 goto bad;
13241 }
13242 switch (ai->ai_family) {
13243 case AF_INET:
13244 if (strcmp(strport, "54321") != 0) {
13245 goto bad;
13246 }
13247 if (passive) {
13248 if (strcmp(straddr, "0.0.0.0") != 0) {
13249 goto bad;
13250 }
13251 } else {
13252 if (strcmp(straddr, "127.0.0.1") != 0) {
13253 goto bad;
13254 }
13255 }
13256 inet4++;
13257 break;
13258 case AF_INET6:
13259 if (strcmp(strport, "54321") != 0) {
13260 goto bad;
13261 }
13262 if (passive) {
13263 if (strcmp(straddr, "::") != 0) {
13264 goto bad;
13265 }
13266 } else {
13267 if (strcmp(straddr, "::1") != 0) {
13268 goto bad;
13269 }
13270 }
13271 inet6++;
13272 break;
13273 case AF_UNSPEC:
13274 goto bad;
13275 break;
13276 default:
13277 /* another family support? */
13278 break;
13279 }
13280 }
13281 }
13282
13283 if (!(inet4 == 0 || inet4 == 2))
13284 goto bad;
13285 if (!(inet6 == 0 || inet6 == 2))
13286 goto bad;
13287
13288 if (aitop)
13289 freeaddrinfo(aitop);
13290 exit(0);
13291
13292 bad:
13293 if (aitop)
13294 freeaddrinfo(aitop);
13295 exit(1);
13296}
13297
Martin v. Löwis11437992002-04-12 09:54:03 +000013298_ACEOF
13299rm -f conftest$ac_exeext
13300if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13301 (eval $ac_link) 2>&5
13302 ac_status=$?
13303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13304 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13305 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13306 (eval $ac_try) 2>&5
13307 ac_status=$?
13308 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13309 (exit $ac_status); }; }; then
13310 echo "$as_me:$LINENO: result: good" >&5
13311echo "${ECHO_T}good" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013312buggygetaddrinfo=no
13313else
Martin v. Löwis11437992002-04-12 09:54:03 +000013314 echo "$as_me: program exited with status $ac_status" >&5
13315echo "$as_me: failed program was:" >&5
13316cat conftest.$ac_ext >&5
13317( exit $ac_status )
13318echo "$as_me:$LINENO: result: buggy" >&5
13319echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013320buggygetaddrinfo=yes
13321fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013322rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013323fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013324else
Martin v. Löwis11437992002-04-12 09:54:03 +000013325 echo "$as_me: failed program was:" >&5
13326cat conftest.$ac_ext >&5
13327
13328echo "$as_me:$LINENO: result: no" >&5
13329echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013330buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013331
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013332fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013333rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013334
13335if test "$buggygetaddrinfo" = "yes"; then
13336 if test "$ipv6" = "yes"; then
13337 echo 'Fatal: You must get working getaddrinfo() function.'
13338 echo ' or you can specify "--disable-ipv6"'.
13339 exit 1
13340 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013341else
Martin v. Löwis11437992002-04-12 09:54:03 +000013342
13343cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013344#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013345_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013346
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013347fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013348
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013349for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013350do
Martin v. Löwis11437992002-04-12 09:54:03 +000013351as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13352echo "$as_me:$LINENO: checking for $ac_func" >&5
13353echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13354if eval "test \"\${$as_ac_var+set}\" = set"; then
13355 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013356else
Martin v. Löwis11437992002-04-12 09:54:03 +000013357 cat >conftest.$ac_ext <<_ACEOF
13358#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013359#include "confdefs.h"
13360/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000013361 which can conflict with char $ac_func (); below. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013362#include <assert.h>
13363/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013364#ifdef __cplusplus
13365extern "C"
13366#endif
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013367/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000013368 builtin and then its argument prototype would still apply. */
13369char $ac_func ();
13370char (*f) ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013371
Martin v. Löwis11437992002-04-12 09:54:03 +000013372#ifdef F77_DUMMY_MAIN
13373# ifdef __cplusplus
13374 extern "C"
13375# endif
13376 int F77_DUMMY_MAIN() { return 1; }
13377#endif
13378int
13379main ()
13380{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013381/* The GNU C library defines this for functions which it implements
13382 to always fail with ENOSYS. Some functions are actually named
13383 something starting with __ and the normal name is an alias. */
13384#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13385choke me
13386#else
Martin v. Löwis11437992002-04-12 09:54:03 +000013387f = $ac_func;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013388#endif
13389
Martin v. Löwis11437992002-04-12 09:54:03 +000013390 ;
13391 return 0;
13392}
13393_ACEOF
13394rm -f conftest.$ac_objext conftest$ac_exeext
13395if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13396 (eval $ac_link) 2>&5
13397 ac_status=$?
13398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13399 (exit $ac_status); } &&
13400 { ac_try='test -s conftest$ac_exeext'
13401 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13402 (eval $ac_try) 2>&5
13403 ac_status=$?
13404 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13405 (exit $ac_status); }; }; then
13406 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013407else
Martin v. Löwis11437992002-04-12 09:54:03 +000013408 echo "$as_me: failed program was:" >&5
13409cat conftest.$ac_ext >&5
13410eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013411fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013412rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013413fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013414echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13415echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13416if test `eval echo '${'$as_ac_var'}'` = yes; then
13417 cat >>confdefs.h <<_ACEOF
13418#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13419_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013420
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013421fi
13422done
13423
Michael W. Hudson54241132001-12-07 15:38:26 +000013424
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013425# checks for structures
Martin v. Löwis11437992002-04-12 09:54:03 +000013426echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
13427echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13428if test "${ac_cv_header_time+set}" = set; then
13429 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013430else
Martin v. Löwis11437992002-04-12 09:54:03 +000013431 cat >conftest.$ac_ext <<_ACEOF
13432#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013433#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013434#include <sys/types.h>
13435#include <sys/time.h>
13436#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013437
13438#ifdef F77_DUMMY_MAIN
13439# ifdef __cplusplus
13440 extern "C"
13441# endif
13442 int F77_DUMMY_MAIN() { return 1; }
13443#endif
13444int
13445main ()
13446{
13447if ((struct tm *) 0)
13448return 0;
13449 ;
13450 return 0;
13451}
13452_ACEOF
13453rm -f conftest.$ac_objext
13454if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13455 (eval $ac_compile) 2>&5
13456 ac_status=$?
13457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13458 (exit $ac_status); } &&
13459 { ac_try='test -s conftest.$ac_objext'
13460 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13461 (eval $ac_try) 2>&5
13462 ac_status=$?
13463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13464 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013465 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000013466else
Martin v. Löwis11437992002-04-12 09:54:03 +000013467 echo "$as_me: failed program was:" >&5
13468cat conftest.$ac_ext >&5
13469ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013470fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013471rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013472fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013473echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
13474echo "${ECHO_T}$ac_cv_header_time" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013475if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013476
13477cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013478#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013479_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013480
13481fi
13482
Martin v. Löwis11437992002-04-12 09:54:03 +000013483echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
13484echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
13485if test "${ac_cv_struct_tm+set}" = set; then
13486 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013487else
Martin v. Löwis11437992002-04-12 09:54:03 +000013488 cat >conftest.$ac_ext <<_ACEOF
13489#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013490#include "confdefs.h"
13491#include <sys/types.h>
13492#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013493
13494#ifdef F77_DUMMY_MAIN
13495# ifdef __cplusplus
13496 extern "C"
13497# endif
13498 int F77_DUMMY_MAIN() { return 1; }
13499#endif
13500int
13501main ()
13502{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013503struct tm *tp; tp->tm_sec;
Martin v. Löwis11437992002-04-12 09:54:03 +000013504 ;
13505 return 0;
13506}
13507_ACEOF
13508rm -f conftest.$ac_objext
13509if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13510 (eval $ac_compile) 2>&5
13511 ac_status=$?
13512 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13513 (exit $ac_status); } &&
13514 { ac_try='test -s conftest.$ac_objext'
13515 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13516 (eval $ac_try) 2>&5
13517 ac_status=$?
13518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13519 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013520 ac_cv_struct_tm=time.h
13521else
Martin v. Löwis11437992002-04-12 09:54:03 +000013522 echo "$as_me: failed program was:" >&5
13523cat conftest.$ac_ext >&5
13524ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013525fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013526rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013527fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013528echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
13529echo "${ECHO_T}$ac_cv_struct_tm" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013530if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013531
13532cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013533#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013534_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013535
13536fi
13537
Martin v. Löwis11437992002-04-12 09:54:03 +000013538echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
13539echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
13540if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
13541 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013542else
Martin v. Löwis11437992002-04-12 09:54:03 +000013543 cat >conftest.$ac_ext <<_ACEOF
13544#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013545#include "confdefs.h"
13546#include <sys/types.h>
13547#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000013548
13549
13550#ifdef F77_DUMMY_MAIN
13551# ifdef __cplusplus
13552 extern "C"
13553# endif
13554 int F77_DUMMY_MAIN() { return 1; }
13555#endif
13556int
13557main ()
13558{
13559static struct tm ac_aggr;
13560if (ac_aggr.tm_zone)
13561return 0;
13562 ;
13563 return 0;
13564}
13565_ACEOF
13566rm -f conftest.$ac_objext
13567if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13568 (eval $ac_compile) 2>&5
13569 ac_status=$?
13570 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13571 (exit $ac_status); } &&
13572 { ac_try='test -s conftest.$ac_objext'
13573 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13574 (eval $ac_try) 2>&5
13575 ac_status=$?
13576 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13577 (exit $ac_status); }; }; then
13578 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013579else
Martin v. Löwis11437992002-04-12 09:54:03 +000013580 echo "$as_me: failed program was:" >&5
13581cat conftest.$ac_ext >&5
13582ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013583fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013584rm -f conftest.$ac_objext conftest.$ac_ext
13585fi
13586echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
13587echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
13588if test $ac_cv_member_struct_tm_tm_zone = yes; then
13589
13590cat >>confdefs.h <<_ACEOF
13591#define HAVE_STRUCT_TM_TM_ZONE 1
13592_ACEOF
13593
13594
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013595fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000013596
Martin v. Löwis11437992002-04-12 09:54:03 +000013597if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13598
13599cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013600#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013601_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013602
13603else
Martin v. Löwis11437992002-04-12 09:54:03 +000013604 echo "$as_me:$LINENO: checking for tzname" >&5
13605echo $ECHO_N "checking for tzname... $ECHO_C" >&6
13606if test "${ac_cv_var_tzname+set}" = set; then
13607 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013608else
Martin v. Löwis11437992002-04-12 09:54:03 +000013609 cat >conftest.$ac_ext <<_ACEOF
13610#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013611#include "confdefs.h"
13612#include <time.h>
13613#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013614extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000013615#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013616
13617#ifdef F77_DUMMY_MAIN
13618# ifdef __cplusplus
13619 extern "C"
13620# endif
13621 int F77_DUMMY_MAIN() { return 1; }
13622#endif
13623int
13624main ()
13625{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013626atoi(*tzname);
Martin v. Löwis11437992002-04-12 09:54:03 +000013627 ;
13628 return 0;
13629}
13630_ACEOF
13631rm -f conftest.$ac_objext conftest$ac_exeext
13632if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13633 (eval $ac_link) 2>&5
13634 ac_status=$?
13635 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13636 (exit $ac_status); } &&
13637 { ac_try='test -s conftest$ac_exeext'
13638 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13639 (eval $ac_try) 2>&5
13640 ac_status=$?
13641 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13642 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013643 ac_cv_var_tzname=yes
13644else
Martin v. Löwis11437992002-04-12 09:54:03 +000013645 echo "$as_me: failed program was:" >&5
13646cat conftest.$ac_ext >&5
13647ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013648fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013649rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000013650fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013651echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
13652echo "${ECHO_T}$ac_cv_var_tzname" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013653 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013654
13655cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013656#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013657_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013658
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013659 fi
13660fi
13661
Martin v. Löwis11437992002-04-12 09:54:03 +000013662echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
13663echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6
13664if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
13665 echo $ECHO_N "(cached) $ECHO_C" >&6
13666else
13667 cat >conftest.$ac_ext <<_ACEOF
13668#line $LINENO "configure"
13669#include "confdefs.h"
13670$ac_includes_default
13671#ifdef F77_DUMMY_MAIN
13672# ifdef __cplusplus
13673 extern "C"
13674# endif
13675 int F77_DUMMY_MAIN() { return 1; }
13676#endif
13677int
13678main ()
13679{
13680static struct stat ac_aggr;
13681if (ac_aggr.st_rdev)
13682return 0;
13683 ;
13684 return 0;
13685}
13686_ACEOF
13687rm -f conftest.$ac_objext
13688if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13689 (eval $ac_compile) 2>&5
13690 ac_status=$?
13691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13692 (exit $ac_status); } &&
13693 { ac_try='test -s conftest.$ac_objext'
13694 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13695 (eval $ac_try) 2>&5
13696 ac_status=$?
13697 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13698 (exit $ac_status); }; }; then
13699 ac_cv_member_struct_stat_st_rdev=yes
13700else
13701 echo "$as_me: failed program was:" >&5
13702cat conftest.$ac_ext >&5
13703ac_cv_member_struct_stat_st_rdev=no
13704fi
13705rm -f conftest.$ac_objext conftest.$ac_ext
13706fi
13707echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
13708echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6
13709if test $ac_cv_member_struct_stat_st_rdev = yes; then
13710
13711cat >>confdefs.h <<_ACEOF
13712#define HAVE_STRUCT_STAT_ST_RDEV 1
13713_ACEOF
13714
13715
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013716fi
13717
Martin v. Löwis11437992002-04-12 09:54:03 +000013718echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
13719echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
13720if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
13721 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013722else
Martin v. Löwis11437992002-04-12 09:54:03 +000013723 cat >conftest.$ac_ext <<_ACEOF
13724#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013725#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013726$ac_includes_default
13727#ifdef F77_DUMMY_MAIN
13728# ifdef __cplusplus
13729 extern "C"
13730# endif
13731 int F77_DUMMY_MAIN() { return 1; }
13732#endif
13733int
13734main ()
13735{
13736static struct stat ac_aggr;
13737if (ac_aggr.st_blksize)
13738return 0;
13739 ;
13740 return 0;
13741}
13742_ACEOF
13743rm -f conftest.$ac_objext
13744if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13745 (eval $ac_compile) 2>&5
13746 ac_status=$?
13747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13748 (exit $ac_status); } &&
13749 { ac_try='test -s conftest.$ac_objext'
13750 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13751 (eval $ac_try) 2>&5
13752 ac_status=$?
13753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13754 (exit $ac_status); }; }; then
13755 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013756else
Martin v. Löwis11437992002-04-12 09:54:03 +000013757 echo "$as_me: failed program was:" >&5
13758cat conftest.$ac_ext >&5
13759ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013760fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013761rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013762fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013763echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
13764echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
13765if test $ac_cv_member_struct_stat_st_blksize = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013766
Martin v. Löwis11437992002-04-12 09:54:03 +000013767cat >>confdefs.h <<_ACEOF
13768#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13769_ACEOF
13770
13771
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013772fi
13773
Martin v. Löwis11437992002-04-12 09:54:03 +000013774echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
13775echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6
13776if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
13777 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013778else
Martin v. Löwis11437992002-04-12 09:54:03 +000013779 cat >conftest.$ac_ext <<_ACEOF
13780#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013781#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013782$ac_includes_default
13783#ifdef F77_DUMMY_MAIN
13784# ifdef __cplusplus
13785 extern "C"
13786# endif
13787 int F77_DUMMY_MAIN() { return 1; }
13788#endif
13789int
13790main ()
13791{
13792static struct stat ac_aggr;
13793if (ac_aggr.st_blocks)
13794return 0;
13795 ;
13796 return 0;
13797}
13798_ACEOF
13799rm -f conftest.$ac_objext
13800if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13801 (eval $ac_compile) 2>&5
13802 ac_status=$?
13803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13804 (exit $ac_status); } &&
13805 { ac_try='test -s conftest.$ac_objext'
13806 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13807 (eval $ac_try) 2>&5
13808 ac_status=$?
13809 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13810 (exit $ac_status); }; }; then
13811 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013812else
Martin v. Löwis11437992002-04-12 09:54:03 +000013813 echo "$as_me: failed program was:" >&5
13814cat conftest.$ac_ext >&5
13815ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013816fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013817rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013818fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013819echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
13820echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6
13821if test $ac_cv_member_struct_stat_st_blocks = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013822
Martin v. Löwis11437992002-04-12 09:54:03 +000013823cat >>confdefs.h <<_ACEOF
13824#define HAVE_STRUCT_STAT_ST_BLOCKS 1
13825_ACEOF
13826
13827
13828cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013829#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013830_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013831
13832else
Martin v. Löwis11437992002-04-12 09:54:03 +000013833 LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013834fi
13835
Michael W. Hudson54241132001-12-07 15:38:26 +000013836
Martin v. Löwis11437992002-04-12 09:54:03 +000013837
13838echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
13839echo $ECHO_N "checking for time.h that defines altzone... $ECHO_C" >&6
13840if test "${ac_cv_header_time_altzone+set}" = set; then
13841 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013842else
Martin v. Löwis11437992002-04-12 09:54:03 +000013843 cat >conftest.$ac_ext <<_ACEOF
13844#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013845#include "confdefs.h"
13846#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013847#ifdef F77_DUMMY_MAIN
13848# ifdef __cplusplus
13849 extern "C"
13850# endif
13851 int F77_DUMMY_MAIN() { return 1; }
13852#endif
13853int
13854main ()
13855{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013856return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000013857 ;
13858 return 0;
13859}
13860_ACEOF
13861rm -f conftest.$ac_objext
13862if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13863 (eval $ac_compile) 2>&5
13864 ac_status=$?
13865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13866 (exit $ac_status); } &&
13867 { ac_try='test -s conftest.$ac_objext'
13868 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13869 (eval $ac_try) 2>&5
13870 ac_status=$?
13871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13872 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013873 ac_cv_header_time_altzone=yes
13874else
Martin v. Löwis11437992002-04-12 09:54:03 +000013875 echo "$as_me: failed program was:" >&5
13876cat conftest.$ac_ext >&5
13877ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +000013878fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013879rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013880fi
13881
Martin v. Löwis11437992002-04-12 09:54:03 +000013882echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
13883echo "${ECHO_T}$ac_cv_header_time_altzone" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013884if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013885
13886cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013887#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013888_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013889
13890fi
13891
Guido van Rossumda88dad1995-01-26 00:46:29 +000013892was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013893echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
13894echo $ECHO_N "checking whether sys/select.h and sys/time.h may both be included... $ECHO_C" >&6
13895cat >conftest.$ac_ext <<_ACEOF
13896#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013897#include "confdefs.h"
13898
13899#include <sys/types.h>
13900#include <sys/select.h>
13901#include <sys/time.h>
13902
Martin v. Löwis11437992002-04-12 09:54:03 +000013903#ifdef F77_DUMMY_MAIN
13904# ifdef __cplusplus
13905 extern "C"
13906# endif
13907 int F77_DUMMY_MAIN() { return 1; }
13908#endif
13909int
13910main ()
13911{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013912;
Martin v. Löwis11437992002-04-12 09:54:03 +000013913 ;
13914 return 0;
13915}
13916_ACEOF
13917rm -f conftest.$ac_objext
13918if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13919 (eval $ac_compile) 2>&5
13920 ac_status=$?
13921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13922 (exit $ac_status); } &&
13923 { ac_try='test -s conftest.$ac_objext'
13924 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13925 (eval $ac_try) 2>&5
13926 ac_status=$?
13927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13928 (exit $ac_status); }; }; then
13929
13930
13931cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013932#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013933_ACEOF
13934
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013935 was_it_defined=yes
13936
Guido van Rossumf78abae1997-01-21 22:02:36 +000013937else
Martin v. Löwis11437992002-04-12 09:54:03 +000013938 echo "$as_me: failed program was:" >&5
13939cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000013940fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013941rm -f conftest.$ac_objext conftest.$ac_ext
13942echo "$as_me:$LINENO: result: $was_it_defined" >&5
13943echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000013944
Martin v. Löwis11437992002-04-12 09:54:03 +000013945echo "$as_me:$LINENO: checking for addrinfo" >&5
13946echo $ECHO_N "checking for addrinfo... $ECHO_C" >&6
13947if test "${ac_cv_struct_addrinfo+set}" = set; then
13948 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013949else
Martin v. Löwis11437992002-04-12 09:54:03 +000013950 cat >conftest.$ac_ext <<_ACEOF
13951#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013952#include "confdefs.h"
13953
13954# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013955#ifdef F77_DUMMY_MAIN
13956# ifdef __cplusplus
13957 extern "C"
13958# endif
13959 int F77_DUMMY_MAIN() { return 1; }
13960#endif
13961int
13962main ()
13963{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013964struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000013965 ;
13966 return 0;
13967}
13968_ACEOF
13969rm -f conftest.$ac_objext
13970if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13971 (eval $ac_compile) 2>&5
13972 ac_status=$?
13973 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13974 (exit $ac_status); } &&
13975 { ac_try='test -s conftest.$ac_objext'
13976 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13977 (eval $ac_try) 2>&5
13978 ac_status=$?
13979 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13980 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013981 ac_cv_struct_addrinfo=yes
13982else
Martin v. Löwis11437992002-04-12 09:54:03 +000013983 echo "$as_me: failed program was:" >&5
13984cat conftest.$ac_ext >&5
13985ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013986fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013987rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013988fi
13989
Martin v. Löwis11437992002-04-12 09:54:03 +000013990echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
13991echo "${ECHO_T}$ac_cv_struct_addrinfo" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013992if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013993
13994cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013995#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013996_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013997
13998fi
13999
Martin v. Löwis11437992002-04-12 09:54:03 +000014000echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
14001echo $ECHO_N "checking for sockaddr_storage... $ECHO_C" >&6
14002if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
14003 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014004else
Martin v. Löwis11437992002-04-12 09:54:03 +000014005 cat >conftest.$ac_ext <<_ACEOF
14006#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014007#include "confdefs.h"
14008
14009# include <sys/types.h>
14010# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014011#ifdef F77_DUMMY_MAIN
14012# ifdef __cplusplus
14013 extern "C"
14014# endif
14015 int F77_DUMMY_MAIN() { return 1; }
14016#endif
14017int
14018main ()
14019{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014020struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000014021 ;
14022 return 0;
14023}
14024_ACEOF
14025rm -f conftest.$ac_objext
14026if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14027 (eval $ac_compile) 2>&5
14028 ac_status=$?
14029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14030 (exit $ac_status); } &&
14031 { ac_try='test -s conftest.$ac_objext'
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
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014037 ac_cv_struct_sockaddr_storage=yes
14038else
Martin v. Löwis11437992002-04-12 09:54:03 +000014039 echo "$as_me: failed program was:" >&5
14040cat conftest.$ac_ext >&5
14041ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014042fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014043rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014044fi
14045
Martin v. Löwis11437992002-04-12 09:54:03 +000014046echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
14047echo "${ECHO_T}$ac_cv_struct_sockaddr_storage" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014048if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014049
14050cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014051#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014052_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014053
14054fi
14055
Guido van Rossum627b2d71993-12-24 10:39:16 +000014056# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000014057
Michael W. Hudson54241132001-12-07 15:38:26 +000014058
Martin v. Löwis11437992002-04-12 09:54:03 +000014059echo "$as_me:$LINENO: checking whether char is unsigned" >&5
14060echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
14061if test "${ac_cv_c_char_unsigned+set}" = set; then
14062 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000014063else
Martin v. Löwis11437992002-04-12 09:54:03 +000014064 cat >conftest.$ac_ext <<_ACEOF
14065#line $LINENO "configure"
Michael W. Hudson54241132001-12-07 15:38:26 +000014066#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000014067$ac_includes_default
14068#ifdef F77_DUMMY_MAIN
14069# ifdef __cplusplus
14070 extern "C"
14071# endif
14072 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000014073#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014074int
14075main ()
14076{
14077static int test_array [1 - 2 * !(((char) -1) < 0)];
14078test_array [0] = 0
14079
14080 ;
14081 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000014082}
Martin v. Löwis11437992002-04-12 09:54:03 +000014083_ACEOF
14084rm -f conftest.$ac_objext
14085if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14086 (eval $ac_compile) 2>&5
14087 ac_status=$?
14088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14089 (exit $ac_status); } &&
14090 { ac_try='test -s conftest.$ac_objext'
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
Michael W. Hudson54241132001-12-07 15:38:26 +000014096 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014097else
14098 echo "$as_me: failed program was:" >&5
14099cat conftest.$ac_ext >&5
14100ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014101fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014102rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014103fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014104echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
14105echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014106if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014107 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014108#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014109_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014110
14111fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000014112
Martin v. Löwis11437992002-04-12 09:54:03 +000014113echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
14114echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
14115if test "${ac_cv_prog_cc_stdc+set}" = set; then
14116 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014117else
Martin v. Löwis11437992002-04-12 09:54:03 +000014118 ac_cv_prog_cc_stdc=no
14119ac_save_CC=$CC
14120cat >conftest.$ac_ext <<_ACEOF
14121#line $LINENO "configure"
14122#include "confdefs.h"
14123#include <stdarg.h>
14124#include <stdio.h>
14125#include <sys/types.h>
14126#include <sys/stat.h>
14127/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
14128struct buf { int x; };
14129FILE * (*rcsopen) (struct buf *, struct stat *, int);
14130static char *e (p, i)
14131 char **p;
14132 int i;
14133{
14134 return p[i];
14135}
14136static char *f (char * (*g) (char **, int), char **p, ...)
14137{
14138 char *s;
14139 va_list v;
14140 va_start (v,p);
14141 s = g (p, va_arg (v,int));
14142 va_end (v);
14143 return s;
14144}
14145int test (int i, double x);
14146struct s1 {int (*f) (int a);};
14147struct s2 {int (*f) (double a);};
14148int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
14149int argc;
14150char **argv;
14151#ifdef F77_DUMMY_MAIN
14152# ifdef __cplusplus
14153 extern "C"
14154# endif
14155 int F77_DUMMY_MAIN() { return 1; }
14156#endif
14157int
14158main ()
14159{
14160return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
14161 ;
14162 return 0;
14163}
14164_ACEOF
14165# Don't try gcc -ansi; that turns off useful extensions and
14166# breaks some systems' header files.
14167# AIX -qlanglvl=ansi
14168# Ultrix and OSF/1 -std1
14169# HP-UX 10.20 and later -Ae
14170# HP-UX older versions -Aa -D_HPUX_SOURCE
14171# SVR4 -Xc -D__EXTENSIONS__
14172for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
14173do
14174 CC="$ac_save_CC $ac_arg"
14175 rm -f conftest.$ac_objext
14176if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14177 (eval $ac_compile) 2>&5
14178 ac_status=$?
14179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14180 (exit $ac_status); } &&
14181 { ac_try='test -s conftest.$ac_objext'
14182 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14183 (eval $ac_try) 2>&5
14184 ac_status=$?
14185 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14186 (exit $ac_status); }; }; then
14187 ac_cv_prog_cc_stdc=$ac_arg
14188break
14189else
14190 echo "$as_me: failed program was:" >&5
14191cat conftest.$ac_ext >&5
14192fi
14193rm -f conftest.$ac_objext
14194done
14195rm -f conftest.$ac_ext conftest.$ac_objext
14196CC=$ac_save_CC
14197
14198fi
14199
14200case "x$ac_cv_prog_cc_stdc" in
14201 x|xno)
14202 echo "$as_me:$LINENO: result: none needed" >&5
14203echo "${ECHO_T}none needed" >&6 ;;
14204 *)
14205 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
14206echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
14207 CC="$CC $ac_cv_prog_cc_stdc" ;;
14208esac
14209
14210echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14211echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
14212if test "${ac_cv_c_const+set}" = set; then
14213 echo $ECHO_N "(cached) $ECHO_C" >&6
14214else
14215 cat >conftest.$ac_ext <<_ACEOF
14216#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014217#include "confdefs.h"
14218
Martin v. Löwis11437992002-04-12 09:54:03 +000014219#ifdef F77_DUMMY_MAIN
14220# ifdef __cplusplus
14221 extern "C"
14222# endif
14223 int F77_DUMMY_MAIN() { return 1; }
14224#endif
14225int
14226main ()
14227{
14228/* FIXME: Include the comments suggested by Paul. */
14229#ifndef __cplusplus
14230 /* Ultrix mips cc rejects this. */
14231 typedef int charset[2];
14232 const charset x;
14233 /* SunOS 4.1.1 cc rejects this. */
14234 char const *const *ccp;
14235 char **p;
14236 /* NEC SVR4.0.2 mips cc rejects this. */
14237 struct point {int x, y;};
14238 static struct point const zero = {0,0};
14239 /* AIX XL C 1.02.0.0 rejects this.
14240 It does not let you subtract one const X* pointer from another in
14241 an arm of an if-expression whose if-part is not a constant
14242 expression */
14243 const char *g = "string";
14244 ccp = &g + (g ? g-g : 0);
14245 /* HPUX 7.0 cc rejects these. */
14246 ++ccp;
14247 p = (char**) ccp;
14248 ccp = (char const *const *) p;
14249 { /* SCO 3.2v4 cc rejects this. */
14250 char *t;
14251 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014252
Martin v. Löwis11437992002-04-12 09:54:03 +000014253 *t++ = 0;
14254 }
14255 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
14256 int x[] = {25, 17};
14257 const int *foo = &x[0];
14258 ++foo;
14259 }
14260 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14261 typedef const int *iptr;
14262 iptr p = 0;
14263 ++p;
14264 }
14265 { /* AIX XL C 1.02.0.0 rejects this saying
14266 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14267 struct s { int j; const int *ap[3]; };
14268 struct s *b; b->j = 5;
14269 }
14270 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14271 const int foo = 10;
14272 }
14273#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000014274
Martin v. Löwis11437992002-04-12 09:54:03 +000014275 ;
14276 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000014277}
Martin v. Löwis11437992002-04-12 09:54:03 +000014278_ACEOF
14279rm -f conftest.$ac_objext
14280if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14281 (eval $ac_compile) 2>&5
14282 ac_status=$?
14283 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14284 (exit $ac_status); } &&
14285 { ac_try='test -s conftest.$ac_objext'
14286 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14287 (eval $ac_try) 2>&5
14288 ac_status=$?
14289 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14290 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014291 ac_cv_c_const=yes
14292else
Martin v. Löwis11437992002-04-12 09:54:03 +000014293 echo "$as_me: failed program was:" >&5
14294cat conftest.$ac_ext >&5
14295ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014296fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014297rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014298fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014299echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14300echo "${ECHO_T}$ac_cv_c_const" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014301if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014302
14303cat >>confdefs.h <<\_ACEOF
14304#define const
14305_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014306
14307fi
14308
Michael W. Hudson54241132001-12-07 15:38:26 +000014309
Guido van Rossumda88dad1995-01-26 00:46:29 +000014310works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014311echo "$as_me:$LINENO: checking for working volatile" >&5
14312echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
14313cat >conftest.$ac_ext <<_ACEOF
14314#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014315#include "confdefs.h"
14316
Martin v. Löwis11437992002-04-12 09:54:03 +000014317#ifdef F77_DUMMY_MAIN
14318# ifdef __cplusplus
14319 extern "C"
14320# endif
14321 int F77_DUMMY_MAIN() { return 1; }
14322#endif
14323int
14324main ()
14325{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014326volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000014327 ;
14328 return 0;
14329}
14330_ACEOF
14331rm -f conftest.$ac_objext
14332if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14333 (eval $ac_compile) 2>&5
14334 ac_status=$?
14335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14336 (exit $ac_status); } &&
14337 { ac_try='test -s conftest.$ac_objext'
14338 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14339 (eval $ac_try) 2>&5
14340 ac_status=$?
14341 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14342 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000014343 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000014344else
Martin v. Löwis11437992002-04-12 09:54:03 +000014345 echo "$as_me: failed program was:" >&5
14346cat conftest.$ac_ext >&5
14347
14348cat >>confdefs.h <<\_ACEOF
14349#define volatile
14350_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014351
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014352
Guido van Rossum627b2d71993-12-24 10:39:16 +000014353fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014354rm -f conftest.$ac_objext conftest.$ac_ext
14355echo "$as_me:$LINENO: result: $works" >&5
14356echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000014357
Guido van Rossumda88dad1995-01-26 00:46:29 +000014358works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014359echo "$as_me:$LINENO: checking for working signed char" >&5
14360echo $ECHO_N "checking for working signed char... $ECHO_C" >&6
14361cat >conftest.$ac_ext <<_ACEOF
14362#line $LINENO "configure"
Guido van Rossumdabb11b1994-10-11 15:04:27 +000014363#include "confdefs.h"
14364
Martin v. Löwis11437992002-04-12 09:54:03 +000014365#ifdef F77_DUMMY_MAIN
14366# ifdef __cplusplus
14367 extern "C"
14368# endif
14369 int F77_DUMMY_MAIN() { return 1; }
14370#endif
14371int
14372main ()
14373{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014374signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000014375 ;
14376 return 0;
14377}
14378_ACEOF
14379rm -f conftest.$ac_objext
14380if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14381 (eval $ac_compile) 2>&5
14382 ac_status=$?
14383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14384 (exit $ac_status); } &&
14385 { ac_try='test -s conftest.$ac_objext'
14386 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14387 (eval $ac_try) 2>&5
14388 ac_status=$?
14389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14390 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000014391 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000014392else
Martin v. Löwis11437992002-04-12 09:54:03 +000014393 echo "$as_me: failed program was:" >&5
14394cat conftest.$ac_ext >&5
14395
14396cat >>confdefs.h <<\_ACEOF
14397#define signed
14398_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000014399
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014400
Guido van Rossum7f43da71994-08-01 12:15:30 +000014401fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014402rm -f conftest.$ac_objext conftest.$ac_ext
14403echo "$as_me:$LINENO: result: $works" >&5
14404echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000014405
Guido van Rossumda88dad1995-01-26 00:46:29 +000014406have_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014407echo "$as_me:$LINENO: checking for prototypes" >&5
14408echo $ECHO_N "checking for prototypes... $ECHO_C" >&6
14409cat >conftest.$ac_ext <<_ACEOF
14410#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014411#include "confdefs.h"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014412int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014413#ifdef F77_DUMMY_MAIN
14414# ifdef __cplusplus
14415 extern "C"
14416# endif
14417 int F77_DUMMY_MAIN() { return 1; }
14418#endif
14419int
14420main ()
14421{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014422return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000014423 ;
14424 return 0;
14425}
14426_ACEOF
14427rm -f conftest.$ac_objext
14428if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14429 (eval $ac_compile) 2>&5
14430 ac_status=$?
14431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14432 (exit $ac_status); } &&
14433 { ac_try='test -s conftest.$ac_objext'
14434 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14435 (eval $ac_try) 2>&5
14436 ac_status=$?
14437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14438 (exit $ac_status); }; }; then
14439
14440
14441cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014442#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014443_ACEOF
14444
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014445 have_prototypes=yes
14446
Guido van Rossumf78abae1997-01-21 22:02:36 +000014447else
Martin v. Löwis11437992002-04-12 09:54:03 +000014448 echo "$as_me: failed program was:" >&5
14449cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000014450fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014451rm -f conftest.$ac_objext conftest.$ac_ext
14452echo "$as_me:$LINENO: result: $have_prototypes" >&5
14453echo "${ECHO_T}$have_prototypes" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014454
Guido van Rossumda88dad1995-01-26 00:46:29 +000014455works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014456echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
14457echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6
14458cat >conftest.$ac_ext <<_ACEOF
14459#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014460#include "confdefs.h"
14461
14462#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000014463int foo(int x, ...) {
14464 va_list va;
14465 va_start(va, x);
14466 va_arg(va, int);
14467 va_arg(va, char *);
14468 va_arg(va, double);
14469 return 0;
14470}
Guido van Rossum7f43da71994-08-01 12:15:30 +000014471
Martin v. Löwis11437992002-04-12 09:54:03 +000014472#ifdef F77_DUMMY_MAIN
14473# ifdef __cplusplus
14474 extern "C"
14475# endif
14476 int F77_DUMMY_MAIN() { return 1; }
14477#endif
14478int
14479main ()
14480{
Guido van Rossum90eea071996-08-30 20:58:57 +000014481return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000014482 ;
14483 return 0;
14484}
14485_ACEOF
14486rm -f conftest.$ac_objext
14487if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14488 (eval $ac_compile) 2>&5
14489 ac_status=$?
14490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14491 (exit $ac_status); } &&
14492 { ac_try='test -s conftest.$ac_objext'
14493 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14494 (eval $ac_try) 2>&5
14495 ac_status=$?
14496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14497 (exit $ac_status); }; }; then
14498
14499
14500cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014501#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014502_ACEOF
14503
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014504 works=yes
14505
Guido van Rossumf78abae1997-01-21 22:02:36 +000014506else
Martin v. Löwis11437992002-04-12 09:54:03 +000014507 echo "$as_me: failed program was:" >&5
14508cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000014509fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014510rm -f conftest.$ac_objext conftest.$ac_ext
14511echo "$as_me:$LINENO: result: $works" >&5
14512echo "${ECHO_T}$works" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014513
Guido van Rossumda88dad1995-01-26 00:46:29 +000014514if test "$have_prototypes" = yes; then
14515bad_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014516echo "$as_me:$LINENO: checking for bad exec* prototypes" >&5
14517echo $ECHO_N "checking for bad exec* prototypes... $ECHO_C" >&6
14518cat >conftest.$ac_ext <<_ACEOF
14519#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014520#include "confdefs.h"
14521#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014522#ifdef F77_DUMMY_MAIN
14523# ifdef __cplusplus
14524 extern "C"
14525# endif
14526 int F77_DUMMY_MAIN() { return 1; }
14527#endif
14528int
14529main ()
14530{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014531char **t;execve("@",t,t);
Martin v. Löwis11437992002-04-12 09:54:03 +000014532 ;
14533 return 0;
14534}
14535_ACEOF
14536rm -f conftest.$ac_objext
14537if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14538 (eval $ac_compile) 2>&5
14539 ac_status=$?
14540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14541 (exit $ac_status); } &&
14542 { ac_try='test -s conftest.$ac_objext'
14543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14544 (eval $ac_try) 2>&5
14545 ac_status=$?
14546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14547 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000014548 :
14549else
Martin v. Löwis11437992002-04-12 09:54:03 +000014550 echo "$as_me: failed program was:" >&5
14551cat conftest.$ac_ext >&5
14552
14553cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014554#define BAD_EXEC_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014555_ACEOF
14556
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014557 bad_prototypes=yes
14558
Guido van Rossum627b2d71993-12-24 10:39:16 +000014559fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014560rm -f conftest.$ac_objext conftest.$ac_ext
14561echo "$as_me:$LINENO: result: $bad_prototypes" >&5
14562echo "${ECHO_T}$bad_prototypes" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000014563fi
14564
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014565# check if sockaddr has sa_len member
Martin v. Löwis11437992002-04-12 09:54:03 +000014566echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
14567echo $ECHO_N "checking if sockaddr has sa_len member... $ECHO_C" >&6
14568cat >conftest.$ac_ext <<_ACEOF
14569#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014570#include "confdefs.h"
14571#include <sys/types.h>
14572#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014573#ifdef F77_DUMMY_MAIN
14574# ifdef __cplusplus
14575 extern "C"
14576# endif
14577 int F77_DUMMY_MAIN() { return 1; }
14578#endif
14579int
14580main ()
14581{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014582struct sockaddr x;
14583x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000014584 ;
14585 return 0;
14586}
14587_ACEOF
14588rm -f conftest.$ac_objext
14589if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14590 (eval $ac_compile) 2>&5
14591 ac_status=$?
14592 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14593 (exit $ac_status); } &&
14594 { ac_try='test -s conftest.$ac_objext'
14595 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14596 (eval $ac_try) 2>&5
14597 ac_status=$?
14598 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14599 (exit $ac_status); }; }; then
14600 echo "$as_me:$LINENO: result: yes" >&5
14601echo "${ECHO_T}yes" >&6
14602
14603cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014604#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014605_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014606
14607else
Martin v. Löwis11437992002-04-12 09:54:03 +000014608 echo "$as_me: failed program was:" >&5
14609cat conftest.$ac_ext >&5
14610echo "$as_me:$LINENO: result: no" >&5
14611echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014612fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014613rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014614
Guido van Rossumda88dad1995-01-26 00:46:29 +000014615va_list_is_array=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014616echo "$as_me:$LINENO: checking whether va_list is an array" >&5
14617echo $ECHO_N "checking whether va_list is an array... $ECHO_C" >&6
14618cat >conftest.$ac_ext <<_ACEOF
14619#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014620#include "confdefs.h"
14621
14622#ifdef HAVE_STDARG_PROTOTYPES
14623#include <stdarg.h>
14624#else
14625#include <varargs.h>
14626#endif
14627
Martin v. Löwis11437992002-04-12 09:54:03 +000014628#ifdef F77_DUMMY_MAIN
14629# ifdef __cplusplus
14630 extern "C"
14631# endif
14632 int F77_DUMMY_MAIN() { return 1; }
14633#endif
14634int
14635main ()
14636{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014637va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000014638 ;
14639 return 0;
14640}
14641_ACEOF
14642rm -f conftest.$ac_objext
14643if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14644 (eval $ac_compile) 2>&5
14645 ac_status=$?
14646 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14647 (exit $ac_status); } &&
14648 { ac_try='test -s conftest.$ac_objext'
14649 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14650 (eval $ac_try) 2>&5
14651 ac_status=$?
14652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14653 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014654 :
14655else
Martin v. Löwis11437992002-04-12 09:54:03 +000014656 echo "$as_me: failed program was:" >&5
14657cat conftest.$ac_ext >&5
14658
14659
14660cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014661#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014662_ACEOF
14663
Guido van Rossumda88dad1995-01-26 00:46:29 +000014664 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014665
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014666fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014667rm -f conftest.$ac_objext conftest.$ac_ext
14668echo "$as_me:$LINENO: result: $va_list_is_array" >&5
14669echo "${ECHO_T}$va_list_is_array" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014670
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014671# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000014672
14673
14674
14675echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
14676echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
14677if test "${ac_cv_func_gethostbyname_r+set}" = set; then
14678 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014679else
Martin v. Löwis11437992002-04-12 09:54:03 +000014680 cat >conftest.$ac_ext <<_ACEOF
14681#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014682#include "confdefs.h"
14683/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014684 which can conflict with char gethostbyname_r (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014685#include <assert.h>
14686/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014687#ifdef __cplusplus
14688extern "C"
14689#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014690/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014691 builtin and then its argument prototype would still apply. */
14692char gethostbyname_r ();
14693char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014694
Martin v. Löwis11437992002-04-12 09:54:03 +000014695#ifdef F77_DUMMY_MAIN
14696# ifdef __cplusplus
14697 extern "C"
14698# endif
14699 int F77_DUMMY_MAIN() { return 1; }
14700#endif
14701int
14702main ()
14703{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014704/* The GNU C library defines this for functions which it implements
14705 to always fail with ENOSYS. Some functions are actually named
14706 something starting with __ and the normal name is an alias. */
14707#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
14708choke me
14709#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014710f = gethostbyname_r;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014711#endif
14712
Martin v. Löwis11437992002-04-12 09:54:03 +000014713 ;
14714 return 0;
14715}
14716_ACEOF
14717rm -f conftest.$ac_objext conftest$ac_exeext
14718if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14719 (eval $ac_link) 2>&5
14720 ac_status=$?
14721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14722 (exit $ac_status); } &&
14723 { ac_try='test -s conftest$ac_exeext'
14724 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14725 (eval $ac_try) 2>&5
14726 ac_status=$?
14727 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14728 (exit $ac_status); }; }; then
14729 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014730else
Martin v. Löwis11437992002-04-12 09:54:03 +000014731 echo "$as_me: failed program was:" >&5
14732cat conftest.$ac_ext >&5
14733ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014734fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014735rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014736fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014737echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
14738echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
14739if test $ac_cv_func_gethostbyname_r = yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014740
Martin v. Löwis11437992002-04-12 09:54:03 +000014741 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014742#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014743_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014744
Martin v. Löwis11437992002-04-12 09:54:03 +000014745 echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
14746echo $ECHO_N "checking gethostbyname_r with 6 args... $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014747 OLD_CFLAGS=$CFLAGS
14748 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014749 cat >conftest.$ac_ext <<_ACEOF
14750#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014751#include "confdefs.h"
14752
14753# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014754
14755#ifdef F77_DUMMY_MAIN
14756# ifdef __cplusplus
14757 extern "C"
14758# endif
14759 int F77_DUMMY_MAIN() { return 1; }
14760#endif
14761int
14762main ()
14763{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014764
14765 char *name;
14766 struct hostent *he, *res;
14767 char buffer[2048];
14768 int buflen = 2048;
14769 int h_errnop;
14770
14771 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014772
14773 ;
14774 return 0;
14775}
14776_ACEOF
14777rm -f conftest.$ac_objext
14778if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14779 (eval $ac_compile) 2>&5
14780 ac_status=$?
14781 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14782 (exit $ac_status); } &&
14783 { ac_try='test -s conftest.$ac_objext'
14784 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14785 (eval $ac_try) 2>&5
14786 ac_status=$?
14787 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14788 (exit $ac_status); }; }; then
14789
14790 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014791#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014792_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014793
Martin v. Löwis11437992002-04-12 09:54:03 +000014794
14795cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014796#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014797_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014798
Martin v. Löwis11437992002-04-12 09:54:03 +000014799 echo "$as_me:$LINENO: result: yes" >&5
14800echo "${ECHO_T}yes" >&6
14801
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014802else
Martin v. Löwis11437992002-04-12 09:54:03 +000014803 echo "$as_me: failed program was:" >&5
14804cat conftest.$ac_ext >&5
14805
14806 echo "$as_me:$LINENO: result: no" >&5
14807echo "${ECHO_T}no" >&6
14808 echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
14809echo $ECHO_N "checking gethostbyname_r with 5 args... $ECHO_C" >&6
14810 cat >conftest.$ac_ext <<_ACEOF
14811#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014812#include "confdefs.h"
14813
14814# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014815
14816#ifdef F77_DUMMY_MAIN
14817# ifdef __cplusplus
14818 extern "C"
14819# endif
14820 int F77_DUMMY_MAIN() { return 1; }
14821#endif
14822int
14823main ()
14824{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014825
14826 char *name;
14827 struct hostent *he;
14828 char buffer[2048];
14829 int buflen = 2048;
14830 int h_errnop;
14831
14832 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014833
14834 ;
14835 return 0;
14836}
14837_ACEOF
14838rm -f conftest.$ac_objext
14839if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14840 (eval $ac_compile) 2>&5
14841 ac_status=$?
14842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14843 (exit $ac_status); } &&
14844 { ac_try='test -s conftest.$ac_objext'
14845 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14846 (eval $ac_try) 2>&5
14847 ac_status=$?
14848 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14849 (exit $ac_status); }; }; then
14850
14851 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014852#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014853_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014854
Martin v. Löwis11437992002-04-12 09:54:03 +000014855
14856cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014857#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014858_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014859
Martin v. Löwis11437992002-04-12 09:54:03 +000014860 echo "$as_me:$LINENO: result: yes" >&5
14861echo "${ECHO_T}yes" >&6
14862
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014863else
Martin v. Löwis11437992002-04-12 09:54:03 +000014864 echo "$as_me: failed program was:" >&5
14865cat conftest.$ac_ext >&5
14866
14867 echo "$as_me:$LINENO: result: no" >&5
14868echo "${ECHO_T}no" >&6
14869 echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
14870echo $ECHO_N "checking gethostbyname_r with 3 args... $ECHO_C" >&6
14871 cat >conftest.$ac_ext <<_ACEOF
14872#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014873#include "confdefs.h"
14874
14875# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014876
14877#ifdef F77_DUMMY_MAIN
14878# ifdef __cplusplus
14879 extern "C"
14880# endif
14881 int F77_DUMMY_MAIN() { return 1; }
14882#endif
14883int
14884main ()
14885{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014886
14887 char *name;
14888 struct hostent *he;
14889 struct hostent_data data;
14890
14891 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000014892
14893 ;
14894 return 0;
14895}
14896_ACEOF
14897rm -f conftest.$ac_objext
14898if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14899 (eval $ac_compile) 2>&5
14900 ac_status=$?
14901 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14902 (exit $ac_status); } &&
14903 { ac_try='test -s conftest.$ac_objext'
14904 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14905 (eval $ac_try) 2>&5
14906 ac_status=$?
14907 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14908 (exit $ac_status); }; }; then
14909
14910 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014911#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014912_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014913
Martin v. Löwis11437992002-04-12 09:54:03 +000014914
14915cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014916#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014917_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014918
Martin v. Löwis11437992002-04-12 09:54:03 +000014919 echo "$as_me:$LINENO: result: yes" >&5
14920echo "${ECHO_T}yes" >&6
14921
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014922else
Martin v. Löwis11437992002-04-12 09:54:03 +000014923 echo "$as_me: failed program was:" >&5
14924cat conftest.$ac_ext >&5
14925
14926 echo "$as_me:$LINENO: result: no" >&5
14927echo "${ECHO_T}no" >&6
14928
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014929fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014930rm -f conftest.$ac_objext conftest.$ac_ext
14931
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014932fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014933rm -f conftest.$ac_objext conftest.$ac_ext
14934
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014935fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014936rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014937 CFLAGS=$OLD_CFLAGS
14938
14939else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014940
Martin v. Löwis11437992002-04-12 09:54:03 +000014941
14942for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000014943do
Martin v. Löwis11437992002-04-12 09:54:03 +000014944as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14945echo "$as_me:$LINENO: checking for $ac_func" >&5
14946echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14947if eval "test \"\${$as_ac_var+set}\" = set"; then
14948 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014949else
Martin v. Löwis11437992002-04-12 09:54:03 +000014950 cat >conftest.$ac_ext <<_ACEOF
14951#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014952#include "confdefs.h"
14953/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014954 which can conflict with char $ac_func (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014955#include <assert.h>
14956/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014957#ifdef __cplusplus
14958extern "C"
14959#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014960/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014961 builtin and then its argument prototype would still apply. */
14962char $ac_func ();
14963char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014964
Martin v. Löwis11437992002-04-12 09:54:03 +000014965#ifdef F77_DUMMY_MAIN
14966# ifdef __cplusplus
14967 extern "C"
14968# endif
14969 int F77_DUMMY_MAIN() { return 1; }
14970#endif
14971int
14972main ()
14973{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014974/* The GNU C library defines this for functions which it implements
14975 to always fail with ENOSYS. Some functions are actually named
14976 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000014977#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014978choke me
14979#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014980f = $ac_func;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014981#endif
14982
Martin v. Löwis11437992002-04-12 09:54:03 +000014983 ;
14984 return 0;
14985}
14986_ACEOF
14987rm -f conftest.$ac_objext conftest$ac_exeext
14988if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14989 (eval $ac_link) 2>&5
14990 ac_status=$?
14991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14992 (exit $ac_status); } &&
14993 { ac_try='test -s conftest$ac_exeext'
14994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14995 (eval $ac_try) 2>&5
14996 ac_status=$?
14997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14998 (exit $ac_status); }; }; then
14999 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000015000else
Martin v. Löwis11437992002-04-12 09:54:03 +000015001 echo "$as_me: failed program was:" >&5
15002cat conftest.$ac_ext >&5
15003eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000015004fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015005rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015006fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015007echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15008echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15009if test `eval echo '${'$as_ac_var'}'` = yes; then
15010 cat >>confdefs.h <<_ACEOF
15011#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15012_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015013
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015014fi
Thomas Wouters3a584202000-08-05 23:28:51 +000015015done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015016
Michael W. Hudson54241132001-12-07 15:38:26 +000015017
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015018fi
15019
Michael W. Hudson54241132001-12-07 15:38:26 +000015020
15021
15022
15023
15024
15025
Guido van Rossum627b2d71993-12-24 10:39:16 +000015026# checks for system services
15027# (none yet)
15028
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015029# Linux requires this for correct f.p. operations
Martin v. Löwis11437992002-04-12 09:54:03 +000015030echo "$as_me:$LINENO: checking for __fpu_control" >&5
15031echo $ECHO_N "checking for __fpu_control... $ECHO_C" >&6
15032if test "${ac_cv_func___fpu_control+set}" = set; then
15033 echo $ECHO_N "(cached) $ECHO_C" >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015034else
Martin v. Löwis11437992002-04-12 09:54:03 +000015035 cat >conftest.$ac_ext <<_ACEOF
15036#line $LINENO "configure"
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015037#include "confdefs.h"
15038/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000015039 which can conflict with char __fpu_control (); below. */
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015040#include <assert.h>
15041/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015042#ifdef __cplusplus
15043extern "C"
15044#endif
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015045/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015046 builtin and then its argument prototype would still apply. */
15047char __fpu_control ();
15048char (*f) ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015049
Martin v. Löwis11437992002-04-12 09:54:03 +000015050#ifdef F77_DUMMY_MAIN
15051# ifdef __cplusplus
15052 extern "C"
15053# endif
15054 int F77_DUMMY_MAIN() { return 1; }
15055#endif
15056int
15057main ()
15058{
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015059/* The GNU C library defines this for functions which it implements
15060 to always fail with ENOSYS. Some functions are actually named
15061 something starting with __ and the normal name is an alias. */
15062#if defined (__stub___fpu_control) || defined (__stub_____fpu_control)
15063choke me
15064#else
Martin v. Löwis11437992002-04-12 09:54:03 +000015065f = __fpu_control;
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015066#endif
15067
Martin v. Löwis11437992002-04-12 09:54:03 +000015068 ;
15069 return 0;
15070}
15071_ACEOF
15072rm -f conftest.$ac_objext conftest$ac_exeext
15073if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15074 (eval $ac_link) 2>&5
15075 ac_status=$?
15076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15077 (exit $ac_status); } &&
15078 { ac_try='test -s conftest$ac_exeext'
15079 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15080 (eval $ac_try) 2>&5
15081 ac_status=$?
15082 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15083 (exit $ac_status); }; }; then
15084 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015085else
Martin v. Löwis11437992002-04-12 09:54:03 +000015086 echo "$as_me: failed program was:" >&5
15087cat conftest.$ac_ext >&5
15088ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015089fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015090rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015091fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015092echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
15093echo "${ECHO_T}$ac_cv_func___fpu_control" >&6
15094if test $ac_cv_func___fpu_control = yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015095 :
15096else
Martin v. Löwis11437992002-04-12 09:54:03 +000015097
15098echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
15099echo $ECHO_N "checking for __fpu_control in -lieee... $ECHO_C" >&6
15100if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
15101 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015102else
Martin v. Löwis11437992002-04-12 09:54:03 +000015103 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015104LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015105cat >conftest.$ac_ext <<_ACEOF
15106#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000015107#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015108
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015109/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015110#ifdef __cplusplus
15111extern "C"
15112#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015113/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015114 builtin and then its argument prototype would still apply. */
15115char __fpu_control ();
15116#ifdef F77_DUMMY_MAIN
15117# ifdef __cplusplus
15118 extern "C"
15119# endif
15120 int F77_DUMMY_MAIN() { return 1; }
15121#endif
15122int
15123main ()
15124{
15125__fpu_control ();
15126 ;
15127 return 0;
15128}
15129_ACEOF
15130rm -f conftest.$ac_objext conftest$ac_exeext
15131if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15132 (eval $ac_link) 2>&5
15133 ac_status=$?
15134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15135 (exit $ac_status); } &&
15136 { ac_try='test -s conftest$ac_exeext'
15137 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15138 (eval $ac_try) 2>&5
15139 ac_status=$?
15140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15141 (exit $ac_status); }; }; then
15142 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000015143else
Martin v. Löwis11437992002-04-12 09:54:03 +000015144 echo "$as_me: failed program was:" >&5
15145cat conftest.$ac_ext >&5
15146ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015147fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015148rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15149LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015150fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015151echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
15152echo "${ECHO_T}$ac_cv_lib_ieee___fpu_control" >&6
15153if test $ac_cv_lib_ieee___fpu_control = yes; then
15154 cat >>confdefs.h <<_ACEOF
15155#define HAVE_LIBIEEE 1
15156_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015157
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015158 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015159
Guido van Rossum627b2d71993-12-24 10:39:16 +000015160fi
15161
Michael W. Hudson54241132001-12-07 15:38:26 +000015162
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015163fi
15164
Michael W. Hudson54241132001-12-07 15:38:26 +000015165
Guido van Rossum7f253911997-05-09 02:42:48 +000015166# Check for --with-fpectl
Martin v. Löwis11437992002-04-12 09:54:03 +000015167echo "$as_me:$LINENO: checking for --with-fpectl" >&5
15168echo $ECHO_N "checking for --with-fpectl... $ECHO_C" >&6
15169
Guido van Rossum7f253911997-05-09 02:42:48 +000015170# Check whether --with-fpectl or --without-fpectl was given.
15171if test "${with_fpectl+set}" = set; then
15172 withval="$with_fpectl"
Martin v. Löwis11437992002-04-12 09:54:03 +000015173
Guido van Rossum7f253911997-05-09 02:42:48 +000015174if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000015175then
15176
15177cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000015178#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015179_ACEOF
15180
15181 echo "$as_me:$LINENO: result: yes" >&5
15182echo "${ECHO_T}yes" >&6
15183else echo "$as_me:$LINENO: result: no" >&5
15184echo "${ECHO_T}no" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015185fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015186else
Martin v. Löwis11437992002-04-12 09:54:03 +000015187 echo "$as_me:$LINENO: result: no" >&5
15188echo "${ECHO_T}no" >&6
15189fi;
Guido van Rossum7f253911997-05-09 02:42:48 +000015190
Guido van Rossum7f43da71994-08-01 12:15:30 +000015191# check for --with-libm=...
15192
Guido van Rossum563e7081996-09-10 18:20:48 +000015193case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000015194Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015195BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000015196*) LIBM=-lm
15197esac
Martin v. Löwis11437992002-04-12 09:54:03 +000015198echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
15199echo $ECHO_N "checking for --with-libm=STRING... $ECHO_C" >&6
15200
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015201# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015202if test "${with_libm+set}" = set; then
15203 withval="$with_libm"
Martin v. Löwis11437992002-04-12 09:54:03 +000015204
Guido van Rossum7f253911997-05-09 02:42:48 +000015205if test "$withval" = no
15206then LIBM=
Martin v. Löwis11437992002-04-12 09:54:03 +000015207 echo "$as_me:$LINENO: result: force LIBM empty" >&5
15208echo "${ECHO_T}force LIBM empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015209elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000015210then LIBM=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000015211 echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
15212echo "${ECHO_T}set LIBM=\"$withval\"" >&6
15213else { { echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
15214echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
15215 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000015216fi
Guido van Rossum7f253911997-05-09 02:42:48 +000015217else
Martin v. Löwis11437992002-04-12 09:54:03 +000015218 echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
15219echo "${ECHO_T}default LIBM=\"$LIBM\"" >&6
15220fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000015221
15222# check for --with-libc=...
15223
Martin v. Löwis11437992002-04-12 09:54:03 +000015224echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
15225echo $ECHO_N "checking for --with-libc=STRING... $ECHO_C" >&6
15226
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015227# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015228if test "${with_libc+set}" = set; then
15229 withval="$with_libc"
Martin v. Löwis11437992002-04-12 09:54:03 +000015230
Guido van Rossum7f253911997-05-09 02:42:48 +000015231if test "$withval" = no
15232then LIBC=
Martin v. Löwis11437992002-04-12 09:54:03 +000015233 echo "$as_me:$LINENO: result: force LIBC empty" >&5
15234echo "${ECHO_T}force LIBC empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015235elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000015236then LIBC=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000015237 echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
15238echo "${ECHO_T}set LIBC=\"$withval\"" >&6
15239else { { echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
15240echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
15241 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000015242fi
Guido van Rossum7f253911997-05-09 02:42:48 +000015243else
Martin v. Löwis11437992002-04-12 09:54:03 +000015244 echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
15245echo "${ECHO_T}default LIBC=\"$LIBC\"" >&6
15246fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000015247
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015248# check for hypot() in math library
15249LIBS_SAVE=$LIBS
15250LIBS="$LIBS $LIBM"
Martin v. Löwis11437992002-04-12 09:54:03 +000015251
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015252for ac_func in hypot
15253do
Martin v. Löwis11437992002-04-12 09:54:03 +000015254as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15255echo "$as_me:$LINENO: checking for $ac_func" >&5
15256echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15257if eval "test \"\${$as_ac_var+set}\" = set"; then
15258 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015259else
Martin v. Löwis11437992002-04-12 09:54:03 +000015260 cat >conftest.$ac_ext <<_ACEOF
15261#line $LINENO "configure"
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015262#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015263/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000015264 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015265#include <assert.h>
15266/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015267#ifdef __cplusplus
15268extern "C"
15269#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015270/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015271 builtin and then its argument prototype would still apply. */
15272char $ac_func ();
15273char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015274
Martin v. Löwis11437992002-04-12 09:54:03 +000015275#ifdef F77_DUMMY_MAIN
15276# ifdef __cplusplus
15277 extern "C"
15278# endif
15279 int F77_DUMMY_MAIN() { return 1; }
15280#endif
15281int
15282main ()
15283{
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015284/* The GNU C library defines this for functions which it implements
15285 to always fail with ENOSYS. Some functions are actually named
15286 something starting with __ and the normal name is an alias. */
15287#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15288choke me
15289#else
Martin v. Löwis11437992002-04-12 09:54:03 +000015290f = $ac_func;
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015291#endif
15292
Martin v. Löwis11437992002-04-12 09:54:03 +000015293 ;
15294 return 0;
15295}
15296_ACEOF
15297rm -f conftest.$ac_objext conftest$ac_exeext
15298if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15299 (eval $ac_link) 2>&5
15300 ac_status=$?
15301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15302 (exit $ac_status); } &&
15303 { ac_try='test -s conftest$ac_exeext'
15304 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15305 (eval $ac_try) 2>&5
15306 ac_status=$?
15307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15308 (exit $ac_status); }; }; then
15309 eval "$as_ac_var=yes"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015310else
Martin v. Löwis11437992002-04-12 09:54:03 +000015311 echo "$as_me: failed program was:" >&5
15312cat conftest.$ac_ext >&5
15313eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000015314fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015315rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015316fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015317echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15318echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15319if test `eval echo '${'$as_ac_var'}'` = yes; then
15320 cat >>confdefs.h <<_ACEOF
15321#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15322_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000015323
Michael W. Hudson54241132001-12-07 15:38:26 +000015324else
Martin v. Löwis11437992002-04-12 09:54:03 +000015325 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015326fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015327done
15328
Michael W. Hudson54241132001-12-07 15:38:26 +000015329
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015330LIBS=$LIBS_SAVE
15331
Guido van Rossumef2255b2000-03-10 22:30:29 +000015332# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015333if test "${ac_cv_header_wchar_h+set}" = set; then
15334 echo "$as_me:$LINENO: checking for wchar.h" >&5
15335echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
15336if test "${ac_cv_header_wchar_h+set}" = set; then
15337 echo $ECHO_N "(cached) $ECHO_C" >&6
15338fi
15339echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
15340echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015341else
Martin v. Löwis11437992002-04-12 09:54:03 +000015342 # Is the header compilable?
15343echo "$as_me:$LINENO: checking wchar.h usability" >&5
15344echo $ECHO_N "checking wchar.h usability... $ECHO_C" >&6
15345cat >conftest.$ac_ext <<_ACEOF
15346#line $LINENO "configure"
15347#include "confdefs.h"
15348$ac_includes_default
15349#include <wchar.h>
15350_ACEOF
15351rm -f conftest.$ac_objext
15352if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15353 (eval $ac_compile) 2>&5
15354 ac_status=$?
15355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15356 (exit $ac_status); } &&
15357 { ac_try='test -s conftest.$ac_objext'
15358 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15359 (eval $ac_try) 2>&5
15360 ac_status=$?
15361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15362 (exit $ac_status); }; }; then
15363 ac_header_compiler=yes
15364else
15365 echo "$as_me: failed program was:" >&5
15366cat conftest.$ac_ext >&5
15367ac_header_compiler=no
15368fi
15369rm -f conftest.$ac_objext conftest.$ac_ext
15370echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15371echo "${ECHO_T}$ac_header_compiler" >&6
15372
15373# Is the header present?
15374echo "$as_me:$LINENO: checking wchar.h presence" >&5
15375echo $ECHO_N "checking wchar.h presence... $ECHO_C" >&6
15376cat >conftest.$ac_ext <<_ACEOF
15377#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015378#include "confdefs.h"
15379#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015380_ACEOF
15381if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15382 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15383 ac_status=$?
15384 egrep -v '^ *\+' conftest.er1 >conftest.err
15385 rm -f conftest.er1
15386 cat conftest.err >&5
15387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15388 (exit $ac_status); } >/dev/null; then
15389 if test -s conftest.err; then
15390 ac_cpp_err=$ac_c_preproc_warn_flag
15391 else
15392 ac_cpp_err=
15393 fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015394else
Martin v. Löwis11437992002-04-12 09:54:03 +000015395 ac_cpp_err=yes
15396fi
15397if test -z "$ac_cpp_err"; then
15398 ac_header_preproc=yes
15399else
15400 echo "$as_me: failed program was:" >&5
Guido van Rossumef2255b2000-03-10 22:30:29 +000015401 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015402 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015403fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015404rm -f conftest.err conftest.$ac_ext
15405echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15406echo "${ECHO_T}$ac_header_preproc" >&6
15407
15408# So? What about this header?
15409case $ac_header_compiler:$ac_header_preproc in
15410 yes:no )
15411 { echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
15412echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15413 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
15414echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
15415 no:yes )
15416 { echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
15417echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
15418 { echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
15419echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
15420 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
15421echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
15422esac
15423echo "$as_me:$LINENO: checking for wchar.h" >&5
15424echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
15425if test "${ac_cv_header_wchar_h+set}" = set; then
15426 echo $ECHO_N "(cached) $ECHO_C" >&6
15427else
15428 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000015429fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015430echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
15431echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
15432
15433fi
15434if test $ac_cv_header_wchar_h = yes; then
15435
15436
15437cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000015438#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015439_ACEOF
15440
Martin v. Löwisc45929e2002-04-06 10:10:49 +000015441 wchar_h="yes"
15442
Guido van Rossumef2255b2000-03-10 22:30:29 +000015443else
Martin v. Löwis11437992002-04-12 09:54:03 +000015444 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015445
15446fi
15447
Michael W. Hudson54241132001-12-07 15:38:26 +000015448
Martin v. Löwis11437992002-04-12 09:54:03 +000015449
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015450# determine wchar_t size
15451if test "$wchar_h" = yes
15452then
Martin v. Löwis11437992002-04-12 09:54:03 +000015453 echo "$as_me:$LINENO: checking for wchar_t" >&5
15454echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
15455if test "${ac_cv_type_wchar_t+set}" = set; then
15456 echo $ECHO_N "(cached) $ECHO_C" >&6
15457else
15458 cat >conftest.$ac_ext <<_ACEOF
15459#line $LINENO "configure"
15460#include "confdefs.h"
15461#include <wchar.h>
15462
15463#ifdef F77_DUMMY_MAIN
15464# ifdef __cplusplus
15465 extern "C"
15466# endif
15467 int F77_DUMMY_MAIN() { return 1; }
15468#endif
15469int
15470main ()
15471{
15472if ((wchar_t *) 0)
15473 return 0;
15474if (sizeof (wchar_t))
15475 return 0;
15476 ;
15477 return 0;
15478}
15479_ACEOF
15480rm -f conftest.$ac_objext
15481if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15482 (eval $ac_compile) 2>&5
15483 ac_status=$?
15484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15485 (exit $ac_status); } &&
15486 { ac_try='test -s conftest.$ac_objext'
15487 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15488 (eval $ac_try) 2>&5
15489 ac_status=$?
15490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15491 (exit $ac_status); }; }; then
15492 ac_cv_type_wchar_t=yes
15493else
15494 echo "$as_me: failed program was:" >&5
15495cat conftest.$ac_ext >&5
15496ac_cv_type_wchar_t=no
15497fi
15498rm -f conftest.$ac_objext conftest.$ac_ext
15499fi
15500echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
15501echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
15502
15503echo "$as_me:$LINENO: checking size of wchar_t" >&5
15504echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
15505if test "${ac_cv_sizeof_wchar_t+set}" = set; then
15506 echo $ECHO_N "(cached) $ECHO_C" >&6
15507else
15508 if test "$ac_cv_type_wchar_t" = yes; then
15509 # The cast to unsigned long works around a bug in the HP C Compiler
15510 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15511 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15512 # This bug is HP SR number 8606223364.
15513 if test "$cross_compiling" = yes; then
15514 # Depending upon the size, compute the lo and hi bounds.
15515cat >conftest.$ac_ext <<_ACEOF
15516#line $LINENO "configure"
15517#include "confdefs.h"
15518#include <wchar.h>
15519
15520#ifdef F77_DUMMY_MAIN
15521# ifdef __cplusplus
15522 extern "C"
15523# endif
15524 int F77_DUMMY_MAIN() { return 1; }
15525#endif
15526int
15527main ()
15528{
15529static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
15530test_array [0] = 0
15531
15532 ;
15533 return 0;
15534}
15535_ACEOF
15536rm -f conftest.$ac_objext
15537if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15538 (eval $ac_compile) 2>&5
15539 ac_status=$?
15540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15541 (exit $ac_status); } &&
15542 { ac_try='test -s conftest.$ac_objext'
15543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15544 (eval $ac_try) 2>&5
15545 ac_status=$?
15546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15547 (exit $ac_status); }; }; then
15548 ac_lo=0 ac_mid=0
15549 while :; do
15550 cat >conftest.$ac_ext <<_ACEOF
15551#line $LINENO "configure"
15552#include "confdefs.h"
15553#include <wchar.h>
15554
15555#ifdef F77_DUMMY_MAIN
15556# ifdef __cplusplus
15557 extern "C"
15558# endif
15559 int F77_DUMMY_MAIN() { return 1; }
15560#endif
15561int
15562main ()
15563{
15564static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15565test_array [0] = 0
15566
15567 ;
15568 return 0;
15569}
15570_ACEOF
15571rm -f conftest.$ac_objext
15572if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15573 (eval $ac_compile) 2>&5
15574 ac_status=$?
15575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15576 (exit $ac_status); } &&
15577 { ac_try='test -s conftest.$ac_objext'
15578 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15579 (eval $ac_try) 2>&5
15580 ac_status=$?
15581 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15582 (exit $ac_status); }; }; then
15583 ac_hi=$ac_mid; break
15584else
15585 echo "$as_me: failed program was:" >&5
15586cat conftest.$ac_ext >&5
15587ac_lo=`expr $ac_mid + 1`
15588 if test $ac_lo -le $ac_mid; then
15589 ac_lo= ac_hi=
15590 break
15591 fi
15592 ac_mid=`expr 2 '*' $ac_mid + 1`
15593fi
15594rm -f conftest.$ac_objext conftest.$ac_ext
15595 done
15596else
15597 echo "$as_me: failed program was:" >&5
15598cat conftest.$ac_ext >&5
15599cat >conftest.$ac_ext <<_ACEOF
15600#line $LINENO "configure"
15601#include "confdefs.h"
15602#include <wchar.h>
15603
15604#ifdef F77_DUMMY_MAIN
15605# ifdef __cplusplus
15606 extern "C"
15607# endif
15608 int F77_DUMMY_MAIN() { return 1; }
15609#endif
15610int
15611main ()
15612{
15613static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
15614test_array [0] = 0
15615
15616 ;
15617 return 0;
15618}
15619_ACEOF
15620rm -f conftest.$ac_objext
15621if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15622 (eval $ac_compile) 2>&5
15623 ac_status=$?
15624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15625 (exit $ac_status); } &&
15626 { ac_try='test -s conftest.$ac_objext'
15627 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15628 (eval $ac_try) 2>&5
15629 ac_status=$?
15630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15631 (exit $ac_status); }; }; then
15632 ac_hi=-1 ac_mid=-1
15633 while :; do
15634 cat >conftest.$ac_ext <<_ACEOF
15635#line $LINENO "configure"
15636#include "confdefs.h"
15637#include <wchar.h>
15638
15639#ifdef F77_DUMMY_MAIN
15640# ifdef __cplusplus
15641 extern "C"
15642# endif
15643 int F77_DUMMY_MAIN() { return 1; }
15644#endif
15645int
15646main ()
15647{
15648static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
15649test_array [0] = 0
15650
15651 ;
15652 return 0;
15653}
15654_ACEOF
15655rm -f conftest.$ac_objext
15656if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15657 (eval $ac_compile) 2>&5
15658 ac_status=$?
15659 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15660 (exit $ac_status); } &&
15661 { ac_try='test -s conftest.$ac_objext'
15662 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15663 (eval $ac_try) 2>&5
15664 ac_status=$?
15665 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15666 (exit $ac_status); }; }; then
15667 ac_lo=$ac_mid; break
15668else
15669 echo "$as_me: failed program was:" >&5
15670cat conftest.$ac_ext >&5
15671ac_hi=`expr '(' $ac_mid ')' - 1`
15672 if test $ac_mid -le $ac_hi; then
15673 ac_lo= ac_hi=
15674 break
15675 fi
15676 ac_mid=`expr 2 '*' $ac_mid`
15677fi
15678rm -f conftest.$ac_objext conftest.$ac_ext
15679 done
15680else
15681 echo "$as_me: failed program was:" >&5
15682cat conftest.$ac_ext >&5
15683ac_lo= ac_hi=
15684fi
15685rm -f conftest.$ac_objext conftest.$ac_ext
15686fi
15687rm -f conftest.$ac_objext conftest.$ac_ext
15688# Binary search between lo and hi bounds.
15689while test "x$ac_lo" != "x$ac_hi"; do
15690 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15691 cat >conftest.$ac_ext <<_ACEOF
15692#line $LINENO "configure"
15693#include "confdefs.h"
15694#include <wchar.h>
15695
15696#ifdef F77_DUMMY_MAIN
15697# ifdef __cplusplus
15698 extern "C"
15699# endif
15700 int F77_DUMMY_MAIN() { return 1; }
15701#endif
15702int
15703main ()
15704{
15705static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15706test_array [0] = 0
15707
15708 ;
15709 return 0;
15710}
15711_ACEOF
15712rm -f conftest.$ac_objext
15713if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15714 (eval $ac_compile) 2>&5
15715 ac_status=$?
15716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15717 (exit $ac_status); } &&
15718 { ac_try='test -s conftest.$ac_objext'
15719 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15720 (eval $ac_try) 2>&5
15721 ac_status=$?
15722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15723 (exit $ac_status); }; }; then
15724 ac_hi=$ac_mid
15725else
15726 echo "$as_me: failed program was:" >&5
15727cat conftest.$ac_ext >&5
15728ac_lo=`expr '(' $ac_mid ')' + 1`
15729fi
15730rm -f conftest.$ac_objext conftest.$ac_ext
15731done
15732case $ac_lo in
15733?*) ac_cv_sizeof_wchar_t=$ac_lo;;
15734'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15735echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15736 { (exit 1); exit 1; }; } ;;
15737esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015738else
15739 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015740 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15741echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15742 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000015743else
Martin v. Löwis11437992002-04-12 09:54:03 +000015744 cat >conftest.$ac_ext <<_ACEOF
15745#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015746#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015747#include <wchar.h>
15748
15749long longval () { return (long) (sizeof (wchar_t)); }
15750unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000015751#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015752#include <stdlib.h>
15753#ifdef F77_DUMMY_MAIN
15754# ifdef __cplusplus
15755 extern "C"
15756# endif
15757 int F77_DUMMY_MAIN() { return 1; }
15758#endif
15759int
15760main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015761{
Martin v. Löwis11437992002-04-12 09:54:03 +000015762
15763 FILE *f = fopen ("conftest.val", "w");
15764 if (! f)
15765 exit (1);
15766 if (((long) (sizeof (wchar_t))) < 0)
15767 {
15768 long i = longval ();
15769 if (i != ((long) (sizeof (wchar_t))))
15770 exit (1);
15771 fprintf (f, "%ld\n", i);
15772 }
15773 else
15774 {
15775 unsigned long i = ulongval ();
15776 if (i != ((long) (sizeof (wchar_t))))
15777 exit (1);
15778 fprintf (f, "%lu\n", i);
15779 }
15780 exit (ferror (f) || fclose (f) != 0);
15781
15782 ;
15783 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000015784}
Martin v. Löwis11437992002-04-12 09:54:03 +000015785_ACEOF
15786rm -f conftest$ac_exeext
15787if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15788 (eval $ac_link) 2>&5
15789 ac_status=$?
15790 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15791 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15792 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15793 (eval $ac_try) 2>&5
15794 ac_status=$?
15795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15796 (exit $ac_status); }; }; then
15797 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000015798else
Martin v. Löwis11437992002-04-12 09:54:03 +000015799 echo "$as_me: program exited with status $ac_status" >&5
15800echo "$as_me: failed program was:" >&5
15801cat conftest.$ac_ext >&5
15802( exit $ac_status )
15803{ { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15804echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15805 { (exit 1); exit 1; }; }
15806fi
15807rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15808fi
15809fi
15810rm -f conftest.val
15811else
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015812 ac_cv_sizeof_wchar_t=0
Guido van Rossumef2255b2000-03-10 22:30:29 +000015813fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015814fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015815echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
15816echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
15817cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015818#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015819_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015820
Michael W. Hudson54241132001-12-07 15:38:26 +000015821
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015822fi
15823
Martin v. Löwis11437992002-04-12 09:54:03 +000015824echo "$as_me:$LINENO: checking what type to use for unicode" >&5
15825echo $ECHO_N "checking what type to use for unicode... $ECHO_C" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015826# Check whether --enable-unicode or --disable-unicode was given.
15827if test "${enable_unicode+set}" = set; then
15828 enableval="$enable_unicode"
Martin v. Löwis11437992002-04-12 09:54:03 +000015829
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015830else
15831 enable_unicode=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000015832fi;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015833
15834if test $enable_unicode = yes
15835then
Martin v. Löwisfd917792001-06-27 20:22:04 +000015836 # Without any arguments, Py_UNICODE defaults to two-byte mode
15837 enable_unicode="ucs2"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015838fi
15839
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015840
15841
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015842case "$enable_unicode" in
15843ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000015844 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015845#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000015846_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015847
15848 ;;
15849ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000015850 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015851#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000015852_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015853
15854 ;;
15855esac
15856
Michael W. Hudson54241132001-12-07 15:38:26 +000015857
Martin v. Löwis11437992002-04-12 09:54:03 +000015858
15859
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015860
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015861if test "$enable_unicode" = "no"
15862then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015863 UNICODE_OBJS=""
Martin v. Löwis11437992002-04-12 09:54:03 +000015864 echo "$as_me:$LINENO: result: not used" >&5
15865echo "${ECHO_T}not used" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015866else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015867 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000015868
15869cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015870#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015871_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015872
15873 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t"
15874 then
15875 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015876
Martin v. Löwis11437992002-04-12 09:54:03 +000015877cat >>confdefs.h <<\_ACEOF
15878#define HAVE_USABLE_WCHAR_T 1
15879_ACEOF
15880
15881 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015882#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015883_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015884
15885 elif test "$ac_cv_sizeof_short" = "$unicode_size"
15886 then
15887 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000015888 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015889#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000015890_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015891
15892 elif test "$ac_cv_sizeof_long" = "$unicode_size"
15893 then
15894 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000015895 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015896#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000015897_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015898
15899 else
15900 PY_UNICODE_TYPE="no type found"
15901 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015902 echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
15903echo "${ECHO_T}$PY_UNICODE_TYPE" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015904fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015905
15906# check for endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000015907echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
15908echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
15909if test "${ac_cv_c_bigendian+set}" = set; then
15910 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015911else
Martin v. Löwis11437992002-04-12 09:54:03 +000015912 # See if sys/param.h defines the BYTE_ORDER macro.
15913cat >conftest.$ac_ext <<_ACEOF
15914#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015915#include "confdefs.h"
15916#include <sys/types.h>
15917#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015918
Martin v. Löwis11437992002-04-12 09:54:03 +000015919#ifdef F77_DUMMY_MAIN
15920# ifdef __cplusplus
15921 extern "C"
15922# endif
15923 int F77_DUMMY_MAIN() { return 1; }
15924#endif
15925int
15926main ()
15927{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015928#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
15929 bogus endian macros
15930#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015931
15932 ;
15933 return 0;
15934}
15935_ACEOF
15936rm -f conftest.$ac_objext
15937if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15938 (eval $ac_compile) 2>&5
15939 ac_status=$?
15940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15941 (exit $ac_status); } &&
15942 { ac_try='test -s conftest.$ac_objext'
15943 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15944 (eval $ac_try) 2>&5
15945 ac_status=$?
15946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15947 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015948 # It does; now see whether it defined to BIG_ENDIAN or not.
Martin v. Löwis11437992002-04-12 09:54:03 +000015949cat >conftest.$ac_ext <<_ACEOF
15950#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015951#include "confdefs.h"
15952#include <sys/types.h>
15953#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015954
Martin v. Löwis11437992002-04-12 09:54:03 +000015955#ifdef F77_DUMMY_MAIN
15956# ifdef __cplusplus
15957 extern "C"
15958# endif
15959 int F77_DUMMY_MAIN() { return 1; }
15960#endif
15961int
15962main ()
15963{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015964#if BYTE_ORDER != BIG_ENDIAN
15965 not big endian
15966#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015967
15968 ;
15969 return 0;
15970}
15971_ACEOF
15972rm -f conftest.$ac_objext
15973if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15974 (eval $ac_compile) 2>&5
15975 ac_status=$?
15976 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15977 (exit $ac_status); } &&
15978 { ac_try='test -s conftest.$ac_objext'
15979 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15980 (eval $ac_try) 2>&5
15981 ac_status=$?
15982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15983 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015984 ac_cv_c_bigendian=yes
15985else
Martin v. Löwis11437992002-04-12 09:54:03 +000015986 echo "$as_me: failed program was:" >&5
15987cat conftest.$ac_ext >&5
15988ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015989fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015990rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000015991else
Martin v. Löwis11437992002-04-12 09:54:03 +000015992 echo "$as_me: failed program was:" >&5
15993cat conftest.$ac_ext >&5
15994# It does not; compile a test program.
Guido van Rossumef2255b2000-03-10 22:30:29 +000015995if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015996 # try to guess the endianess by grep'ing values into an object file
15997 ac_cv_c_bigendian=unknown
15998 cat >conftest.$ac_ext <<_ACEOF
15999#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000016000#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016001short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16002short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16003void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
16004short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16005short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16006void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
16007#ifdef F77_DUMMY_MAIN
16008# ifdef __cplusplus
16009 extern "C"
16010# endif
16011 int F77_DUMMY_MAIN() { return 1; }
16012#endif
16013int
16014main ()
16015{
16016 _ascii (); _ebcdic ();
16017 ;
16018 return 0;
16019}
16020_ACEOF
16021rm -f conftest.$ac_objext
16022if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16023 (eval $ac_compile) 2>&5
16024 ac_status=$?
16025 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16026 (exit $ac_status); } &&
16027 { ac_try='test -s conftest.$ac_objext'
16028 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16029 (eval $ac_try) 2>&5
16030 ac_status=$?
16031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16032 (exit $ac_status); }; }; then
16033 if fgrep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
16034 ac_cv_c_bigendian=yes
16035fi
16036if fgrep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16037 if test "$ac_cv_c_bigendian" = unknown; then
16038 ac_cv_c_bigendian=no
16039 else
16040 # finding both strings is unlikely to happen, but who knows?
16041 ac_cv_c_bigendian=unknown
16042 fi
16043fi
16044else
16045 echo "$as_me: failed program was:" >&5
16046cat conftest.$ac_ext >&5
16047fi
16048rm -f conftest.$ac_objext conftest.$ac_ext
16049else
16050 cat >conftest.$ac_ext <<_ACEOF
16051#line $LINENO "configure"
16052#include "confdefs.h"
16053int
16054main ()
16055{
Guido van Rossumef2255b2000-03-10 22:30:29 +000016056 /* Are we little or big endian? From Harbison&Steele. */
16057 union
16058 {
16059 long l;
16060 char c[sizeof (long)];
16061 } u;
16062 u.l = 1;
16063 exit (u.c[sizeof (long) - 1] == 1);
16064}
Martin v. Löwis11437992002-04-12 09:54:03 +000016065_ACEOF
16066rm -f conftest$ac_exeext
16067if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16068 (eval $ac_link) 2>&5
16069 ac_status=$?
16070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16071 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16072 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16073 (eval $ac_try) 2>&5
16074 ac_status=$?
16075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16076 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000016077 ac_cv_c_bigendian=no
16078else
Martin v. Löwis11437992002-04-12 09:54:03 +000016079 echo "$as_me: program exited with status $ac_status" >&5
16080echo "$as_me: failed program was:" >&5
16081cat conftest.$ac_ext >&5
16082( exit $ac_status )
16083ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000016084fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016085rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000016086fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016087fi
16088rm -f conftest.$ac_objext conftest.$ac_ext
16089fi
16090echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
16091echo "${ECHO_T}$ac_cv_c_bigendian" >&6
16092case $ac_cv_c_bigendian in
16093 yes)
Jack Jansendd19cf82001-12-06 22:36:17 +000016094
Martin v. Löwis11437992002-04-12 09:54:03 +000016095cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000016096#define WORDS_BIGENDIAN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016097_ACEOF
16098 ;;
16099 no)
16100 ;;
16101 *)
16102 { { echo "$as_me:$LINENO: error: unknown endianess
16103presetting ac_cv_c_bigendian=no (or yes) will help" >&5
16104echo "$as_me: error: unknown endianess
16105presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
16106 { (exit 1); exit 1; }; } ;;
16107esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000016108
Michael W. Hudson54241132001-12-07 15:38:26 +000016109
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016110# Check whether right shifting a negative integer extends the sign bit
16111# or fills with zeros (like the Cray J90, according to Tim Peters).
Martin v. Löwis11437992002-04-12 09:54:03 +000016112echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
16113echo $ECHO_N "checking whether right shift extends the sign bit... $ECHO_C" >&6
16114if test "${ac_cv_rshift_extends_sign+set}" = set; then
16115 echo $ECHO_N "(cached) $ECHO_C" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000016116else
Martin v. Löwis11437992002-04-12 09:54:03 +000016117
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016118if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000016119 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016120else
Martin v. Löwis11437992002-04-12 09:54:03 +000016121 cat >conftest.$ac_ext <<_ACEOF
16122#line $LINENO "configure"
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016123#include "confdefs.h"
16124
16125int main()
16126{
Vladimir Marangozova6180282000-07-12 05:05:06 +000016127 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016128}
16129
Martin v. Löwis11437992002-04-12 09:54:03 +000016130_ACEOF
16131rm -f conftest$ac_exeext
16132if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16133 (eval $ac_link) 2>&5
16134 ac_status=$?
16135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16136 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16137 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16138 (eval $ac_try) 2>&5
16139 ac_status=$?
16140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16141 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000016142 ac_cv_rshift_extends_sign=yes
16143else
Martin v. Löwis11437992002-04-12 09:54:03 +000016144 echo "$as_me: program exited with status $ac_status" >&5
16145echo "$as_me: failed program was:" >&5
16146cat conftest.$ac_ext >&5
16147( exit $ac_status )
16148ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000016149fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016150rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16151fi
Vladimir Marangozova6180282000-07-12 05:05:06 +000016152fi
16153
Martin v. Löwis11437992002-04-12 09:54:03 +000016154echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
16155echo "${ECHO_T}$ac_cv_rshift_extends_sign" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000016156if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016157then
Martin v. Löwis11437992002-04-12 09:54:03 +000016158
16159cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016160#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016161_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016162
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016163fi
16164
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016165# check for getc_unlocked and related locking functions
Martin v. Löwis11437992002-04-12 09:54:03 +000016166echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
16167echo $ECHO_N "checking for getc_unlocked() and friends... $ECHO_C" >&6
16168if test "${ac_cv_have_getc_unlocked+set}" = set; then
16169 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016170else
Martin v. Löwis11437992002-04-12 09:54:03 +000016171
16172cat >conftest.$ac_ext <<_ACEOF
16173#line $LINENO "configure"
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016174#include "confdefs.h"
16175#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016176#ifdef F77_DUMMY_MAIN
16177# ifdef __cplusplus
16178 extern "C"
16179# endif
16180 int F77_DUMMY_MAIN() { return 1; }
16181#endif
16182int
16183main ()
16184{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016185
16186 FILE *f = fopen("/dev/null", "r");
16187 flockfile(f);
16188 getc_unlocked(f);
16189 funlockfile(f);
16190
Martin v. Löwis11437992002-04-12 09:54:03 +000016191 ;
16192 return 0;
16193}
16194_ACEOF
16195rm -f conftest.$ac_objext conftest$ac_exeext
16196if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16197 (eval $ac_link) 2>&5
16198 ac_status=$?
16199 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16200 (exit $ac_status); } &&
16201 { ac_try='test -s conftest$ac_exeext'
16202 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16203 (eval $ac_try) 2>&5
16204 ac_status=$?
16205 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16206 (exit $ac_status); }; }; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016207 ac_cv_have_getc_unlocked=yes
16208else
Martin v. Löwis11437992002-04-12 09:54:03 +000016209 echo "$as_me: failed program was:" >&5
16210cat conftest.$ac_ext >&5
16211ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016212fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016213rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016214fi
16215
Martin v. Löwis11437992002-04-12 09:54:03 +000016216echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
16217echo "${ECHO_T}$ac_cv_have_getc_unlocked" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016218if test "$ac_cv_have_getc_unlocked" = yes
16219then
Martin v. Löwis11437992002-04-12 09:54:03 +000016220
16221cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016222#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016223_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016224
16225fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016226
Martin v. Löwis0daad592001-09-30 21:09:59 +000016227# check for readline 4.0
Martin v. Löwis11437992002-04-12 09:54:03 +000016228echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
16229echo $ECHO_N "checking for rl_pre_input_hook in -lreadline... $ECHO_C" >&6
16230if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
16231 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000016232else
Martin v. Löwis11437992002-04-12 09:54:03 +000016233 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum353ae582001-07-10 16:45:32 +000016234LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016235cat >conftest.$ac_ext <<_ACEOF
16236#line $LINENO "configure"
Guido van Rossum353ae582001-07-10 16:45:32 +000016237#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016238
Guido van Rossum353ae582001-07-10 16:45:32 +000016239/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016240#ifdef __cplusplus
16241extern "C"
16242#endif
Guido van Rossum353ae582001-07-10 16:45:32 +000016243/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016244 builtin and then its argument prototype would still apply. */
16245char rl_pre_input_hook ();
16246#ifdef F77_DUMMY_MAIN
16247# ifdef __cplusplus
16248 extern "C"
16249# endif
16250 int F77_DUMMY_MAIN() { return 1; }
16251#endif
16252int
16253main ()
16254{
16255rl_pre_input_hook ();
16256 ;
16257 return 0;
16258}
16259_ACEOF
16260rm -f conftest.$ac_objext conftest$ac_exeext
16261if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16262 (eval $ac_link) 2>&5
16263 ac_status=$?
16264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16265 (exit $ac_status); } &&
16266 { ac_try='test -s conftest$ac_exeext'
16267 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16268 (eval $ac_try) 2>&5
16269 ac_status=$?
16270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16271 (exit $ac_status); }; }; then
16272 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000016273else
Martin v. Löwis11437992002-04-12 09:54:03 +000016274 echo "$as_me: failed program was:" >&5
16275cat conftest.$ac_ext >&5
16276ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000016277fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016278rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16279LIBS=$ac_check_lib_save_LIBS
16280fi
16281echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
16282echo "${ECHO_T}$ac_cv_lib_readline_rl_pre_input_hook" >&6
16283if test $ac_cv_lib_readline_rl_pre_input_hook = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000016284
Martin v. Löwis11437992002-04-12 09:54:03 +000016285cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000016286#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016287_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000016288
Martin v. Löwis0daad592001-09-30 21:09:59 +000016289fi
16290
Michael W. Hudson54241132001-12-07 15:38:26 +000016291
Martin v. Löwis0daad592001-09-30 21:09:59 +000016292# check for readline 4.2
Martin v. Löwis11437992002-04-12 09:54:03 +000016293echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
16294echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6
16295if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
16296 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000016297else
Martin v. Löwis11437992002-04-12 09:54:03 +000016298 ac_check_lib_save_LIBS=$LIBS
Martin v. Löwis0daad592001-09-30 21:09:59 +000016299LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016300cat >conftest.$ac_ext <<_ACEOF
16301#line $LINENO "configure"
Martin v. Löwis0daad592001-09-30 21:09:59 +000016302#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016303
Martin v. Löwis0daad592001-09-30 21:09:59 +000016304/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016305#ifdef __cplusplus
16306extern "C"
16307#endif
Martin v. Löwis0daad592001-09-30 21:09:59 +000016308/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016309 builtin and then its argument prototype would still apply. */
16310char rl_completion_matches ();
16311#ifdef F77_DUMMY_MAIN
16312# ifdef __cplusplus
16313 extern "C"
16314# endif
16315 int F77_DUMMY_MAIN() { return 1; }
16316#endif
16317int
16318main ()
16319{
16320rl_completion_matches ();
16321 ;
16322 return 0;
16323}
16324_ACEOF
16325rm -f conftest.$ac_objext conftest$ac_exeext
16326if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16327 (eval $ac_link) 2>&5
16328 ac_status=$?
16329 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16330 (exit $ac_status); } &&
16331 { ac_try='test -s conftest$ac_exeext'
16332 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16333 (eval $ac_try) 2>&5
16334 ac_status=$?
16335 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16336 (exit $ac_status); }; }; then
16337 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000016338else
Martin v. Löwis11437992002-04-12 09:54:03 +000016339 echo "$as_me: failed program was:" >&5
16340cat conftest.$ac_ext >&5
16341ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000016342fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016343rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16344LIBS=$ac_check_lib_save_LIBS
16345fi
16346echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
16347echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6
16348if test $ac_cv_lib_readline_rl_completion_matches = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000016349
Martin v. Löwis11437992002-04-12 09:54:03 +000016350cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000016351#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016352_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000016353
Guido van Rossum353ae582001-07-10 16:45:32 +000016354fi
16355
Jack Jansendd19cf82001-12-06 22:36:17 +000016356
Martin v. Löwis11437992002-04-12 09:54:03 +000016357echo "$as_me:$LINENO: checking for broken nice()" >&5
16358echo $ECHO_N "checking for broken nice()... $ECHO_C" >&6
16359if test "${ac_cv_broken_nice+set}" = set; then
16360 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000016361else
Martin v. Löwis11437992002-04-12 09:54:03 +000016362
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016363if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000016364 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016365else
Martin v. Löwis11437992002-04-12 09:54:03 +000016366 cat >conftest.$ac_ext <<_ACEOF
16367#line $LINENO "configure"
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016368#include "confdefs.h"
16369
16370int main()
16371{
16372 int val1 = nice(1);
16373 if (val1 != -1 && val1 == nice(2))
16374 exit(0);
16375 exit(1);
16376}
16377
Martin v. Löwis11437992002-04-12 09:54:03 +000016378_ACEOF
16379rm -f conftest$ac_exeext
16380if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16381 (eval $ac_link) 2>&5
16382 ac_status=$?
16383 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16384 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16385 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16386 (eval $ac_try) 2>&5
16387 ac_status=$?
16388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16389 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016390 ac_cv_broken_nice=yes
16391else
Martin v. Löwis11437992002-04-12 09:54:03 +000016392 echo "$as_me: program exited with status $ac_status" >&5
16393echo "$as_me: failed program was:" >&5
16394cat conftest.$ac_ext >&5
16395( exit $ac_status )
16396ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016397fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016398rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16399fi
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016400fi
16401
Martin v. Löwis11437992002-04-12 09:54:03 +000016402echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
16403echo "${ECHO_T}$ac_cv_broken_nice" >&6
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016404if test "$ac_cv_broken_nice" = yes
16405then
Martin v. Löwis11437992002-04-12 09:54:03 +000016406
16407cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016408#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016409_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016410
16411fi
16412
Martin v. Löwis94717ed2002-09-09 14:24:16 +000016413# Look for subsecond timestamps in struct stat
16414echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
16415echo $ECHO_N "checking for tv_nsec in struct stat... $ECHO_C" >&6
16416if test "${ac_cv_stat_tv_nsec+set}" = set; then
16417 echo $ECHO_N "(cached) $ECHO_C" >&6
16418else
16419 cat >conftest.$ac_ext <<_ACEOF
16420#line $LINENO "configure"
16421#include "confdefs.h"
16422#include <sys/stat.h>
16423#ifdef F77_DUMMY_MAIN
16424# ifdef __cplusplus
16425 extern "C"
16426# endif
16427 int F77_DUMMY_MAIN() { return 1; }
16428#endif
16429int
16430main ()
16431{
16432
16433struct stat st;
16434st.st_mtim.tv_nsec = 1;
16435
16436 ;
16437 return 0;
16438}
16439_ACEOF
16440rm -f conftest.$ac_objext
16441if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16442 (eval $ac_compile) 2>&5
16443 ac_status=$?
16444 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16445 (exit $ac_status); } &&
16446 { ac_try='test -s conftest.$ac_objext'
16447 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16448 (eval $ac_try) 2>&5
16449 ac_status=$?
16450 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16451 (exit $ac_status); }; }; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000016452 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000016453else
16454 echo "$as_me: failed program was:" >&5
16455cat conftest.$ac_ext >&5
16456ac_cv_stat_tv_nsec=no
16457fi
16458rm -f conftest.$ac_objext conftest.$ac_ext
16459fi
16460
16461echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
16462echo "${ECHO_T}$ac_cv_stat_tv_nsec" >&6
16463if test "$ac_cv_stat_tv_nsec" = yes
16464then
16465
16466cat >>confdefs.h <<\_ACEOF
16467#define HAVE_STAT_TV_NSEC 1
16468_ACEOF
16469
16470fi
16471
Jack Jansen666b1e72001-10-31 12:11:48 +000016472# On HP/UX 11.0, mvwdelch is a block with a return statement
Martin v. Löwis11437992002-04-12 09:54:03 +000016473echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
16474echo $ECHO_N "checking whether mvwdelch is an expression... $ECHO_C" >&6
16475if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
16476 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016477else
Martin v. Löwis11437992002-04-12 09:54:03 +000016478 cat >conftest.$ac_ext <<_ACEOF
16479#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000016480#include "confdefs.h"
16481#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016482#ifdef F77_DUMMY_MAIN
16483# ifdef __cplusplus
16484 extern "C"
16485# endif
16486 int F77_DUMMY_MAIN() { return 1; }
16487#endif
16488int
16489main ()
16490{
Jack Jansen666b1e72001-10-31 12:11:48 +000016491
16492 int rtn;
16493 rtn = mvwdelch(0,0,0);
16494
Martin v. Löwis11437992002-04-12 09:54:03 +000016495 ;
16496 return 0;
16497}
16498_ACEOF
16499rm -f conftest.$ac_objext
16500if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16501 (eval $ac_compile) 2>&5
16502 ac_status=$?
16503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16504 (exit $ac_status); } &&
16505 { ac_try='test -s conftest.$ac_objext'
16506 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16507 (eval $ac_try) 2>&5
16508 ac_status=$?
16509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16510 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000016511 ac_cv_mvwdelch_is_expression=yes
16512else
Martin v. Löwis11437992002-04-12 09:54:03 +000016513 echo "$as_me: failed program was:" >&5
16514cat conftest.$ac_ext >&5
16515ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000016516fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016517rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000016518fi
16519
Martin v. Löwis11437992002-04-12 09:54:03 +000016520echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
16521echo "${ECHO_T}$ac_cv_mvwdelch_is_expression" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016522
16523if test "$ac_cv_mvwdelch_is_expression" = yes
16524then
Martin v. Löwis11437992002-04-12 09:54:03 +000016525
16526cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016527#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016528_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016529
16530fi
16531
Martin v. Löwis11437992002-04-12 09:54:03 +000016532echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
16533echo $ECHO_N "checking whether WINDOW has _flags... $ECHO_C" >&6
16534if test "${ac_cv_window_has_flags+set}" = set; then
16535 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016536else
Martin v. Löwis11437992002-04-12 09:54:03 +000016537 cat >conftest.$ac_ext <<_ACEOF
16538#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000016539#include "confdefs.h"
16540#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016541#ifdef F77_DUMMY_MAIN
16542# ifdef __cplusplus
16543 extern "C"
16544# endif
16545 int F77_DUMMY_MAIN() { return 1; }
16546#endif
16547int
16548main ()
16549{
Jack Jansen666b1e72001-10-31 12:11:48 +000016550
16551 WINDOW *w;
16552 w->_flags = 0;
16553
Martin v. Löwis11437992002-04-12 09:54:03 +000016554 ;
16555 return 0;
16556}
16557_ACEOF
16558rm -f conftest.$ac_objext
16559if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16560 (eval $ac_compile) 2>&5
16561 ac_status=$?
16562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16563 (exit $ac_status); } &&
16564 { ac_try='test -s conftest.$ac_objext'
16565 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16566 (eval $ac_try) 2>&5
16567 ac_status=$?
16568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16569 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000016570 ac_cv_window_has_flags=yes
16571else
Martin v. Löwis11437992002-04-12 09:54:03 +000016572 echo "$as_me: failed program was:" >&5
16573cat conftest.$ac_ext >&5
16574ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000016575fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016576rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000016577fi
16578
Martin v. Löwis11437992002-04-12 09:54:03 +000016579echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
16580echo "${ECHO_T}$ac_cv_window_has_flags" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000016581
Jack Jansen666b1e72001-10-31 12:11:48 +000016582
16583if test "$ac_cv_window_has_flags" = yes
16584then
Martin v. Löwis11437992002-04-12 09:54:03 +000016585
16586cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016587#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016588_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016589
16590fi
16591
Martin v. Löwis11437992002-04-12 09:54:03 +000016592echo "$as_me:$LINENO: checking for socklen_t" >&5
16593echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
16594if test "${ac_cv_type_socklen_t+set}" = set; then
16595 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000016596else
Martin v. Löwis11437992002-04-12 09:54:03 +000016597 cat >conftest.$ac_ext <<_ACEOF
16598#line $LINENO "configure"
Guido van Rossum95713eb2000-05-18 20:53:31 +000016599#include "confdefs.h"
Martin v. Löwis01c04012002-11-11 14:58:44 +000016600
16601#ifdef HAVE_SYS_TYPES_H
16602#include <sys/types.h>
16603#endif
16604#ifdef HAVE_SYS_SOCKET_H
16605#include <sys/socket.h>
16606#endif
16607
16608
Martin v. Löwis11437992002-04-12 09:54:03 +000016609#ifdef F77_DUMMY_MAIN
16610# ifdef __cplusplus
16611 extern "C"
16612# endif
16613 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016614#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016615int
16616main ()
16617{
16618if ((socklen_t *) 0)
16619 return 0;
16620if (sizeof (socklen_t))
16621 return 0;
16622 ;
16623 return 0;
16624}
16625_ACEOF
16626rm -f conftest.$ac_objext
16627if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16628 (eval $ac_compile) 2>&5
16629 ac_status=$?
16630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16631 (exit $ac_status); } &&
16632 { ac_try='test -s conftest.$ac_objext'
16633 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16634 (eval $ac_try) 2>&5
16635 ac_status=$?
16636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16637 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000016638 ac_cv_type_socklen_t=yes
Guido van Rossum95713eb2000-05-18 20:53:31 +000016639else
Martin v. Löwis11437992002-04-12 09:54:03 +000016640 echo "$as_me: failed program was:" >&5
16641cat conftest.$ac_ext >&5
16642ac_cv_type_socklen_t=no
Guido van Rossum95713eb2000-05-18 20:53:31 +000016643fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016644rm -f conftest.$ac_objext conftest.$ac_ext
16645fi
16646echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
16647echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
16648if test $ac_cv_type_socklen_t = yes; then
16649 :
16650else
Guido van Rossum95713eb2000-05-18 20:53:31 +000016651
Martin v. Löwis01c04012002-11-11 14:58:44 +000016652cat >>confdefs.h <<\_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016653#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000016654_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016655
16656fi
16657
Michael W. Hudson54241132001-12-07 15:38:26 +000016658
Michael W. Hudson54241132001-12-07 15:38:26 +000016659
16660
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000016661for h in `(cd $srcdir;echo Python/thread_*.h)`
16662do
16663 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
16664done
16665
Michael W. Hudson54241132001-12-07 15:38:26 +000016666
Jack Jansen0b06be72002-06-21 14:48:38 +000016667SRCDIRS="Parser Grammar Objects Python Modules Mac Mac/Python"
Martin v. Löwis11437992002-04-12 09:54:03 +000016668echo "$as_me:$LINENO: checking for build directories" >&5
16669echo $ECHO_N "checking for build directories... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016670for dir in $SRCDIRS; do
16671 if test ! -d $dir; then
16672 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000016673 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016674done
Martin v. Löwis11437992002-04-12 09:54:03 +000016675echo "$as_me:$LINENO: result: done" >&5
16676echo "${ECHO_T}done" >&6
Fred Drake036144d2000-10-26 17:09:35 +000016677
Guido van Rossum627b2d71993-12-24 10:39:16 +000016678# generate output files
Martin v. Löwis11437992002-04-12 09:54:03 +000016679ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config"
Martin v. Löwis88afe662002-10-26 13:47:44 +000016680
Martin v. Löwis11437992002-04-12 09:54:03 +000016681cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016682# This file is a shell script that caches the results of configure
16683# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000016684# scripts and configure runs, see configure's option --config-cache.
16685# It is not useful on other systems. If it contains results you don't
16686# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016687#
Martin v. Löwis11437992002-04-12 09:54:03 +000016688# config.status only pays attention to the cache file if you give it
16689# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016690#
Martin v. Löwis11437992002-04-12 09:54:03 +000016691# `ac_cv_env_foo' variables (set or unset) will be overriden when
16692# loading this file, other *unset* `ac_cv_foo' will be assigned the
16693# following values.
16694
16695_ACEOF
16696
Guido van Rossumf78abae1997-01-21 22:02:36 +000016697# The following way of writing the cache mishandles newlines in values,
16698# but we know of no workaround that is simple, portable, and efficient.
16699# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016700# Ultrix sh set writes to stderr and can't be redirected directly,
16701# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwis11437992002-04-12 09:54:03 +000016702{
16703 (set) 2>&1 |
16704 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16705 *ac_space=\ *)
16706 # `set' does not quote correctly, so add quotes (double-quote
16707 # substitution turns \\\\ into \\, and sed turns \\ into \).
16708 sed -n \
16709 "s/'/'\\\\''/g;
16710 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16711 ;;
16712 *)
16713 # `set' quotes correctly as required by POSIX, so do not add quotes.
16714 sed -n \
16715 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16716 ;;
16717 esac;
16718} |
16719 sed '
16720 t clear
16721 : clear
16722 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16723 t end
16724 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16725 : end' >>confcache
16726if cmp -s $cache_file confcache; then :; else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016727 if test -w $cache_file; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016728 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16729 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016730 else
16731 echo "not updating unwritable cache $cache_file"
16732 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016733fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016734rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000016735
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016736test "x$prefix" = xNONE && prefix=$ac_default_prefix
16737# Let make expand exec_prefix.
16738test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000016739
Martin v. Löwis11437992002-04-12 09:54:03 +000016740# VPATH may cause trouble with some makes, so we remove $(srcdir),
16741# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16742# trailing colons and then remove the whole line if VPATH becomes empty
16743# (actually we leave an empty line to preserve line numbers).
Guido van Rossum7f43da71994-08-01 12:15:30 +000016744if test "x$srcdir" = x.; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016745 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16746s/:*\$(srcdir):*/:/;
16747s/:*\${srcdir}:*/:/;
16748s/:*@srcdir@:*/:/;
16749s/^\([^=]*=[ ]*\):*/\1/;
16750s/:*$//;
16751s/^[^=]*=[ ]*$//;
16752}'
Guido van Rossum7f43da71994-08-01 12:15:30 +000016753fi
16754
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016755DEFS=-DHAVE_CONFIG_H
16756
Martin v. Löwis11437992002-04-12 09:54:03 +000016757
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016758: ${CONFIG_STATUS=./config.status}
Martin v. Löwis11437992002-04-12 09:54:03 +000016759ac_clean_files_save=$ac_clean_files
16760ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16761{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
16762echo "$as_me: creating $CONFIG_STATUS" >&6;}
16763cat >$CONFIG_STATUS <<_ACEOF
16764#! $SHELL
16765# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016766# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016767# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000016768# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016769
Martin v. Löwis11437992002-04-12 09:54:03 +000016770debug=false
16771SHELL=\${CONFIG_SHELL-$SHELL}
16772_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016773
Martin v. Löwis11437992002-04-12 09:54:03 +000016774cat >>$CONFIG_STATUS <<\_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016775
Martin v. Löwis11437992002-04-12 09:54:03 +000016776## --------------------- ##
16777## M4sh Initialization. ##
16778## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000016779
Martin v. Löwis11437992002-04-12 09:54:03 +000016780# Be Bourne compatible
16781if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16782 emulate sh
16783 NULLCMD=:
16784elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16785 set -o posix
Michael W. Hudson54241132001-12-07 15:38:26 +000016786fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016787
Martin v. Löwis11437992002-04-12 09:54:03 +000016788# NLS nuisances.
16789# Support unset when possible.
16790if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16791 as_unset=unset
16792else
16793 as_unset=false
16794fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016795
Martin v. Löwis11437992002-04-12 09:54:03 +000016796(set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
16797 { $as_unset LANG || test "${LANG+set}" != set; } ||
16798 { LANG=C; export LANG; }
16799(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
16800 { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
16801 { LC_ALL=C; export LC_ALL; }
16802(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
16803 { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
16804 { LC_TIME=C; export LC_TIME; }
16805(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
16806 { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
16807 { LC_CTYPE=C; export LC_CTYPE; }
16808(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
16809 { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
16810 { LANGUAGE=C; export LANGUAGE; }
16811(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
16812 { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
16813 { LC_COLLATE=C; export LC_COLLATE; }
16814(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
16815 { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
16816 { LC_NUMERIC=C; export LC_NUMERIC; }
16817(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
16818 { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
16819 { LC_MESSAGES=C; export LC_MESSAGES; }
16820
16821
16822# Name of the executable.
16823as_me=`(basename "$0") 2>/dev/null ||
16824$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16825 X"$0" : 'X\(//\)$' \| \
16826 X"$0" : 'X\(/\)$' \| \
16827 . : '\(.\)' 2>/dev/null ||
16828echo X/"$0" |
16829 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
16830 /^X\/\(\/\/\)$/{ s//\1/; q; }
16831 /^X\/\(\/\).*/{ s//\1/; q; }
16832 s/.*/./; q'`
16833
16834# PATH needs CR, and LINENO needs CR and PATH.
16835# Avoid depending upon Character Ranges.
16836as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16837as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16838as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16839as_cr_digits='0123456789'
16840as_cr_alnum=$as_cr_Letters$as_cr_digits
16841
16842# The user is always right.
16843if test "${PATH_SEPARATOR+set}" != set; then
16844 echo "#! /bin/sh" >conftest.sh
16845 echo "exit 0" >>conftest.sh
16846 chmod +x conftest.sh
16847 if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
16848 PATH_SEPARATOR=';'
16849 else
16850 PATH_SEPARATOR=:
16851 fi
16852 rm -f conftest.sh
16853fi
16854
16855
16856 as_lineno_1=$LINENO
16857 as_lineno_2=$LINENO
16858 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16859 test "x$as_lineno_1" != "x$as_lineno_2" &&
16860 test "x$as_lineno_3" = "x$as_lineno_2" || {
16861 # Find who we are. Look in the path if we contain no path at all
16862 # relative or not.
16863 case $0 in
16864 *[\\/]* ) as_myself=$0 ;;
16865 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16866for as_dir in $PATH
16867do
16868 IFS=$as_save_IFS
16869 test -z "$as_dir" && as_dir=.
16870 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16871done
16872
16873 ;;
16874 esac
16875 # We did not find ourselves, most probably we were run as `sh COMMAND'
16876 # in which case we are not to be found in the path.
16877 if test "x$as_myself" = x; then
16878 as_myself=$0
16879 fi
16880 if test ! -f "$as_myself"; then
16881 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
16882echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
16883 { (exit 1); exit 1; }; }
16884 fi
16885 case $CONFIG_SHELL in
16886 '')
16887 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16888for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
16889do
16890 IFS=$as_save_IFS
16891 test -z "$as_dir" && as_dir=.
16892 for as_base in sh bash ksh sh5; do
16893 case $as_dir in
16894 /*)
16895 if ("$as_dir/$as_base" -c '
16896 as_lineno_1=$LINENO
16897 as_lineno_2=$LINENO
16898 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16899 test "x$as_lineno_1" != "x$as_lineno_2" &&
16900 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
16901 CONFIG_SHELL=$as_dir/$as_base
16902 export CONFIG_SHELL
16903 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
16904 fi;;
16905 esac
16906 done
16907done
16908;;
Jack Jansendd19cf82001-12-06 22:36:17 +000016909 esac
16910
Martin v. Löwis11437992002-04-12 09:54:03 +000016911 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
16912 # uniformly replaced by the line number. The first 'sed' inserts a
16913 # line-number line before each line; the second 'sed' does the real
16914 # work. The second script uses 'N' to pair each line-number line
16915 # with the numbered line, and appends trailing '-' during
16916 # substitution so that $LINENO is not a special case at line end.
16917 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
16918 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
16919 sed '=' <$as_myself |
16920 sed '
16921 N
16922 s,$,-,
16923 : loop
16924 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
16925 t loop
16926 s,-$,,
16927 s,^['$as_cr_digits']*\n,,
16928 ' >$as_me.lineno &&
16929 chmod +x $as_me.lineno ||
16930 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
16931echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
16932 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016933
Martin v. Löwis11437992002-04-12 09:54:03 +000016934 # Don't try to exec as it changes $[0], causing all sort of problems
16935 # (the dirname of $[0] is not the place where we might find the
16936 # original and so on. Autoconf is especially sensible to this).
16937 . ./$as_me.lineno
16938 # Exit status is that of the last command.
16939 exit
16940}
16941
16942
16943case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
16944 *c*,-n*) ECHO_N= ECHO_C='
16945' ECHO_T=' ' ;;
16946 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
16947 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
16948esac
16949
16950if expr a : '\(a\)' >/dev/null 2>&1; then
16951 as_expr=expr
16952else
16953 as_expr=false
16954fi
16955
16956rm -f conf$$ conf$$.exe conf$$.file
16957echo >conf$$.file
16958if ln -s conf$$.file conf$$ 2>/dev/null; then
16959 # We could just check for DJGPP; but this test a) works b) is more generic
16960 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16961 if test -f conf$$.exe; then
16962 # Don't use ln at all; we don't have any links
16963 as_ln_s='cp -p'
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016964 else
Martin v. Löwis11437992002-04-12 09:54:03 +000016965 as_ln_s='ln -s'
16966 fi
16967elif ln conf$$.file conf$$ 2>/dev/null; then
16968 as_ln_s=ln
16969else
16970 as_ln_s='cp -p'
16971fi
16972rm -f conf$$ conf$$.exe conf$$.file
16973
16974as_executable_p="test -f"
16975
16976# Sed expression to map a string onto a valid CPP name.
16977as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
16978
16979# Sed expression to map a string onto a valid variable name.
16980as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
16981
16982
16983# IFS
16984# We need space, tab and new line, in precisely that order.
16985as_nl='
16986'
16987IFS=" $as_nl"
16988
16989# CDPATH.
16990$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
16991
16992exec 6>&1
16993
16994# Open the log real soon, to keep \$[0] and so on meaningful, and to
16995# report actual input values of CONFIG_FILES etc. instead of their
16996# values after options handling. Logging --version etc. is OK.
16997exec 5>>config.log
16998{
16999 echo
17000 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
17001## Running $as_me. ##
17002_ASBOX
17003} >&5
17004cat >&5 <<_CSEOF
17005
Martin v. Löwis88afe662002-10-26 13:47:44 +000017006This file was extended by python $as_me 2.3, which was
Martin v. Löwis11437992002-04-12 09:54:03 +000017007generated by GNU Autoconf 2.53. Invocation command line was
17008
17009 CONFIG_FILES = $CONFIG_FILES
17010 CONFIG_HEADERS = $CONFIG_HEADERS
17011 CONFIG_LINKS = $CONFIG_LINKS
17012 CONFIG_COMMANDS = $CONFIG_COMMANDS
17013 $ $0 $@
17014
17015_CSEOF
17016echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
17017echo >&5
17018_ACEOF
17019
17020# Files that config.status was made for.
17021if test -n "$ac_config_files"; then
17022 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
17023fi
17024
17025if test -n "$ac_config_headers"; then
17026 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
17027fi
17028
17029if test -n "$ac_config_links"; then
17030 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
17031fi
17032
17033if test -n "$ac_config_commands"; then
17034 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
17035fi
17036
17037cat >>$CONFIG_STATUS <<\_ACEOF
17038
17039ac_cs_usage="\
17040\`$as_me' instantiates files from templates according to the
17041current configuration.
17042
17043Usage: $0 [OPTIONS] [FILE]...
17044
17045 -h, --help print this help, then exit
17046 -V, --version print version number, then exit
17047 -d, --debug don't remove temporary files
17048 --recheck update $as_me by reconfiguring in the same conditions
17049 --file=FILE[:TEMPLATE]
17050 instantiate the configuration file FILE
17051 --header=FILE[:TEMPLATE]
17052 instantiate the configuration header FILE
17053
17054Configuration files:
17055$config_files
17056
17057Configuration headers:
17058$config_headers
17059
17060Report bugs to <bug-autoconf@gnu.org>."
17061_ACEOF
17062
17063cat >>$CONFIG_STATUS <<_ACEOF
17064ac_cs_version="\\
Martin v. Löwis88afe662002-10-26 13:47:44 +000017065python config.status 2.3
Martin v. Löwis11437992002-04-12 09:54:03 +000017066configured by $0, generated by GNU Autoconf 2.53,
17067 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
17068
17069Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
17070Free Software Foundation, Inc.
17071This config.status script is free software; the Free Software Foundation
17072gives unlimited permission to copy, distribute and modify it."
17073srcdir=$srcdir
17074INSTALL="$INSTALL"
17075_ACEOF
17076
17077cat >>$CONFIG_STATUS <<\_ACEOF
17078# If no file are specified by the user, then we need to provide default
17079# value. By we need to know if files were specified by the user.
17080ac_need_defaults=:
17081while test $# != 0
17082do
17083 case $1 in
17084 --*=*)
17085 ac_option=`expr "x$1" : 'x\([^=]*\)='`
17086 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
17087 shift
17088 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
17089 shift
17090 ;;
17091 -*);;
17092 *) # This is not an option, so the user has probably given explicit
17093 # arguments.
17094 ac_need_defaults=false;;
17095 esac
17096
17097 case $1 in
17098 # Handling of the options.
17099_ACEOF
17100cat >>$CONFIG_STATUS <<_ACEOF
17101 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
17102 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
17103 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
17104_ACEOF
17105cat >>$CONFIG_STATUS <<\_ACEOF
17106 --version | --vers* | -V )
17107 echo "$ac_cs_version"; exit 0 ;;
17108 --he | --h)
17109 # Conflict between --help and --header
17110 { { echo "$as_me:$LINENO: error: ambiguous option: $1
17111Try \`$0 --help' for more information." >&5
17112echo "$as_me: error: ambiguous option: $1
17113Try \`$0 --help' for more information." >&2;}
17114 { (exit 1); exit 1; }; };;
17115 --help | --hel | -h )
17116 echo "$ac_cs_usage"; exit 0 ;;
17117 --debug | --d* | -d )
17118 debug=: ;;
17119 --file | --fil | --fi | --f )
17120 shift
17121 CONFIG_FILES="$CONFIG_FILES $1"
17122 ac_need_defaults=false;;
17123 --header | --heade | --head | --hea )
17124 shift
17125 CONFIG_HEADERS="$CONFIG_HEADERS $1"
17126 ac_need_defaults=false;;
17127
17128 # This is an error.
17129 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
17130Try \`$0 --help' for more information." >&5
17131echo "$as_me: error: unrecognized option: $1
17132Try \`$0 --help' for more information." >&2;}
17133 { (exit 1); exit 1; }; } ;;
17134
17135 *) ac_config_targets="$ac_config_targets $1" ;;
17136
17137 esac
17138 shift
17139done
17140
17141_ACEOF
17142
17143
17144
17145
17146
17147cat >>$CONFIG_STATUS <<\_ACEOF
17148for ac_config_target in $ac_config_targets
17149do
17150 case "$ac_config_target" in
17151 # Handling of arguments.
17152 "Makefile.pre" ) CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
17153 "Modules/Setup.config" ) CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
17154 "pyconfig.h" ) CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
17155 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
17156echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
17157 { (exit 1); exit 1; }; };;
17158 esac
17159done
17160
17161# If the user did not use the arguments to specify the items to instantiate,
17162# then the envvar interface is used. Set only those that are not.
17163# We use the long form for the default assignment because of an extremely
17164# bizarre bug on SunOS 4.1.3.
17165if $ac_need_defaults; then
17166 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
17167 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
17168fi
17169
17170# Create a temporary directory, and hook for its removal unless debugging.
17171$debug ||
17172{
17173 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
17174 trap '{ (exit 1); exit 1; }' 1 2 13 15
17175}
17176
17177# Create a (secure) tmp directory for tmp files.
17178: ${TMPDIR=/tmp}
17179{
17180 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
17181 test -n "$tmp" && test -d "$tmp"
17182} ||
17183{
17184 tmp=$TMPDIR/cs$$-$RANDOM
17185 (umask 077 && mkdir $tmp)
17186} ||
17187{
17188 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
17189 { (exit 1); exit 1; }
17190}
17191
17192_ACEOF
17193
17194cat >>$CONFIG_STATUS <<_ACEOF
17195
17196#
17197# CONFIG_FILES section.
17198#
17199
17200# No need to generate the scripts if there are no CONFIG_FILES.
17201# This happens for instance when ./config.status config.h
17202if test -n "\$CONFIG_FILES"; then
17203 # Protect against being on the right side of a sed subst in config.status.
17204 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
17205 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
17206s,@SHELL@,$SHELL,;t t
17207s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
17208s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
17209s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
17210s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
17211s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
17212s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
17213s,@exec_prefix@,$exec_prefix,;t t
17214s,@prefix@,$prefix,;t t
17215s,@program_transform_name@,$program_transform_name,;t t
17216s,@bindir@,$bindir,;t t
17217s,@sbindir@,$sbindir,;t t
17218s,@libexecdir@,$libexecdir,;t t
17219s,@datadir@,$datadir,;t t
17220s,@sysconfdir@,$sysconfdir,;t t
17221s,@sharedstatedir@,$sharedstatedir,;t t
17222s,@localstatedir@,$localstatedir,;t t
17223s,@libdir@,$libdir,;t t
17224s,@includedir@,$includedir,;t t
17225s,@oldincludedir@,$oldincludedir,;t t
17226s,@infodir@,$infodir,;t t
17227s,@mandir@,$mandir,;t t
17228s,@build_alias@,$build_alias,;t t
17229s,@host_alias@,$host_alias,;t t
17230s,@target_alias@,$target_alias,;t t
17231s,@DEFS@,$DEFS,;t t
17232s,@ECHO_C@,$ECHO_C,;t t
17233s,@ECHO_N@,$ECHO_N,;t t
17234s,@ECHO_T@,$ECHO_T,;t t
17235s,@LIBS@,$LIBS,;t t
17236s,@VERSION@,$VERSION,;t t
17237s,@SOVERSION@,$SOVERSION,;t t
17238s,@CONFIG_ARGS@,$CONFIG_ARGS,;t t
17239s,@PYTHONFRAMEWORK@,$PYTHONFRAMEWORK,;t t
17240s,@PYTHONFRAMEWORKDIR@,$PYTHONFRAMEWORKDIR,;t t
17241s,@PYTHONFRAMEWORKPREFIX@,$PYTHONFRAMEWORKPREFIX,;t t
17242s,@PYTHONFRAMEWORKINSTALLDIR@,$PYTHONFRAMEWORKINSTALLDIR,;t t
17243s,@MACHDEP@,$MACHDEP,;t t
17244s,@SGI_ABI@,$SGI_ABI,;t t
17245s,@CXX@,$CXX,;t t
17246s,@MAINOBJ@,$MAINOBJ,;t t
17247s,@EXEEXT@,$EXEEXT,;t t
17248s,@CC@,$CC,;t t
17249s,@CFLAGS@,$CFLAGS,;t t
17250s,@LDFLAGS@,$LDFLAGS,;t t
17251s,@CPPFLAGS@,$CPPFLAGS,;t t
17252s,@ac_ct_CC@,$ac_ct_CC,;t t
17253s,@OBJEXT@,$OBJEXT,;t t
17254s,@CPP@,$CPP,;t t
17255s,@BUILDEXEEXT@,$BUILDEXEEXT,;t t
17256s,@LIBRARY@,$LIBRARY,;t t
17257s,@LDLIBRARY@,$LDLIBRARY,;t t
17258s,@DLLLIBRARY@,$DLLLIBRARY,;t t
17259s,@BLDLIBRARY@,$BLDLIBRARY,;t t
17260s,@LDLIBRARYDIR@,$LDLIBRARYDIR,;t t
17261s,@INSTSONAME@,$INSTSONAME,;t t
17262s,@RUNSHARED@,$RUNSHARED,;t t
17263s,@LINKCC@,$LINKCC,;t t
17264s,@RANLIB@,$RANLIB,;t t
17265s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
17266s,@AR@,$AR,;t t
17267s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
17268s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
17269s,@INSTALL_DATA@,$INSTALL_DATA,;t t
17270s,@LN@,$LN,;t t
17271s,@OPT@,$OPT,;t t
17272s,@LIBTOOL_CRUFT@,$LIBTOOL_CRUFT,;t t
17273s,@SO@,$SO,;t t
17274s,@LDSHARED@,$LDSHARED,;t t
17275s,@BLDSHARED@,$BLDSHARED,;t t
17276s,@CCSHARED@,$CCSHARED,;t t
17277s,@LINKFORSHARED@,$LINKFORSHARED,;t t
17278s,@CFLAGSFORSHARED@,$CFLAGSFORSHARED,;t t
Martin v. Löwisf90ae202002-06-11 06:22:31 +000017279s,@SHLIBS@,$SHLIBS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000017280s,@USE_SIGNAL_MODULE@,$USE_SIGNAL_MODULE,;t t
17281s,@SIGNAL_OBJS@,$SIGNAL_OBJS,;t t
17282s,@USE_THREAD_MODULE@,$USE_THREAD_MODULE,;t t
17283s,@LDLAST@,$LDLAST,;t t
17284s,@THREADOBJ@,$THREADOBJ,;t t
17285s,@DLINCLDIR@,$DLINCLDIR,;t t
17286s,@DYNLOADFILE@,$DYNLOADFILE,;t t
17287s,@MACHDEP_OBJS@,$MACHDEP_OBJS,;t t
17288s,@LIBOBJS@,$LIBOBJS,;t t
17289s,@HAVE_GETHOSTBYNAME_R_6_ARG@,$HAVE_GETHOSTBYNAME_R_6_ARG,;t t
17290s,@HAVE_GETHOSTBYNAME_R_5_ARG@,$HAVE_GETHOSTBYNAME_R_5_ARG,;t t
17291s,@HAVE_GETHOSTBYNAME_R_3_ARG@,$HAVE_GETHOSTBYNAME_R_3_ARG,;t t
17292s,@HAVE_GETHOSTBYNAME_R@,$HAVE_GETHOSTBYNAME_R,;t t
17293s,@HAVE_GETHOSTBYNAME@,$HAVE_GETHOSTBYNAME,;t t
17294s,@LIBM@,$LIBM,;t t
17295s,@LIBC@,$LIBC,;t t
17296s,@UNICODE_OBJS@,$UNICODE_OBJS,;t t
17297s,@THREADHEADERS@,$THREADHEADERS,;t t
17298s,@SRCDIRS@,$SRCDIRS,;t t
17299CEOF
17300
17301_ACEOF
17302
17303 cat >>$CONFIG_STATUS <<\_ACEOF
17304 # Split the substitutions into bite-sized pieces for seds with
17305 # small command number limits, like on Digital OSF/1 and HP-UX.
17306 ac_max_sed_lines=48
17307 ac_sed_frag=1 # Number of current file.
17308 ac_beg=1 # First line for current file.
17309 ac_end=$ac_max_sed_lines # Line after last line for current file.
17310 ac_more_lines=:
17311 ac_sed_cmds=
17312 while $ac_more_lines; do
17313 if test $ac_beg -gt 1; then
17314 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17315 else
17316 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17317 fi
17318 if test ! -s $tmp/subs.frag; then
17319 ac_more_lines=false
17320 else
17321 # The purpose of the label and of the branching condition is to
17322 # speed up the sed processing (if there are no `@' at all, there
17323 # is no need to browse any of the substitutions).
17324 # These are the two extra sed commands mentioned above.
17325 (echo ':t
17326 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
17327 if test -z "$ac_sed_cmds"; then
17328 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
17329 else
17330 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
17331 fi
17332 ac_sed_frag=`expr $ac_sed_frag + 1`
17333 ac_beg=$ac_end
17334 ac_end=`expr $ac_end + $ac_max_sed_lines`
17335 fi
17336 done
17337 if test -z "$ac_sed_cmds"; then
17338 ac_sed_cmds=cat
17339 fi
17340fi # test -n "$CONFIG_FILES"
17341
17342_ACEOF
17343cat >>$CONFIG_STATUS <<\_ACEOF
17344for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
17345 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17346 case $ac_file in
17347 - | *:- | *:-:* ) # input from stdin
17348 cat >$tmp/stdin
17349 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17350 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17351 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17352 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17353 * ) ac_file_in=$ac_file.in ;;
17354 esac
17355
17356 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
17357 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17358$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17359 X"$ac_file" : 'X\(//\)[^/]' \| \
17360 X"$ac_file" : 'X\(//\)$' \| \
17361 X"$ac_file" : 'X\(/\)' \| \
17362 . : '\(.\)' 2>/dev/null ||
17363echo X"$ac_file" |
17364 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17365 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17366 /^X\(\/\/\)$/{ s//\1/; q; }
17367 /^X\(\/\).*/{ s//\1/; q; }
17368 s/.*/./; q'`
17369 { case "$ac_dir" in
17370 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17371 *) as_incr_dir=.;;
17372esac
17373as_dummy="$ac_dir"
17374for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17375 case $as_mkdir_dir in
17376 # Skip DOS drivespec
17377 ?:) as_incr_dir=$as_mkdir_dir ;;
17378 *)
17379 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17380 test -d "$as_incr_dir" ||
17381 mkdir "$as_incr_dir" ||
17382 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17383echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17384 { (exit 1); exit 1; }; }
17385 ;;
17386 esac
17387done; }
17388
17389 ac_builddir=.
17390
17391if test "$ac_dir" != .; then
17392 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
17393 # A "../" for each directory in $ac_dir_suffix.
17394 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
17395else
17396 ac_dir_suffix= ac_top_builddir=
17397fi
17398
17399case $srcdir in
17400 .) # No --srcdir option. We are building in place.
17401 ac_srcdir=.
17402 if test -z "$ac_top_builddir"; then
17403 ac_top_srcdir=.
17404 else
17405 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
17406 fi ;;
17407 [\\/]* | ?:[\\/]* ) # Absolute path.
17408 ac_srcdir=$srcdir$ac_dir_suffix;
17409 ac_top_srcdir=$srcdir ;;
17410 *) # Relative path.
17411 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
17412 ac_top_srcdir=$ac_top_builddir$srcdir ;;
17413esac
17414# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
17415# absolute.
17416ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwise3271202002-11-07 07:42:30 +000017417ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +000017418ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
17419ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
17420
17421
17422 case $INSTALL in
17423 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17424 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
17425 esac
17426
17427 if test x"$ac_file" != x-; then
17428 { echo "$as_me:$LINENO: creating $ac_file" >&5
17429echo "$as_me: creating $ac_file" >&6;}
17430 rm -f "$ac_file"
17431 fi
17432 # Let's still pretend it is `configure' which instantiates (i.e., don't
17433 # use $as_me), people would be surprised to read:
17434 # /* config.h. Generated by config.status. */
17435 if test x"$ac_file" = x-; then
17436 configure_input=
17437 else
17438 configure_input="$ac_file. "
17439 fi
17440 configure_input=$configure_input"Generated from `echo $ac_file_in |
17441 sed 's,.*/,,'` by configure."
17442
17443 # First look for the input files in the build tree, otherwise in the
17444 # src tree.
17445 ac_file_inputs=`IFS=:
17446 for f in $ac_file_in; do
17447 case $f in
17448 -) echo $tmp/stdin ;;
17449 [\\/$]*)
17450 # Absolute (can't be DOS-style, as IFS=:)
17451 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17452echo "$as_me: error: cannot find input file: $f" >&2;}
17453 { (exit 1); exit 1; }; }
17454 echo $f;;
17455 *) # Relative
17456 if test -f "$f"; then
17457 # Build tree
17458 echo $f
17459 elif test -f "$srcdir/$f"; then
17460 # Source tree
17461 echo $srcdir/$f
17462 else
17463 # /dev/null tree
17464 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17465echo "$as_me: error: cannot find input file: $f" >&2;}
17466 { (exit 1); exit 1; }; }
17467 fi;;
17468 esac
17469 done` || { (exit 1); exit 1; }
17470_ACEOF
17471cat >>$CONFIG_STATUS <<_ACEOF
17472 sed "$ac_vpsub
17473$extrasub
17474_ACEOF
17475cat >>$CONFIG_STATUS <<\_ACEOF
17476:t
17477/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17478s,@configure_input@,$configure_input,;t t
17479s,@srcdir@,$ac_srcdir,;t t
17480s,@abs_srcdir@,$ac_abs_srcdir,;t t
17481s,@top_srcdir@,$ac_top_srcdir,;t t
17482s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
17483s,@builddir@,$ac_builddir,;t t
17484s,@abs_builddir@,$ac_abs_builddir,;t t
17485s,@top_builddir@,$ac_top_builddir,;t t
17486s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
17487s,@INSTALL@,$ac_INSTALL,;t t
17488" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
17489 rm -f $tmp/stdin
17490 if test x"$ac_file" != x-; then
17491 mv $tmp/out $ac_file
17492 else
17493 cat $tmp/out
17494 rm -f $tmp/out
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017495 fi
17496
Martin v. Löwis11437992002-04-12 09:54:03 +000017497done
17498_ACEOF
17499cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017500
Martin v. Löwis11437992002-04-12 09:54:03 +000017501#
17502# CONFIG_HEADER section.
17503#
Guido van Rossum627b2d71993-12-24 10:39:16 +000017504
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017505# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
17506# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +000017507#
17508# ac_d sets the value in "#define NAME VALUE" lines.
Martin v. Löwis11437992002-04-12 09:54:03 +000017509ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
17510ac_dB='[ ].*$,\1#\2'
17511ac_dC=' '
17512ac_dD=',;t'
17513# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
17514ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17515ac_uB='$,\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +000017516ac_uC=' '
Martin v. Löwis11437992002-04-12 09:54:03 +000017517ac_uD=',;t'
Guido van Rossum7f43da71994-08-01 12:15:30 +000017518
Martin v. Löwis11437992002-04-12 09:54:03 +000017519for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
Guido van Rossumf78abae1997-01-21 22:02:36 +000017520 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Martin v. Löwis11437992002-04-12 09:54:03 +000017521 case $ac_file in
17522 - | *:- | *:-:* ) # input from stdin
17523 cat >$tmp/stdin
17524 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17525 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17526 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17527 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17528 * ) ac_file_in=$ac_file.in ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017529 esac
17530
Martin v. Löwis11437992002-04-12 09:54:03 +000017531 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
17532echo "$as_me: creating $ac_file" >&6;}
Guido van Rossum7f43da71994-08-01 12:15:30 +000017533
Martin v. Löwis11437992002-04-12 09:54:03 +000017534 # First look for the input files in the build tree, otherwise in the
17535 # src tree.
17536 ac_file_inputs=`IFS=:
17537 for f in $ac_file_in; do
17538 case $f in
17539 -) echo $tmp/stdin ;;
17540 [\\/$]*)
17541 # Absolute (can't be DOS-style, as IFS=:)
17542 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17543echo "$as_me: error: cannot find input file: $f" >&2;}
17544 { (exit 1); exit 1; }; }
17545 echo $f;;
17546 *) # Relative
17547 if test -f "$f"; then
17548 # Build tree
17549 echo $f
17550 elif test -f "$srcdir/$f"; then
17551 # Source tree
17552 echo $srcdir/$f
17553 else
17554 # /dev/null tree
17555 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17556echo "$as_me: error: cannot find input file: $f" >&2;}
17557 { (exit 1); exit 1; }; }
17558 fi;;
17559 esac
17560 done` || { (exit 1); exit 1; }
17561 # Remove the trailing spaces.
17562 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017563
Martin v. Löwis11437992002-04-12 09:54:03 +000017564_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017565
Martin v. Löwis11437992002-04-12 09:54:03 +000017566# Transform confdefs.h into two sed scripts, `conftest.defines' and
17567# `conftest.undefs', that substitutes the proper values into
17568# config.h.in to produce config.h. The first handles `#define'
17569# templates, and the second `#undef' templates.
17570# And first: Protect against being on the right side of a sed subst in
17571# config.status. Protect against being in an unquoted here document
17572# in config.status.
17573rm -f conftest.defines conftest.undefs
17574# Using a here document instead of a string reduces the quoting nightmare.
17575# Putting comments in sed scripts is not portable.
17576#
17577# `end' is used to avoid that the second main sed command (meant for
17578# 0-ary CPP macros) applies to n-ary macro definitions.
17579# See the Autoconf documentation for `clear'.
17580cat >confdef2sed.sed <<\_ACEOF
17581s/[\\&,]/\\&/g
17582s,[\\$`],\\&,g
17583t clear
17584: clear
17585s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
17586t end
17587s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
17588: end
17589_ACEOF
17590# If some macros were called several times there might be several times
17591# the same #defines, which is useless. Nevertheless, we may not want to
17592# sort them, since we want the *last* AC-DEFINE to be honored.
17593uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
17594sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
17595rm -f confdef2sed.sed
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017596
17597# This sed command replaces #undef with comments. This is necessary, for
17598# example, in the case of _POSIX_SOURCE, which is predefined and required
17599# on some systems where configure will not decide to define it.
Martin v. Löwis11437992002-04-12 09:54:03 +000017600cat >>conftest.undefs <<\_ACEOF
17601s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
17602_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017603
Martin v. Löwis11437992002-04-12 09:54:03 +000017604# Break up conftest.defines because some shells have a limit on the size
17605# of here documents, and old seds have small limits too (100 cmds).
17606echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
17607echo ' if egrep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
17608echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
17609echo ' :' >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017610rm -f conftest.tail
Martin v. Löwis11437992002-04-12 09:54:03 +000017611while grep . conftest.defines >/dev/null
Jack Jansendd19cf82001-12-06 22:36:17 +000017612do
Martin v. Löwis11437992002-04-12 09:54:03 +000017613 # Write a limited-size here document to $tmp/defines.sed.
17614 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
17615 # Speed up: don't consider the non `#define' lines.
17616 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
17617 # Work around the forget-to-reset-the-flag bug.
17618 echo 't clr' >>$CONFIG_STATUS
17619 echo ': clr' >>$CONFIG_STATUS
17620 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017621 echo 'CEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000017622 sed -f $tmp/defines.sed $tmp/in >$tmp/out
17623 rm -f $tmp/in
17624 mv $tmp/out $tmp/in
17625' >>$CONFIG_STATUS
17626 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
17627 rm -f conftest.defines
17628 mv conftest.tail conftest.defines
Jack Jansendd19cf82001-12-06 22:36:17 +000017629done
Martin v. Löwis11437992002-04-12 09:54:03 +000017630rm -f conftest.defines
17631echo ' fi # egrep' >>$CONFIG_STATUS
17632echo >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017633
Martin v. Löwis11437992002-04-12 09:54:03 +000017634# Break up conftest.undefs because some shells have a limit on the size
17635# of here documents, and old seds have small limits too (100 cmds).
17636echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
17637rm -f conftest.tail
17638while grep . conftest.undefs >/dev/null
17639do
17640 # Write a limited-size here document to $tmp/undefs.sed.
17641 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
17642 # Speed up: don't consider the non `#undef'
17643 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
17644 # Work around the forget-to-reset-the-flag bug.
17645 echo 't clr' >>$CONFIG_STATUS
17646 echo ': clr' >>$CONFIG_STATUS
17647 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
17648 echo 'CEOF
17649 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
17650 rm -f $tmp/in
17651 mv $tmp/out $tmp/in
17652' >>$CONFIG_STATUS
17653 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
17654 rm -f conftest.undefs
17655 mv conftest.tail conftest.undefs
17656done
17657rm -f conftest.undefs
17658
17659cat >>$CONFIG_STATUS <<\_ACEOF
17660 # Let's still pretend it is `configure' which instantiates (i.e., don't
17661 # use $as_me), people would be surprised to read:
17662 # /* config.h. Generated by config.status. */
17663 if test x"$ac_file" = x-; then
17664 echo "/* Generated by configure. */" >$tmp/config.h
Guido van Rossum7f43da71994-08-01 12:15:30 +000017665 else
Martin v. Löwis11437992002-04-12 09:54:03 +000017666 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
Jack Jansendd19cf82001-12-06 22:36:17 +000017667 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017668 cat $tmp/in >>$tmp/config.h
17669 rm -f $tmp/in
17670 if test x"$ac_file" != x-; then
17671 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17672 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
17673echo "$as_me: $ac_file is unchanged" >&6;}
17674 else
17675 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17676$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17677 X"$ac_file" : 'X\(//\)[^/]' \| \
17678 X"$ac_file" : 'X\(//\)$' \| \
17679 X"$ac_file" : 'X\(/\)' \| \
17680 . : '\(.\)' 2>/dev/null ||
17681echo X"$ac_file" |
17682 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17683 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17684 /^X\(\/\/\)$/{ s//\1/; q; }
17685 /^X\(\/\).*/{ s//\1/; q; }
17686 s/.*/./; q'`
17687 { case "$ac_dir" in
17688 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17689 *) as_incr_dir=.;;
17690esac
17691as_dummy="$ac_dir"
17692for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17693 case $as_mkdir_dir in
17694 # Skip DOS drivespec
17695 ?:) as_incr_dir=$as_mkdir_dir ;;
17696 *)
17697 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17698 test -d "$as_incr_dir" ||
17699 mkdir "$as_incr_dir" ||
17700 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17701echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17702 { (exit 1); exit 1; }; }
17703 ;;
17704 esac
17705done; }
Michael W. Hudson54241132001-12-07 15:38:26 +000017706
Martin v. Löwis11437992002-04-12 09:54:03 +000017707 rm -f $ac_file
17708 mv $tmp/config.h $ac_file
17709 fi
17710 else
17711 cat $tmp/config.h
17712 rm -f $tmp/config.h
17713 fi
17714done
17715_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000017716
Martin v. Löwis11437992002-04-12 09:54:03 +000017717cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000017718
Martin v. Löwis11437992002-04-12 09:54:03 +000017719{ (exit 0); exit 0; }
17720_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017721chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000017722ac_clean_files=$ac_clean_files_save
17723
17724
17725# configure is writing to config.log, and then calls config.status.
17726# config.status does its own redirection, appending to config.log.
17727# Unfortunately, on DOS this fails, as config.log is still kept open
17728# by configure, so config.status won't be able to write to it; its
17729# output is simply discarded. So we exec the FD to /dev/null,
17730# effectively closing config.log, so it can be properly (re)opened and
17731# appended to by config.status. When coming back to configure, we
17732# need to make the FD available again.
17733if test "$no_create" != yes; then
17734 ac_cs_success=:
17735 exec 5>/dev/null
17736 $SHELL $CONFIG_STATUS || ac_cs_success=false
17737 exec 5>>config.log
17738 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17739 # would make configure fail if this is the last instruction.
17740 $ac_cs_success || { (exit 1); exit 1; }
17741fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000017742
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000017743
17744echo "creating Setup"
17745if test ! -f Modules/Setup
17746then
17747 cp $srcdir/Modules/Setup.dist Modules/Setup
17748fi
17749
17750echo "creating Setup.local"
17751if test ! -f Modules/Setup.local
17752then
17753 echo "# Edit this file for local setup changes" >Modules/Setup.local
17754fi
17755
17756echo "creating Makefile"
17757$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
17758 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000017759 Modules/Setup.local Modules/Setup
Neil Schemenauerc761fc82001-02-19 04:50:49 +000017760mv config.c Modules