blob: 60f5f5f68be34a72974d7a6bcb9503a463f109d2 [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Martin v. Löwis9ef33762002-12-02 22:23:56 +00002# From configure.in Revision: 1.373 .
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"
9303 then LDSHARED="$(CC) -shared"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009304 else LDSHARED="$(CC) -G"
Martin v. Löwisbec19582001-03-21 15:57:54 +00009305 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +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
11656if test "$with_universal_newlines" != "no"
11657then
Martin v. Löwise8aea582002-04-16 05:51:02 +000011658
11659cat >>confdefs.h <<\_ACEOF
Jack Jansen7b8c7542002-04-14 20:12:41 +000011660#define WITH_UNIVERSAL_NEWLINES 1
11661_ACEOF
11662
11663fi
11664echo "$as_me:$LINENO: result: $with_universal_newlines" >&5
11665echo "${ECHO_T}$with_universal_newlines" >&6
11666
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000011667# Check for --with-doc-strings
11668echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
11669echo $ECHO_N "checking for --with-doc-strings... $ECHO_C" >&6
11670
11671# Check whether --with-doc-strings or --without-doc-strings was given.
11672if test "${with_doc_strings+set}" = set; then
11673 withval="$with_doc_strings"
11674
11675fi;
11676
11677if test -z "$with_doc_strings"
11678then with_doc_strings="yes"
11679fi
11680if test "$with_doc_strings" != "no"
11681then
11682
11683cat >>confdefs.h <<\_ACEOF
11684#define WITH_DOC_STRINGS 1
11685_ACEOF
11686
11687fi
11688echo "$as_me:$LINENO: result: $with_doc_strings" >&5
11689echo "${ECHO_T}$with_doc_strings" >&6
11690
Neil Schemenauera35c6882001-02-27 04:45:05 +000011691# Check for Python-specific malloc support
Martin v. Löwis11437992002-04-12 09:54:03 +000011692echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
11693echo $ECHO_N "checking for --with-pymalloc... $ECHO_C" >&6
11694
Neil Schemenauera35c6882001-02-27 04:45:05 +000011695# Check whether --with-pymalloc or --without-pymalloc was given.
11696if test "${with_pymalloc+set}" = set; then
11697 withval="$with_pymalloc"
Michael W. Hudson54241132001-12-07 15:38:26 +000011698
Martin v. Löwis11437992002-04-12 09:54:03 +000011699fi;
Neil Schemenauera35c6882001-02-27 04:45:05 +000011700
Neil Schemenauer16c22972002-03-22 15:34:49 +000011701if test -z "$with_pymalloc"
11702then with_pymalloc="yes"
11703fi
11704if test "$with_pymalloc" != "no"
11705then
Martin v. Löwis11437992002-04-12 09:54:03 +000011706
11707cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011708#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011709_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011710
11711fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011712echo "$as_me:$LINENO: result: $with_pymalloc" >&5
11713echo "${ECHO_T}$with_pymalloc" >&6
Neil Schemenauer16c22972002-03-22 15:34:49 +000011714
Barry Warsawef82cd72000-06-30 16:21:01 +000011715# Check for --with-wctype-functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011716echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
11717echo $ECHO_N "checking for --with-wctype-functions... $ECHO_C" >&6
11718
Barry Warsawef82cd72000-06-30 16:21:01 +000011719# Check whether --with-wctype-functions or --without-wctype-functions was given.
11720if test "${with_wctype_functions+set}" = set; then
11721 withval="$with_wctype_functions"
Martin v. Löwis11437992002-04-12 09:54:03 +000011722
Barry Warsawef82cd72000-06-30 16:21:01 +000011723if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000011724then
11725
11726cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000011727#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011728_ACEOF
11729
11730 echo "$as_me:$LINENO: result: yes" >&5
11731echo "${ECHO_T}yes" >&6
11732else echo "$as_me:$LINENO: result: no" >&5
11733echo "${ECHO_T}no" >&6
Barry Warsawef82cd72000-06-30 16:21:01 +000011734fi
11735else
Martin v. Löwis11437992002-04-12 09:54:03 +000011736 echo "$as_me:$LINENO: result: no" >&5
11737echo "${ECHO_T}no" >&6
11738fi;
Barry Warsawef82cd72000-06-30 16:21:01 +000011739
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011740# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000011741
Guido van Rossum98935bf2001-09-05 19:13:16 +000011742DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000011743
Martin v. Löwis11437992002-04-12 09:54:03 +000011744echo "$as_me:$LINENO: checking for --with-sgi-dl" >&5
11745echo $ECHO_N "checking for --with-sgi-dl... $ECHO_C" >&6
11746
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011747# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011748if test "${with_sgi_dl+set}" = set; then
11749 withval="$with_sgi_dl"
Martin v. Löwis11437992002-04-12 09:54:03 +000011750
11751echo "$as_me:$LINENO: result: $withval" >&5
11752echo "${ECHO_T}$withval" >&6
Martin v. Löwis9ef33762002-12-02 22:23:56 +000011753echo --with-sgi-dl is unsupported, see README
Martin v. Löwis779ffc02002-12-02 22:17:01 +000011754exit 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011755
11756cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011757#define WITH_SGI_DL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011758_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011759
Guido van Rossume97ee181999-12-20 21:27:22 +000011760DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011761dldir=$withval
Guido van Rossum40951012000-10-07 16:21:27 +000011762if test ! -z "$dldir" -a -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011763then LDFLAGS="$LDFLAGS -L$dldir"
Martin v. Löwis11437992002-04-12 09:54:03 +000011764else { { echo "$as_me:$LINENO: error: proper usage is --with-sgi-dl=DIRECTORY" >&5
11765echo "$as_me: error: proper usage is --with-sgi-dl=DIRECTORY" >&2;}
11766 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011767fi
11768DLINCLDIR=${dldir}
11769LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011770else
Martin v. Löwis11437992002-04-12 09:54:03 +000011771 echo "$as_me:$LINENO: result: no" >&5
11772echo "${ECHO_T}no" >&6
11773fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011774
Martin v. Löwis11437992002-04-12 09:54:03 +000011775echo "$as_me:$LINENO: checking for --with-dl-dld" >&5
11776echo $ECHO_N "checking for --with-dl-dld... $ECHO_C" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000011777
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011778# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011779if test "${with_dl_dld+set}" = set; then
11780 withval="$with_dl_dld"
Martin v. Löwis11437992002-04-12 09:54:03 +000011781
11782echo "$as_me:$LINENO: result: $withval" >&5
11783echo "${ECHO_T}$withval" >&6
Martin v. Löwis9ef33762002-12-02 22:23:56 +000011784echo --with-dl-dld is unsupported, see README
Martin v. Löwis779ffc02002-12-02 22:17:01 +000011785exit 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011786
11787cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011788#define WITH_DL_DLD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011789_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011790
Guido van Rossume97ee181999-12-20 21:27:22 +000011791DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011792dldir=`echo "$withval" | sed 's/,.*//'`
11793dlddir=`echo "$withval" | sed 's/.*,//'`
Barry Warsaw7d1219d2000-10-05 18:45:53 +000011794if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011795then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011796else { { echo "$as_me:$LINENO: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&5
11797echo "$as_me: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&2;}
11798 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011799fi
11800DLINCLDIR=${dldir}
11801LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011802else
Martin v. Löwis11437992002-04-12 09:54:03 +000011803 echo "$as_me:$LINENO: result: no" >&5
11804echo "${ECHO_T}no" >&6
11805fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011806
Guido van Rossume97ee181999-12-20 21:27:22 +000011807# the dlopen() function means we might want to use dynload_shlib.o. some
11808# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000011809
Thomas Wouters3a584202000-08-05 23:28:51 +000011810for ac_func in dlopen
11811do
Martin v. Löwis11437992002-04-12 09:54:03 +000011812as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11813echo "$as_me:$LINENO: checking for $ac_func" >&5
11814echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11815if eval "test \"\${$as_ac_var+set}\" = set"; then
11816 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011817else
Martin v. Löwis11437992002-04-12 09:54:03 +000011818 cat >conftest.$ac_ext <<_ACEOF
11819#line $LINENO "configure"
Guido van Rossume97ee181999-12-20 21:27:22 +000011820#include "confdefs.h"
11821/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011822 which can conflict with char $ac_func (); below. */
Guido van Rossume97ee181999-12-20 21:27:22 +000011823#include <assert.h>
11824/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011825#ifdef __cplusplus
11826extern "C"
11827#endif
Guido van Rossume97ee181999-12-20 21:27:22 +000011828/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011829 builtin and then its argument prototype would still apply. */
11830char $ac_func ();
11831char (*f) ();
Guido van Rossume97ee181999-12-20 21:27:22 +000011832
Martin v. Löwis11437992002-04-12 09:54:03 +000011833#ifdef F77_DUMMY_MAIN
11834# ifdef __cplusplus
11835 extern "C"
11836# endif
11837 int F77_DUMMY_MAIN() { return 1; }
11838#endif
11839int
11840main ()
11841{
Guido van Rossume97ee181999-12-20 21:27:22 +000011842/* The GNU C library defines this for functions which it implements
11843 to always fail with ENOSYS. Some functions are actually named
11844 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000011845#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossume97ee181999-12-20 21:27:22 +000011846choke me
11847#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011848f = $ac_func;
Guido van Rossume97ee181999-12-20 21:27:22 +000011849#endif
11850
Martin v. Löwis11437992002-04-12 09:54:03 +000011851 ;
11852 return 0;
11853}
11854_ACEOF
11855rm -f conftest.$ac_objext conftest$ac_exeext
11856if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11857 (eval $ac_link) 2>&5
11858 ac_status=$?
11859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11860 (exit $ac_status); } &&
11861 { ac_try='test -s conftest$ac_exeext'
11862 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11863 (eval $ac_try) 2>&5
11864 ac_status=$?
11865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11866 (exit $ac_status); }; }; then
11867 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011868else
Martin v. Löwis11437992002-04-12 09:54:03 +000011869 echo "$as_me: failed program was:" >&5
11870cat conftest.$ac_ext >&5
11871eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011872fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011873rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011874fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011875echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11876echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11877if test `eval echo '${'$as_ac_var'}'` = yes; then
11878 cat >>confdefs.h <<_ACEOF
11879#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11880_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011881
Guido van Rossume97ee181999-12-20 21:27:22 +000011882fi
Thomas Wouters3a584202000-08-05 23:28:51 +000011883done
Guido van Rossume97ee181999-12-20 21:27:22 +000011884
Michael W. Hudson54241132001-12-07 15:38:26 +000011885
Guido van Rossume97ee181999-12-20 21:27:22 +000011886# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
11887# loading of modules.
11888
Martin v. Löwis11437992002-04-12 09:54:03 +000011889echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
11890echo $ECHO_N "checking DYNLOADFILE... $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011891if test -z "$DYNLOADFILE"
11892then
11893 case $ac_sys_system/$ac_sys_release in
11894 AIX*) DYNLOADFILE="dynload_aix.o";;
11895 BeOS*) DYNLOADFILE="dynload_beos.o";;
11896 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Jack Jansene578a632001-08-15 01:27:14 +000011897 Darwin/*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011898 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000011899 *)
11900 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
11901 # out any dynamic loading
11902 if test "$ac_cv_func_dlopen" = yes
11903 then DYNLOADFILE="dynload_shlib.o"
11904 else DYNLOADFILE="dynload_stub.o"
11905 fi
11906 ;;
11907 esac
11908fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011909echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
11910echo "${ECHO_T}$DYNLOADFILE" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011911if test "$DYNLOADFILE" != "dynload_stub.o"
11912then
Martin v. Löwis11437992002-04-12 09:54:03 +000011913
11914cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011915#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011916_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011917
11918fi
11919
Neil Schemenauer4e425612001-06-19 15:44:15 +000011920# MACHDEP_OBJS can be set to platform-specific object files needed by Python
11921
Michael W. Hudson54241132001-12-07 15:38:26 +000011922
Martin v. Löwis11437992002-04-12 09:54:03 +000011923echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
11924echo $ECHO_N "checking MACHDEP_OBJS... $ECHO_C" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011925if test -z "$MACHDEP_OBJS"
11926then
Jack Jansene578a632001-08-15 01:27:14 +000011927 MACHDEP_OBJS=$extra_machdep_objs
11928else
11929 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000011930fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011931echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
11932echo "${ECHO_T}MACHDEP_OBJS" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011933
Guido van Rossum627b2d71993-12-24 10:39:16 +000011934# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011935
11936
11937
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
Martin v. Löwisd5843682002-11-21 20:41:28 +000012008for ac_func in alarm chown clock confstr ctermid execv \
Fred Drake6b3cc522002-04-15 19:20:27 +000012009 fchdir flock fork fsync fdatasync fpathconf ftime ftruncate \
Martin v. Löwis606edc12002-06-13 21:09:11 +000012010 gai_strerror getgroups getlogin getpeername getpgid getpid getpwent getwd \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012011 hstrerror inet_pton kill killpg lchown lstat mkfifo mknod mktime \
Martin v. Löwisa5f09072002-10-11 05:37:59 +000012012 mremap nice pathconf pause plock poll pthread_init \
Fred Drake35a092f1999-12-13 16:23:35 +000012013 putenv readlink \
Martin v. Löwisd5843682002-11-21 20:41:28 +000012014 select setegid seteuid setgid \
Martin v. Löwis791bfda2001-07-24 06:33:08 +000012015 setlocale setregid setreuid setsid setpgid setuid setvbuf snprintf \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012016 sigaction siginterrupt sigrelse strftime strptime \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000012017 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Martin v. Löwis6aa9fdb2002-09-10 09:16:13 +000012018 truncate uname unsetenv utimes waitpid _getpty getpriority
Guido van Rossum627b2d71993-12-24 10:39:16 +000012019do
Martin v. Löwis11437992002-04-12 09:54:03 +000012020as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12021echo "$as_me:$LINENO: checking for $ac_func" >&5
12022echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12023if eval "test \"\${$as_ac_var+set}\" = set"; then
12024 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012025else
Martin v. Löwis11437992002-04-12 09:54:03 +000012026 cat >conftest.$ac_ext <<_ACEOF
12027#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012028#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012029/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012030 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012031#include <assert.h>
12032/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012033#ifdef __cplusplus
12034extern "C"
12035#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012036/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012037 builtin and then its argument prototype would still apply. */
12038char $ac_func ();
12039char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012040
Martin v. Löwis11437992002-04-12 09:54:03 +000012041#ifdef F77_DUMMY_MAIN
12042# ifdef __cplusplus
12043 extern "C"
12044# endif
12045 int F77_DUMMY_MAIN() { return 1; }
12046#endif
12047int
12048main ()
12049{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012050/* The GNU C library defines this for functions which it implements
12051 to always fail with ENOSYS. Some functions are actually named
12052 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012053#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012054choke me
12055#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012056f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012057#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012058
Martin v. Löwis11437992002-04-12 09:54:03 +000012059 ;
12060 return 0;
12061}
12062_ACEOF
12063rm -f conftest.$ac_objext conftest$ac_exeext
12064if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12065 (eval $ac_link) 2>&5
12066 ac_status=$?
12067 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12068 (exit $ac_status); } &&
12069 { ac_try='test -s conftest$ac_exeext'
12070 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12071 (eval $ac_try) 2>&5
12072 ac_status=$?
12073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12074 (exit $ac_status); }; }; then
12075 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012076else
Martin v. Löwis11437992002-04-12 09:54:03 +000012077 echo "$as_me: failed program was:" >&5
12078cat conftest.$ac_ext >&5
12079eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012080fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012081rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012082fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012083echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12084echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12085if test `eval echo '${'$as_ac_var'}'` = yes; then
12086 cat >>confdefs.h <<_ACEOF
12087#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12088_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012089
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012090fi
12091done
12092
Michael W. Hudson54241132001-12-07 15:38:26 +000012093
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012094# For some functions, having a definition is not sufficient, since
12095# we want to take their address.
12096echo "$as_me:$LINENO: checking for chroot" >&5
12097echo $ECHO_N "checking for chroot... $ECHO_C" >&6
12098cat >conftest.$ac_ext <<_ACEOF
12099#line $LINENO "configure"
12100#include "confdefs.h"
12101#include <unistd.h>
12102#ifdef F77_DUMMY_MAIN
12103# ifdef __cplusplus
12104 extern "C"
12105# endif
12106 int F77_DUMMY_MAIN() { return 1; }
12107#endif
12108int
12109main ()
12110{
12111void *x=chroot
12112 ;
12113 return 0;
12114}
12115_ACEOF
12116rm -f conftest.$ac_objext
12117if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12118 (eval $ac_compile) 2>&5
12119 ac_status=$?
12120 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12121 (exit $ac_status); } &&
12122 { ac_try='test -s conftest.$ac_objext'
12123 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12124 (eval $ac_try) 2>&5
12125 ac_status=$?
12126 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12127 (exit $ac_status); }; }; then
12128
12129cat >>confdefs.h <<\_ACEOF
12130#define HAVE_CHROOT 1
12131_ACEOF
12132
12133 echo "$as_me:$LINENO: result: yes" >&5
12134echo "${ECHO_T}yes" >&6
12135else
12136 echo "$as_me: failed program was:" >&5
12137cat conftest.$ac_ext >&5
12138echo "$as_me:$LINENO: result: no" >&5
12139echo "${ECHO_T}no" >&6
12140
12141fi
12142rm -f conftest.$ac_objext conftest.$ac_ext
12143echo "$as_me:$LINENO: checking for link" >&5
12144echo $ECHO_N "checking for link... $ECHO_C" >&6
12145cat >conftest.$ac_ext <<_ACEOF
12146#line $LINENO "configure"
12147#include "confdefs.h"
12148#include <unistd.h>
12149#ifdef F77_DUMMY_MAIN
12150# ifdef __cplusplus
12151 extern "C"
12152# endif
12153 int F77_DUMMY_MAIN() { return 1; }
12154#endif
12155int
12156main ()
12157{
12158void *x=link
12159 ;
12160 return 0;
12161}
12162_ACEOF
12163rm -f conftest.$ac_objext
12164if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12165 (eval $ac_compile) 2>&5
12166 ac_status=$?
12167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12168 (exit $ac_status); } &&
12169 { ac_try='test -s conftest.$ac_objext'
12170 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12171 (eval $ac_try) 2>&5
12172 ac_status=$?
12173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12174 (exit $ac_status); }; }; then
12175
12176cat >>confdefs.h <<\_ACEOF
12177#define HAVE_LINK 1
12178_ACEOF
12179
12180 echo "$as_me:$LINENO: result: yes" >&5
12181echo "${ECHO_T}yes" >&6
12182else
12183 echo "$as_me: failed program was:" >&5
12184cat conftest.$ac_ext >&5
12185echo "$as_me:$LINENO: result: no" >&5
12186echo "${ECHO_T}no" >&6
12187
12188fi
12189rm -f conftest.$ac_objext conftest.$ac_ext
12190echo "$as_me:$LINENO: checking for symlink" >&5
12191echo $ECHO_N "checking for symlink... $ECHO_C" >&6
12192cat >conftest.$ac_ext <<_ACEOF
12193#line $LINENO "configure"
12194#include "confdefs.h"
12195#include <unistd.h>
12196#ifdef F77_DUMMY_MAIN
12197# ifdef __cplusplus
12198 extern "C"
12199# endif
12200 int F77_DUMMY_MAIN() { return 1; }
12201#endif
12202int
12203main ()
12204{
12205void *x=symlink
12206 ;
12207 return 0;
12208}
12209_ACEOF
12210rm -f conftest.$ac_objext
12211if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12212 (eval $ac_compile) 2>&5
12213 ac_status=$?
12214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12215 (exit $ac_status); } &&
12216 { ac_try='test -s conftest.$ac_objext'
12217 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12218 (eval $ac_try) 2>&5
12219 ac_status=$?
12220 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12221 (exit $ac_status); }; }; then
12222
12223cat >>confdefs.h <<\_ACEOF
12224#define HAVE_SYMLINK 1
12225_ACEOF
12226
12227 echo "$as_me:$LINENO: result: yes" >&5
12228echo "${ECHO_T}yes" >&6
12229else
12230 echo "$as_me: failed program was:" >&5
12231cat conftest.$ac_ext >&5
12232echo "$as_me:$LINENO: result: no" >&5
12233echo "${ECHO_T}no" >&6
12234
12235fi
12236rm -f conftest.$ac_objext conftest.$ac_ext
12237
Martin v. Löwisd5843682002-11-21 20:41:28 +000012238# On some systems (eg. FreeBSD 5), we would find a definition of the
12239# functions ctermid_r, setgroups in the library, but no prototype
12240# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
12241# address to avoid compiler warnings and potential miscompilations
12242# because of the missing prototypes.
12243
12244echo "$as_me:$LINENO: checking for ctermid_r" >&5
12245echo $ECHO_N "checking for ctermid_r... $ECHO_C" >&6
12246cat >conftest.$ac_ext <<_ACEOF
12247#line $LINENO "configure"
12248#include "confdefs.h"
12249
12250#include "confdefs.h"
12251#include <stdio.h>
12252
12253#ifdef F77_DUMMY_MAIN
12254# ifdef __cplusplus
12255 extern "C"
12256# endif
12257 int F77_DUMMY_MAIN() { return 1; }
12258#endif
12259int
12260main ()
12261{
12262void* p = ctermid_r
12263 ;
12264 return 0;
12265}
12266_ACEOF
12267rm -f conftest.$ac_objext
12268if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12269 (eval $ac_compile) 2>&5
12270 ac_status=$?
12271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12272 (exit $ac_status); } &&
12273 { ac_try='test -s conftest.$ac_objext'
12274 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12275 (eval $ac_try) 2>&5
12276 ac_status=$?
12277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12278 (exit $ac_status); }; }; then
12279
12280cat >>confdefs.h <<\_ACEOF
12281#define HAVE_CTERMID_R 1
12282_ACEOF
12283
12284 echo "$as_me:$LINENO: result: yes" >&5
12285echo "${ECHO_T}yes" >&6
12286else
12287 echo "$as_me: failed program was:" >&5
12288cat conftest.$ac_ext >&5
12289echo "$as_me:$LINENO: result: no" >&5
12290echo "${ECHO_T}no" >&6
12291
12292fi
12293rm -f conftest.$ac_objext conftest.$ac_ext
12294
12295echo "$as_me:$LINENO: checking for setgroups" >&5
12296echo $ECHO_N "checking for setgroups... $ECHO_C" >&6
12297cat >conftest.$ac_ext <<_ACEOF
12298#line $LINENO "configure"
12299#include "confdefs.h"
12300
12301#include "confdefs.h"
12302#include <unistd.h.h>
12303
12304#ifdef F77_DUMMY_MAIN
12305# ifdef __cplusplus
12306 extern "C"
12307# endif
12308 int F77_DUMMY_MAIN() { return 1; }
12309#endif
12310int
12311main ()
12312{
12313void* p = setgroups
12314 ;
12315 return 0;
12316}
12317_ACEOF
12318rm -f conftest.$ac_objext
12319if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12320 (eval $ac_compile) 2>&5
12321 ac_status=$?
12322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12323 (exit $ac_status); } &&
12324 { ac_try='test -s conftest.$ac_objext'
12325 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12326 (eval $ac_try) 2>&5
12327 ac_status=$?
12328 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12329 (exit $ac_status); }; }; then
12330
12331cat >>confdefs.h <<\_ACEOF
12332#define HAVE_SETGROUPS 1
12333_ACEOF
12334
12335 echo "$as_me:$LINENO: result: yes" >&5
12336echo "${ECHO_T}yes" >&6
12337else
12338 echo "$as_me: failed program was:" >&5
12339cat conftest.$ac_ext >&5
12340echo "$as_me:$LINENO: result: no" >&5
12341echo "${ECHO_T}no" >&6
12342
12343fi
12344rm -f conftest.$ac_objext conftest.$ac_ext
12345
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012346# check for openpty and forkpty
12347
Martin v. Löwis11437992002-04-12 09:54:03 +000012348
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012349for ac_func in openpty
12350do
Martin v. Löwis11437992002-04-12 09:54:03 +000012351as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12352echo "$as_me:$LINENO: checking for $ac_func" >&5
12353echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12354if eval "test \"\${$as_ac_var+set}\" = set"; then
12355 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012356else
Martin v. Löwis11437992002-04-12 09:54:03 +000012357 cat >conftest.$ac_ext <<_ACEOF
12358#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012359#include "confdefs.h"
12360/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012361 which can conflict with char $ac_func (); below. */
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012362#include <assert.h>
12363/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012364#ifdef __cplusplus
12365extern "C"
12366#endif
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012367/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012368 builtin and then its argument prototype would still apply. */
12369char $ac_func ();
12370char (*f) ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012371
Martin v. Löwis11437992002-04-12 09:54:03 +000012372#ifdef F77_DUMMY_MAIN
12373# ifdef __cplusplus
12374 extern "C"
12375# endif
12376 int F77_DUMMY_MAIN() { return 1; }
12377#endif
12378int
12379main ()
12380{
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012381/* The GNU C library defines this for functions which it implements
12382 to always fail with ENOSYS. Some functions are actually named
12383 something starting with __ and the normal name is an alias. */
12384#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12385choke me
12386#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012387f = $ac_func;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012388#endif
12389
Martin v. Löwis11437992002-04-12 09:54:03 +000012390 ;
12391 return 0;
12392}
12393_ACEOF
12394rm -f conftest.$ac_objext conftest$ac_exeext
12395if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12396 (eval $ac_link) 2>&5
12397 ac_status=$?
12398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12399 (exit $ac_status); } &&
12400 { ac_try='test -s conftest$ac_exeext'
12401 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12402 (eval $ac_try) 2>&5
12403 ac_status=$?
12404 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12405 (exit $ac_status); }; }; then
12406 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012407else
Martin v. Löwis11437992002-04-12 09:54:03 +000012408 echo "$as_me: failed program was:" >&5
12409cat conftest.$ac_ext >&5
12410eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012411fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012412rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012413fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012414echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12415echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12416if test `eval echo '${'$as_ac_var'}'` = yes; then
12417 cat >>confdefs.h <<_ACEOF
12418#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12419_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012420
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012421else
Martin v. Löwis11437992002-04-12 09:54:03 +000012422 echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
12423echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
12424if test "${ac_cv_lib_util_openpty+set}" = set; then
12425 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012426else
Martin v. Löwis11437992002-04-12 09:54:03 +000012427 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012428LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012429cat >conftest.$ac_ext <<_ACEOF
12430#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012431#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000012432
Fred Drake8cef4cf2000-06-28 16:40:38 +000012433/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012434#ifdef __cplusplus
12435extern "C"
12436#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012437/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012438 builtin and then its argument prototype would still apply. */
12439char openpty ();
12440#ifdef F77_DUMMY_MAIN
12441# ifdef __cplusplus
12442 extern "C"
12443# endif
12444 int F77_DUMMY_MAIN() { return 1; }
12445#endif
12446int
12447main ()
12448{
12449openpty ();
12450 ;
12451 return 0;
12452}
12453_ACEOF
12454rm -f conftest.$ac_objext conftest$ac_exeext
12455if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12456 (eval $ac_link) 2>&5
12457 ac_status=$?
12458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12459 (exit $ac_status); } &&
12460 { ac_try='test -s conftest$ac_exeext'
12461 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12462 (eval $ac_try) 2>&5
12463 ac_status=$?
12464 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12465 (exit $ac_status); }; }; then
12466 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012467else
Martin v. Löwis11437992002-04-12 09:54:03 +000012468 echo "$as_me: failed program was:" >&5
12469cat conftest.$ac_ext >&5
12470ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012471fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012472rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12473LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012474fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012475echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
12476echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
12477if test $ac_cv_lib_util_openpty = yes; then
12478 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012479#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012480_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012481 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012482fi
12483
12484fi
12485done
12486
Martin v. Löwis11437992002-04-12 09:54:03 +000012487
Fred Drake8cef4cf2000-06-28 16:40:38 +000012488for ac_func in forkpty
12489do
Martin v. Löwis11437992002-04-12 09:54:03 +000012490as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12491echo "$as_me:$LINENO: checking for $ac_func" >&5
12492echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12493if eval "test \"\${$as_ac_var+set}\" = set"; then
12494 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012495else
Martin v. Löwis11437992002-04-12 09:54:03 +000012496 cat >conftest.$ac_ext <<_ACEOF
12497#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012498#include "confdefs.h"
12499/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012500 which can conflict with char $ac_func (); below. */
Fred Drake8cef4cf2000-06-28 16:40:38 +000012501#include <assert.h>
12502/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012503#ifdef __cplusplus
12504extern "C"
12505#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012506/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012507 builtin and then its argument prototype would still apply. */
12508char $ac_func ();
12509char (*f) ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000012510
Martin v. Löwis11437992002-04-12 09:54:03 +000012511#ifdef F77_DUMMY_MAIN
12512# ifdef __cplusplus
12513 extern "C"
12514# endif
12515 int F77_DUMMY_MAIN() { return 1; }
12516#endif
12517int
12518main ()
12519{
Fred Drake8cef4cf2000-06-28 16:40:38 +000012520/* The GNU C library defines this for functions which it implements
12521 to always fail with ENOSYS. Some functions are actually named
12522 something starting with __ and the normal name is an alias. */
12523#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12524choke me
12525#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012526f = $ac_func;
Fred Drake8cef4cf2000-06-28 16:40:38 +000012527#endif
12528
Martin v. Löwis11437992002-04-12 09:54:03 +000012529 ;
12530 return 0;
12531}
12532_ACEOF
12533rm -f conftest.$ac_objext conftest$ac_exeext
12534if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12535 (eval $ac_link) 2>&5
12536 ac_status=$?
12537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12538 (exit $ac_status); } &&
12539 { ac_try='test -s conftest$ac_exeext'
12540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12541 (eval $ac_try) 2>&5
12542 ac_status=$?
12543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12544 (exit $ac_status); }; }; then
12545 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012546else
Martin v. Löwis11437992002-04-12 09:54:03 +000012547 echo "$as_me: failed program was:" >&5
12548cat conftest.$ac_ext >&5
12549eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012550fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012551rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012552fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012553echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12554echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12555if test `eval echo '${'$as_ac_var'}'` = yes; then
12556 cat >>confdefs.h <<_ACEOF
12557#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12558_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012559
Fred Drake8cef4cf2000-06-28 16:40:38 +000012560else
Martin v. Löwis11437992002-04-12 09:54:03 +000012561 echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
12562echo $ECHO_N "checking for forkpty in -lutil... $ECHO_C" >&6
12563if test "${ac_cv_lib_util_forkpty+set}" = set; then
12564 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012565else
Martin v. Löwis11437992002-04-12 09:54:03 +000012566 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012567LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012568cat >conftest.$ac_ext <<_ACEOF
12569#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012570#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000012571
Fred Drake8cef4cf2000-06-28 16:40:38 +000012572/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012573#ifdef __cplusplus
12574extern "C"
12575#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012576/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012577 builtin and then its argument prototype would still apply. */
12578char forkpty ();
12579#ifdef F77_DUMMY_MAIN
12580# ifdef __cplusplus
12581 extern "C"
12582# endif
12583 int F77_DUMMY_MAIN() { return 1; }
12584#endif
12585int
12586main ()
12587{
12588forkpty ();
12589 ;
12590 return 0;
12591}
12592_ACEOF
12593rm -f conftest.$ac_objext conftest$ac_exeext
12594if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12595 (eval $ac_link) 2>&5
12596 ac_status=$?
12597 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12598 (exit $ac_status); } &&
12599 { ac_try='test -s conftest$ac_exeext'
12600 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12601 (eval $ac_try) 2>&5
12602 ac_status=$?
12603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12604 (exit $ac_status); }; }; then
12605 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012606else
Martin v. Löwis11437992002-04-12 09:54:03 +000012607 echo "$as_me: failed program was:" >&5
12608cat conftest.$ac_ext >&5
12609ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012610fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012611rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12612LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012613fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012614echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
12615echo "${ECHO_T}$ac_cv_lib_util_forkpty" >&6
12616if test $ac_cv_lib_util_forkpty = yes; then
12617 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012618#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012619_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012620 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012621fi
12622
12623fi
12624done
12625
Jack Jansendd19cf82001-12-06 22:36:17 +000012626
Michael W. Hudson54241132001-12-07 15:38:26 +000012627# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000012628
12629
12630
12631
12632
12633
Fred Drake8cef4cf2000-06-28 16:40:38 +000012634for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
12635do
Martin v. Löwis11437992002-04-12 09:54:03 +000012636as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12637echo "$as_me:$LINENO: checking for $ac_func" >&5
12638echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12639if eval "test \"\${$as_ac_var+set}\" = set"; then
12640 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012641else
Martin v. Löwis11437992002-04-12 09:54:03 +000012642 cat >conftest.$ac_ext <<_ACEOF
12643#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012644#include "confdefs.h"
12645/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012646 which can conflict with char $ac_func (); below. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012647#include <assert.h>
12648/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012649#ifdef __cplusplus
12650extern "C"
12651#endif
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012652/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012653 builtin and then its argument prototype would still apply. */
12654char $ac_func ();
12655char (*f) ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012656
Martin v. Löwis11437992002-04-12 09:54:03 +000012657#ifdef F77_DUMMY_MAIN
12658# ifdef __cplusplus
12659 extern "C"
12660# endif
12661 int F77_DUMMY_MAIN() { return 1; }
12662#endif
12663int
12664main ()
12665{
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012666/* The GNU C library defines this for functions which it implements
12667 to always fail with ENOSYS. Some functions are actually named
12668 something starting with __ and the normal name is an alias. */
12669#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12670choke me
12671#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012672f = $ac_func;
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012673#endif
12674
Martin v. Löwis11437992002-04-12 09:54:03 +000012675 ;
12676 return 0;
12677}
12678_ACEOF
12679rm -f conftest.$ac_objext conftest$ac_exeext
12680if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12681 (eval $ac_link) 2>&5
12682 ac_status=$?
12683 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12684 (exit $ac_status); } &&
12685 { ac_try='test -s conftest$ac_exeext'
12686 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12687 (eval $ac_try) 2>&5
12688 ac_status=$?
12689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12690 (exit $ac_status); }; }; then
12691 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012692else
Martin v. Löwis11437992002-04-12 09:54:03 +000012693 echo "$as_me: failed program was:" >&5
12694cat conftest.$ac_ext >&5
12695eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012696fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012697rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012698fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012699echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12700echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12701if test `eval echo '${'$as_ac_var'}'` = yes; then
12702 cat >>confdefs.h <<_ACEOF
12703#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12704_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000012705
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012706fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000012707done
12708
Michael W. Hudson54241132001-12-07 15:38:26 +000012709
Martin v. Löwis11437992002-04-12 09:54:03 +000012710
12711
12712
12713
12714
Martin v. Löwis1142de32002-03-29 16:28:31 +000012715for ac_func in dup2 getcwd strdup strerror memmove
Thomas Wouters3a584202000-08-05 23:28:51 +000012716do
Martin v. Löwis11437992002-04-12 09:54:03 +000012717as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12718echo "$as_me:$LINENO: checking for $ac_func" >&5
12719echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12720if eval "test \"\${$as_ac_var+set}\" = set"; then
12721 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012722else
Martin v. Löwis11437992002-04-12 09:54:03 +000012723 cat >conftest.$ac_ext <<_ACEOF
12724#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012725#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012726/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012727 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012728#include <assert.h>
12729/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012730#ifdef __cplusplus
12731extern "C"
12732#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012733/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012734 builtin and then its argument prototype would still apply. */
12735char $ac_func ();
12736char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012737
Martin v. Löwis11437992002-04-12 09:54:03 +000012738#ifdef F77_DUMMY_MAIN
12739# ifdef __cplusplus
12740 extern "C"
12741# endif
12742 int F77_DUMMY_MAIN() { return 1; }
12743#endif
12744int
12745main ()
12746{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012747/* The GNU C library defines this for functions which it implements
12748 to always fail with ENOSYS. Some functions are actually named
12749 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012750#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012751choke me
12752#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012753f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012754#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012755
Martin v. Löwis11437992002-04-12 09:54:03 +000012756 ;
12757 return 0;
12758}
12759_ACEOF
12760rm -f conftest.$ac_objext conftest$ac_exeext
12761if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12762 (eval $ac_link) 2>&5
12763 ac_status=$?
12764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12765 (exit $ac_status); } &&
12766 { ac_try='test -s conftest$ac_exeext'
12767 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12768 (eval $ac_try) 2>&5
12769 ac_status=$?
12770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12771 (exit $ac_status); }; }; then
12772 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012773else
Martin v. Löwis11437992002-04-12 09:54:03 +000012774 echo "$as_me: failed program was:" >&5
12775cat conftest.$ac_ext >&5
12776eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012777fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012778rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000012779fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012780echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12781echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12782if test `eval echo '${'$as_ac_var'}'` = yes; then
12783 cat >>confdefs.h <<_ACEOF
12784#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12785_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000012786
Martin v. Löwis1142de32002-03-29 16:28:31 +000012787else
Martin v. Löwis11437992002-04-12 09:54:03 +000012788 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012789fi
12790done
12791
12792
Martin v. Löwis11437992002-04-12 09:54:03 +000012793
Martin v. Löwis1142de32002-03-29 16:28:31 +000012794for ac_func in getpgrp
12795do
Martin v. Löwis11437992002-04-12 09:54:03 +000012796as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12797echo "$as_me:$LINENO: checking for $ac_func" >&5
12798echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12799if eval "test \"\${$as_ac_var+set}\" = set"; then
12800 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000012801else
Martin v. Löwis11437992002-04-12 09:54:03 +000012802 cat >conftest.$ac_ext <<_ACEOF
12803#line $LINENO "configure"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012804#include "confdefs.h"
12805/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012806 which can conflict with char $ac_func (); below. */
Martin v. Löwis1142de32002-03-29 16:28:31 +000012807#include <assert.h>
12808/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012809#ifdef __cplusplus
12810extern "C"
12811#endif
Martin v. Löwis1142de32002-03-29 16:28:31 +000012812/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012813 builtin and then its argument prototype would still apply. */
12814char $ac_func ();
12815char (*f) ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000012816
Martin v. Löwis11437992002-04-12 09:54:03 +000012817#ifdef F77_DUMMY_MAIN
12818# ifdef __cplusplus
12819 extern "C"
12820# endif
12821 int F77_DUMMY_MAIN() { return 1; }
12822#endif
12823int
12824main ()
12825{
Martin v. Löwis1142de32002-03-29 16:28:31 +000012826/* The GNU C library defines this for functions which it implements
12827 to always fail with ENOSYS. Some functions are actually named
12828 something starting with __ and the normal name is an alias. */
12829#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12830choke me
12831#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012832f = $ac_func;
Martin v. Löwis1142de32002-03-29 16:28:31 +000012833#endif
12834
Martin v. Löwis11437992002-04-12 09:54:03 +000012835 ;
12836 return 0;
12837}
12838_ACEOF
12839rm -f conftest.$ac_objext conftest$ac_exeext
12840if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12841 (eval $ac_link) 2>&5
12842 ac_status=$?
12843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12844 (exit $ac_status); } &&
12845 { ac_try='test -s conftest$ac_exeext'
12846 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12847 (eval $ac_try) 2>&5
12848 ac_status=$?
12849 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12850 (exit $ac_status); }; }; then
12851 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012852else
Martin v. Löwis11437992002-04-12 09:54:03 +000012853 echo "$as_me: failed program was:" >&5
12854cat conftest.$ac_ext >&5
12855eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012856fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012857rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012858fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012859echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12860echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12861if test `eval echo '${'$as_ac_var'}'` = yes; then
12862 cat >>confdefs.h <<_ACEOF
12863#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12864_ACEOF
12865 cat >conftest.$ac_ext <<_ACEOF
12866#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012867#include "confdefs.h"
12868#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012869#ifdef F77_DUMMY_MAIN
12870# ifdef __cplusplus
12871 extern "C"
12872# endif
12873 int F77_DUMMY_MAIN() { return 1; }
12874#endif
12875int
12876main ()
12877{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012878getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000012879 ;
12880 return 0;
12881}
12882_ACEOF
12883rm -f conftest.$ac_objext
12884if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12885 (eval $ac_compile) 2>&5
12886 ac_status=$?
12887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12888 (exit $ac_status); } &&
12889 { ac_try='test -s conftest.$ac_objext'
12890 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12891 (eval $ac_try) 2>&5
12892 ac_status=$?
12893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12894 (exit $ac_status); }; }; then
12895
12896cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012897#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012898_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012899
Martin v. Löwis11437992002-04-12 09:54:03 +000012900
Guido van Rossumf78abae1997-01-21 22:02:36 +000012901else
Martin v. Löwis11437992002-04-12 09:54:03 +000012902 echo "$as_me: failed program was:" >&5
12903cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000012904fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012905rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000012906
Guido van Rossum627b2d71993-12-24 10:39:16 +000012907fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012908done
Guido van Rossum627b2d71993-12-24 10:39:16 +000012909
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012910echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
12911echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
12912if test "${ac_cv_func_setpgrp_void+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012913 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012914else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012915 if test "$cross_compiling" = yes; then
12916 { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5
12917echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;}
12918 { (exit 1); exit 1; }; }
12919else
Martin v. Löwis11437992002-04-12 09:54:03 +000012920 cat >conftest.$ac_ext <<_ACEOF
12921#line $LINENO "configure"
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012922#include "confdefs.h"
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012923#if HAVE_UNISTD_H
12924# include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012925#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012926
Martin v. Löwis11437992002-04-12 09:54:03 +000012927#ifdef F77_DUMMY_MAIN
12928# ifdef __cplusplus
12929 extern "C"
12930# endif
12931 int F77_DUMMY_MAIN() { return 1; }
12932#endif
12933int
12934main ()
12935{
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012936/* If this system has a BSD-style setpgrp which takes arguments,
12937 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
12938 exit successfully. */
12939 exit (setpgrp (1,1) == -1 ? 0 : 1);
Martin v. Löwis11437992002-04-12 09:54:03 +000012940 ;
12941 return 0;
12942}
12943_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012944rm -f conftest$ac_exeext
Martin v. Löwis11437992002-04-12 09:54:03 +000012945if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12946 (eval $ac_link) 2>&5
12947 ac_status=$?
12948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012949 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwis11437992002-04-12 09:54:03 +000012950 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12951 (eval $ac_try) 2>&5
12952 ac_status=$?
12953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12954 (exit $ac_status); }; }; then
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012955 ac_cv_func_setpgrp_void=no
Michael W. Hudson54241132001-12-07 15:38:26 +000012956else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012957 echo "$as_me: program exited with status $ac_status" >&5
12958echo "$as_me: failed program was:" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012959cat conftest.$ac_ext >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012960( exit $ac_status )
12961ac_cv_func_setpgrp_void=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000012962fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012963rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012964fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012965fi
12966echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
12967echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
12968if test $ac_cv_func_setpgrp_void = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012969
12970cat >>confdefs.h <<\_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012971#define SETPGRP_VOID 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012972_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012973
12974fi
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012975
Martin v. Löwis11437992002-04-12 09:54:03 +000012976
Thomas Wouters3a584202000-08-05 23:28:51 +000012977for ac_func in gettimeofday
12978do
Martin v. Löwis11437992002-04-12 09:54:03 +000012979as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12980echo "$as_me:$LINENO: checking for $ac_func" >&5
12981echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12982if eval "test \"\${$as_ac_var+set}\" = set"; then
12983 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012984else
Martin v. Löwis11437992002-04-12 09:54:03 +000012985 cat >conftest.$ac_ext <<_ACEOF
12986#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012987#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012988/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012989 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012990#include <assert.h>
12991/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012992#ifdef __cplusplus
12993extern "C"
12994#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012995/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012996 builtin and then its argument prototype would still apply. */
12997char $ac_func ();
12998char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012999
Martin v. Löwis11437992002-04-12 09:54:03 +000013000#ifdef F77_DUMMY_MAIN
13001# ifdef __cplusplus
13002 extern "C"
13003# endif
13004 int F77_DUMMY_MAIN() { return 1; }
13005#endif
13006int
13007main ()
13008{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013009/* The GNU C library defines this for functions which it implements
13010 to always fail with ENOSYS. Some functions are actually named
13011 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000013012#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013013choke me
13014#else
Martin v. Löwis11437992002-04-12 09:54:03 +000013015f = $ac_func;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013016#endif
13017
Martin v. Löwis11437992002-04-12 09:54:03 +000013018 ;
13019 return 0;
13020}
13021_ACEOF
13022rm -f conftest.$ac_objext conftest$ac_exeext
13023if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13024 (eval $ac_link) 2>&5
13025 ac_status=$?
13026 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13027 (exit $ac_status); } &&
13028 { ac_try='test -s conftest$ac_exeext'
13029 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13030 (eval $ac_try) 2>&5
13031 ac_status=$?
13032 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13033 (exit $ac_status); }; }; then
13034 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013035else
Martin v. Löwis11437992002-04-12 09:54:03 +000013036 echo "$as_me: failed program was:" >&5
13037cat conftest.$ac_ext >&5
13038eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013039fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013040rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013041fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013042echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13043echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13044if test `eval echo '${'$as_ac_var'}'` = yes; then
13045 cat >>confdefs.h <<_ACEOF
13046#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13047_ACEOF
13048 cat >conftest.$ac_ext <<_ACEOF
13049#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013050#include "confdefs.h"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013051#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013052#ifdef F77_DUMMY_MAIN
13053# ifdef __cplusplus
13054 extern "C"
13055# endif
13056 int F77_DUMMY_MAIN() { return 1; }
13057#endif
13058int
13059main ()
13060{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013061gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000013062 ;
13063 return 0;
13064}
13065_ACEOF
13066rm -f conftest.$ac_objext
13067if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13068 (eval $ac_compile) 2>&5
13069 ac_status=$?
13070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13071 (exit $ac_status); } &&
13072 { ac_try='test -s conftest.$ac_objext'
13073 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13074 (eval $ac_try) 2>&5
13075 ac_status=$?
13076 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13077 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000013078 :
13079else
Martin v. Löwis11437992002-04-12 09:54:03 +000013080 echo "$as_me: failed program was:" >&5
13081cat conftest.$ac_ext >&5
13082
13083cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013084#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013085_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013086
Martin v. Löwis11437992002-04-12 09:54:03 +000013087
Guido van Rossum627b2d71993-12-24 10:39:16 +000013088fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013089rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013090
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013091fi
Thomas Wouters3a584202000-08-05 23:28:51 +000013092done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013093
Michael W. Hudson54241132001-12-07 15:38:26 +000013094
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000013095echo "$as_me:$LINENO: checking for major" >&5
13096echo $ECHO_N "checking for major... $ECHO_C" >&6
13097cat >conftest.$ac_ext <<_ACEOF
13098#line $LINENO "configure"
13099#include "confdefs.h"
13100
13101 #if defined(MAJOR_IN_MKDEV)
13102 #include <sys/mkdev.h>
13103 #elif defined(MAJOR_IN_SYSMACROS)
13104 #include <sys/sysmacros.h>
13105 #else
13106 #include <sys/types.h>
13107 #endif
13108
13109#ifdef F77_DUMMY_MAIN
13110# ifdef __cplusplus
13111 extern "C"
13112# endif
13113 int F77_DUMMY_MAIN() { return 1; }
13114#endif
13115int
13116main ()
13117{
13118
13119 makedev(major(0),minor(0));
13120
13121 ;
13122 return 0;
13123}
13124_ACEOF
Martin v. Löwise3271202002-11-07 07:42:30 +000013125rm -f conftest.$ac_objext conftest$ac_exeext
13126if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13127 (eval $ac_link) 2>&5
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000013128 ac_status=$?
13129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13130 (exit $ac_status); } &&
Martin v. Löwise3271202002-11-07 07:42:30 +000013131 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000013132 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13133 (eval $ac_try) 2>&5
13134 ac_status=$?
13135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13136 (exit $ac_status); }; }; then
13137
13138
13139cat >>confdefs.h <<\_ACEOF
13140#define HAVE_DEVICE_MACROS 1
13141_ACEOF
13142
13143 echo "$as_me:$LINENO: result: yes" >&5
13144echo "${ECHO_T}yes" >&6
13145
13146else
13147 echo "$as_me: failed program was:" >&5
13148cat conftest.$ac_ext >&5
13149
13150 echo "$as_me:$LINENO: result: no" >&5
13151echo "${ECHO_T}no" >&6
13152
13153fi
Martin v. Löwise3271202002-11-07 07:42:30 +000013154rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013155
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013156# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000013157# for [no]getaddrinfo in netdb.h.
13158echo "$as_me:$LINENO: checking for getaddrinfo" >&5
13159echo $ECHO_N "checking for getaddrinfo... $ECHO_C" >&6
13160cat >conftest.$ac_ext <<_ACEOF
13161#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013162#include "confdefs.h"
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013163
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000013164#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013165#include <sys/socket.h>
13166#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000013167#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013168
Martin v. Löwis11437992002-04-12 09:54:03 +000013169#ifdef F77_DUMMY_MAIN
13170# ifdef __cplusplus
13171 extern "C"
13172# endif
13173 int F77_DUMMY_MAIN() { return 1; }
13174#endif
13175int
13176main ()
13177{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013178
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013179getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013180
Martin v. Löwis11437992002-04-12 09:54:03 +000013181 ;
13182 return 0;
13183}
13184_ACEOF
13185rm -f conftest.$ac_objext conftest$ac_exeext
13186if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13187 (eval $ac_link) 2>&5
13188 ac_status=$?
13189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13190 (exit $ac_status); } &&
13191 { ac_try='test -s conftest$ac_exeext'
13192 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13193 (eval $ac_try) 2>&5
13194 ac_status=$?
13195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13196 (exit $ac_status); }; }; then
13197
13198echo "$as_me:$LINENO: result: yes" >&5
13199echo "${ECHO_T}yes" >&6
13200echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
13201echo $ECHO_N "checking getaddrinfo bug... $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013202if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013203 echo "$as_me:$LINENO: result: buggy" >&5
13204echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013205buggygetaddrinfo=yes
13206else
Martin v. Löwis11437992002-04-12 09:54:03 +000013207 cat >conftest.$ac_ext <<_ACEOF
13208#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013209#include "confdefs.h"
13210
13211#include <sys/types.h>
13212#include <netdb.h>
13213#include <string.h>
13214#include <sys/socket.h>
13215#include <netinet/in.h>
13216
13217main()
13218{
13219 int passive, gaierr, inet4 = 0, inet6 = 0;
13220 struct addrinfo hints, *ai, *aitop;
13221 char straddr[INET6_ADDRSTRLEN], strport[16];
13222
13223 for (passive = 0; passive <= 1; passive++) {
13224 memset(&hints, 0, sizeof(hints));
13225 hints.ai_family = AF_UNSPEC;
13226 hints.ai_flags = passive ? AI_PASSIVE : 0;
13227 hints.ai_socktype = SOCK_STREAM;
13228 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
13229 (void)gai_strerror(gaierr);
13230 goto bad;
13231 }
13232 for (ai = aitop; ai; ai = ai->ai_next) {
13233 if (ai->ai_addr == NULL ||
13234 ai->ai_addrlen == 0 ||
13235 getnameinfo(ai->ai_addr, ai->ai_addrlen,
13236 straddr, sizeof(straddr), strport, sizeof(strport),
13237 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
13238 goto bad;
13239 }
13240 switch (ai->ai_family) {
13241 case AF_INET:
13242 if (strcmp(strport, "54321") != 0) {
13243 goto bad;
13244 }
13245 if (passive) {
13246 if (strcmp(straddr, "0.0.0.0") != 0) {
13247 goto bad;
13248 }
13249 } else {
13250 if (strcmp(straddr, "127.0.0.1") != 0) {
13251 goto bad;
13252 }
13253 }
13254 inet4++;
13255 break;
13256 case AF_INET6:
13257 if (strcmp(strport, "54321") != 0) {
13258 goto bad;
13259 }
13260 if (passive) {
13261 if (strcmp(straddr, "::") != 0) {
13262 goto bad;
13263 }
13264 } else {
13265 if (strcmp(straddr, "::1") != 0) {
13266 goto bad;
13267 }
13268 }
13269 inet6++;
13270 break;
13271 case AF_UNSPEC:
13272 goto bad;
13273 break;
13274 default:
13275 /* another family support? */
13276 break;
13277 }
13278 }
13279 }
13280
13281 if (!(inet4 == 0 || inet4 == 2))
13282 goto bad;
13283 if (!(inet6 == 0 || inet6 == 2))
13284 goto bad;
13285
13286 if (aitop)
13287 freeaddrinfo(aitop);
13288 exit(0);
13289
13290 bad:
13291 if (aitop)
13292 freeaddrinfo(aitop);
13293 exit(1);
13294}
13295
Martin v. Löwis11437992002-04-12 09:54:03 +000013296_ACEOF
13297rm -f conftest$ac_exeext
13298if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13299 (eval $ac_link) 2>&5
13300 ac_status=$?
13301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13302 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13303 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13304 (eval $ac_try) 2>&5
13305 ac_status=$?
13306 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13307 (exit $ac_status); }; }; then
13308 echo "$as_me:$LINENO: result: good" >&5
13309echo "${ECHO_T}good" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013310buggygetaddrinfo=no
13311else
Martin v. Löwis11437992002-04-12 09:54:03 +000013312 echo "$as_me: program exited with status $ac_status" >&5
13313echo "$as_me: failed program was:" >&5
13314cat conftest.$ac_ext >&5
13315( exit $ac_status )
13316echo "$as_me:$LINENO: result: buggy" >&5
13317echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013318buggygetaddrinfo=yes
13319fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013320rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013321fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013322else
Martin v. Löwis11437992002-04-12 09:54:03 +000013323 echo "$as_me: failed program was:" >&5
13324cat conftest.$ac_ext >&5
13325
13326echo "$as_me:$LINENO: result: no" >&5
13327echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013328buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013329
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013330fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013331rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013332
13333if test "$buggygetaddrinfo" = "yes"; then
13334 if test "$ipv6" = "yes"; then
13335 echo 'Fatal: You must get working getaddrinfo() function.'
13336 echo ' or you can specify "--disable-ipv6"'.
13337 exit 1
13338 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013339else
Martin v. Löwis11437992002-04-12 09:54:03 +000013340
13341cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013342#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013343_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013344
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013345fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013346
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013347for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013348do
Martin v. Löwis11437992002-04-12 09:54:03 +000013349as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13350echo "$as_me:$LINENO: checking for $ac_func" >&5
13351echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13352if eval "test \"\${$as_ac_var+set}\" = set"; then
13353 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013354else
Martin v. Löwis11437992002-04-12 09:54:03 +000013355 cat >conftest.$ac_ext <<_ACEOF
13356#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013357#include "confdefs.h"
13358/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000013359 which can conflict with char $ac_func (); below. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013360#include <assert.h>
13361/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013362#ifdef __cplusplus
13363extern "C"
13364#endif
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013365/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000013366 builtin and then its argument prototype would still apply. */
13367char $ac_func ();
13368char (*f) ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013369
Martin v. Löwis11437992002-04-12 09:54:03 +000013370#ifdef F77_DUMMY_MAIN
13371# ifdef __cplusplus
13372 extern "C"
13373# endif
13374 int F77_DUMMY_MAIN() { return 1; }
13375#endif
13376int
13377main ()
13378{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013379/* The GNU C library defines this for functions which it implements
13380 to always fail with ENOSYS. Some functions are actually named
13381 something starting with __ and the normal name is an alias. */
13382#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13383choke me
13384#else
Martin v. Löwis11437992002-04-12 09:54:03 +000013385f = $ac_func;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013386#endif
13387
Martin v. Löwis11437992002-04-12 09:54:03 +000013388 ;
13389 return 0;
13390}
13391_ACEOF
13392rm -f conftest.$ac_objext conftest$ac_exeext
13393if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13394 (eval $ac_link) 2>&5
13395 ac_status=$?
13396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13397 (exit $ac_status); } &&
13398 { ac_try='test -s conftest$ac_exeext'
13399 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13400 (eval $ac_try) 2>&5
13401 ac_status=$?
13402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13403 (exit $ac_status); }; }; then
13404 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013405else
Martin v. Löwis11437992002-04-12 09:54:03 +000013406 echo "$as_me: failed program was:" >&5
13407cat conftest.$ac_ext >&5
13408eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013409fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013410rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013411fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013412echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13413echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13414if test `eval echo '${'$as_ac_var'}'` = yes; then
13415 cat >>confdefs.h <<_ACEOF
13416#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13417_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013418
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013419fi
13420done
13421
Michael W. Hudson54241132001-12-07 15:38:26 +000013422
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013423# checks for structures
Martin v. Löwis11437992002-04-12 09:54:03 +000013424echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
13425echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13426if test "${ac_cv_header_time+set}" = set; then
13427 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013428else
Martin v. Löwis11437992002-04-12 09:54:03 +000013429 cat >conftest.$ac_ext <<_ACEOF
13430#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013431#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013432#include <sys/types.h>
13433#include <sys/time.h>
13434#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013435
13436#ifdef F77_DUMMY_MAIN
13437# ifdef __cplusplus
13438 extern "C"
13439# endif
13440 int F77_DUMMY_MAIN() { return 1; }
13441#endif
13442int
13443main ()
13444{
13445if ((struct tm *) 0)
13446return 0;
13447 ;
13448 return 0;
13449}
13450_ACEOF
13451rm -f conftest.$ac_objext
13452if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13453 (eval $ac_compile) 2>&5
13454 ac_status=$?
13455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13456 (exit $ac_status); } &&
13457 { ac_try='test -s conftest.$ac_objext'
13458 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13459 (eval $ac_try) 2>&5
13460 ac_status=$?
13461 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13462 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013463 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000013464else
Martin v. Löwis11437992002-04-12 09:54:03 +000013465 echo "$as_me: failed program was:" >&5
13466cat conftest.$ac_ext >&5
13467ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013468fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013469rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013470fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013471echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
13472echo "${ECHO_T}$ac_cv_header_time" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013473if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013474
13475cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013476#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013477_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013478
13479fi
13480
Martin v. Löwis11437992002-04-12 09:54:03 +000013481echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
13482echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
13483if test "${ac_cv_struct_tm+set}" = set; then
13484 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013485else
Martin v. Löwis11437992002-04-12 09:54:03 +000013486 cat >conftest.$ac_ext <<_ACEOF
13487#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013488#include "confdefs.h"
13489#include <sys/types.h>
13490#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013491
13492#ifdef F77_DUMMY_MAIN
13493# ifdef __cplusplus
13494 extern "C"
13495# endif
13496 int F77_DUMMY_MAIN() { return 1; }
13497#endif
13498int
13499main ()
13500{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013501struct tm *tp; tp->tm_sec;
Martin v. Löwis11437992002-04-12 09:54:03 +000013502 ;
13503 return 0;
13504}
13505_ACEOF
13506rm -f conftest.$ac_objext
13507if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13508 (eval $ac_compile) 2>&5
13509 ac_status=$?
13510 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13511 (exit $ac_status); } &&
13512 { ac_try='test -s conftest.$ac_objext'
13513 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13514 (eval $ac_try) 2>&5
13515 ac_status=$?
13516 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13517 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013518 ac_cv_struct_tm=time.h
13519else
Martin v. Löwis11437992002-04-12 09:54:03 +000013520 echo "$as_me: failed program was:" >&5
13521cat conftest.$ac_ext >&5
13522ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013523fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013524rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013525fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013526echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
13527echo "${ECHO_T}$ac_cv_struct_tm" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013528if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013529
13530cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013531#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013532_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013533
13534fi
13535
Martin v. Löwis11437992002-04-12 09:54:03 +000013536echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
13537echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
13538if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
13539 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013540else
Martin v. Löwis11437992002-04-12 09:54:03 +000013541 cat >conftest.$ac_ext <<_ACEOF
13542#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013543#include "confdefs.h"
13544#include <sys/types.h>
13545#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000013546
13547
13548#ifdef F77_DUMMY_MAIN
13549# ifdef __cplusplus
13550 extern "C"
13551# endif
13552 int F77_DUMMY_MAIN() { return 1; }
13553#endif
13554int
13555main ()
13556{
13557static struct tm ac_aggr;
13558if (ac_aggr.tm_zone)
13559return 0;
13560 ;
13561 return 0;
13562}
13563_ACEOF
13564rm -f conftest.$ac_objext
13565if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13566 (eval $ac_compile) 2>&5
13567 ac_status=$?
13568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13569 (exit $ac_status); } &&
13570 { ac_try='test -s conftest.$ac_objext'
13571 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13572 (eval $ac_try) 2>&5
13573 ac_status=$?
13574 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13575 (exit $ac_status); }; }; then
13576 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013577else
Martin v. Löwis11437992002-04-12 09:54:03 +000013578 echo "$as_me: failed program was:" >&5
13579cat conftest.$ac_ext >&5
13580ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013581fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013582rm -f conftest.$ac_objext conftest.$ac_ext
13583fi
13584echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
13585echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
13586if test $ac_cv_member_struct_tm_tm_zone = yes; then
13587
13588cat >>confdefs.h <<_ACEOF
13589#define HAVE_STRUCT_TM_TM_ZONE 1
13590_ACEOF
13591
13592
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013593fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000013594
Martin v. Löwis11437992002-04-12 09:54:03 +000013595if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13596
13597cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013598#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013599_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013600
13601else
Martin v. Löwis11437992002-04-12 09:54:03 +000013602 echo "$as_me:$LINENO: checking for tzname" >&5
13603echo $ECHO_N "checking for tzname... $ECHO_C" >&6
13604if test "${ac_cv_var_tzname+set}" = set; then
13605 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013606else
Martin v. Löwis11437992002-04-12 09:54:03 +000013607 cat >conftest.$ac_ext <<_ACEOF
13608#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013609#include "confdefs.h"
13610#include <time.h>
13611#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013612extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000013613#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013614
13615#ifdef F77_DUMMY_MAIN
13616# ifdef __cplusplus
13617 extern "C"
13618# endif
13619 int F77_DUMMY_MAIN() { return 1; }
13620#endif
13621int
13622main ()
13623{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013624atoi(*tzname);
Martin v. Löwis11437992002-04-12 09:54:03 +000013625 ;
13626 return 0;
13627}
13628_ACEOF
13629rm -f conftest.$ac_objext conftest$ac_exeext
13630if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13631 (eval $ac_link) 2>&5
13632 ac_status=$?
13633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13634 (exit $ac_status); } &&
13635 { ac_try='test -s conftest$ac_exeext'
13636 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13637 (eval $ac_try) 2>&5
13638 ac_status=$?
13639 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13640 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013641 ac_cv_var_tzname=yes
13642else
Martin v. Löwis11437992002-04-12 09:54:03 +000013643 echo "$as_me: failed program was:" >&5
13644cat conftest.$ac_ext >&5
13645ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013646fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013647rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000013648fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013649echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
13650echo "${ECHO_T}$ac_cv_var_tzname" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013651 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013652
13653cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013654#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013655_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013656
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013657 fi
13658fi
13659
Martin v. Löwis11437992002-04-12 09:54:03 +000013660echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
13661echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6
13662if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
13663 echo $ECHO_N "(cached) $ECHO_C" >&6
13664else
13665 cat >conftest.$ac_ext <<_ACEOF
13666#line $LINENO "configure"
13667#include "confdefs.h"
13668$ac_includes_default
13669#ifdef F77_DUMMY_MAIN
13670# ifdef __cplusplus
13671 extern "C"
13672# endif
13673 int F77_DUMMY_MAIN() { return 1; }
13674#endif
13675int
13676main ()
13677{
13678static struct stat ac_aggr;
13679if (ac_aggr.st_rdev)
13680return 0;
13681 ;
13682 return 0;
13683}
13684_ACEOF
13685rm -f conftest.$ac_objext
13686if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13687 (eval $ac_compile) 2>&5
13688 ac_status=$?
13689 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13690 (exit $ac_status); } &&
13691 { ac_try='test -s conftest.$ac_objext'
13692 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13693 (eval $ac_try) 2>&5
13694 ac_status=$?
13695 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13696 (exit $ac_status); }; }; then
13697 ac_cv_member_struct_stat_st_rdev=yes
13698else
13699 echo "$as_me: failed program was:" >&5
13700cat conftest.$ac_ext >&5
13701ac_cv_member_struct_stat_st_rdev=no
13702fi
13703rm -f conftest.$ac_objext conftest.$ac_ext
13704fi
13705echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
13706echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6
13707if test $ac_cv_member_struct_stat_st_rdev = yes; then
13708
13709cat >>confdefs.h <<_ACEOF
13710#define HAVE_STRUCT_STAT_ST_RDEV 1
13711_ACEOF
13712
13713
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013714fi
13715
Martin v. Löwis11437992002-04-12 09:54:03 +000013716echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
13717echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
13718if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
13719 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013720else
Martin v. Löwis11437992002-04-12 09:54:03 +000013721 cat >conftest.$ac_ext <<_ACEOF
13722#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013723#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013724$ac_includes_default
13725#ifdef F77_DUMMY_MAIN
13726# ifdef __cplusplus
13727 extern "C"
13728# endif
13729 int F77_DUMMY_MAIN() { return 1; }
13730#endif
13731int
13732main ()
13733{
13734static struct stat ac_aggr;
13735if (ac_aggr.st_blksize)
13736return 0;
13737 ;
13738 return 0;
13739}
13740_ACEOF
13741rm -f conftest.$ac_objext
13742if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13743 (eval $ac_compile) 2>&5
13744 ac_status=$?
13745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13746 (exit $ac_status); } &&
13747 { ac_try='test -s conftest.$ac_objext'
13748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13749 (eval $ac_try) 2>&5
13750 ac_status=$?
13751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13752 (exit $ac_status); }; }; then
13753 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013754else
Martin v. Löwis11437992002-04-12 09:54:03 +000013755 echo "$as_me: failed program was:" >&5
13756cat conftest.$ac_ext >&5
13757ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013758fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013759rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013760fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013761echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
13762echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
13763if test $ac_cv_member_struct_stat_st_blksize = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013764
Martin v. Löwis11437992002-04-12 09:54:03 +000013765cat >>confdefs.h <<_ACEOF
13766#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13767_ACEOF
13768
13769
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013770fi
13771
Martin v. Löwis11437992002-04-12 09:54:03 +000013772echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
13773echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6
13774if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
13775 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013776else
Martin v. Löwis11437992002-04-12 09:54:03 +000013777 cat >conftest.$ac_ext <<_ACEOF
13778#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013779#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013780$ac_includes_default
13781#ifdef F77_DUMMY_MAIN
13782# ifdef __cplusplus
13783 extern "C"
13784# endif
13785 int F77_DUMMY_MAIN() { return 1; }
13786#endif
13787int
13788main ()
13789{
13790static struct stat ac_aggr;
13791if (ac_aggr.st_blocks)
13792return 0;
13793 ;
13794 return 0;
13795}
13796_ACEOF
13797rm -f conftest.$ac_objext
13798if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13799 (eval $ac_compile) 2>&5
13800 ac_status=$?
13801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13802 (exit $ac_status); } &&
13803 { ac_try='test -s conftest.$ac_objext'
13804 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13805 (eval $ac_try) 2>&5
13806 ac_status=$?
13807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13808 (exit $ac_status); }; }; then
13809 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013810else
Martin v. Löwis11437992002-04-12 09:54:03 +000013811 echo "$as_me: failed program was:" >&5
13812cat conftest.$ac_ext >&5
13813ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013814fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013815rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013816fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013817echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
13818echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6
13819if test $ac_cv_member_struct_stat_st_blocks = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013820
Martin v. Löwis11437992002-04-12 09:54:03 +000013821cat >>confdefs.h <<_ACEOF
13822#define HAVE_STRUCT_STAT_ST_BLOCKS 1
13823_ACEOF
13824
13825
13826cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013827#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013828_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013829
13830else
Martin v. Löwis11437992002-04-12 09:54:03 +000013831 LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013832fi
13833
Michael W. Hudson54241132001-12-07 15:38:26 +000013834
Martin v. Löwis11437992002-04-12 09:54:03 +000013835
13836echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
13837echo $ECHO_N "checking for time.h that defines altzone... $ECHO_C" >&6
13838if test "${ac_cv_header_time_altzone+set}" = set; then
13839 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013840else
Martin v. Löwis11437992002-04-12 09:54:03 +000013841 cat >conftest.$ac_ext <<_ACEOF
13842#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013843#include "confdefs.h"
13844#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013845#ifdef F77_DUMMY_MAIN
13846# ifdef __cplusplus
13847 extern "C"
13848# endif
13849 int F77_DUMMY_MAIN() { return 1; }
13850#endif
13851int
13852main ()
13853{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013854return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000013855 ;
13856 return 0;
13857}
13858_ACEOF
13859rm -f conftest.$ac_objext
13860if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13861 (eval $ac_compile) 2>&5
13862 ac_status=$?
13863 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13864 (exit $ac_status); } &&
13865 { ac_try='test -s conftest.$ac_objext'
13866 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13867 (eval $ac_try) 2>&5
13868 ac_status=$?
13869 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13870 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013871 ac_cv_header_time_altzone=yes
13872else
Martin v. Löwis11437992002-04-12 09:54:03 +000013873 echo "$as_me: failed program was:" >&5
13874cat conftest.$ac_ext >&5
13875ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +000013876fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013877rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013878fi
13879
Martin v. Löwis11437992002-04-12 09:54:03 +000013880echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
13881echo "${ECHO_T}$ac_cv_header_time_altzone" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013882if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013883
13884cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013885#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013886_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013887
13888fi
13889
Guido van Rossumda88dad1995-01-26 00:46:29 +000013890was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013891echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
13892echo $ECHO_N "checking whether sys/select.h and sys/time.h may both be included... $ECHO_C" >&6
13893cat >conftest.$ac_ext <<_ACEOF
13894#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013895#include "confdefs.h"
13896
13897#include <sys/types.h>
13898#include <sys/select.h>
13899#include <sys/time.h>
13900
Martin v. Löwis11437992002-04-12 09:54:03 +000013901#ifdef F77_DUMMY_MAIN
13902# ifdef __cplusplus
13903 extern "C"
13904# endif
13905 int F77_DUMMY_MAIN() { return 1; }
13906#endif
13907int
13908main ()
13909{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013910;
Martin v. Löwis11437992002-04-12 09:54:03 +000013911 ;
13912 return 0;
13913}
13914_ACEOF
13915rm -f conftest.$ac_objext
13916if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13917 (eval $ac_compile) 2>&5
13918 ac_status=$?
13919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13920 (exit $ac_status); } &&
13921 { ac_try='test -s conftest.$ac_objext'
13922 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13923 (eval $ac_try) 2>&5
13924 ac_status=$?
13925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13926 (exit $ac_status); }; }; then
13927
13928
13929cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013930#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013931_ACEOF
13932
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013933 was_it_defined=yes
13934
Guido van Rossumf78abae1997-01-21 22:02:36 +000013935else
Martin v. Löwis11437992002-04-12 09:54:03 +000013936 echo "$as_me: failed program was:" >&5
13937cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000013938fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013939rm -f conftest.$ac_objext conftest.$ac_ext
13940echo "$as_me:$LINENO: result: $was_it_defined" >&5
13941echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000013942
Martin v. Löwis11437992002-04-12 09:54:03 +000013943echo "$as_me:$LINENO: checking for addrinfo" >&5
13944echo $ECHO_N "checking for addrinfo... $ECHO_C" >&6
13945if test "${ac_cv_struct_addrinfo+set}" = set; then
13946 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013947else
Martin v. Löwis11437992002-04-12 09:54:03 +000013948 cat >conftest.$ac_ext <<_ACEOF
13949#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013950#include "confdefs.h"
13951
13952# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013953#ifdef F77_DUMMY_MAIN
13954# ifdef __cplusplus
13955 extern "C"
13956# endif
13957 int F77_DUMMY_MAIN() { return 1; }
13958#endif
13959int
13960main ()
13961{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013962struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000013963 ;
13964 return 0;
13965}
13966_ACEOF
13967rm -f conftest.$ac_objext
13968if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13969 (eval $ac_compile) 2>&5
13970 ac_status=$?
13971 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13972 (exit $ac_status); } &&
13973 { ac_try='test -s conftest.$ac_objext'
13974 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13975 (eval $ac_try) 2>&5
13976 ac_status=$?
13977 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13978 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013979 ac_cv_struct_addrinfo=yes
13980else
Martin v. Löwis11437992002-04-12 09:54:03 +000013981 echo "$as_me: failed program was:" >&5
13982cat conftest.$ac_ext >&5
13983ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013984fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013985rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013986fi
13987
Martin v. Löwis11437992002-04-12 09:54:03 +000013988echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
13989echo "${ECHO_T}$ac_cv_struct_addrinfo" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013990if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013991
13992cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013993#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013994_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013995
13996fi
13997
Martin v. Löwis11437992002-04-12 09:54:03 +000013998echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
13999echo $ECHO_N "checking for sockaddr_storage... $ECHO_C" >&6
14000if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
14001 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014002else
Martin v. Löwis11437992002-04-12 09:54:03 +000014003 cat >conftest.$ac_ext <<_ACEOF
14004#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014005#include "confdefs.h"
14006
14007# include <sys/types.h>
14008# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014009#ifdef F77_DUMMY_MAIN
14010# ifdef __cplusplus
14011 extern "C"
14012# endif
14013 int F77_DUMMY_MAIN() { return 1; }
14014#endif
14015int
14016main ()
14017{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014018struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000014019 ;
14020 return 0;
14021}
14022_ACEOF
14023rm -f conftest.$ac_objext
14024if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14025 (eval $ac_compile) 2>&5
14026 ac_status=$?
14027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14028 (exit $ac_status); } &&
14029 { ac_try='test -s conftest.$ac_objext'
14030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14031 (eval $ac_try) 2>&5
14032 ac_status=$?
14033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14034 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014035 ac_cv_struct_sockaddr_storage=yes
14036else
Martin v. Löwis11437992002-04-12 09:54:03 +000014037 echo "$as_me: failed program was:" >&5
14038cat conftest.$ac_ext >&5
14039ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014040fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014041rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014042fi
14043
Martin v. Löwis11437992002-04-12 09:54:03 +000014044echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
14045echo "${ECHO_T}$ac_cv_struct_sockaddr_storage" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014046if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014047
14048cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014049#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014050_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014051
14052fi
14053
Guido van Rossum627b2d71993-12-24 10:39:16 +000014054# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000014055
Michael W. Hudson54241132001-12-07 15:38:26 +000014056
Martin v. Löwis11437992002-04-12 09:54:03 +000014057echo "$as_me:$LINENO: checking whether char is unsigned" >&5
14058echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
14059if test "${ac_cv_c_char_unsigned+set}" = set; then
14060 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000014061else
Martin v. Löwis11437992002-04-12 09:54:03 +000014062 cat >conftest.$ac_ext <<_ACEOF
14063#line $LINENO "configure"
Michael W. Hudson54241132001-12-07 15:38:26 +000014064#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000014065$ac_includes_default
14066#ifdef F77_DUMMY_MAIN
14067# ifdef __cplusplus
14068 extern "C"
14069# endif
14070 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000014071#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014072int
14073main ()
14074{
14075static int test_array [1 - 2 * !(((char) -1) < 0)];
14076test_array [0] = 0
14077
14078 ;
14079 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000014080}
Martin v. Löwis11437992002-04-12 09:54:03 +000014081_ACEOF
14082rm -f conftest.$ac_objext
14083if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14084 (eval $ac_compile) 2>&5
14085 ac_status=$?
14086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14087 (exit $ac_status); } &&
14088 { ac_try='test -s conftest.$ac_objext'
14089 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14090 (eval $ac_try) 2>&5
14091 ac_status=$?
14092 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14093 (exit $ac_status); }; }; then
Michael W. Hudson54241132001-12-07 15:38:26 +000014094 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014095else
14096 echo "$as_me: failed program was:" >&5
14097cat conftest.$ac_ext >&5
14098ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014099fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014100rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014101fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014102echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
14103echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014104if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014105 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014106#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014107_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014108
14109fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000014110
Martin v. Löwis11437992002-04-12 09:54:03 +000014111echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
14112echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
14113if test "${ac_cv_prog_cc_stdc+set}" = set; then
14114 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014115else
Martin v. Löwis11437992002-04-12 09:54:03 +000014116 ac_cv_prog_cc_stdc=no
14117ac_save_CC=$CC
14118cat >conftest.$ac_ext <<_ACEOF
14119#line $LINENO "configure"
14120#include "confdefs.h"
14121#include <stdarg.h>
14122#include <stdio.h>
14123#include <sys/types.h>
14124#include <sys/stat.h>
14125/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
14126struct buf { int x; };
14127FILE * (*rcsopen) (struct buf *, struct stat *, int);
14128static char *e (p, i)
14129 char **p;
14130 int i;
14131{
14132 return p[i];
14133}
14134static char *f (char * (*g) (char **, int), char **p, ...)
14135{
14136 char *s;
14137 va_list v;
14138 va_start (v,p);
14139 s = g (p, va_arg (v,int));
14140 va_end (v);
14141 return s;
14142}
14143int test (int i, double x);
14144struct s1 {int (*f) (int a);};
14145struct s2 {int (*f) (double a);};
14146int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
14147int argc;
14148char **argv;
14149#ifdef F77_DUMMY_MAIN
14150# ifdef __cplusplus
14151 extern "C"
14152# endif
14153 int F77_DUMMY_MAIN() { return 1; }
14154#endif
14155int
14156main ()
14157{
14158return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
14159 ;
14160 return 0;
14161}
14162_ACEOF
14163# Don't try gcc -ansi; that turns off useful extensions and
14164# breaks some systems' header files.
14165# AIX -qlanglvl=ansi
14166# Ultrix and OSF/1 -std1
14167# HP-UX 10.20 and later -Ae
14168# HP-UX older versions -Aa -D_HPUX_SOURCE
14169# SVR4 -Xc -D__EXTENSIONS__
14170for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
14171do
14172 CC="$ac_save_CC $ac_arg"
14173 rm -f conftest.$ac_objext
14174if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14175 (eval $ac_compile) 2>&5
14176 ac_status=$?
14177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14178 (exit $ac_status); } &&
14179 { ac_try='test -s conftest.$ac_objext'
14180 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14181 (eval $ac_try) 2>&5
14182 ac_status=$?
14183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14184 (exit $ac_status); }; }; then
14185 ac_cv_prog_cc_stdc=$ac_arg
14186break
14187else
14188 echo "$as_me: failed program was:" >&5
14189cat conftest.$ac_ext >&5
14190fi
14191rm -f conftest.$ac_objext
14192done
14193rm -f conftest.$ac_ext conftest.$ac_objext
14194CC=$ac_save_CC
14195
14196fi
14197
14198case "x$ac_cv_prog_cc_stdc" in
14199 x|xno)
14200 echo "$as_me:$LINENO: result: none needed" >&5
14201echo "${ECHO_T}none needed" >&6 ;;
14202 *)
14203 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
14204echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
14205 CC="$CC $ac_cv_prog_cc_stdc" ;;
14206esac
14207
14208echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14209echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
14210if test "${ac_cv_c_const+set}" = set; then
14211 echo $ECHO_N "(cached) $ECHO_C" >&6
14212else
14213 cat >conftest.$ac_ext <<_ACEOF
14214#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014215#include "confdefs.h"
14216
Martin v. Löwis11437992002-04-12 09:54:03 +000014217#ifdef F77_DUMMY_MAIN
14218# ifdef __cplusplus
14219 extern "C"
14220# endif
14221 int F77_DUMMY_MAIN() { return 1; }
14222#endif
14223int
14224main ()
14225{
14226/* FIXME: Include the comments suggested by Paul. */
14227#ifndef __cplusplus
14228 /* Ultrix mips cc rejects this. */
14229 typedef int charset[2];
14230 const charset x;
14231 /* SunOS 4.1.1 cc rejects this. */
14232 char const *const *ccp;
14233 char **p;
14234 /* NEC SVR4.0.2 mips cc rejects this. */
14235 struct point {int x, y;};
14236 static struct point const zero = {0,0};
14237 /* AIX XL C 1.02.0.0 rejects this.
14238 It does not let you subtract one const X* pointer from another in
14239 an arm of an if-expression whose if-part is not a constant
14240 expression */
14241 const char *g = "string";
14242 ccp = &g + (g ? g-g : 0);
14243 /* HPUX 7.0 cc rejects these. */
14244 ++ccp;
14245 p = (char**) ccp;
14246 ccp = (char const *const *) p;
14247 { /* SCO 3.2v4 cc rejects this. */
14248 char *t;
14249 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014250
Martin v. Löwis11437992002-04-12 09:54:03 +000014251 *t++ = 0;
14252 }
14253 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
14254 int x[] = {25, 17};
14255 const int *foo = &x[0];
14256 ++foo;
14257 }
14258 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14259 typedef const int *iptr;
14260 iptr p = 0;
14261 ++p;
14262 }
14263 { /* AIX XL C 1.02.0.0 rejects this saying
14264 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14265 struct s { int j; const int *ap[3]; };
14266 struct s *b; b->j = 5;
14267 }
14268 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14269 const int foo = 10;
14270 }
14271#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000014272
Martin v. Löwis11437992002-04-12 09:54:03 +000014273 ;
14274 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000014275}
Martin v. Löwis11437992002-04-12 09:54:03 +000014276_ACEOF
14277rm -f conftest.$ac_objext
14278if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14279 (eval $ac_compile) 2>&5
14280 ac_status=$?
14281 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14282 (exit $ac_status); } &&
14283 { ac_try='test -s conftest.$ac_objext'
14284 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14285 (eval $ac_try) 2>&5
14286 ac_status=$?
14287 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14288 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014289 ac_cv_c_const=yes
14290else
Martin v. Löwis11437992002-04-12 09:54:03 +000014291 echo "$as_me: failed program was:" >&5
14292cat conftest.$ac_ext >&5
14293ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014294fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014295rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014296fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014297echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14298echo "${ECHO_T}$ac_cv_c_const" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014299if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014300
14301cat >>confdefs.h <<\_ACEOF
14302#define const
14303_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014304
14305fi
14306
Michael W. Hudson54241132001-12-07 15:38:26 +000014307
Guido van Rossumda88dad1995-01-26 00:46:29 +000014308works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014309echo "$as_me:$LINENO: checking for working volatile" >&5
14310echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
14311cat >conftest.$ac_ext <<_ACEOF
14312#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014313#include "confdefs.h"
14314
Martin v. Löwis11437992002-04-12 09:54:03 +000014315#ifdef F77_DUMMY_MAIN
14316# ifdef __cplusplus
14317 extern "C"
14318# endif
14319 int F77_DUMMY_MAIN() { return 1; }
14320#endif
14321int
14322main ()
14323{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014324volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000014325 ;
14326 return 0;
14327}
14328_ACEOF
14329rm -f conftest.$ac_objext
14330if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14331 (eval $ac_compile) 2>&5
14332 ac_status=$?
14333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14334 (exit $ac_status); } &&
14335 { ac_try='test -s conftest.$ac_objext'
14336 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14337 (eval $ac_try) 2>&5
14338 ac_status=$?
14339 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14340 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000014341 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000014342else
Martin v. Löwis11437992002-04-12 09:54:03 +000014343 echo "$as_me: failed program was:" >&5
14344cat conftest.$ac_ext >&5
14345
14346cat >>confdefs.h <<\_ACEOF
14347#define volatile
14348_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014349
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014350
Guido van Rossum627b2d71993-12-24 10:39:16 +000014351fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014352rm -f conftest.$ac_objext conftest.$ac_ext
14353echo "$as_me:$LINENO: result: $works" >&5
14354echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000014355
Guido van Rossumda88dad1995-01-26 00:46:29 +000014356works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014357echo "$as_me:$LINENO: checking for working signed char" >&5
14358echo $ECHO_N "checking for working signed char... $ECHO_C" >&6
14359cat >conftest.$ac_ext <<_ACEOF
14360#line $LINENO "configure"
Guido van Rossumdabb11b1994-10-11 15:04:27 +000014361#include "confdefs.h"
14362
Martin v. Löwis11437992002-04-12 09:54:03 +000014363#ifdef F77_DUMMY_MAIN
14364# ifdef __cplusplus
14365 extern "C"
14366# endif
14367 int F77_DUMMY_MAIN() { return 1; }
14368#endif
14369int
14370main ()
14371{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014372signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000014373 ;
14374 return 0;
14375}
14376_ACEOF
14377rm -f conftest.$ac_objext
14378if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14379 (eval $ac_compile) 2>&5
14380 ac_status=$?
14381 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14382 (exit $ac_status); } &&
14383 { ac_try='test -s conftest.$ac_objext'
14384 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14385 (eval $ac_try) 2>&5
14386 ac_status=$?
14387 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14388 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000014389 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000014390else
Martin v. Löwis11437992002-04-12 09:54:03 +000014391 echo "$as_me: failed program was:" >&5
14392cat conftest.$ac_ext >&5
14393
14394cat >>confdefs.h <<\_ACEOF
14395#define signed
14396_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000014397
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014398
Guido van Rossum7f43da71994-08-01 12:15:30 +000014399fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014400rm -f conftest.$ac_objext conftest.$ac_ext
14401echo "$as_me:$LINENO: result: $works" >&5
14402echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000014403
Guido van Rossumda88dad1995-01-26 00:46:29 +000014404have_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014405echo "$as_me:$LINENO: checking for prototypes" >&5
14406echo $ECHO_N "checking for prototypes... $ECHO_C" >&6
14407cat >conftest.$ac_ext <<_ACEOF
14408#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014409#include "confdefs.h"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014410int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014411#ifdef F77_DUMMY_MAIN
14412# ifdef __cplusplus
14413 extern "C"
14414# endif
14415 int F77_DUMMY_MAIN() { return 1; }
14416#endif
14417int
14418main ()
14419{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014420return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000014421 ;
14422 return 0;
14423}
14424_ACEOF
14425rm -f conftest.$ac_objext
14426if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14427 (eval $ac_compile) 2>&5
14428 ac_status=$?
14429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14430 (exit $ac_status); } &&
14431 { ac_try='test -s conftest.$ac_objext'
14432 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14433 (eval $ac_try) 2>&5
14434 ac_status=$?
14435 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14436 (exit $ac_status); }; }; then
14437
14438
14439cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014440#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014441_ACEOF
14442
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014443 have_prototypes=yes
14444
Guido van Rossumf78abae1997-01-21 22:02:36 +000014445else
Martin v. Löwis11437992002-04-12 09:54:03 +000014446 echo "$as_me: failed program was:" >&5
14447cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000014448fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014449rm -f conftest.$ac_objext conftest.$ac_ext
14450echo "$as_me:$LINENO: result: $have_prototypes" >&5
14451echo "${ECHO_T}$have_prototypes" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014452
Guido van Rossumda88dad1995-01-26 00:46:29 +000014453works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014454echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
14455echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6
14456cat >conftest.$ac_ext <<_ACEOF
14457#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014458#include "confdefs.h"
14459
14460#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000014461int foo(int x, ...) {
14462 va_list va;
14463 va_start(va, x);
14464 va_arg(va, int);
14465 va_arg(va, char *);
14466 va_arg(va, double);
14467 return 0;
14468}
Guido van Rossum7f43da71994-08-01 12:15:30 +000014469
Martin v. Löwis11437992002-04-12 09:54:03 +000014470#ifdef F77_DUMMY_MAIN
14471# ifdef __cplusplus
14472 extern "C"
14473# endif
14474 int F77_DUMMY_MAIN() { return 1; }
14475#endif
14476int
14477main ()
14478{
Guido van Rossum90eea071996-08-30 20:58:57 +000014479return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000014480 ;
14481 return 0;
14482}
14483_ACEOF
14484rm -f conftest.$ac_objext
14485if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14486 (eval $ac_compile) 2>&5
14487 ac_status=$?
14488 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14489 (exit $ac_status); } &&
14490 { ac_try='test -s conftest.$ac_objext'
14491 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14492 (eval $ac_try) 2>&5
14493 ac_status=$?
14494 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14495 (exit $ac_status); }; }; then
14496
14497
14498cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014499#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014500_ACEOF
14501
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014502 works=yes
14503
Guido van Rossumf78abae1997-01-21 22:02:36 +000014504else
Martin v. Löwis11437992002-04-12 09:54:03 +000014505 echo "$as_me: failed program was:" >&5
14506cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000014507fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014508rm -f conftest.$ac_objext conftest.$ac_ext
14509echo "$as_me:$LINENO: result: $works" >&5
14510echo "${ECHO_T}$works" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014511
Guido van Rossumda88dad1995-01-26 00:46:29 +000014512if test "$have_prototypes" = yes; then
14513bad_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014514echo "$as_me:$LINENO: checking for bad exec* prototypes" >&5
14515echo $ECHO_N "checking for bad exec* prototypes... $ECHO_C" >&6
14516cat >conftest.$ac_ext <<_ACEOF
14517#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014518#include "confdefs.h"
14519#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014520#ifdef F77_DUMMY_MAIN
14521# ifdef __cplusplus
14522 extern "C"
14523# endif
14524 int F77_DUMMY_MAIN() { return 1; }
14525#endif
14526int
14527main ()
14528{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014529char **t;execve("@",t,t);
Martin v. Löwis11437992002-04-12 09:54:03 +000014530 ;
14531 return 0;
14532}
14533_ACEOF
14534rm -f conftest.$ac_objext
14535if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14536 (eval $ac_compile) 2>&5
14537 ac_status=$?
14538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14539 (exit $ac_status); } &&
14540 { ac_try='test -s conftest.$ac_objext'
14541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14542 (eval $ac_try) 2>&5
14543 ac_status=$?
14544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14545 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000014546 :
14547else
Martin v. Löwis11437992002-04-12 09:54:03 +000014548 echo "$as_me: failed program was:" >&5
14549cat conftest.$ac_ext >&5
14550
14551cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014552#define BAD_EXEC_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014553_ACEOF
14554
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014555 bad_prototypes=yes
14556
Guido van Rossum627b2d71993-12-24 10:39:16 +000014557fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014558rm -f conftest.$ac_objext conftest.$ac_ext
14559echo "$as_me:$LINENO: result: $bad_prototypes" >&5
14560echo "${ECHO_T}$bad_prototypes" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000014561fi
14562
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014563# check if sockaddr has sa_len member
Martin v. Löwis11437992002-04-12 09:54:03 +000014564echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
14565echo $ECHO_N "checking if sockaddr has sa_len member... $ECHO_C" >&6
14566cat >conftest.$ac_ext <<_ACEOF
14567#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014568#include "confdefs.h"
14569#include <sys/types.h>
14570#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014571#ifdef F77_DUMMY_MAIN
14572# ifdef __cplusplus
14573 extern "C"
14574# endif
14575 int F77_DUMMY_MAIN() { return 1; }
14576#endif
14577int
14578main ()
14579{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014580struct sockaddr x;
14581x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000014582 ;
14583 return 0;
14584}
14585_ACEOF
14586rm -f conftest.$ac_objext
14587if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14588 (eval $ac_compile) 2>&5
14589 ac_status=$?
14590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14591 (exit $ac_status); } &&
14592 { ac_try='test -s conftest.$ac_objext'
14593 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14594 (eval $ac_try) 2>&5
14595 ac_status=$?
14596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14597 (exit $ac_status); }; }; then
14598 echo "$as_me:$LINENO: result: yes" >&5
14599echo "${ECHO_T}yes" >&6
14600
14601cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014602#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014603_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014604
14605else
Martin v. Löwis11437992002-04-12 09:54:03 +000014606 echo "$as_me: failed program was:" >&5
14607cat conftest.$ac_ext >&5
14608echo "$as_me:$LINENO: result: no" >&5
14609echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014610fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014611rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014612
Guido van Rossumda88dad1995-01-26 00:46:29 +000014613va_list_is_array=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014614echo "$as_me:$LINENO: checking whether va_list is an array" >&5
14615echo $ECHO_N "checking whether va_list is an array... $ECHO_C" >&6
14616cat >conftest.$ac_ext <<_ACEOF
14617#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014618#include "confdefs.h"
14619
14620#ifdef HAVE_STDARG_PROTOTYPES
14621#include <stdarg.h>
14622#else
14623#include <varargs.h>
14624#endif
14625
Martin v. Löwis11437992002-04-12 09:54:03 +000014626#ifdef F77_DUMMY_MAIN
14627# ifdef __cplusplus
14628 extern "C"
14629# endif
14630 int F77_DUMMY_MAIN() { return 1; }
14631#endif
14632int
14633main ()
14634{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014635va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000014636 ;
14637 return 0;
14638}
14639_ACEOF
14640rm -f conftest.$ac_objext
14641if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14642 (eval $ac_compile) 2>&5
14643 ac_status=$?
14644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14645 (exit $ac_status); } &&
14646 { ac_try='test -s conftest.$ac_objext'
14647 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14648 (eval $ac_try) 2>&5
14649 ac_status=$?
14650 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14651 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014652 :
14653else
Martin v. Löwis11437992002-04-12 09:54:03 +000014654 echo "$as_me: failed program was:" >&5
14655cat conftest.$ac_ext >&5
14656
14657
14658cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014659#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014660_ACEOF
14661
Guido van Rossumda88dad1995-01-26 00:46:29 +000014662 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014663
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014664fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014665rm -f conftest.$ac_objext conftest.$ac_ext
14666echo "$as_me:$LINENO: result: $va_list_is_array" >&5
14667echo "${ECHO_T}$va_list_is_array" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014668
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014669# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000014670
14671
14672
14673echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
14674echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
14675if test "${ac_cv_func_gethostbyname_r+set}" = set; then
14676 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014677else
Martin v. Löwis11437992002-04-12 09:54:03 +000014678 cat >conftest.$ac_ext <<_ACEOF
14679#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014680#include "confdefs.h"
14681/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014682 which can conflict with char gethostbyname_r (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014683#include <assert.h>
14684/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014685#ifdef __cplusplus
14686extern "C"
14687#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014688/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014689 builtin and then its argument prototype would still apply. */
14690char gethostbyname_r ();
14691char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014692
Martin v. Löwis11437992002-04-12 09:54:03 +000014693#ifdef F77_DUMMY_MAIN
14694# ifdef __cplusplus
14695 extern "C"
14696# endif
14697 int F77_DUMMY_MAIN() { return 1; }
14698#endif
14699int
14700main ()
14701{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014702/* The GNU C library defines this for functions which it implements
14703 to always fail with ENOSYS. Some functions are actually named
14704 something starting with __ and the normal name is an alias. */
14705#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
14706choke me
14707#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014708f = gethostbyname_r;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014709#endif
14710
Martin v. Löwis11437992002-04-12 09:54:03 +000014711 ;
14712 return 0;
14713}
14714_ACEOF
14715rm -f conftest.$ac_objext conftest$ac_exeext
14716if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14717 (eval $ac_link) 2>&5
14718 ac_status=$?
14719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14720 (exit $ac_status); } &&
14721 { ac_try='test -s conftest$ac_exeext'
14722 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14723 (eval $ac_try) 2>&5
14724 ac_status=$?
14725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14726 (exit $ac_status); }; }; then
14727 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014728else
Martin v. Löwis11437992002-04-12 09:54:03 +000014729 echo "$as_me: failed program was:" >&5
14730cat conftest.$ac_ext >&5
14731ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014732fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014733rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014734fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014735echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
14736echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
14737if test $ac_cv_func_gethostbyname_r = yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014738
Martin v. Löwis11437992002-04-12 09:54:03 +000014739 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014740#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014741_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014742
Martin v. Löwis11437992002-04-12 09:54:03 +000014743 echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
14744echo $ECHO_N "checking gethostbyname_r with 6 args... $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014745 OLD_CFLAGS=$CFLAGS
14746 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014747 cat >conftest.$ac_ext <<_ACEOF
14748#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014749#include "confdefs.h"
14750
14751# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014752
14753#ifdef F77_DUMMY_MAIN
14754# ifdef __cplusplus
14755 extern "C"
14756# endif
14757 int F77_DUMMY_MAIN() { return 1; }
14758#endif
14759int
14760main ()
14761{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014762
14763 char *name;
14764 struct hostent *he, *res;
14765 char buffer[2048];
14766 int buflen = 2048;
14767 int h_errnop;
14768
14769 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014770
14771 ;
14772 return 0;
14773}
14774_ACEOF
14775rm -f conftest.$ac_objext
14776if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14777 (eval $ac_compile) 2>&5
14778 ac_status=$?
14779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14780 (exit $ac_status); } &&
14781 { ac_try='test -s conftest.$ac_objext'
14782 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14783 (eval $ac_try) 2>&5
14784 ac_status=$?
14785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14786 (exit $ac_status); }; }; then
14787
14788 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014789#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014790_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014791
Martin v. Löwis11437992002-04-12 09:54:03 +000014792
14793cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014794#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014795_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014796
Martin v. Löwis11437992002-04-12 09:54:03 +000014797 echo "$as_me:$LINENO: result: yes" >&5
14798echo "${ECHO_T}yes" >&6
14799
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014800else
Martin v. Löwis11437992002-04-12 09:54:03 +000014801 echo "$as_me: failed program was:" >&5
14802cat conftest.$ac_ext >&5
14803
14804 echo "$as_me:$LINENO: result: no" >&5
14805echo "${ECHO_T}no" >&6
14806 echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
14807echo $ECHO_N "checking gethostbyname_r with 5 args... $ECHO_C" >&6
14808 cat >conftest.$ac_ext <<_ACEOF
14809#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014810#include "confdefs.h"
14811
14812# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014813
14814#ifdef F77_DUMMY_MAIN
14815# ifdef __cplusplus
14816 extern "C"
14817# endif
14818 int F77_DUMMY_MAIN() { return 1; }
14819#endif
14820int
14821main ()
14822{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014823
14824 char *name;
14825 struct hostent *he;
14826 char buffer[2048];
14827 int buflen = 2048;
14828 int h_errnop;
14829
14830 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014831
14832 ;
14833 return 0;
14834}
14835_ACEOF
14836rm -f conftest.$ac_objext
14837if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14838 (eval $ac_compile) 2>&5
14839 ac_status=$?
14840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14841 (exit $ac_status); } &&
14842 { ac_try='test -s conftest.$ac_objext'
14843 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14844 (eval $ac_try) 2>&5
14845 ac_status=$?
14846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14847 (exit $ac_status); }; }; then
14848
14849 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014850#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014851_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014852
Martin v. Löwis11437992002-04-12 09:54:03 +000014853
14854cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014855#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014856_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014857
Martin v. Löwis11437992002-04-12 09:54:03 +000014858 echo "$as_me:$LINENO: result: yes" >&5
14859echo "${ECHO_T}yes" >&6
14860
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014861else
Martin v. Löwis11437992002-04-12 09:54:03 +000014862 echo "$as_me: failed program was:" >&5
14863cat conftest.$ac_ext >&5
14864
14865 echo "$as_me:$LINENO: result: no" >&5
14866echo "${ECHO_T}no" >&6
14867 echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
14868echo $ECHO_N "checking gethostbyname_r with 3 args... $ECHO_C" >&6
14869 cat >conftest.$ac_ext <<_ACEOF
14870#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014871#include "confdefs.h"
14872
14873# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014874
14875#ifdef F77_DUMMY_MAIN
14876# ifdef __cplusplus
14877 extern "C"
14878# endif
14879 int F77_DUMMY_MAIN() { return 1; }
14880#endif
14881int
14882main ()
14883{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014884
14885 char *name;
14886 struct hostent *he;
14887 struct hostent_data data;
14888
14889 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000014890
14891 ;
14892 return 0;
14893}
14894_ACEOF
14895rm -f conftest.$ac_objext
14896if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14897 (eval $ac_compile) 2>&5
14898 ac_status=$?
14899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14900 (exit $ac_status); } &&
14901 { ac_try='test -s conftest.$ac_objext'
14902 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14903 (eval $ac_try) 2>&5
14904 ac_status=$?
14905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14906 (exit $ac_status); }; }; then
14907
14908 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014909#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014910_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014911
Martin v. Löwis11437992002-04-12 09:54:03 +000014912
14913cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014914#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014915_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014916
Martin v. Löwis11437992002-04-12 09:54:03 +000014917 echo "$as_me:$LINENO: result: yes" >&5
14918echo "${ECHO_T}yes" >&6
14919
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014920else
Martin v. Löwis11437992002-04-12 09:54:03 +000014921 echo "$as_me: failed program was:" >&5
14922cat conftest.$ac_ext >&5
14923
14924 echo "$as_me:$LINENO: result: no" >&5
14925echo "${ECHO_T}no" >&6
14926
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014927fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014928rm -f conftest.$ac_objext conftest.$ac_ext
14929
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014930fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014931rm -f conftest.$ac_objext conftest.$ac_ext
14932
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014933fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014934rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014935 CFLAGS=$OLD_CFLAGS
14936
14937else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014938
Martin v. Löwis11437992002-04-12 09:54:03 +000014939
14940for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000014941do
Martin v. Löwis11437992002-04-12 09:54:03 +000014942as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14943echo "$as_me:$LINENO: checking for $ac_func" >&5
14944echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14945if eval "test \"\${$as_ac_var+set}\" = set"; then
14946 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014947else
Martin v. Löwis11437992002-04-12 09:54:03 +000014948 cat >conftest.$ac_ext <<_ACEOF
14949#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014950#include "confdefs.h"
14951/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014952 which can conflict with char $ac_func (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014953#include <assert.h>
14954/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014955#ifdef __cplusplus
14956extern "C"
14957#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014958/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014959 builtin and then its argument prototype would still apply. */
14960char $ac_func ();
14961char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014962
Martin v. Löwis11437992002-04-12 09:54:03 +000014963#ifdef F77_DUMMY_MAIN
14964# ifdef __cplusplus
14965 extern "C"
14966# endif
14967 int F77_DUMMY_MAIN() { return 1; }
14968#endif
14969int
14970main ()
14971{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014972/* The GNU C library defines this for functions which it implements
14973 to always fail with ENOSYS. Some functions are actually named
14974 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000014975#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014976choke me
14977#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014978f = $ac_func;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014979#endif
14980
Martin v. Löwis11437992002-04-12 09:54:03 +000014981 ;
14982 return 0;
14983}
14984_ACEOF
14985rm -f conftest.$ac_objext conftest$ac_exeext
14986if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14987 (eval $ac_link) 2>&5
14988 ac_status=$?
14989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14990 (exit $ac_status); } &&
14991 { ac_try='test -s conftest$ac_exeext'
14992 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14993 (eval $ac_try) 2>&5
14994 ac_status=$?
14995 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14996 (exit $ac_status); }; }; then
14997 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014998else
Martin v. Löwis11437992002-04-12 09:54:03 +000014999 echo "$as_me: failed program was:" >&5
15000cat conftest.$ac_ext >&5
15001eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000015002fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015003rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015004fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015005echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15006echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15007if test `eval echo '${'$as_ac_var'}'` = yes; then
15008 cat >>confdefs.h <<_ACEOF
15009#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15010_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015011
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015012fi
Thomas Wouters3a584202000-08-05 23:28:51 +000015013done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015014
Michael W. Hudson54241132001-12-07 15:38:26 +000015015
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000015016fi
15017
Michael W. Hudson54241132001-12-07 15:38:26 +000015018
15019
15020
15021
15022
15023
Guido van Rossum627b2d71993-12-24 10:39:16 +000015024# checks for system services
15025# (none yet)
15026
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015027# Linux requires this for correct f.p. operations
Martin v. Löwis11437992002-04-12 09:54:03 +000015028echo "$as_me:$LINENO: checking for __fpu_control" >&5
15029echo $ECHO_N "checking for __fpu_control... $ECHO_C" >&6
15030if test "${ac_cv_func___fpu_control+set}" = set; then
15031 echo $ECHO_N "(cached) $ECHO_C" >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015032else
Martin v. Löwis11437992002-04-12 09:54:03 +000015033 cat >conftest.$ac_ext <<_ACEOF
15034#line $LINENO "configure"
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015035#include "confdefs.h"
15036/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000015037 which can conflict with char __fpu_control (); below. */
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015038#include <assert.h>
15039/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015040#ifdef __cplusplus
15041extern "C"
15042#endif
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015043/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015044 builtin and then its argument prototype would still apply. */
15045char __fpu_control ();
15046char (*f) ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015047
Martin v. Löwis11437992002-04-12 09:54:03 +000015048#ifdef F77_DUMMY_MAIN
15049# ifdef __cplusplus
15050 extern "C"
15051# endif
15052 int F77_DUMMY_MAIN() { return 1; }
15053#endif
15054int
15055main ()
15056{
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015057/* The GNU C library defines this for functions which it implements
15058 to always fail with ENOSYS. Some functions are actually named
15059 something starting with __ and the normal name is an alias. */
15060#if defined (__stub___fpu_control) || defined (__stub_____fpu_control)
15061choke me
15062#else
Martin v. Löwis11437992002-04-12 09:54:03 +000015063f = __fpu_control;
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015064#endif
15065
Martin v. Löwis11437992002-04-12 09:54:03 +000015066 ;
15067 return 0;
15068}
15069_ACEOF
15070rm -f conftest.$ac_objext conftest$ac_exeext
15071if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15072 (eval $ac_link) 2>&5
15073 ac_status=$?
15074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15075 (exit $ac_status); } &&
15076 { ac_try='test -s conftest$ac_exeext'
15077 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15078 (eval $ac_try) 2>&5
15079 ac_status=$?
15080 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15081 (exit $ac_status); }; }; then
15082 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015083else
Martin v. Löwis11437992002-04-12 09:54:03 +000015084 echo "$as_me: failed program was:" >&5
15085cat conftest.$ac_ext >&5
15086ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015087fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015088rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015089fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015090echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
15091echo "${ECHO_T}$ac_cv_func___fpu_control" >&6
15092if test $ac_cv_func___fpu_control = yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015093 :
15094else
Martin v. Löwis11437992002-04-12 09:54:03 +000015095
15096echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
15097echo $ECHO_N "checking for __fpu_control in -lieee... $ECHO_C" >&6
15098if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
15099 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015100else
Martin v. Löwis11437992002-04-12 09:54:03 +000015101 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015102LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015103cat >conftest.$ac_ext <<_ACEOF
15104#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000015105#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015106
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015107/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015108#ifdef __cplusplus
15109extern "C"
15110#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015111/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015112 builtin and then its argument prototype would still apply. */
15113char __fpu_control ();
15114#ifdef F77_DUMMY_MAIN
15115# ifdef __cplusplus
15116 extern "C"
15117# endif
15118 int F77_DUMMY_MAIN() { return 1; }
15119#endif
15120int
15121main ()
15122{
15123__fpu_control ();
15124 ;
15125 return 0;
15126}
15127_ACEOF
15128rm -f conftest.$ac_objext conftest$ac_exeext
15129if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15130 (eval $ac_link) 2>&5
15131 ac_status=$?
15132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15133 (exit $ac_status); } &&
15134 { ac_try='test -s conftest$ac_exeext'
15135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15136 (eval $ac_try) 2>&5
15137 ac_status=$?
15138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15139 (exit $ac_status); }; }; then
15140 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000015141else
Martin v. Löwis11437992002-04-12 09:54:03 +000015142 echo "$as_me: failed program was:" >&5
15143cat conftest.$ac_ext >&5
15144ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015145fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015146rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15147LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015148fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015149echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
15150echo "${ECHO_T}$ac_cv_lib_ieee___fpu_control" >&6
15151if test $ac_cv_lib_ieee___fpu_control = yes; then
15152 cat >>confdefs.h <<_ACEOF
15153#define HAVE_LIBIEEE 1
15154_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015155
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015156 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015157
Guido van Rossum627b2d71993-12-24 10:39:16 +000015158fi
15159
Michael W. Hudson54241132001-12-07 15:38:26 +000015160
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015161fi
15162
Michael W. Hudson54241132001-12-07 15:38:26 +000015163
Guido van Rossum7f253911997-05-09 02:42:48 +000015164# Check for --with-fpectl
Martin v. Löwis11437992002-04-12 09:54:03 +000015165echo "$as_me:$LINENO: checking for --with-fpectl" >&5
15166echo $ECHO_N "checking for --with-fpectl... $ECHO_C" >&6
15167
Guido van Rossum7f253911997-05-09 02:42:48 +000015168# Check whether --with-fpectl or --without-fpectl was given.
15169if test "${with_fpectl+set}" = set; then
15170 withval="$with_fpectl"
Martin v. Löwis11437992002-04-12 09:54:03 +000015171
Guido van Rossum7f253911997-05-09 02:42:48 +000015172if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000015173then
15174
15175cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000015176#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015177_ACEOF
15178
15179 echo "$as_me:$LINENO: result: yes" >&5
15180echo "${ECHO_T}yes" >&6
15181else echo "$as_me:$LINENO: result: no" >&5
15182echo "${ECHO_T}no" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015183fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015184else
Martin v. Löwis11437992002-04-12 09:54:03 +000015185 echo "$as_me:$LINENO: result: no" >&5
15186echo "${ECHO_T}no" >&6
15187fi;
Guido van Rossum7f253911997-05-09 02:42:48 +000015188
Guido van Rossum7f43da71994-08-01 12:15:30 +000015189# check for --with-libm=...
15190
Guido van Rossum563e7081996-09-10 18:20:48 +000015191case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000015192Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015193BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000015194*) LIBM=-lm
15195esac
Martin v. Löwis11437992002-04-12 09:54:03 +000015196echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
15197echo $ECHO_N "checking for --with-libm=STRING... $ECHO_C" >&6
15198
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015199# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015200if test "${with_libm+set}" = set; then
15201 withval="$with_libm"
Martin v. Löwis11437992002-04-12 09:54:03 +000015202
Guido van Rossum7f253911997-05-09 02:42:48 +000015203if test "$withval" = no
15204then LIBM=
Martin v. Löwis11437992002-04-12 09:54:03 +000015205 echo "$as_me:$LINENO: result: force LIBM empty" >&5
15206echo "${ECHO_T}force LIBM empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015207elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000015208then LIBM=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000015209 echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
15210echo "${ECHO_T}set LIBM=\"$withval\"" >&6
15211else { { echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
15212echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
15213 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000015214fi
Guido van Rossum7f253911997-05-09 02:42:48 +000015215else
Martin v. Löwis11437992002-04-12 09:54:03 +000015216 echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
15217echo "${ECHO_T}default LIBM=\"$LIBM\"" >&6
15218fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000015219
15220# check for --with-libc=...
15221
Martin v. Löwis11437992002-04-12 09:54:03 +000015222echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
15223echo $ECHO_N "checking for --with-libc=STRING... $ECHO_C" >&6
15224
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015225# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015226if test "${with_libc+set}" = set; then
15227 withval="$with_libc"
Martin v. Löwis11437992002-04-12 09:54:03 +000015228
Guido van Rossum7f253911997-05-09 02:42:48 +000015229if test "$withval" = no
15230then LIBC=
Martin v. Löwis11437992002-04-12 09:54:03 +000015231 echo "$as_me:$LINENO: result: force LIBC empty" >&5
15232echo "${ECHO_T}force LIBC empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015233elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000015234then LIBC=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000015235 echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
15236echo "${ECHO_T}set LIBC=\"$withval\"" >&6
15237else { { echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
15238echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
15239 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000015240fi
Guido van Rossum7f253911997-05-09 02:42:48 +000015241else
Martin v. Löwis11437992002-04-12 09:54:03 +000015242 echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
15243echo "${ECHO_T}default LIBC=\"$LIBC\"" >&6
15244fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000015245
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015246# check for hypot() in math library
15247LIBS_SAVE=$LIBS
15248LIBS="$LIBS $LIBM"
Martin v. Löwis11437992002-04-12 09:54:03 +000015249
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015250for ac_func in hypot
15251do
Martin v. Löwis11437992002-04-12 09:54:03 +000015252as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15253echo "$as_me:$LINENO: checking for $ac_func" >&5
15254echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15255if eval "test \"\${$as_ac_var+set}\" = set"; then
15256 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015257else
Martin v. Löwis11437992002-04-12 09:54:03 +000015258 cat >conftest.$ac_ext <<_ACEOF
15259#line $LINENO "configure"
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015260#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015261/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000015262 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015263#include <assert.h>
15264/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015265#ifdef __cplusplus
15266extern "C"
15267#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015268/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015269 builtin and then its argument prototype would still apply. */
15270char $ac_func ();
15271char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015272
Martin v. Löwis11437992002-04-12 09:54:03 +000015273#ifdef F77_DUMMY_MAIN
15274# ifdef __cplusplus
15275 extern "C"
15276# endif
15277 int F77_DUMMY_MAIN() { return 1; }
15278#endif
15279int
15280main ()
15281{
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015282/* The GNU C library defines this for functions which it implements
15283 to always fail with ENOSYS. Some functions are actually named
15284 something starting with __ and the normal name is an alias. */
15285#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15286choke me
15287#else
Martin v. Löwis11437992002-04-12 09:54:03 +000015288f = $ac_func;
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015289#endif
15290
Martin v. Löwis11437992002-04-12 09:54:03 +000015291 ;
15292 return 0;
15293}
15294_ACEOF
15295rm -f conftest.$ac_objext conftest$ac_exeext
15296if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15297 (eval $ac_link) 2>&5
15298 ac_status=$?
15299 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15300 (exit $ac_status); } &&
15301 { ac_try='test -s conftest$ac_exeext'
15302 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15303 (eval $ac_try) 2>&5
15304 ac_status=$?
15305 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15306 (exit $ac_status); }; }; then
15307 eval "$as_ac_var=yes"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015308else
Martin v. Löwis11437992002-04-12 09:54:03 +000015309 echo "$as_me: failed program was:" >&5
15310cat conftest.$ac_ext >&5
15311eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000015312fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015313rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015314fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015315echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15316echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15317if test `eval echo '${'$as_ac_var'}'` = yes; then
15318 cat >>confdefs.h <<_ACEOF
15319#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15320_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000015321
Michael W. Hudson54241132001-12-07 15:38:26 +000015322else
Martin v. Löwis11437992002-04-12 09:54:03 +000015323 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015324fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015325done
15326
Michael W. Hudson54241132001-12-07 15:38:26 +000015327
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015328LIBS=$LIBS_SAVE
15329
Guido van Rossumef2255b2000-03-10 22:30:29 +000015330# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015331if test "${ac_cv_header_wchar_h+set}" = set; then
15332 echo "$as_me:$LINENO: checking for wchar.h" >&5
15333echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
15334if test "${ac_cv_header_wchar_h+set}" = set; then
15335 echo $ECHO_N "(cached) $ECHO_C" >&6
15336fi
15337echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
15338echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015339else
Martin v. Löwis11437992002-04-12 09:54:03 +000015340 # Is the header compilable?
15341echo "$as_me:$LINENO: checking wchar.h usability" >&5
15342echo $ECHO_N "checking wchar.h usability... $ECHO_C" >&6
15343cat >conftest.$ac_ext <<_ACEOF
15344#line $LINENO "configure"
15345#include "confdefs.h"
15346$ac_includes_default
15347#include <wchar.h>
15348_ACEOF
15349rm -f conftest.$ac_objext
15350if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15351 (eval $ac_compile) 2>&5
15352 ac_status=$?
15353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15354 (exit $ac_status); } &&
15355 { ac_try='test -s conftest.$ac_objext'
15356 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15357 (eval $ac_try) 2>&5
15358 ac_status=$?
15359 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15360 (exit $ac_status); }; }; then
15361 ac_header_compiler=yes
15362else
15363 echo "$as_me: failed program was:" >&5
15364cat conftest.$ac_ext >&5
15365ac_header_compiler=no
15366fi
15367rm -f conftest.$ac_objext conftest.$ac_ext
15368echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15369echo "${ECHO_T}$ac_header_compiler" >&6
15370
15371# Is the header present?
15372echo "$as_me:$LINENO: checking wchar.h presence" >&5
15373echo $ECHO_N "checking wchar.h presence... $ECHO_C" >&6
15374cat >conftest.$ac_ext <<_ACEOF
15375#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015376#include "confdefs.h"
15377#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015378_ACEOF
15379if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15380 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15381 ac_status=$?
15382 egrep -v '^ *\+' conftest.er1 >conftest.err
15383 rm -f conftest.er1
15384 cat conftest.err >&5
15385 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15386 (exit $ac_status); } >/dev/null; then
15387 if test -s conftest.err; then
15388 ac_cpp_err=$ac_c_preproc_warn_flag
15389 else
15390 ac_cpp_err=
15391 fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015392else
Martin v. Löwis11437992002-04-12 09:54:03 +000015393 ac_cpp_err=yes
15394fi
15395if test -z "$ac_cpp_err"; then
15396 ac_header_preproc=yes
15397else
15398 echo "$as_me: failed program was:" >&5
Guido van Rossumef2255b2000-03-10 22:30:29 +000015399 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015400 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015401fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015402rm -f conftest.err conftest.$ac_ext
15403echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15404echo "${ECHO_T}$ac_header_preproc" >&6
15405
15406# So? What about this header?
15407case $ac_header_compiler:$ac_header_preproc in
15408 yes:no )
15409 { echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
15410echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15411 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
15412echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
15413 no:yes )
15414 { echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
15415echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
15416 { echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
15417echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
15418 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
15419echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
15420esac
15421echo "$as_me:$LINENO: checking for wchar.h" >&5
15422echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
15423if test "${ac_cv_header_wchar_h+set}" = set; then
15424 echo $ECHO_N "(cached) $ECHO_C" >&6
15425else
15426 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000015427fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015428echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
15429echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
15430
15431fi
15432if test $ac_cv_header_wchar_h = yes; then
15433
15434
15435cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000015436#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015437_ACEOF
15438
Martin v. Löwisc45929e2002-04-06 10:10:49 +000015439 wchar_h="yes"
15440
Guido van Rossumef2255b2000-03-10 22:30:29 +000015441else
Martin v. Löwis11437992002-04-12 09:54:03 +000015442 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015443
15444fi
15445
Michael W. Hudson54241132001-12-07 15:38:26 +000015446
Martin v. Löwis11437992002-04-12 09:54:03 +000015447
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015448# determine wchar_t size
15449if test "$wchar_h" = yes
15450then
Martin v. Löwis11437992002-04-12 09:54:03 +000015451 echo "$as_me:$LINENO: checking for wchar_t" >&5
15452echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
15453if test "${ac_cv_type_wchar_t+set}" = set; then
15454 echo $ECHO_N "(cached) $ECHO_C" >&6
15455else
15456 cat >conftest.$ac_ext <<_ACEOF
15457#line $LINENO "configure"
15458#include "confdefs.h"
15459#include <wchar.h>
15460
15461#ifdef F77_DUMMY_MAIN
15462# ifdef __cplusplus
15463 extern "C"
15464# endif
15465 int F77_DUMMY_MAIN() { return 1; }
15466#endif
15467int
15468main ()
15469{
15470if ((wchar_t *) 0)
15471 return 0;
15472if (sizeof (wchar_t))
15473 return 0;
15474 ;
15475 return 0;
15476}
15477_ACEOF
15478rm -f conftest.$ac_objext
15479if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15480 (eval $ac_compile) 2>&5
15481 ac_status=$?
15482 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15483 (exit $ac_status); } &&
15484 { ac_try='test -s conftest.$ac_objext'
15485 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15486 (eval $ac_try) 2>&5
15487 ac_status=$?
15488 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15489 (exit $ac_status); }; }; then
15490 ac_cv_type_wchar_t=yes
15491else
15492 echo "$as_me: failed program was:" >&5
15493cat conftest.$ac_ext >&5
15494ac_cv_type_wchar_t=no
15495fi
15496rm -f conftest.$ac_objext conftest.$ac_ext
15497fi
15498echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
15499echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
15500
15501echo "$as_me:$LINENO: checking size of wchar_t" >&5
15502echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
15503if test "${ac_cv_sizeof_wchar_t+set}" = set; then
15504 echo $ECHO_N "(cached) $ECHO_C" >&6
15505else
15506 if test "$ac_cv_type_wchar_t" = yes; then
15507 # The cast to unsigned long works around a bug in the HP C Compiler
15508 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15509 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15510 # This bug is HP SR number 8606223364.
15511 if test "$cross_compiling" = yes; then
15512 # Depending upon the size, compute the lo and hi bounds.
15513cat >conftest.$ac_ext <<_ACEOF
15514#line $LINENO "configure"
15515#include "confdefs.h"
15516#include <wchar.h>
15517
15518#ifdef F77_DUMMY_MAIN
15519# ifdef __cplusplus
15520 extern "C"
15521# endif
15522 int F77_DUMMY_MAIN() { return 1; }
15523#endif
15524int
15525main ()
15526{
15527static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
15528test_array [0] = 0
15529
15530 ;
15531 return 0;
15532}
15533_ACEOF
15534rm -f conftest.$ac_objext
15535if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15536 (eval $ac_compile) 2>&5
15537 ac_status=$?
15538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15539 (exit $ac_status); } &&
15540 { ac_try='test -s conftest.$ac_objext'
15541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15542 (eval $ac_try) 2>&5
15543 ac_status=$?
15544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15545 (exit $ac_status); }; }; then
15546 ac_lo=0 ac_mid=0
15547 while :; do
15548 cat >conftest.$ac_ext <<_ACEOF
15549#line $LINENO "configure"
15550#include "confdefs.h"
15551#include <wchar.h>
15552
15553#ifdef F77_DUMMY_MAIN
15554# ifdef __cplusplus
15555 extern "C"
15556# endif
15557 int F77_DUMMY_MAIN() { return 1; }
15558#endif
15559int
15560main ()
15561{
15562static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15563test_array [0] = 0
15564
15565 ;
15566 return 0;
15567}
15568_ACEOF
15569rm -f conftest.$ac_objext
15570if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15571 (eval $ac_compile) 2>&5
15572 ac_status=$?
15573 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15574 (exit $ac_status); } &&
15575 { ac_try='test -s conftest.$ac_objext'
15576 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15577 (eval $ac_try) 2>&5
15578 ac_status=$?
15579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15580 (exit $ac_status); }; }; then
15581 ac_hi=$ac_mid; break
15582else
15583 echo "$as_me: failed program was:" >&5
15584cat conftest.$ac_ext >&5
15585ac_lo=`expr $ac_mid + 1`
15586 if test $ac_lo -le $ac_mid; then
15587 ac_lo= ac_hi=
15588 break
15589 fi
15590 ac_mid=`expr 2 '*' $ac_mid + 1`
15591fi
15592rm -f conftest.$ac_objext conftest.$ac_ext
15593 done
15594else
15595 echo "$as_me: failed program was:" >&5
15596cat conftest.$ac_ext >&5
15597cat >conftest.$ac_ext <<_ACEOF
15598#line $LINENO "configure"
15599#include "confdefs.h"
15600#include <wchar.h>
15601
15602#ifdef F77_DUMMY_MAIN
15603# ifdef __cplusplus
15604 extern "C"
15605# endif
15606 int F77_DUMMY_MAIN() { return 1; }
15607#endif
15608int
15609main ()
15610{
15611static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
15612test_array [0] = 0
15613
15614 ;
15615 return 0;
15616}
15617_ACEOF
15618rm -f conftest.$ac_objext
15619if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15620 (eval $ac_compile) 2>&5
15621 ac_status=$?
15622 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15623 (exit $ac_status); } &&
15624 { ac_try='test -s conftest.$ac_objext'
15625 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15626 (eval $ac_try) 2>&5
15627 ac_status=$?
15628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15629 (exit $ac_status); }; }; then
15630 ac_hi=-1 ac_mid=-1
15631 while :; do
15632 cat >conftest.$ac_ext <<_ACEOF
15633#line $LINENO "configure"
15634#include "confdefs.h"
15635#include <wchar.h>
15636
15637#ifdef F77_DUMMY_MAIN
15638# ifdef __cplusplus
15639 extern "C"
15640# endif
15641 int F77_DUMMY_MAIN() { return 1; }
15642#endif
15643int
15644main ()
15645{
15646static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
15647test_array [0] = 0
15648
15649 ;
15650 return 0;
15651}
15652_ACEOF
15653rm -f conftest.$ac_objext
15654if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15655 (eval $ac_compile) 2>&5
15656 ac_status=$?
15657 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15658 (exit $ac_status); } &&
15659 { ac_try='test -s conftest.$ac_objext'
15660 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15661 (eval $ac_try) 2>&5
15662 ac_status=$?
15663 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15664 (exit $ac_status); }; }; then
15665 ac_lo=$ac_mid; break
15666else
15667 echo "$as_me: failed program was:" >&5
15668cat conftest.$ac_ext >&5
15669ac_hi=`expr '(' $ac_mid ')' - 1`
15670 if test $ac_mid -le $ac_hi; then
15671 ac_lo= ac_hi=
15672 break
15673 fi
15674 ac_mid=`expr 2 '*' $ac_mid`
15675fi
15676rm -f conftest.$ac_objext conftest.$ac_ext
15677 done
15678else
15679 echo "$as_me: failed program was:" >&5
15680cat conftest.$ac_ext >&5
15681ac_lo= ac_hi=
15682fi
15683rm -f conftest.$ac_objext conftest.$ac_ext
15684fi
15685rm -f conftest.$ac_objext conftest.$ac_ext
15686# Binary search between lo and hi bounds.
15687while test "x$ac_lo" != "x$ac_hi"; do
15688 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15689 cat >conftest.$ac_ext <<_ACEOF
15690#line $LINENO "configure"
15691#include "confdefs.h"
15692#include <wchar.h>
15693
15694#ifdef F77_DUMMY_MAIN
15695# ifdef __cplusplus
15696 extern "C"
15697# endif
15698 int F77_DUMMY_MAIN() { return 1; }
15699#endif
15700int
15701main ()
15702{
15703static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15704test_array [0] = 0
15705
15706 ;
15707 return 0;
15708}
15709_ACEOF
15710rm -f conftest.$ac_objext
15711if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15712 (eval $ac_compile) 2>&5
15713 ac_status=$?
15714 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15715 (exit $ac_status); } &&
15716 { ac_try='test -s conftest.$ac_objext'
15717 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15718 (eval $ac_try) 2>&5
15719 ac_status=$?
15720 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15721 (exit $ac_status); }; }; then
15722 ac_hi=$ac_mid
15723else
15724 echo "$as_me: failed program was:" >&5
15725cat conftest.$ac_ext >&5
15726ac_lo=`expr '(' $ac_mid ')' + 1`
15727fi
15728rm -f conftest.$ac_objext conftest.$ac_ext
15729done
15730case $ac_lo in
15731?*) ac_cv_sizeof_wchar_t=$ac_lo;;
15732'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15733echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15734 { (exit 1); exit 1; }; } ;;
15735esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015736else
15737 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015738 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15739echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15740 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000015741else
Martin v. Löwis11437992002-04-12 09:54:03 +000015742 cat >conftest.$ac_ext <<_ACEOF
15743#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015744#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015745#include <wchar.h>
15746
15747long longval () { return (long) (sizeof (wchar_t)); }
15748unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000015749#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015750#include <stdlib.h>
15751#ifdef F77_DUMMY_MAIN
15752# ifdef __cplusplus
15753 extern "C"
15754# endif
15755 int F77_DUMMY_MAIN() { return 1; }
15756#endif
15757int
15758main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015759{
Martin v. Löwis11437992002-04-12 09:54:03 +000015760
15761 FILE *f = fopen ("conftest.val", "w");
15762 if (! f)
15763 exit (1);
15764 if (((long) (sizeof (wchar_t))) < 0)
15765 {
15766 long i = longval ();
15767 if (i != ((long) (sizeof (wchar_t))))
15768 exit (1);
15769 fprintf (f, "%ld\n", i);
15770 }
15771 else
15772 {
15773 unsigned long i = ulongval ();
15774 if (i != ((long) (sizeof (wchar_t))))
15775 exit (1);
15776 fprintf (f, "%lu\n", i);
15777 }
15778 exit (ferror (f) || fclose (f) != 0);
15779
15780 ;
15781 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000015782}
Martin v. Löwis11437992002-04-12 09:54:03 +000015783_ACEOF
15784rm -f conftest$ac_exeext
15785if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15786 (eval $ac_link) 2>&5
15787 ac_status=$?
15788 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15789 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15790 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15791 (eval $ac_try) 2>&5
15792 ac_status=$?
15793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15794 (exit $ac_status); }; }; then
15795 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000015796else
Martin v. Löwis11437992002-04-12 09:54:03 +000015797 echo "$as_me: program exited with status $ac_status" >&5
15798echo "$as_me: failed program was:" >&5
15799cat conftest.$ac_ext >&5
15800( exit $ac_status )
15801{ { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15802echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15803 { (exit 1); exit 1; }; }
15804fi
15805rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15806fi
15807fi
15808rm -f conftest.val
15809else
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015810 ac_cv_sizeof_wchar_t=0
Guido van Rossumef2255b2000-03-10 22:30:29 +000015811fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015812fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015813echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
15814echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
15815cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015816#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015817_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015818
Michael W. Hudson54241132001-12-07 15:38:26 +000015819
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015820fi
15821
Martin v. Löwis11437992002-04-12 09:54:03 +000015822echo "$as_me:$LINENO: checking what type to use for unicode" >&5
15823echo $ECHO_N "checking what type to use for unicode... $ECHO_C" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015824# Check whether --enable-unicode or --disable-unicode was given.
15825if test "${enable_unicode+set}" = set; then
15826 enableval="$enable_unicode"
Martin v. Löwis11437992002-04-12 09:54:03 +000015827
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015828else
15829 enable_unicode=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000015830fi;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015831
15832if test $enable_unicode = yes
15833then
Martin v. Löwisfd917792001-06-27 20:22:04 +000015834 # Without any arguments, Py_UNICODE defaults to two-byte mode
15835 enable_unicode="ucs2"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015836fi
15837
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015838
15839
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015840case "$enable_unicode" in
15841ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000015842 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015843#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000015844_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015845
15846 ;;
15847ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000015848 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015849#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000015850_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015851
15852 ;;
15853esac
15854
Michael W. Hudson54241132001-12-07 15:38:26 +000015855
Martin v. Löwis11437992002-04-12 09:54:03 +000015856
15857
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015858
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015859if test "$enable_unicode" = "no"
15860then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015861 UNICODE_OBJS=""
Martin v. Löwis11437992002-04-12 09:54:03 +000015862 echo "$as_me:$LINENO: result: not used" >&5
15863echo "${ECHO_T}not used" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015864else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015865 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000015866
15867cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015868#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015869_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015870
15871 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t"
15872 then
15873 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015874
Martin v. Löwis11437992002-04-12 09:54:03 +000015875cat >>confdefs.h <<\_ACEOF
15876#define HAVE_USABLE_WCHAR_T 1
15877_ACEOF
15878
15879 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015880#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015881_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015882
15883 elif test "$ac_cv_sizeof_short" = "$unicode_size"
15884 then
15885 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000015886 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015887#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000015888_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015889
15890 elif test "$ac_cv_sizeof_long" = "$unicode_size"
15891 then
15892 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000015893 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015894#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000015895_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015896
15897 else
15898 PY_UNICODE_TYPE="no type found"
15899 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015900 echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
15901echo "${ECHO_T}$PY_UNICODE_TYPE" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015902fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015903
15904# check for endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000015905echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
15906echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
15907if test "${ac_cv_c_bigendian+set}" = set; then
15908 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015909else
Martin v. Löwis11437992002-04-12 09:54:03 +000015910 # See if sys/param.h defines the BYTE_ORDER macro.
15911cat >conftest.$ac_ext <<_ACEOF
15912#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015913#include "confdefs.h"
15914#include <sys/types.h>
15915#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015916
Martin v. Löwis11437992002-04-12 09:54:03 +000015917#ifdef F77_DUMMY_MAIN
15918# ifdef __cplusplus
15919 extern "C"
15920# endif
15921 int F77_DUMMY_MAIN() { return 1; }
15922#endif
15923int
15924main ()
15925{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015926#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
15927 bogus endian macros
15928#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015929
15930 ;
15931 return 0;
15932}
15933_ACEOF
15934rm -f conftest.$ac_objext
15935if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15936 (eval $ac_compile) 2>&5
15937 ac_status=$?
15938 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15939 (exit $ac_status); } &&
15940 { ac_try='test -s conftest.$ac_objext'
15941 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15942 (eval $ac_try) 2>&5
15943 ac_status=$?
15944 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15945 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015946 # It does; now see whether it defined to BIG_ENDIAN or not.
Martin v. Löwis11437992002-04-12 09:54:03 +000015947cat >conftest.$ac_ext <<_ACEOF
15948#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015949#include "confdefs.h"
15950#include <sys/types.h>
15951#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015952
Martin v. Löwis11437992002-04-12 09:54:03 +000015953#ifdef F77_DUMMY_MAIN
15954# ifdef __cplusplus
15955 extern "C"
15956# endif
15957 int F77_DUMMY_MAIN() { return 1; }
15958#endif
15959int
15960main ()
15961{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015962#if BYTE_ORDER != BIG_ENDIAN
15963 not big endian
15964#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015965
15966 ;
15967 return 0;
15968}
15969_ACEOF
15970rm -f conftest.$ac_objext
15971if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15972 (eval $ac_compile) 2>&5
15973 ac_status=$?
15974 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15975 (exit $ac_status); } &&
15976 { ac_try='test -s conftest.$ac_objext'
15977 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15978 (eval $ac_try) 2>&5
15979 ac_status=$?
15980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15981 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015982 ac_cv_c_bigendian=yes
15983else
Martin v. Löwis11437992002-04-12 09:54:03 +000015984 echo "$as_me: failed program was:" >&5
15985cat conftest.$ac_ext >&5
15986ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015987fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015988rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000015989else
Martin v. Löwis11437992002-04-12 09:54:03 +000015990 echo "$as_me: failed program was:" >&5
15991cat conftest.$ac_ext >&5
15992# It does not; compile a test program.
Guido van Rossumef2255b2000-03-10 22:30:29 +000015993if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015994 # try to guess the endianess by grep'ing values into an object file
15995 ac_cv_c_bigendian=unknown
15996 cat >conftest.$ac_ext <<_ACEOF
15997#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015998#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015999short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16000short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16001void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
16002short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16003short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16004void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
16005#ifdef F77_DUMMY_MAIN
16006# ifdef __cplusplus
16007 extern "C"
16008# endif
16009 int F77_DUMMY_MAIN() { return 1; }
16010#endif
16011int
16012main ()
16013{
16014 _ascii (); _ebcdic ();
16015 ;
16016 return 0;
16017}
16018_ACEOF
16019rm -f conftest.$ac_objext
16020if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16021 (eval $ac_compile) 2>&5
16022 ac_status=$?
16023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16024 (exit $ac_status); } &&
16025 { ac_try='test -s conftest.$ac_objext'
16026 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16027 (eval $ac_try) 2>&5
16028 ac_status=$?
16029 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16030 (exit $ac_status); }; }; then
16031 if fgrep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
16032 ac_cv_c_bigendian=yes
16033fi
16034if fgrep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16035 if test "$ac_cv_c_bigendian" = unknown; then
16036 ac_cv_c_bigendian=no
16037 else
16038 # finding both strings is unlikely to happen, but who knows?
16039 ac_cv_c_bigendian=unknown
16040 fi
16041fi
16042else
16043 echo "$as_me: failed program was:" >&5
16044cat conftest.$ac_ext >&5
16045fi
16046rm -f conftest.$ac_objext conftest.$ac_ext
16047else
16048 cat >conftest.$ac_ext <<_ACEOF
16049#line $LINENO "configure"
16050#include "confdefs.h"
16051int
16052main ()
16053{
Guido van Rossumef2255b2000-03-10 22:30:29 +000016054 /* Are we little or big endian? From Harbison&Steele. */
16055 union
16056 {
16057 long l;
16058 char c[sizeof (long)];
16059 } u;
16060 u.l = 1;
16061 exit (u.c[sizeof (long) - 1] == 1);
16062}
Martin v. Löwis11437992002-04-12 09:54:03 +000016063_ACEOF
16064rm -f conftest$ac_exeext
16065if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16066 (eval $ac_link) 2>&5
16067 ac_status=$?
16068 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16069 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16070 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16071 (eval $ac_try) 2>&5
16072 ac_status=$?
16073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16074 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000016075 ac_cv_c_bigendian=no
16076else
Martin v. Löwis11437992002-04-12 09:54:03 +000016077 echo "$as_me: program exited with status $ac_status" >&5
16078echo "$as_me: failed program was:" >&5
16079cat conftest.$ac_ext >&5
16080( exit $ac_status )
16081ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000016082fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016083rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000016084fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016085fi
16086rm -f conftest.$ac_objext conftest.$ac_ext
16087fi
16088echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
16089echo "${ECHO_T}$ac_cv_c_bigendian" >&6
16090case $ac_cv_c_bigendian in
16091 yes)
Jack Jansendd19cf82001-12-06 22:36:17 +000016092
Martin v. Löwis11437992002-04-12 09:54:03 +000016093cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000016094#define WORDS_BIGENDIAN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016095_ACEOF
16096 ;;
16097 no)
16098 ;;
16099 *)
16100 { { echo "$as_me:$LINENO: error: unknown endianess
16101presetting ac_cv_c_bigendian=no (or yes) will help" >&5
16102echo "$as_me: error: unknown endianess
16103presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
16104 { (exit 1); exit 1; }; } ;;
16105esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000016106
Michael W. Hudson54241132001-12-07 15:38:26 +000016107
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016108# Check whether right shifting a negative integer extends the sign bit
16109# or fills with zeros (like the Cray J90, according to Tim Peters).
Martin v. Löwis11437992002-04-12 09:54:03 +000016110echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
16111echo $ECHO_N "checking whether right shift extends the sign bit... $ECHO_C" >&6
16112if test "${ac_cv_rshift_extends_sign+set}" = set; then
16113 echo $ECHO_N "(cached) $ECHO_C" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000016114else
Martin v. Löwis11437992002-04-12 09:54:03 +000016115
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016116if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000016117 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016118else
Martin v. Löwis11437992002-04-12 09:54:03 +000016119 cat >conftest.$ac_ext <<_ACEOF
16120#line $LINENO "configure"
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016121#include "confdefs.h"
16122
16123int main()
16124{
Vladimir Marangozova6180282000-07-12 05:05:06 +000016125 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016126}
16127
Martin v. Löwis11437992002-04-12 09:54:03 +000016128_ACEOF
16129rm -f conftest$ac_exeext
16130if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16131 (eval $ac_link) 2>&5
16132 ac_status=$?
16133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16134 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16136 (eval $ac_try) 2>&5
16137 ac_status=$?
16138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16139 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000016140 ac_cv_rshift_extends_sign=yes
16141else
Martin v. Löwis11437992002-04-12 09:54:03 +000016142 echo "$as_me: program exited with status $ac_status" >&5
16143echo "$as_me: failed program was:" >&5
16144cat conftest.$ac_ext >&5
16145( exit $ac_status )
16146ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000016147fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016148rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16149fi
Vladimir Marangozova6180282000-07-12 05:05:06 +000016150fi
16151
Martin v. Löwis11437992002-04-12 09:54:03 +000016152echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
16153echo "${ECHO_T}$ac_cv_rshift_extends_sign" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000016154if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016155then
Martin v. Löwis11437992002-04-12 09:54:03 +000016156
16157cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016158#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016159_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016160
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016161fi
16162
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016163# check for getc_unlocked and related locking functions
Martin v. Löwis11437992002-04-12 09:54:03 +000016164echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
16165echo $ECHO_N "checking for getc_unlocked() and friends... $ECHO_C" >&6
16166if test "${ac_cv_have_getc_unlocked+set}" = set; then
16167 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016168else
Martin v. Löwis11437992002-04-12 09:54:03 +000016169
16170cat >conftest.$ac_ext <<_ACEOF
16171#line $LINENO "configure"
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016172#include "confdefs.h"
16173#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016174#ifdef F77_DUMMY_MAIN
16175# ifdef __cplusplus
16176 extern "C"
16177# endif
16178 int F77_DUMMY_MAIN() { return 1; }
16179#endif
16180int
16181main ()
16182{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016183
16184 FILE *f = fopen("/dev/null", "r");
16185 flockfile(f);
16186 getc_unlocked(f);
16187 funlockfile(f);
16188
Martin v. Löwis11437992002-04-12 09:54:03 +000016189 ;
16190 return 0;
16191}
16192_ACEOF
16193rm -f conftest.$ac_objext conftest$ac_exeext
16194if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16195 (eval $ac_link) 2>&5
16196 ac_status=$?
16197 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16198 (exit $ac_status); } &&
16199 { ac_try='test -s conftest$ac_exeext'
16200 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16201 (eval $ac_try) 2>&5
16202 ac_status=$?
16203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16204 (exit $ac_status); }; }; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016205 ac_cv_have_getc_unlocked=yes
16206else
Martin v. Löwis11437992002-04-12 09:54:03 +000016207 echo "$as_me: failed program was:" >&5
16208cat conftest.$ac_ext >&5
16209ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016210fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016211rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016212fi
16213
Martin v. Löwis11437992002-04-12 09:54:03 +000016214echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
16215echo "${ECHO_T}$ac_cv_have_getc_unlocked" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016216if test "$ac_cv_have_getc_unlocked" = yes
16217then
Martin v. Löwis11437992002-04-12 09:54:03 +000016218
16219cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016220#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016221_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016222
16223fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016224
Martin v. Löwis0daad592001-09-30 21:09:59 +000016225# check for readline 4.0
Martin v. Löwis11437992002-04-12 09:54:03 +000016226echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
16227echo $ECHO_N "checking for rl_pre_input_hook in -lreadline... $ECHO_C" >&6
16228if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
16229 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000016230else
Martin v. Löwis11437992002-04-12 09:54:03 +000016231 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum353ae582001-07-10 16:45:32 +000016232LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016233cat >conftest.$ac_ext <<_ACEOF
16234#line $LINENO "configure"
Guido van Rossum353ae582001-07-10 16:45:32 +000016235#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016236
Guido van Rossum353ae582001-07-10 16:45:32 +000016237/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016238#ifdef __cplusplus
16239extern "C"
16240#endif
Guido van Rossum353ae582001-07-10 16:45:32 +000016241/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016242 builtin and then its argument prototype would still apply. */
16243char rl_pre_input_hook ();
16244#ifdef F77_DUMMY_MAIN
16245# ifdef __cplusplus
16246 extern "C"
16247# endif
16248 int F77_DUMMY_MAIN() { return 1; }
16249#endif
16250int
16251main ()
16252{
16253rl_pre_input_hook ();
16254 ;
16255 return 0;
16256}
16257_ACEOF
16258rm -f conftest.$ac_objext conftest$ac_exeext
16259if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16260 (eval $ac_link) 2>&5
16261 ac_status=$?
16262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16263 (exit $ac_status); } &&
16264 { ac_try='test -s conftest$ac_exeext'
16265 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16266 (eval $ac_try) 2>&5
16267 ac_status=$?
16268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16269 (exit $ac_status); }; }; then
16270 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000016271else
Martin v. Löwis11437992002-04-12 09:54:03 +000016272 echo "$as_me: failed program was:" >&5
16273cat conftest.$ac_ext >&5
16274ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000016275fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016276rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16277LIBS=$ac_check_lib_save_LIBS
16278fi
16279echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
16280echo "${ECHO_T}$ac_cv_lib_readline_rl_pre_input_hook" >&6
16281if test $ac_cv_lib_readline_rl_pre_input_hook = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000016282
Martin v. Löwis11437992002-04-12 09:54:03 +000016283cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000016284#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016285_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000016286
Martin v. Löwis0daad592001-09-30 21:09:59 +000016287fi
16288
Michael W. Hudson54241132001-12-07 15:38:26 +000016289
Martin v. Löwis0daad592001-09-30 21:09:59 +000016290# check for readline 4.2
Martin v. Löwis11437992002-04-12 09:54:03 +000016291echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
16292echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6
16293if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
16294 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000016295else
Martin v. Löwis11437992002-04-12 09:54:03 +000016296 ac_check_lib_save_LIBS=$LIBS
Martin v. Löwis0daad592001-09-30 21:09:59 +000016297LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016298cat >conftest.$ac_ext <<_ACEOF
16299#line $LINENO "configure"
Martin v. Löwis0daad592001-09-30 21:09:59 +000016300#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016301
Martin v. Löwis0daad592001-09-30 21:09:59 +000016302/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016303#ifdef __cplusplus
16304extern "C"
16305#endif
Martin v. Löwis0daad592001-09-30 21:09:59 +000016306/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016307 builtin and then its argument prototype would still apply. */
16308char rl_completion_matches ();
16309#ifdef F77_DUMMY_MAIN
16310# ifdef __cplusplus
16311 extern "C"
16312# endif
16313 int F77_DUMMY_MAIN() { return 1; }
16314#endif
16315int
16316main ()
16317{
16318rl_completion_matches ();
16319 ;
16320 return 0;
16321}
16322_ACEOF
16323rm -f conftest.$ac_objext conftest$ac_exeext
16324if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16325 (eval $ac_link) 2>&5
16326 ac_status=$?
16327 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16328 (exit $ac_status); } &&
16329 { ac_try='test -s conftest$ac_exeext'
16330 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16331 (eval $ac_try) 2>&5
16332 ac_status=$?
16333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16334 (exit $ac_status); }; }; then
16335 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000016336else
Martin v. Löwis11437992002-04-12 09:54:03 +000016337 echo "$as_me: failed program was:" >&5
16338cat conftest.$ac_ext >&5
16339ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000016340fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016341rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16342LIBS=$ac_check_lib_save_LIBS
16343fi
16344echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
16345echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6
16346if test $ac_cv_lib_readline_rl_completion_matches = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000016347
Martin v. Löwis11437992002-04-12 09:54:03 +000016348cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000016349#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016350_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000016351
Guido van Rossum353ae582001-07-10 16:45:32 +000016352fi
16353
Jack Jansendd19cf82001-12-06 22:36:17 +000016354
Martin v. Löwis11437992002-04-12 09:54:03 +000016355echo "$as_me:$LINENO: checking for broken nice()" >&5
16356echo $ECHO_N "checking for broken nice()... $ECHO_C" >&6
16357if test "${ac_cv_broken_nice+set}" = set; then
16358 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000016359else
Martin v. Löwis11437992002-04-12 09:54:03 +000016360
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016361if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000016362 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016363else
Martin v. Löwis11437992002-04-12 09:54:03 +000016364 cat >conftest.$ac_ext <<_ACEOF
16365#line $LINENO "configure"
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016366#include "confdefs.h"
16367
16368int main()
16369{
16370 int val1 = nice(1);
16371 if (val1 != -1 && val1 == nice(2))
16372 exit(0);
16373 exit(1);
16374}
16375
Martin v. Löwis11437992002-04-12 09:54:03 +000016376_ACEOF
16377rm -f conftest$ac_exeext
16378if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16379 (eval $ac_link) 2>&5
16380 ac_status=$?
16381 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16382 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16383 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16384 (eval $ac_try) 2>&5
16385 ac_status=$?
16386 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16387 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016388 ac_cv_broken_nice=yes
16389else
Martin v. Löwis11437992002-04-12 09:54:03 +000016390 echo "$as_me: program exited with status $ac_status" >&5
16391echo "$as_me: failed program was:" >&5
16392cat conftest.$ac_ext >&5
16393( exit $ac_status )
16394ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016395fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016396rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16397fi
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016398fi
16399
Martin v. Löwis11437992002-04-12 09:54:03 +000016400echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
16401echo "${ECHO_T}$ac_cv_broken_nice" >&6
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016402if test "$ac_cv_broken_nice" = yes
16403then
Martin v. Löwis11437992002-04-12 09:54:03 +000016404
16405cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016406#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016407_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016408
16409fi
16410
Martin v. Löwis94717ed2002-09-09 14:24:16 +000016411# Look for subsecond timestamps in struct stat
16412echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
16413echo $ECHO_N "checking for tv_nsec in struct stat... $ECHO_C" >&6
16414if test "${ac_cv_stat_tv_nsec+set}" = set; then
16415 echo $ECHO_N "(cached) $ECHO_C" >&6
16416else
16417 cat >conftest.$ac_ext <<_ACEOF
16418#line $LINENO "configure"
16419#include "confdefs.h"
16420#include <sys/stat.h>
16421#ifdef F77_DUMMY_MAIN
16422# ifdef __cplusplus
16423 extern "C"
16424# endif
16425 int F77_DUMMY_MAIN() { return 1; }
16426#endif
16427int
16428main ()
16429{
16430
16431struct stat st;
16432st.st_mtim.tv_nsec = 1;
16433
16434 ;
16435 return 0;
16436}
16437_ACEOF
16438rm -f conftest.$ac_objext
16439if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16440 (eval $ac_compile) 2>&5
16441 ac_status=$?
16442 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16443 (exit $ac_status); } &&
16444 { ac_try='test -s conftest.$ac_objext'
16445 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16446 (eval $ac_try) 2>&5
16447 ac_status=$?
16448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16449 (exit $ac_status); }; }; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000016450 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000016451else
16452 echo "$as_me: failed program was:" >&5
16453cat conftest.$ac_ext >&5
16454ac_cv_stat_tv_nsec=no
16455fi
16456rm -f conftest.$ac_objext conftest.$ac_ext
16457fi
16458
16459echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
16460echo "${ECHO_T}$ac_cv_stat_tv_nsec" >&6
16461if test "$ac_cv_stat_tv_nsec" = yes
16462then
16463
16464cat >>confdefs.h <<\_ACEOF
16465#define HAVE_STAT_TV_NSEC 1
16466_ACEOF
16467
16468fi
16469
Jack Jansen666b1e72001-10-31 12:11:48 +000016470# On HP/UX 11.0, mvwdelch is a block with a return statement
Martin v. Löwis11437992002-04-12 09:54:03 +000016471echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
16472echo $ECHO_N "checking whether mvwdelch is an expression... $ECHO_C" >&6
16473if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
16474 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016475else
Martin v. Löwis11437992002-04-12 09:54:03 +000016476 cat >conftest.$ac_ext <<_ACEOF
16477#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000016478#include "confdefs.h"
16479#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016480#ifdef F77_DUMMY_MAIN
16481# ifdef __cplusplus
16482 extern "C"
16483# endif
16484 int F77_DUMMY_MAIN() { return 1; }
16485#endif
16486int
16487main ()
16488{
Jack Jansen666b1e72001-10-31 12:11:48 +000016489
16490 int rtn;
16491 rtn = mvwdelch(0,0,0);
16492
Martin v. Löwis11437992002-04-12 09:54:03 +000016493 ;
16494 return 0;
16495}
16496_ACEOF
16497rm -f conftest.$ac_objext
16498if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16499 (eval $ac_compile) 2>&5
16500 ac_status=$?
16501 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16502 (exit $ac_status); } &&
16503 { ac_try='test -s conftest.$ac_objext'
16504 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16505 (eval $ac_try) 2>&5
16506 ac_status=$?
16507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16508 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000016509 ac_cv_mvwdelch_is_expression=yes
16510else
Martin v. Löwis11437992002-04-12 09:54:03 +000016511 echo "$as_me: failed program was:" >&5
16512cat conftest.$ac_ext >&5
16513ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000016514fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016515rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000016516fi
16517
Martin v. Löwis11437992002-04-12 09:54:03 +000016518echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
16519echo "${ECHO_T}$ac_cv_mvwdelch_is_expression" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016520
16521if test "$ac_cv_mvwdelch_is_expression" = yes
16522then
Martin v. Löwis11437992002-04-12 09:54:03 +000016523
16524cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016525#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016526_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016527
16528fi
16529
Martin v. Löwis11437992002-04-12 09:54:03 +000016530echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
16531echo $ECHO_N "checking whether WINDOW has _flags... $ECHO_C" >&6
16532if test "${ac_cv_window_has_flags+set}" = set; then
16533 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016534else
Martin v. Löwis11437992002-04-12 09:54:03 +000016535 cat >conftest.$ac_ext <<_ACEOF
16536#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000016537#include "confdefs.h"
16538#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016539#ifdef F77_DUMMY_MAIN
16540# ifdef __cplusplus
16541 extern "C"
16542# endif
16543 int F77_DUMMY_MAIN() { return 1; }
16544#endif
16545int
16546main ()
16547{
Jack Jansen666b1e72001-10-31 12:11:48 +000016548
16549 WINDOW *w;
16550 w->_flags = 0;
16551
Martin v. Löwis11437992002-04-12 09:54:03 +000016552 ;
16553 return 0;
16554}
16555_ACEOF
16556rm -f conftest.$ac_objext
16557if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16558 (eval $ac_compile) 2>&5
16559 ac_status=$?
16560 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16561 (exit $ac_status); } &&
16562 { ac_try='test -s conftest.$ac_objext'
16563 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16564 (eval $ac_try) 2>&5
16565 ac_status=$?
16566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16567 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000016568 ac_cv_window_has_flags=yes
16569else
Martin v. Löwis11437992002-04-12 09:54:03 +000016570 echo "$as_me: failed program was:" >&5
16571cat conftest.$ac_ext >&5
16572ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000016573fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016574rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000016575fi
16576
Martin v. Löwis11437992002-04-12 09:54:03 +000016577echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
16578echo "${ECHO_T}$ac_cv_window_has_flags" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000016579
Jack Jansen666b1e72001-10-31 12:11:48 +000016580
16581if test "$ac_cv_window_has_flags" = yes
16582then
Martin v. Löwis11437992002-04-12 09:54:03 +000016583
16584cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016585#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016586_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016587
16588fi
16589
Martin v. Löwis11437992002-04-12 09:54:03 +000016590echo "$as_me:$LINENO: checking for socklen_t" >&5
16591echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
16592if test "${ac_cv_type_socklen_t+set}" = set; then
16593 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000016594else
Martin v. Löwis11437992002-04-12 09:54:03 +000016595 cat >conftest.$ac_ext <<_ACEOF
16596#line $LINENO "configure"
Guido van Rossum95713eb2000-05-18 20:53:31 +000016597#include "confdefs.h"
Martin v. Löwis01c04012002-11-11 14:58:44 +000016598
16599#ifdef HAVE_SYS_TYPES_H
16600#include <sys/types.h>
16601#endif
16602#ifdef HAVE_SYS_SOCKET_H
16603#include <sys/socket.h>
16604#endif
16605
16606
Martin v. Löwis11437992002-04-12 09:54:03 +000016607#ifdef F77_DUMMY_MAIN
16608# ifdef __cplusplus
16609 extern "C"
16610# endif
16611 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016612#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016613int
16614main ()
16615{
16616if ((socklen_t *) 0)
16617 return 0;
16618if (sizeof (socklen_t))
16619 return 0;
16620 ;
16621 return 0;
16622}
16623_ACEOF
16624rm -f conftest.$ac_objext
16625if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16626 (eval $ac_compile) 2>&5
16627 ac_status=$?
16628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16629 (exit $ac_status); } &&
16630 { ac_try='test -s conftest.$ac_objext'
16631 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16632 (eval $ac_try) 2>&5
16633 ac_status=$?
16634 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16635 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000016636 ac_cv_type_socklen_t=yes
Guido van Rossum95713eb2000-05-18 20:53:31 +000016637else
Martin v. Löwis11437992002-04-12 09:54:03 +000016638 echo "$as_me: failed program was:" >&5
16639cat conftest.$ac_ext >&5
16640ac_cv_type_socklen_t=no
Guido van Rossum95713eb2000-05-18 20:53:31 +000016641fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016642rm -f conftest.$ac_objext conftest.$ac_ext
16643fi
16644echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
16645echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
16646if test $ac_cv_type_socklen_t = yes; then
16647 :
16648else
Guido van Rossum95713eb2000-05-18 20:53:31 +000016649
Martin v. Löwis01c04012002-11-11 14:58:44 +000016650cat >>confdefs.h <<\_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016651#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000016652_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016653
16654fi
16655
Michael W. Hudson54241132001-12-07 15:38:26 +000016656
Michael W. Hudson54241132001-12-07 15:38:26 +000016657
16658
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000016659for h in `(cd $srcdir;echo Python/thread_*.h)`
16660do
16661 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
16662done
16663
Michael W. Hudson54241132001-12-07 15:38:26 +000016664
Jack Jansen0b06be72002-06-21 14:48:38 +000016665SRCDIRS="Parser Grammar Objects Python Modules Mac Mac/Python"
Martin v. Löwis11437992002-04-12 09:54:03 +000016666echo "$as_me:$LINENO: checking for build directories" >&5
16667echo $ECHO_N "checking for build directories... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016668for dir in $SRCDIRS; do
16669 if test ! -d $dir; then
16670 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000016671 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016672done
Martin v. Löwis11437992002-04-12 09:54:03 +000016673echo "$as_me:$LINENO: result: done" >&5
16674echo "${ECHO_T}done" >&6
Fred Drake036144d2000-10-26 17:09:35 +000016675
Guido van Rossum627b2d71993-12-24 10:39:16 +000016676# generate output files
Martin v. Löwis11437992002-04-12 09:54:03 +000016677ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config"
Martin v. Löwis88afe662002-10-26 13:47:44 +000016678
Martin v. Löwis11437992002-04-12 09:54:03 +000016679cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016680# This file is a shell script that caches the results of configure
16681# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000016682# scripts and configure runs, see configure's option --config-cache.
16683# It is not useful on other systems. If it contains results you don't
16684# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016685#
Martin v. Löwis11437992002-04-12 09:54:03 +000016686# config.status only pays attention to the cache file if you give it
16687# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016688#
Martin v. Löwis11437992002-04-12 09:54:03 +000016689# `ac_cv_env_foo' variables (set or unset) will be overriden when
16690# loading this file, other *unset* `ac_cv_foo' will be assigned the
16691# following values.
16692
16693_ACEOF
16694
Guido van Rossumf78abae1997-01-21 22:02:36 +000016695# The following way of writing the cache mishandles newlines in values,
16696# but we know of no workaround that is simple, portable, and efficient.
16697# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016698# Ultrix sh set writes to stderr and can't be redirected directly,
16699# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwis11437992002-04-12 09:54:03 +000016700{
16701 (set) 2>&1 |
16702 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16703 *ac_space=\ *)
16704 # `set' does not quote correctly, so add quotes (double-quote
16705 # substitution turns \\\\ into \\, and sed turns \\ into \).
16706 sed -n \
16707 "s/'/'\\\\''/g;
16708 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16709 ;;
16710 *)
16711 # `set' quotes correctly as required by POSIX, so do not add quotes.
16712 sed -n \
16713 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16714 ;;
16715 esac;
16716} |
16717 sed '
16718 t clear
16719 : clear
16720 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16721 t end
16722 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16723 : end' >>confcache
16724if cmp -s $cache_file confcache; then :; else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016725 if test -w $cache_file; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016726 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16727 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016728 else
16729 echo "not updating unwritable cache $cache_file"
16730 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016731fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016732rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000016733
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016734test "x$prefix" = xNONE && prefix=$ac_default_prefix
16735# Let make expand exec_prefix.
16736test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000016737
Martin v. Löwis11437992002-04-12 09:54:03 +000016738# VPATH may cause trouble with some makes, so we remove $(srcdir),
16739# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16740# trailing colons and then remove the whole line if VPATH becomes empty
16741# (actually we leave an empty line to preserve line numbers).
Guido van Rossum7f43da71994-08-01 12:15:30 +000016742if test "x$srcdir" = x.; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016743 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16744s/:*\$(srcdir):*/:/;
16745s/:*\${srcdir}:*/:/;
16746s/:*@srcdir@:*/:/;
16747s/^\([^=]*=[ ]*\):*/\1/;
16748s/:*$//;
16749s/^[^=]*=[ ]*$//;
16750}'
Guido van Rossum7f43da71994-08-01 12:15:30 +000016751fi
16752
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016753DEFS=-DHAVE_CONFIG_H
16754
Martin v. Löwis11437992002-04-12 09:54:03 +000016755
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016756: ${CONFIG_STATUS=./config.status}
Martin v. Löwis11437992002-04-12 09:54:03 +000016757ac_clean_files_save=$ac_clean_files
16758ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16759{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
16760echo "$as_me: creating $CONFIG_STATUS" >&6;}
16761cat >$CONFIG_STATUS <<_ACEOF
16762#! $SHELL
16763# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016764# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016765# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000016766# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016767
Martin v. Löwis11437992002-04-12 09:54:03 +000016768debug=false
16769SHELL=\${CONFIG_SHELL-$SHELL}
16770_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016771
Martin v. Löwis11437992002-04-12 09:54:03 +000016772cat >>$CONFIG_STATUS <<\_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016773
Martin v. Löwis11437992002-04-12 09:54:03 +000016774## --------------------- ##
16775## M4sh Initialization. ##
16776## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000016777
Martin v. Löwis11437992002-04-12 09:54:03 +000016778# Be Bourne compatible
16779if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16780 emulate sh
16781 NULLCMD=:
16782elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16783 set -o posix
Michael W. Hudson54241132001-12-07 15:38:26 +000016784fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016785
Martin v. Löwis11437992002-04-12 09:54:03 +000016786# NLS nuisances.
16787# Support unset when possible.
16788if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16789 as_unset=unset
16790else
16791 as_unset=false
16792fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016793
Martin v. Löwis11437992002-04-12 09:54:03 +000016794(set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
16795 { $as_unset LANG || test "${LANG+set}" != set; } ||
16796 { LANG=C; export LANG; }
16797(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
16798 { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
16799 { LC_ALL=C; export LC_ALL; }
16800(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
16801 { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
16802 { LC_TIME=C; export LC_TIME; }
16803(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
16804 { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
16805 { LC_CTYPE=C; export LC_CTYPE; }
16806(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
16807 { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
16808 { LANGUAGE=C; export LANGUAGE; }
16809(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
16810 { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
16811 { LC_COLLATE=C; export LC_COLLATE; }
16812(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
16813 { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
16814 { LC_NUMERIC=C; export LC_NUMERIC; }
16815(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
16816 { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
16817 { LC_MESSAGES=C; export LC_MESSAGES; }
16818
16819
16820# Name of the executable.
16821as_me=`(basename "$0") 2>/dev/null ||
16822$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16823 X"$0" : 'X\(//\)$' \| \
16824 X"$0" : 'X\(/\)$' \| \
16825 . : '\(.\)' 2>/dev/null ||
16826echo X/"$0" |
16827 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
16828 /^X\/\(\/\/\)$/{ s//\1/; q; }
16829 /^X\/\(\/\).*/{ s//\1/; q; }
16830 s/.*/./; q'`
16831
16832# PATH needs CR, and LINENO needs CR and PATH.
16833# Avoid depending upon Character Ranges.
16834as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16835as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16836as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16837as_cr_digits='0123456789'
16838as_cr_alnum=$as_cr_Letters$as_cr_digits
16839
16840# The user is always right.
16841if test "${PATH_SEPARATOR+set}" != set; then
16842 echo "#! /bin/sh" >conftest.sh
16843 echo "exit 0" >>conftest.sh
16844 chmod +x conftest.sh
16845 if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
16846 PATH_SEPARATOR=';'
16847 else
16848 PATH_SEPARATOR=:
16849 fi
16850 rm -f conftest.sh
16851fi
16852
16853
16854 as_lineno_1=$LINENO
16855 as_lineno_2=$LINENO
16856 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16857 test "x$as_lineno_1" != "x$as_lineno_2" &&
16858 test "x$as_lineno_3" = "x$as_lineno_2" || {
16859 # Find who we are. Look in the path if we contain no path at all
16860 # relative or not.
16861 case $0 in
16862 *[\\/]* ) as_myself=$0 ;;
16863 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16864for as_dir in $PATH
16865do
16866 IFS=$as_save_IFS
16867 test -z "$as_dir" && as_dir=.
16868 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16869done
16870
16871 ;;
16872 esac
16873 # We did not find ourselves, most probably we were run as `sh COMMAND'
16874 # in which case we are not to be found in the path.
16875 if test "x$as_myself" = x; then
16876 as_myself=$0
16877 fi
16878 if test ! -f "$as_myself"; then
16879 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
16880echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
16881 { (exit 1); exit 1; }; }
16882 fi
16883 case $CONFIG_SHELL in
16884 '')
16885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16886for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
16887do
16888 IFS=$as_save_IFS
16889 test -z "$as_dir" && as_dir=.
16890 for as_base in sh bash ksh sh5; do
16891 case $as_dir in
16892 /*)
16893 if ("$as_dir/$as_base" -c '
16894 as_lineno_1=$LINENO
16895 as_lineno_2=$LINENO
16896 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16897 test "x$as_lineno_1" != "x$as_lineno_2" &&
16898 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
16899 CONFIG_SHELL=$as_dir/$as_base
16900 export CONFIG_SHELL
16901 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
16902 fi;;
16903 esac
16904 done
16905done
16906;;
Jack Jansendd19cf82001-12-06 22:36:17 +000016907 esac
16908
Martin v. Löwis11437992002-04-12 09:54:03 +000016909 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
16910 # uniformly replaced by the line number. The first 'sed' inserts a
16911 # line-number line before each line; the second 'sed' does the real
16912 # work. The second script uses 'N' to pair each line-number line
16913 # with the numbered line, and appends trailing '-' during
16914 # substitution so that $LINENO is not a special case at line end.
16915 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
16916 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
16917 sed '=' <$as_myself |
16918 sed '
16919 N
16920 s,$,-,
16921 : loop
16922 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
16923 t loop
16924 s,-$,,
16925 s,^['$as_cr_digits']*\n,,
16926 ' >$as_me.lineno &&
16927 chmod +x $as_me.lineno ||
16928 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
16929echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
16930 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016931
Martin v. Löwis11437992002-04-12 09:54:03 +000016932 # Don't try to exec as it changes $[0], causing all sort of problems
16933 # (the dirname of $[0] is not the place where we might find the
16934 # original and so on. Autoconf is especially sensible to this).
16935 . ./$as_me.lineno
16936 # Exit status is that of the last command.
16937 exit
16938}
16939
16940
16941case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
16942 *c*,-n*) ECHO_N= ECHO_C='
16943' ECHO_T=' ' ;;
16944 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
16945 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
16946esac
16947
16948if expr a : '\(a\)' >/dev/null 2>&1; then
16949 as_expr=expr
16950else
16951 as_expr=false
16952fi
16953
16954rm -f conf$$ conf$$.exe conf$$.file
16955echo >conf$$.file
16956if ln -s conf$$.file conf$$ 2>/dev/null; then
16957 # We could just check for DJGPP; but this test a) works b) is more generic
16958 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16959 if test -f conf$$.exe; then
16960 # Don't use ln at all; we don't have any links
16961 as_ln_s='cp -p'
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016962 else
Martin v. Löwis11437992002-04-12 09:54:03 +000016963 as_ln_s='ln -s'
16964 fi
16965elif ln conf$$.file conf$$ 2>/dev/null; then
16966 as_ln_s=ln
16967else
16968 as_ln_s='cp -p'
16969fi
16970rm -f conf$$ conf$$.exe conf$$.file
16971
16972as_executable_p="test -f"
16973
16974# Sed expression to map a string onto a valid CPP name.
16975as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
16976
16977# Sed expression to map a string onto a valid variable name.
16978as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
16979
16980
16981# IFS
16982# We need space, tab and new line, in precisely that order.
16983as_nl='
16984'
16985IFS=" $as_nl"
16986
16987# CDPATH.
16988$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
16989
16990exec 6>&1
16991
16992# Open the log real soon, to keep \$[0] and so on meaningful, and to
16993# report actual input values of CONFIG_FILES etc. instead of their
16994# values after options handling. Logging --version etc. is OK.
16995exec 5>>config.log
16996{
16997 echo
16998 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16999## Running $as_me. ##
17000_ASBOX
17001} >&5
17002cat >&5 <<_CSEOF
17003
Martin v. Löwis88afe662002-10-26 13:47:44 +000017004This file was extended by python $as_me 2.3, which was
Martin v. Löwis11437992002-04-12 09:54:03 +000017005generated by GNU Autoconf 2.53. Invocation command line was
17006
17007 CONFIG_FILES = $CONFIG_FILES
17008 CONFIG_HEADERS = $CONFIG_HEADERS
17009 CONFIG_LINKS = $CONFIG_LINKS
17010 CONFIG_COMMANDS = $CONFIG_COMMANDS
17011 $ $0 $@
17012
17013_CSEOF
17014echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
17015echo >&5
17016_ACEOF
17017
17018# Files that config.status was made for.
17019if test -n "$ac_config_files"; then
17020 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
17021fi
17022
17023if test -n "$ac_config_headers"; then
17024 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
17025fi
17026
17027if test -n "$ac_config_links"; then
17028 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
17029fi
17030
17031if test -n "$ac_config_commands"; then
17032 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
17033fi
17034
17035cat >>$CONFIG_STATUS <<\_ACEOF
17036
17037ac_cs_usage="\
17038\`$as_me' instantiates files from templates according to the
17039current configuration.
17040
17041Usage: $0 [OPTIONS] [FILE]...
17042
17043 -h, --help print this help, then exit
17044 -V, --version print version number, then exit
17045 -d, --debug don't remove temporary files
17046 --recheck update $as_me by reconfiguring in the same conditions
17047 --file=FILE[:TEMPLATE]
17048 instantiate the configuration file FILE
17049 --header=FILE[:TEMPLATE]
17050 instantiate the configuration header FILE
17051
17052Configuration files:
17053$config_files
17054
17055Configuration headers:
17056$config_headers
17057
17058Report bugs to <bug-autoconf@gnu.org>."
17059_ACEOF
17060
17061cat >>$CONFIG_STATUS <<_ACEOF
17062ac_cs_version="\\
Martin v. Löwis88afe662002-10-26 13:47:44 +000017063python config.status 2.3
Martin v. Löwis11437992002-04-12 09:54:03 +000017064configured by $0, generated by GNU Autoconf 2.53,
17065 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
17066
17067Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
17068Free Software Foundation, Inc.
17069This config.status script is free software; the Free Software Foundation
17070gives unlimited permission to copy, distribute and modify it."
17071srcdir=$srcdir
17072INSTALL="$INSTALL"
17073_ACEOF
17074
17075cat >>$CONFIG_STATUS <<\_ACEOF
17076# If no file are specified by the user, then we need to provide default
17077# value. By we need to know if files were specified by the user.
17078ac_need_defaults=:
17079while test $# != 0
17080do
17081 case $1 in
17082 --*=*)
17083 ac_option=`expr "x$1" : 'x\([^=]*\)='`
17084 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
17085 shift
17086 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
17087 shift
17088 ;;
17089 -*);;
17090 *) # This is not an option, so the user has probably given explicit
17091 # arguments.
17092 ac_need_defaults=false;;
17093 esac
17094
17095 case $1 in
17096 # Handling of the options.
17097_ACEOF
17098cat >>$CONFIG_STATUS <<_ACEOF
17099 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
17100 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
17101 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
17102_ACEOF
17103cat >>$CONFIG_STATUS <<\_ACEOF
17104 --version | --vers* | -V )
17105 echo "$ac_cs_version"; exit 0 ;;
17106 --he | --h)
17107 # Conflict between --help and --header
17108 { { echo "$as_me:$LINENO: error: ambiguous option: $1
17109Try \`$0 --help' for more information." >&5
17110echo "$as_me: error: ambiguous option: $1
17111Try \`$0 --help' for more information." >&2;}
17112 { (exit 1); exit 1; }; };;
17113 --help | --hel | -h )
17114 echo "$ac_cs_usage"; exit 0 ;;
17115 --debug | --d* | -d )
17116 debug=: ;;
17117 --file | --fil | --fi | --f )
17118 shift
17119 CONFIG_FILES="$CONFIG_FILES $1"
17120 ac_need_defaults=false;;
17121 --header | --heade | --head | --hea )
17122 shift
17123 CONFIG_HEADERS="$CONFIG_HEADERS $1"
17124 ac_need_defaults=false;;
17125
17126 # This is an error.
17127 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
17128Try \`$0 --help' for more information." >&5
17129echo "$as_me: error: unrecognized option: $1
17130Try \`$0 --help' for more information." >&2;}
17131 { (exit 1); exit 1; }; } ;;
17132
17133 *) ac_config_targets="$ac_config_targets $1" ;;
17134
17135 esac
17136 shift
17137done
17138
17139_ACEOF
17140
17141
17142
17143
17144
17145cat >>$CONFIG_STATUS <<\_ACEOF
17146for ac_config_target in $ac_config_targets
17147do
17148 case "$ac_config_target" in
17149 # Handling of arguments.
17150 "Makefile.pre" ) CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
17151 "Modules/Setup.config" ) CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
17152 "pyconfig.h" ) CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
17153 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
17154echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
17155 { (exit 1); exit 1; }; };;
17156 esac
17157done
17158
17159# If the user did not use the arguments to specify the items to instantiate,
17160# then the envvar interface is used. Set only those that are not.
17161# We use the long form for the default assignment because of an extremely
17162# bizarre bug on SunOS 4.1.3.
17163if $ac_need_defaults; then
17164 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
17165 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
17166fi
17167
17168# Create a temporary directory, and hook for its removal unless debugging.
17169$debug ||
17170{
17171 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
17172 trap '{ (exit 1); exit 1; }' 1 2 13 15
17173}
17174
17175# Create a (secure) tmp directory for tmp files.
17176: ${TMPDIR=/tmp}
17177{
17178 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
17179 test -n "$tmp" && test -d "$tmp"
17180} ||
17181{
17182 tmp=$TMPDIR/cs$$-$RANDOM
17183 (umask 077 && mkdir $tmp)
17184} ||
17185{
17186 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
17187 { (exit 1); exit 1; }
17188}
17189
17190_ACEOF
17191
17192cat >>$CONFIG_STATUS <<_ACEOF
17193
17194#
17195# CONFIG_FILES section.
17196#
17197
17198# No need to generate the scripts if there are no CONFIG_FILES.
17199# This happens for instance when ./config.status config.h
17200if test -n "\$CONFIG_FILES"; then
17201 # Protect against being on the right side of a sed subst in config.status.
17202 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
17203 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
17204s,@SHELL@,$SHELL,;t t
17205s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
17206s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
17207s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
17208s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
17209s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
17210s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
17211s,@exec_prefix@,$exec_prefix,;t t
17212s,@prefix@,$prefix,;t t
17213s,@program_transform_name@,$program_transform_name,;t t
17214s,@bindir@,$bindir,;t t
17215s,@sbindir@,$sbindir,;t t
17216s,@libexecdir@,$libexecdir,;t t
17217s,@datadir@,$datadir,;t t
17218s,@sysconfdir@,$sysconfdir,;t t
17219s,@sharedstatedir@,$sharedstatedir,;t t
17220s,@localstatedir@,$localstatedir,;t t
17221s,@libdir@,$libdir,;t t
17222s,@includedir@,$includedir,;t t
17223s,@oldincludedir@,$oldincludedir,;t t
17224s,@infodir@,$infodir,;t t
17225s,@mandir@,$mandir,;t t
17226s,@build_alias@,$build_alias,;t t
17227s,@host_alias@,$host_alias,;t t
17228s,@target_alias@,$target_alias,;t t
17229s,@DEFS@,$DEFS,;t t
17230s,@ECHO_C@,$ECHO_C,;t t
17231s,@ECHO_N@,$ECHO_N,;t t
17232s,@ECHO_T@,$ECHO_T,;t t
17233s,@LIBS@,$LIBS,;t t
17234s,@VERSION@,$VERSION,;t t
17235s,@SOVERSION@,$SOVERSION,;t t
17236s,@CONFIG_ARGS@,$CONFIG_ARGS,;t t
17237s,@PYTHONFRAMEWORK@,$PYTHONFRAMEWORK,;t t
17238s,@PYTHONFRAMEWORKDIR@,$PYTHONFRAMEWORKDIR,;t t
17239s,@PYTHONFRAMEWORKPREFIX@,$PYTHONFRAMEWORKPREFIX,;t t
17240s,@PYTHONFRAMEWORKINSTALLDIR@,$PYTHONFRAMEWORKINSTALLDIR,;t t
17241s,@MACHDEP@,$MACHDEP,;t t
17242s,@SGI_ABI@,$SGI_ABI,;t t
17243s,@CXX@,$CXX,;t t
17244s,@MAINOBJ@,$MAINOBJ,;t t
17245s,@EXEEXT@,$EXEEXT,;t t
17246s,@CC@,$CC,;t t
17247s,@CFLAGS@,$CFLAGS,;t t
17248s,@LDFLAGS@,$LDFLAGS,;t t
17249s,@CPPFLAGS@,$CPPFLAGS,;t t
17250s,@ac_ct_CC@,$ac_ct_CC,;t t
17251s,@OBJEXT@,$OBJEXT,;t t
17252s,@CPP@,$CPP,;t t
17253s,@BUILDEXEEXT@,$BUILDEXEEXT,;t t
17254s,@LIBRARY@,$LIBRARY,;t t
17255s,@LDLIBRARY@,$LDLIBRARY,;t t
17256s,@DLLLIBRARY@,$DLLLIBRARY,;t t
17257s,@BLDLIBRARY@,$BLDLIBRARY,;t t
17258s,@LDLIBRARYDIR@,$LDLIBRARYDIR,;t t
17259s,@INSTSONAME@,$INSTSONAME,;t t
17260s,@RUNSHARED@,$RUNSHARED,;t t
17261s,@LINKCC@,$LINKCC,;t t
17262s,@RANLIB@,$RANLIB,;t t
17263s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
17264s,@AR@,$AR,;t t
17265s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
17266s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
17267s,@INSTALL_DATA@,$INSTALL_DATA,;t t
17268s,@LN@,$LN,;t t
17269s,@OPT@,$OPT,;t t
17270s,@LIBTOOL_CRUFT@,$LIBTOOL_CRUFT,;t t
17271s,@SO@,$SO,;t t
17272s,@LDSHARED@,$LDSHARED,;t t
17273s,@BLDSHARED@,$BLDSHARED,;t t
17274s,@CCSHARED@,$CCSHARED,;t t
17275s,@LINKFORSHARED@,$LINKFORSHARED,;t t
17276s,@CFLAGSFORSHARED@,$CFLAGSFORSHARED,;t t
Martin v. Löwisf90ae202002-06-11 06:22:31 +000017277s,@SHLIBS@,$SHLIBS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000017278s,@USE_SIGNAL_MODULE@,$USE_SIGNAL_MODULE,;t t
17279s,@SIGNAL_OBJS@,$SIGNAL_OBJS,;t t
17280s,@USE_THREAD_MODULE@,$USE_THREAD_MODULE,;t t
17281s,@LDLAST@,$LDLAST,;t t
17282s,@THREADOBJ@,$THREADOBJ,;t t
17283s,@DLINCLDIR@,$DLINCLDIR,;t t
17284s,@DYNLOADFILE@,$DYNLOADFILE,;t t
17285s,@MACHDEP_OBJS@,$MACHDEP_OBJS,;t t
17286s,@LIBOBJS@,$LIBOBJS,;t t
17287s,@HAVE_GETHOSTBYNAME_R_6_ARG@,$HAVE_GETHOSTBYNAME_R_6_ARG,;t t
17288s,@HAVE_GETHOSTBYNAME_R_5_ARG@,$HAVE_GETHOSTBYNAME_R_5_ARG,;t t
17289s,@HAVE_GETHOSTBYNAME_R_3_ARG@,$HAVE_GETHOSTBYNAME_R_3_ARG,;t t
17290s,@HAVE_GETHOSTBYNAME_R@,$HAVE_GETHOSTBYNAME_R,;t t
17291s,@HAVE_GETHOSTBYNAME@,$HAVE_GETHOSTBYNAME,;t t
17292s,@LIBM@,$LIBM,;t t
17293s,@LIBC@,$LIBC,;t t
17294s,@UNICODE_OBJS@,$UNICODE_OBJS,;t t
17295s,@THREADHEADERS@,$THREADHEADERS,;t t
17296s,@SRCDIRS@,$SRCDIRS,;t t
17297CEOF
17298
17299_ACEOF
17300
17301 cat >>$CONFIG_STATUS <<\_ACEOF
17302 # Split the substitutions into bite-sized pieces for seds with
17303 # small command number limits, like on Digital OSF/1 and HP-UX.
17304 ac_max_sed_lines=48
17305 ac_sed_frag=1 # Number of current file.
17306 ac_beg=1 # First line for current file.
17307 ac_end=$ac_max_sed_lines # Line after last line for current file.
17308 ac_more_lines=:
17309 ac_sed_cmds=
17310 while $ac_more_lines; do
17311 if test $ac_beg -gt 1; then
17312 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17313 else
17314 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17315 fi
17316 if test ! -s $tmp/subs.frag; then
17317 ac_more_lines=false
17318 else
17319 # The purpose of the label and of the branching condition is to
17320 # speed up the sed processing (if there are no `@' at all, there
17321 # is no need to browse any of the substitutions).
17322 # These are the two extra sed commands mentioned above.
17323 (echo ':t
17324 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
17325 if test -z "$ac_sed_cmds"; then
17326 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
17327 else
17328 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
17329 fi
17330 ac_sed_frag=`expr $ac_sed_frag + 1`
17331 ac_beg=$ac_end
17332 ac_end=`expr $ac_end + $ac_max_sed_lines`
17333 fi
17334 done
17335 if test -z "$ac_sed_cmds"; then
17336 ac_sed_cmds=cat
17337 fi
17338fi # test -n "$CONFIG_FILES"
17339
17340_ACEOF
17341cat >>$CONFIG_STATUS <<\_ACEOF
17342for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
17343 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17344 case $ac_file in
17345 - | *:- | *:-:* ) # input from stdin
17346 cat >$tmp/stdin
17347 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17348 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17349 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17350 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17351 * ) ac_file_in=$ac_file.in ;;
17352 esac
17353
17354 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
17355 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17356$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17357 X"$ac_file" : 'X\(//\)[^/]' \| \
17358 X"$ac_file" : 'X\(//\)$' \| \
17359 X"$ac_file" : 'X\(/\)' \| \
17360 . : '\(.\)' 2>/dev/null ||
17361echo X"$ac_file" |
17362 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17363 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17364 /^X\(\/\/\)$/{ s//\1/; q; }
17365 /^X\(\/\).*/{ s//\1/; q; }
17366 s/.*/./; q'`
17367 { case "$ac_dir" in
17368 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17369 *) as_incr_dir=.;;
17370esac
17371as_dummy="$ac_dir"
17372for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17373 case $as_mkdir_dir in
17374 # Skip DOS drivespec
17375 ?:) as_incr_dir=$as_mkdir_dir ;;
17376 *)
17377 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17378 test -d "$as_incr_dir" ||
17379 mkdir "$as_incr_dir" ||
17380 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17381echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17382 { (exit 1); exit 1; }; }
17383 ;;
17384 esac
17385done; }
17386
17387 ac_builddir=.
17388
17389if test "$ac_dir" != .; then
17390 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
17391 # A "../" for each directory in $ac_dir_suffix.
17392 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
17393else
17394 ac_dir_suffix= ac_top_builddir=
17395fi
17396
17397case $srcdir in
17398 .) # No --srcdir option. We are building in place.
17399 ac_srcdir=.
17400 if test -z "$ac_top_builddir"; then
17401 ac_top_srcdir=.
17402 else
17403 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
17404 fi ;;
17405 [\\/]* | ?:[\\/]* ) # Absolute path.
17406 ac_srcdir=$srcdir$ac_dir_suffix;
17407 ac_top_srcdir=$srcdir ;;
17408 *) # Relative path.
17409 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
17410 ac_top_srcdir=$ac_top_builddir$srcdir ;;
17411esac
17412# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
17413# absolute.
17414ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwise3271202002-11-07 07:42:30 +000017415ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +000017416ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
17417ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
17418
17419
17420 case $INSTALL in
17421 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17422 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
17423 esac
17424
17425 if test x"$ac_file" != x-; then
17426 { echo "$as_me:$LINENO: creating $ac_file" >&5
17427echo "$as_me: creating $ac_file" >&6;}
17428 rm -f "$ac_file"
17429 fi
17430 # Let's still pretend it is `configure' which instantiates (i.e., don't
17431 # use $as_me), people would be surprised to read:
17432 # /* config.h. Generated by config.status. */
17433 if test x"$ac_file" = x-; then
17434 configure_input=
17435 else
17436 configure_input="$ac_file. "
17437 fi
17438 configure_input=$configure_input"Generated from `echo $ac_file_in |
17439 sed 's,.*/,,'` by configure."
17440
17441 # First look for the input files in the build tree, otherwise in the
17442 # src tree.
17443 ac_file_inputs=`IFS=:
17444 for f in $ac_file_in; do
17445 case $f in
17446 -) echo $tmp/stdin ;;
17447 [\\/$]*)
17448 # Absolute (can't be DOS-style, as IFS=:)
17449 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17450echo "$as_me: error: cannot find input file: $f" >&2;}
17451 { (exit 1); exit 1; }; }
17452 echo $f;;
17453 *) # Relative
17454 if test -f "$f"; then
17455 # Build tree
17456 echo $f
17457 elif test -f "$srcdir/$f"; then
17458 # Source tree
17459 echo $srcdir/$f
17460 else
17461 # /dev/null tree
17462 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17463echo "$as_me: error: cannot find input file: $f" >&2;}
17464 { (exit 1); exit 1; }; }
17465 fi;;
17466 esac
17467 done` || { (exit 1); exit 1; }
17468_ACEOF
17469cat >>$CONFIG_STATUS <<_ACEOF
17470 sed "$ac_vpsub
17471$extrasub
17472_ACEOF
17473cat >>$CONFIG_STATUS <<\_ACEOF
17474:t
17475/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17476s,@configure_input@,$configure_input,;t t
17477s,@srcdir@,$ac_srcdir,;t t
17478s,@abs_srcdir@,$ac_abs_srcdir,;t t
17479s,@top_srcdir@,$ac_top_srcdir,;t t
17480s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
17481s,@builddir@,$ac_builddir,;t t
17482s,@abs_builddir@,$ac_abs_builddir,;t t
17483s,@top_builddir@,$ac_top_builddir,;t t
17484s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
17485s,@INSTALL@,$ac_INSTALL,;t t
17486" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
17487 rm -f $tmp/stdin
17488 if test x"$ac_file" != x-; then
17489 mv $tmp/out $ac_file
17490 else
17491 cat $tmp/out
17492 rm -f $tmp/out
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017493 fi
17494
Martin v. Löwis11437992002-04-12 09:54:03 +000017495done
17496_ACEOF
17497cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017498
Martin v. Löwis11437992002-04-12 09:54:03 +000017499#
17500# CONFIG_HEADER section.
17501#
Guido van Rossum627b2d71993-12-24 10:39:16 +000017502
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017503# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
17504# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +000017505#
17506# ac_d sets the value in "#define NAME VALUE" lines.
Martin v. Löwis11437992002-04-12 09:54:03 +000017507ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
17508ac_dB='[ ].*$,\1#\2'
17509ac_dC=' '
17510ac_dD=',;t'
17511# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
17512ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17513ac_uB='$,\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +000017514ac_uC=' '
Martin v. Löwis11437992002-04-12 09:54:03 +000017515ac_uD=',;t'
Guido van Rossum7f43da71994-08-01 12:15:30 +000017516
Martin v. Löwis11437992002-04-12 09:54:03 +000017517for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
Guido van Rossumf78abae1997-01-21 22:02:36 +000017518 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Martin v. Löwis11437992002-04-12 09:54:03 +000017519 case $ac_file in
17520 - | *:- | *:-:* ) # input from stdin
17521 cat >$tmp/stdin
17522 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17523 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17524 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17525 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17526 * ) ac_file_in=$ac_file.in ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017527 esac
17528
Martin v. Löwis11437992002-04-12 09:54:03 +000017529 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
17530echo "$as_me: creating $ac_file" >&6;}
Guido van Rossum7f43da71994-08-01 12:15:30 +000017531
Martin v. Löwis11437992002-04-12 09:54:03 +000017532 # First look for the input files in the build tree, otherwise in the
17533 # src tree.
17534 ac_file_inputs=`IFS=:
17535 for f in $ac_file_in; do
17536 case $f in
17537 -) echo $tmp/stdin ;;
17538 [\\/$]*)
17539 # Absolute (can't be DOS-style, as IFS=:)
17540 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17541echo "$as_me: error: cannot find input file: $f" >&2;}
17542 { (exit 1); exit 1; }; }
17543 echo $f;;
17544 *) # Relative
17545 if test -f "$f"; then
17546 # Build tree
17547 echo $f
17548 elif test -f "$srcdir/$f"; then
17549 # Source tree
17550 echo $srcdir/$f
17551 else
17552 # /dev/null tree
17553 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17554echo "$as_me: error: cannot find input file: $f" >&2;}
17555 { (exit 1); exit 1; }; }
17556 fi;;
17557 esac
17558 done` || { (exit 1); exit 1; }
17559 # Remove the trailing spaces.
17560 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017561
Martin v. Löwis11437992002-04-12 09:54:03 +000017562_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017563
Martin v. Löwis11437992002-04-12 09:54:03 +000017564# Transform confdefs.h into two sed scripts, `conftest.defines' and
17565# `conftest.undefs', that substitutes the proper values into
17566# config.h.in to produce config.h. The first handles `#define'
17567# templates, and the second `#undef' templates.
17568# And first: Protect against being on the right side of a sed subst in
17569# config.status. Protect against being in an unquoted here document
17570# in config.status.
17571rm -f conftest.defines conftest.undefs
17572# Using a here document instead of a string reduces the quoting nightmare.
17573# Putting comments in sed scripts is not portable.
17574#
17575# `end' is used to avoid that the second main sed command (meant for
17576# 0-ary CPP macros) applies to n-ary macro definitions.
17577# See the Autoconf documentation for `clear'.
17578cat >confdef2sed.sed <<\_ACEOF
17579s/[\\&,]/\\&/g
17580s,[\\$`],\\&,g
17581t clear
17582: clear
17583s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
17584t end
17585s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
17586: end
17587_ACEOF
17588# If some macros were called several times there might be several times
17589# the same #defines, which is useless. Nevertheless, we may not want to
17590# sort them, since we want the *last* AC-DEFINE to be honored.
17591uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
17592sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
17593rm -f confdef2sed.sed
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017594
17595# This sed command replaces #undef with comments. This is necessary, for
17596# example, in the case of _POSIX_SOURCE, which is predefined and required
17597# on some systems where configure will not decide to define it.
Martin v. Löwis11437992002-04-12 09:54:03 +000017598cat >>conftest.undefs <<\_ACEOF
17599s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
17600_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017601
Martin v. Löwis11437992002-04-12 09:54:03 +000017602# Break up conftest.defines because some shells have a limit on the size
17603# of here documents, and old seds have small limits too (100 cmds).
17604echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
17605echo ' if egrep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
17606echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
17607echo ' :' >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017608rm -f conftest.tail
Martin v. Löwis11437992002-04-12 09:54:03 +000017609while grep . conftest.defines >/dev/null
Jack Jansendd19cf82001-12-06 22:36:17 +000017610do
Martin v. Löwis11437992002-04-12 09:54:03 +000017611 # Write a limited-size here document to $tmp/defines.sed.
17612 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
17613 # Speed up: don't consider the non `#define' lines.
17614 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
17615 # Work around the forget-to-reset-the-flag bug.
17616 echo 't clr' >>$CONFIG_STATUS
17617 echo ': clr' >>$CONFIG_STATUS
17618 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017619 echo 'CEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000017620 sed -f $tmp/defines.sed $tmp/in >$tmp/out
17621 rm -f $tmp/in
17622 mv $tmp/out $tmp/in
17623' >>$CONFIG_STATUS
17624 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
17625 rm -f conftest.defines
17626 mv conftest.tail conftest.defines
Jack Jansendd19cf82001-12-06 22:36:17 +000017627done
Martin v. Löwis11437992002-04-12 09:54:03 +000017628rm -f conftest.defines
17629echo ' fi # egrep' >>$CONFIG_STATUS
17630echo >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017631
Martin v. Löwis11437992002-04-12 09:54:03 +000017632# Break up conftest.undefs because some shells have a limit on the size
17633# of here documents, and old seds have small limits too (100 cmds).
17634echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
17635rm -f conftest.tail
17636while grep . conftest.undefs >/dev/null
17637do
17638 # Write a limited-size here document to $tmp/undefs.sed.
17639 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
17640 # Speed up: don't consider the non `#undef'
17641 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
17642 # Work around the forget-to-reset-the-flag bug.
17643 echo 't clr' >>$CONFIG_STATUS
17644 echo ': clr' >>$CONFIG_STATUS
17645 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
17646 echo 'CEOF
17647 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
17648 rm -f $tmp/in
17649 mv $tmp/out $tmp/in
17650' >>$CONFIG_STATUS
17651 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
17652 rm -f conftest.undefs
17653 mv conftest.tail conftest.undefs
17654done
17655rm -f conftest.undefs
17656
17657cat >>$CONFIG_STATUS <<\_ACEOF
17658 # Let's still pretend it is `configure' which instantiates (i.e., don't
17659 # use $as_me), people would be surprised to read:
17660 # /* config.h. Generated by config.status. */
17661 if test x"$ac_file" = x-; then
17662 echo "/* Generated by configure. */" >$tmp/config.h
Guido van Rossum7f43da71994-08-01 12:15:30 +000017663 else
Martin v. Löwis11437992002-04-12 09:54:03 +000017664 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
Jack Jansendd19cf82001-12-06 22:36:17 +000017665 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017666 cat $tmp/in >>$tmp/config.h
17667 rm -f $tmp/in
17668 if test x"$ac_file" != x-; then
17669 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17670 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
17671echo "$as_me: $ac_file is unchanged" >&6;}
17672 else
17673 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17674$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17675 X"$ac_file" : 'X\(//\)[^/]' \| \
17676 X"$ac_file" : 'X\(//\)$' \| \
17677 X"$ac_file" : 'X\(/\)' \| \
17678 . : '\(.\)' 2>/dev/null ||
17679echo X"$ac_file" |
17680 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17681 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17682 /^X\(\/\/\)$/{ s//\1/; q; }
17683 /^X\(\/\).*/{ s//\1/; q; }
17684 s/.*/./; q'`
17685 { case "$ac_dir" in
17686 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17687 *) as_incr_dir=.;;
17688esac
17689as_dummy="$ac_dir"
17690for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17691 case $as_mkdir_dir in
17692 # Skip DOS drivespec
17693 ?:) as_incr_dir=$as_mkdir_dir ;;
17694 *)
17695 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17696 test -d "$as_incr_dir" ||
17697 mkdir "$as_incr_dir" ||
17698 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17699echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17700 { (exit 1); exit 1; }; }
17701 ;;
17702 esac
17703done; }
Michael W. Hudson54241132001-12-07 15:38:26 +000017704
Martin v. Löwis11437992002-04-12 09:54:03 +000017705 rm -f $ac_file
17706 mv $tmp/config.h $ac_file
17707 fi
17708 else
17709 cat $tmp/config.h
17710 rm -f $tmp/config.h
17711 fi
17712done
17713_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000017714
Martin v. Löwis11437992002-04-12 09:54:03 +000017715cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000017716
Martin v. Löwis11437992002-04-12 09:54:03 +000017717{ (exit 0); exit 0; }
17718_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017719chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000017720ac_clean_files=$ac_clean_files_save
17721
17722
17723# configure is writing to config.log, and then calls config.status.
17724# config.status does its own redirection, appending to config.log.
17725# Unfortunately, on DOS this fails, as config.log is still kept open
17726# by configure, so config.status won't be able to write to it; its
17727# output is simply discarded. So we exec the FD to /dev/null,
17728# effectively closing config.log, so it can be properly (re)opened and
17729# appended to by config.status. When coming back to configure, we
17730# need to make the FD available again.
17731if test "$no_create" != yes; then
17732 ac_cs_success=:
17733 exec 5>/dev/null
17734 $SHELL $CONFIG_STATUS || ac_cs_success=false
17735 exec 5>>config.log
17736 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17737 # would make configure fail if this is the last instruction.
17738 $ac_cs_success || { (exit 1); exit 1; }
17739fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000017740
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000017741
17742echo "creating Setup"
17743if test ! -f Modules/Setup
17744then
17745 cp $srcdir/Modules/Setup.dist Modules/Setup
17746fi
17747
17748echo "creating Setup.local"
17749if test ! -f Modules/Setup.local
17750then
17751 echo "# Edit this file for local setup changes" >Modules/Setup.local
17752fi
17753
17754echo "creating Makefile"
17755$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
17756 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000017757 Modules/Setup.local Modules/Setup
Neil Schemenauerc761fc82001-02-19 04:50:49 +000017758mv config.c Modules