blob: e6c99dc7441702c1e4ae90f548b9eef8905cb7fe [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Martin v. Löwis82c19a72002-10-06 11:48:09 +00002# From configure.in Revision: 1.351 .
Guido van Rossum627b2d71993-12-24 10:39:16 +00003# Guess values for system-dependent variables and create Makefiles.
Martin v. Löwis11437992002-04-12 09:54:03 +00004# Generated by GNU Autoconf 2.53.
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.
256PACKAGE_NAME=
257PACKAGE_TARNAME=
258PACKAGE_VERSION=
259PACKAGE_STRING=
260PACKAGE_BUGREPORT=
261
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
764\`configure' configures this package to adapt to many kinds of systems.
765
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
820
821 cat <<\_ACEOF
822
823Optional Features:
824 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
825 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
826 --enable-framework=INSTALLDIR Build (MacOSX|Darwin) framework
827 --enable-shared disable/enable building shared python library
828 --enable-toolbox-glue disable/enable MacOSX glue code for extensions
829 --enable-ipv6 Enable ipv6 (with ipv4) support
830 --disable-ipv6 Disable ipv6 support
831 --enable-unicode=ucs2,ucs4 Enable Unicode strings (default is yes)
832
833Optional Packages:
834 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
835 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
836 --without-gcc never use gcc
837 --with-cxx=<compiler> enable C++ support
838 --with-suffix=.exe set executable suffix
839 --with-pydebug build with Py_DEBUG defined
840 --with-libs='lib1 ...' link against additional libs
841 --with-signal-module disable/enable signal module
842 --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries
843 --with(out)-threads=DIRECTORY disable/enable thread support
844 --with(out)-thread=DIRECTORY deprecated; use --with(out)-threads
845 --with-pth use GNU pth threading libraries
Jack Jansen7b8c7542002-04-14 20:12:41 +0000846 --with(out)-universal-newlines disable/enable foreign newlines
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +0000847 --with(out)-doc-strings disable/enable documentation strings
Martin v. Löwis11437992002-04-12 09:54:03 +0000848 --with(out)-pymalloc disable/enable specialized mallocs
849 --with-wctype-functions use wctype.h functions
850 --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking
851 --with-dl-dld=DL_DIR,DLD_DIR GNU dynamic linking
852 --with-fpectl enable SIGFPE catching
853 --with-libm=STRING math library
854 --with-libc=STRING C library
855
856Some influential environment variables:
857 CC C compiler command
858 CFLAGS C compiler flags
859 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
860 nonstandard directory <lib dir>
861 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
862 headers in a nonstandard directory <include dir>
863 CPP C preprocessor
864
865Use these variables to override the choices made by `configure' or to help
866it to find libraries and programs with nonstandard names/locations.
867
868_ACEOF
869fi
870
871if test "$ac_init_help" = "recursive"; then
872 # If there are subdirs, report their specific --help.
873 ac_popdir=`pwd`
874 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
875 test -d $ac_dir || continue
876 ac_builddir=.
877
878if test "$ac_dir" != .; then
879 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
880 # A "../" for each directory in $ac_dir_suffix.
881 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
882else
883 ac_dir_suffix= ac_top_builddir=
884fi
885
886case $srcdir in
887 .) # No --srcdir option. We are building in place.
888 ac_srcdir=.
889 if test -z "$ac_top_builddir"; then
890 ac_top_srcdir=.
891 else
892 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
893 fi ;;
894 [\\/]* | ?:[\\/]* ) # Absolute path.
895 ac_srcdir=$srcdir$ac_dir_suffix;
896 ac_top_srcdir=$srcdir ;;
897 *) # Relative path.
898 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
899 ac_top_srcdir=$ac_top_builddir$srcdir ;;
900esac
901# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
902# absolute.
903ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
904ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
905ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
906ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
907
908 cd $ac_dir
909 # Check for guested configure; otherwise get Cygnus style configure.
910 if test -f $ac_srcdir/configure.gnu; then
911 echo
912 $SHELL $ac_srcdir/configure.gnu --help=recursive
913 elif test -f $ac_srcdir/configure; then
914 echo
915 $SHELL $ac_srcdir/configure --help=recursive
916 elif test -f $ac_srcdir/configure.ac ||
917 test -f $ac_srcdir/configure.in; then
918 echo
919 $ac_configure --help
920 else
921 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
922 fi
923 cd $ac_popdir
924 done
925fi
926
927test -n "$ac_init_help" && exit 0
928if $ac_init_version; then
929 cat <<\_ACEOF
930
931Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
932Free Software Foundation, Inc.
933This configure script is free software; the Free Software Foundation
934gives unlimited permission to copy, distribute and modify it.
935_ACEOF
936 exit 0
937fi
938exec 5>config.log
939cat >&5 <<_ACEOF
940This file contains any messages produced by compilers while
941running configure, to aid debugging if configure makes a mistake.
942
943It was created by $as_me, which was
944generated by GNU Autoconf 2.53. Invocation command line was
945
946 $ $0 $@
947
948_ACEOF
949{
950cat <<_ASUNAME
951## --------- ##
952## Platform. ##
953## --------- ##
954
955hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
956uname -m = `(uname -m) 2>/dev/null || echo unknown`
957uname -r = `(uname -r) 2>/dev/null || echo unknown`
958uname -s = `(uname -s) 2>/dev/null || echo unknown`
959uname -v = `(uname -v) 2>/dev/null || echo unknown`
960
961/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
962/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
963
964/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
965/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
966/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
967hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
968/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
969/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
970/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
971
972_ASUNAME
973
974as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
975for as_dir in $PATH
976do
977 IFS=$as_save_IFS
978 test -z "$as_dir" && as_dir=.
979 echo "PATH: $as_dir"
980done
981
982} >&5
983
984cat >&5 <<_ACEOF
985
986
987## ----------- ##
988## Core tests. ##
989## ----------- ##
990
991_ACEOF
992
993
994# Keep a trace of the command line.
995# Strip out --no-create and --no-recursion so they do not pile up.
996# Also quote any args containing shell meta-characters.
997ac_configure_args=
998ac_sep=
999for ac_arg
1000do
1001 case $ac_arg in
1002 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1003 | --no-cr | --no-c | -n ) continue ;;
1004 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1005 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1006 continue ;;
1007 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1008 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1009 esac
1010 case " $ac_configure_args " in
1011 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1012 *) ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1013 ac_sep=" " ;;
1014 esac
1015 # Get rid of the leading space.
1016done
1017
1018# When interrupted or exit'd, cleanup temporary files, and complete
1019# config.log. We remove comments because anyway the quotes in there
1020# would cause problems or look ugly.
1021# WARNING: Be sure not to use single quotes in there, as some shells,
1022# such as our DU 5.0 friend, will then `close' the trap.
1023trap 'exit_status=$?
1024 # Save into config.log some information that might help in debugging.
1025 {
1026 echo
1027 cat <<\_ASBOX
1028## ---------------- ##
1029## Cache variables. ##
1030## ---------------- ##
1031_ASBOX
1032 echo
1033 # The following way of writing the cache mishandles newlines in values,
1034{
1035 (set) 2>&1 |
1036 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1037 *ac_space=\ *)
1038 sed -n \
1039 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1040 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1041 ;;
1042 *)
1043 sed -n \
1044 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1045 ;;
1046 esac;
1047}
1048 echo
1049 if test -s confdefs.h; then
1050 cat <<\_ASBOX
1051## ----------- ##
1052## confdefs.h. ##
1053## ----------- ##
1054_ASBOX
1055 echo
1056 sed "/^$/d" confdefs.h
1057 echo
1058 fi
1059 test "$ac_signal" != 0 &&
1060 echo "$as_me: caught signal $ac_signal"
1061 echo "$as_me: exit $exit_status"
1062 } >&5
1063 rm -f core core.* *.core &&
1064 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1065 exit $exit_status
1066 ' 0
1067for ac_signal in 1 2 13 15; do
1068 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1069done
1070ac_signal=0
1071
1072# confdefs.h avoids OS command line length limits that DEFS can exceed.
1073rm -rf conftest* confdefs.h
1074# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1075echo >confdefs.h
1076
1077# Predefined preprocessor variables.
1078
1079cat >>confdefs.h <<_ACEOF
1080#define PACKAGE_NAME "$PACKAGE_NAME"
1081_ACEOF
1082
1083
1084cat >>confdefs.h <<_ACEOF
1085#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1086_ACEOF
1087
1088
1089cat >>confdefs.h <<_ACEOF
1090#define PACKAGE_VERSION "$PACKAGE_VERSION"
1091_ACEOF
1092
1093
1094cat >>confdefs.h <<_ACEOF
1095#define PACKAGE_STRING "$PACKAGE_STRING"
1096_ACEOF
1097
1098
1099cat >>confdefs.h <<_ACEOF
1100#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1101_ACEOF
1102
1103
1104# Let the site file select an alternate cache file if it wants to.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001105# Prefer explicitly selected file to automatically selected ones.
1106if test -z "$CONFIG_SITE"; then
1107 if test "x$prefix" != xNONE; then
1108 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1109 else
1110 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1111 fi
1112fi
1113for ac_site_file in $CONFIG_SITE; do
1114 if test -r "$ac_site_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001115 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1116echo "$as_me: loading site script $ac_site_file" >&6;}
1117 sed 's/^/| /' "$ac_site_file" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001118 . "$ac_site_file"
1119 fi
1120done
1121
1122if test -r "$cache_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001123 # Some versions of bash will fail to source /dev/null (special
1124 # files actually), so we avoid doing that.
1125 if test -f "$cache_file"; then
1126 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1127echo "$as_me: loading cache $cache_file" >&6;}
1128 case $cache_file in
1129 [\\/]* | ?:[\\/]* ) . $cache_file;;
1130 *) . ./$cache_file;;
1131 esac
1132 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001133else
Martin v. Löwis11437992002-04-12 09:54:03 +00001134 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1135echo "$as_me: creating cache $cache_file" >&6;}
1136 >$cache_file
1137fi
1138
1139# Check that the precious variables saved in the cache have kept the same
1140# value.
1141ac_cache_corrupted=false
1142for ac_var in `(set) 2>&1 |
1143 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1144 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1145 eval ac_new_set=\$ac_env_${ac_var}_set
1146 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1147 eval ac_new_val="\$ac_env_${ac_var}_value"
1148 case $ac_old_set,$ac_new_set in
1149 set,)
1150 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1151echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1152 ac_cache_corrupted=: ;;
1153 ,set)
1154 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1155echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1156 ac_cache_corrupted=: ;;
1157 ,);;
1158 *)
1159 if test "x$ac_old_val" != "x$ac_new_val"; then
1160 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1161echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1162 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
1163echo "$as_me: former value: $ac_old_val" >&2;}
1164 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
1165echo "$as_me: current value: $ac_new_val" >&2;}
1166 ac_cache_corrupted=:
1167 fi;;
1168 esac
1169 # Pass precious variables to config.status.
1170 if test "$ac_new_set" = set; then
1171 case $ac_new_val in
1172 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1173 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1174 *) ac_arg=$ac_var=$ac_new_val ;;
1175 esac
1176 case " $ac_configure_args " in
1177 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1178 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1179 esac
1180 fi
1181done
1182if $ac_cache_corrupted; then
1183 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1184echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1185 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1186echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1187 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001188fi
1189
Guido van Rossum7f43da71994-08-01 12:15:30 +00001190ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001191ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001192ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1193ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1194ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001195
Guido van Rossum627b2d71993-12-24 10:39:16 +00001196
Michael W. Hudson54241132001-12-07 15:38:26 +00001197
1198
Guido van Rossum627b2d71993-12-24 10:39:16 +00001199
Martin v. Löwis11437992002-04-12 09:54:03 +00001200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213ac_config_headers="$ac_config_headers pyconfig.h"
1214
1215
1216# This is for stuff that absolutely must end up in pyconfig.h.
1217# Please use pyport.h instead, if possible.
1218
1219
1220
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001221# Set VERSION so we only need to edit in one place (i.e., here)
1222
Andrew M. Kuchlingf2f219d2002-02-11 16:31:10 +00001223VERSION=2.3
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001224
Martin v. Löwis1142de32002-03-29 16:28:31 +00001225
1226SOVERSION=1.0
1227
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001228# The later defininition of _XOPEN_SOURCE disables certain features
1229# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1230
1231cat >>confdefs.h <<\_ACEOF
1232#define _GNU_SOURCE 1
1233_ACEOF
1234
1235
1236# The definition of _GNU_SOURCE potentially causes a change of the value
1237# of _XOPEN_SOURCE. So define it only conditionally.
1238
1239
1240cat >>confdefs.h <<\_ACEOF
1241#define _XOPEN_SOURCE 500
1242_ACEOF
1243
1244
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00001245# Arguments passed to configure.
1246
1247CONFIG_ARGS="$ac_configure_args"
1248
Michael W. Hudson54241132001-12-07 15:38:26 +00001249
Jack Jansene578a632001-08-15 01:27:14 +00001250# Check whether --enable-framework or --disable-framework was given.
1251if test "${enable_framework+set}" = set; then
1252 enableval="$enable_framework"
Martin v. Löwis11437992002-04-12 09:54:03 +00001253
Jack Jansene578a632001-08-15 01:27:14 +00001254 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00001255 yes)
Jack Jansene578a632001-08-15 01:27:14 +00001256 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00001257 esac
1258 case $enableval in
1259 no)
1260 PYTHONFRAMEWORK=
1261 PYTHONFRAMEWORKDIR=no-framework
1262 PYTHONFRAMEWORKPREFIX=
1263 PYTHONFRAMEWORKINSTALLDIR=
1264 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00001265 ;;
1266 *)
Jack Jansen127e56e2001-09-11 14:41:54 +00001267 PYTHONFRAMEWORK=Python
1268 PYTHONFRAMEWORKDIR=Python.framework
Jack Jansene578a632001-08-15 01:27:14 +00001269 PYTHONFRAMEWORKPREFIX=$enableval
Jack Jansen127e56e2001-09-11 14:41:54 +00001270 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
1271 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Jack Jansene578a632001-08-15 01:27:14 +00001272 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001273
Guido van Rossum563e7081996-09-10 18:20:48 +00001274else
Martin v. Löwis11437992002-04-12 09:54:03 +00001275
Jack Jansene578a632001-08-15 01:27:14 +00001276 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00001277 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00001278 PYTHONFRAMEWORKPREFIX=
1279 PYTHONFRAMEWORKINSTALLDIR=
1280 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001281
Martin v. Löwis11437992002-04-12 09:54:03 +00001282fi;
Michael W. Hudson54241132001-12-07 15:38:26 +00001283
1284
1285
1286
Jack Jansene578a632001-08-15 01:27:14 +00001287
1288##AC_ARG_WITH(dyld,
1289##[ --with-dyld Use (OpenStep|Rhapsody) dynamic linker],,)
1290##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001291# Set name for machine-dependent library files
1292
Martin v. Löwis11437992002-04-12 09:54:03 +00001293echo "$as_me:$LINENO: checking MACHDEP" >&5
1294echo $ECHO_N "checking MACHDEP... $ECHO_C" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001295if test -z "$MACHDEP"
1296then
Guido van Rossum563e7081996-09-10 18:20:48 +00001297 ac_sys_system=`uname -s`
Martin v. Löwis21ee4092002-09-30 16:19:48 +00001298 if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64" \
1299 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00001300 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001301 else
Guido van Rossum563e7081996-09-10 18:20:48 +00001302 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001303 fi
Guido van Rossum563e7081996-09-10 18:20:48 +00001304 ac_md_system=`echo $ac_sys_system |
1305 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
1306 ac_md_release=`echo $ac_sys_release |
Guido van Rossum67b26592001-10-20 14:21:45 +00001307 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +00001308 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00001309
Guido van Rossum07397971997-04-29 21:49:50 +00001310 case $MACHDEP in
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00001311 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00001312 darwin*) MACHDEP="darwin";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00001313 atheos*) MACHDEP="atheos";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00001314 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001315 esac
1316fi
Guido van Rossum91922671997-10-09 20:24:13 +00001317
1318#
1319# SGI compilers allow the specification of the both the ABI and the
1320# ISA on the command line. Depending on the values of these switches,
1321# different and often incompatable code will be generated.
1322#
1323# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
1324# thus supply support for various ABI/ISA combinations. The MACHDEP
1325# variable is also adjusted.
1326#
1327
1328if test ! -z "$SGI_ABI"
1329then
1330 CC="cc $SGI_ABI"
1331 LDFLAGS="$SGI_ABI $LDFLAGS"
1332 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
1333fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001334echo "$as_me:$LINENO: result: $MACHDEP" >&5
1335echo "${ECHO_T}$MACHDEP" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001336
Guido van Rossum627b2d71993-12-24 10:39:16 +00001337# checks for alternative programs
Martin v. Löwis11437992002-04-12 09:54:03 +00001338echo "$as_me:$LINENO: checking for --without-gcc" >&5
1339echo $ECHO_N "checking for --without-gcc... $ECHO_C" >&6
1340
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001341# Check whether --with-gcc or --without-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001342if test "${with_gcc+set}" = set; then
1343 withval="$with_gcc"
Martin v. Löwis11437992002-04-12 09:54:03 +00001344
Guido van Rossum7f43da71994-08-01 12:15:30 +00001345 case $withval in
Guido van Rossumda88dad1995-01-26 00:46:29 +00001346 no) CC=cc
1347 without_gcc=yes;;
1348 yes) CC=gcc
1349 without_gcc=no;;
1350 *) CC=$withval
1351 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001352 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +00001353else
Martin v. Löwis11437992002-04-12 09:54:03 +00001354
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001355 case $ac_sys_system in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001356 AIX*) CC=cc_r
1357 without_gcc=;;
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001358 BeOS*)
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001359 case $BE_HOST_CPU in
1360 ppc)
Fred Drake5790be12000-10-09 17:06:13 +00001361 CC=mwcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001362 without_gcc=yes
Mark Hammond8235ea12002-07-19 06:55:41 +00001363 OPT="-O -export pragma"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001364 LDFLAGS="$LDFLAGS -nodup"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001365 ;;
1366 x86)
Fred Drake5790be12000-10-09 17:06:13 +00001367 CC=gcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001368 without_gcc=no
Fred Drake5790be12000-10-09 17:06:13 +00001369 OPT=-O
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001370 ;;
1371 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001372 { { echo "$as_me:$LINENO: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&5
1373echo "$as_me: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&2;}
1374 { (exit 1); exit 1; }; }
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001375 ;;
1376 esac
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001377 AR="\$(srcdir)/Modules/ar_beos"
1378 RANLIB=:
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001379 ;;
Trent Mick635f6fb2000-08-23 21:33:05 +00001380 Monterey*)
1381 RANLIB=:
Martin v. Löwis130fb172001-07-19 11:00:41 +00001382 without_gcc=;;
1383 *) without_gcc=no;;
Guido van Rossume77438c1995-09-13 18:59:59 +00001384 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001385fi;
1386echo "$as_me:$LINENO: result: $without_gcc" >&5
1387echo "${ECHO_T}$without_gcc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001388
1389
Guido van Rossum95012191999-12-16 17:50:52 +00001390
Fred Drakea1a84e72001-03-06 05:52:16 +00001391MAINOBJ=python.o
Martin v. Löwis11437992002-04-12 09:54:03 +00001392echo "$as_me:$LINENO: checking for --with-cxx=<compiler>" >&5
1393echo $ECHO_N "checking for --with-cxx=<compiler>... $ECHO_C" >&6
1394
Guido van Rossum95012191999-12-16 17:50:52 +00001395# Check whether --with-cxx or --without-cxx was given.
1396if test "${with_cxx+set}" = set; then
1397 withval="$with_cxx"
Martin v. Löwis11437992002-04-12 09:54:03 +00001398
Martin v. Löwis22352952000-12-13 17:37:02 +00001399 check_cxx=no
Guido van Rossum95012191999-12-16 17:50:52 +00001400 case $withval in
1401 no) CXX=
1402 with_cxx=no;;
1403 *) CXX=$withval
Fred Drakea1a84e72001-03-06 05:52:16 +00001404 MAINOBJ=ccpython.o
Guido van Rossum95012191999-12-16 17:50:52 +00001405 with_cxx=$withval;;
1406 esac
1407else
Martin v. Löwis11437992002-04-12 09:54:03 +00001408
Guido van Rossum95012191999-12-16 17:50:52 +00001409 with_cxx=no
Martin v. Löwis22352952000-12-13 17:37:02 +00001410 check_cxx=yes
Guido van Rossum95012191999-12-16 17:50:52 +00001411
Martin v. Löwis11437992002-04-12 09:54:03 +00001412fi;
1413echo "$as_me:$LINENO: result: $with_cxx" >&5
1414echo "${ECHO_T}$with_cxx" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001415
1416if test "$with_cxx" = "yes"
1417then
Martin v. Löwis11437992002-04-12 09:54:03 +00001418 { { echo "$as_me:$LINENO: error: must supply a compiler when using --with-cxx" >&5
1419echo "$as_me: error: must supply a compiler when using --with-cxx" >&2;}
1420 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001421fi
1422
1423
1424
1425
Martin v. Löwis11437992002-04-12 09:54:03 +00001426if test "$check_cxx" = "yes"
Martin v. Löwis22352952000-12-13 17:37:02 +00001427then
1428 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
1429do
Martin v. Löwis11437992002-04-12 09:54:03 +00001430 # 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 +00001431set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00001432echo "$as_me:$LINENO: checking for $ac_word" >&5
1433echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1434if test "${ac_cv_prog_CXX+set}" = set; then
1435 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001436else
1437 if test -n "$CXX"; then
1438 ac_cv_prog_CXX="$CXX" # Let the user override the test.
1439else
Martin v. Löwis11437992002-04-12 09:54:03 +00001440as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1441for as_dir in $PATH
1442do
1443 IFS=$as_save_IFS
1444 test -z "$as_dir" && as_dir=.
1445 for ac_exec_ext in '' $ac_executable_extensions; do
1446 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1447 ac_cv_prog_CXX="$ac_prog"
1448 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1449 break 2
1450 fi
1451done
1452done
1453
Martin v. Löwis22352952000-12-13 17:37:02 +00001454fi
1455fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001456CXX=$ac_cv_prog_CXX
Martin v. Löwis22352952000-12-13 17:37:02 +00001457if test -n "$CXX"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001458 echo "$as_me:$LINENO: result: $CXX" >&5
1459echo "${ECHO_T}$CXX" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001460else
Martin v. Löwis11437992002-04-12 09:54:03 +00001461 echo "$as_me:$LINENO: result: no" >&5
1462echo "${ECHO_T}no" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001463fi
1464
Martin v. Löwis11437992002-04-12 09:54:03 +00001465 test -n "$CXX" && break
Martin v. Löwis22352952000-12-13 17:37:02 +00001466done
1467test -n "$CXX" || CXX="notfound"
1468
1469 if test "$CXX" = "notfound"
1470 then
1471 CXX=
1472 else
Martin v. Löwis11437992002-04-12 09:54:03 +00001473 ac_ext=cc
Martin v. Löwis22352952000-12-13 17:37:02 +00001474ac_cpp='$CXXCPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001475ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1476ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1477ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
1478 cat >conftest.$ac_ext <<_ACEOF
1479#line $LINENO "configure"
Martin v. Löwis22352952000-12-13 17:37:02 +00001480#include "confdefs.h"
1481
Martin v. Löwis11437992002-04-12 09:54:03 +00001482#ifdef F77_DUMMY_MAIN
1483# ifdef __cplusplus
1484 extern "C"
1485# endif
1486 int F77_DUMMY_MAIN() { return 1; }
1487#endif
1488int
1489main ()
1490{
Michael W. Hudson54241132001-12-07 15:38:26 +00001491
Martin v. Löwis11437992002-04-12 09:54:03 +00001492 ;
1493 return 0;
1494}
1495_ACEOF
1496ac_clean_files_save=$ac_clean_files
1497ac_clean_files="$ac_clean_files a.out a.exe"
1498# Try to create an executable without -o first, disregard a.out.
1499# It will help us diagnose broken compilers, and finding out an intuition
1500# of exeext.
1501echo "$as_me:$LINENO: checking for C++ compiler default output" >&5
1502echo $ECHO_N "checking for C++ compiler default output... $ECHO_C" >&6
1503ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1504if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1505 (eval $ac_link_default) 2>&5
1506 ac_status=$?
1507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1508 (exit $ac_status); }; then
1509 # Find the output, starting from the most likely. This scheme is
1510# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1511# resort.
1512
1513# Be careful to initialize this variable, since it used to be cached.
1514# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1515ac_cv_exeext=
1516for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
1517 ls a.out conftest 2>/dev/null;
1518 ls a.* conftest.* 2>/dev/null`; do
1519 case $ac_file in
1520 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
1521 a.out ) # We found the default executable, but exeext='' is most
1522 # certainly right.
1523 break;;
1524 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1525 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1526 export ac_cv_exeext
1527 break;;
1528 * ) break;;
1529 esac
1530done
1531else
1532 echo "$as_me: failed program was:" >&5
1533cat conftest.$ac_ext >&5
1534{ { echo "$as_me:$LINENO: error: C++ compiler cannot create executables" >&5
1535echo "$as_me: error: C++ compiler cannot create executables" >&2;}
1536 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001537fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001538
1539ac_exeext=$ac_cv_exeext
1540echo "$as_me:$LINENO: result: $ac_file" >&5
1541echo "${ECHO_T}$ac_file" >&6
1542
1543# Check the compiler produces executables we can run. If not, either
1544# the compiler is broken, or we cross compile.
1545echo "$as_me:$LINENO: checking whether the C++ compiler works" >&5
1546echo $ECHO_N "checking whether the C++ compiler works... $ECHO_C" >&6
1547# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1548# If not cross compiling, check that we can run a simple program.
1549if test "$cross_compiling" != yes; then
1550 if { ac_try='./$ac_file'
1551 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1552 (eval $ac_try) 2>&5
1553 ac_status=$?
1554 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1555 (exit $ac_status); }; }; then
1556 cross_compiling=no
1557 else
1558 if test "$cross_compiling" = maybe; then
1559 cross_compiling=yes
1560 else
1561 { { echo "$as_me:$LINENO: error: cannot run C++ compiled programs.
1562If you meant to cross compile, use \`--host'." >&5
1563echo "$as_me: error: cannot run C++ compiled programs.
1564If you meant to cross compile, use \`--host'." >&2;}
1565 { (exit 1); exit 1; }; }
1566 fi
1567 fi
1568fi
1569echo "$as_me:$LINENO: result: yes" >&5
1570echo "${ECHO_T}yes" >&6
1571
1572rm -f a.out a.exe conftest$ac_cv_exeext
1573ac_clean_files=$ac_clean_files_save
1574# Check the compiler produces executables we can run. If not, either
1575# the compiler is broken, or we cross compile.
1576echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1577echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1578echo "$as_me:$LINENO: result: $cross_compiling" >&5
1579echo "${ECHO_T}$cross_compiling" >&6
1580
1581echo "$as_me:$LINENO: checking for suffix of executables" >&5
1582echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1583if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1584 (eval $ac_link) 2>&5
1585 ac_status=$?
1586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1587 (exit $ac_status); }; then
1588 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1589# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1590# work properly (i.e., refer to `conftest.exe'), while it won't with
1591# `rm'.
1592for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1593 case $ac_file in
1594 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1595 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1596 export ac_cv_exeext
1597 break;;
1598 * ) break;;
1599 esac
1600done
1601else
1602 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
1603echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
1604 { (exit 1); exit 1; }; }
1605fi
1606
1607rm -f conftest$ac_cv_exeext
1608echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1609echo "${ECHO_T}$ac_cv_exeext" >&6
1610
1611rm -f conftest.$ac_ext
1612EXEEXT=$ac_cv_exeext
1613ac_exeext=$EXEEXT
1614
1615 ac_ext=c
1616ac_cpp='$CPP $CPPFLAGS'
1617ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1618ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1619ac_compiler_gnu=$ac_cv_c_compiler_gnu
1620
1621
Martin v. Löwis22352952000-12-13 17:37:02 +00001622
1623 fi
1624fi
1625
Guido van Rossum8b131c51995-03-09 14:10:13 +00001626# If the user switches compilers, we can't believe the cache
1627if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
1628then
Martin v. Löwis11437992002-04-12 09:54:03 +00001629 { { echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file
1630(it is also a good idea to do 'make clean' before compiling)" >&5
1631echo "$as_me: error: cached CC is different -- throw away $cache_file
1632(it is also a good idea to do 'make clean' before compiling)" >&2;}
1633 { (exit 1); exit 1; }; }
Guido van Rossum8b131c51995-03-09 14:10:13 +00001634fi
1635
Martin v. Löwis11437992002-04-12 09:54:03 +00001636ac_ext=c
1637ac_cpp='$CPP $CPPFLAGS'
1638ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1639ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1640ac_compiler_gnu=$ac_cv_c_compiler_gnu
1641if test -n "$ac_tool_prefix"; then
1642 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1643set dummy ${ac_tool_prefix}gcc; ac_word=$2
1644echo "$as_me:$LINENO: checking for $ac_word" >&5
1645echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1646if test "${ac_cv_prog_CC+set}" = set; then
1647 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001648else
1649 if test -n "$CC"; then
1650 ac_cv_prog_CC="$CC" # Let the user override the test.
1651else
Martin v. Löwis11437992002-04-12 09:54:03 +00001652as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1653for as_dir in $PATH
1654do
1655 IFS=$as_save_IFS
1656 test -z "$as_dir" && as_dir=.
1657 for ac_exec_ext in '' $ac_executable_extensions; do
1658 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1659 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1660 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1661 break 2
1662 fi
1663done
1664done
1665
Jack Jansendd19cf82001-12-06 22:36:17 +00001666fi
1667fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001668CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00001669if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001670 echo "$as_me:$LINENO: result: $CC" >&5
1671echo "${ECHO_T}$CC" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001672else
Martin v. Löwis11437992002-04-12 09:54:03 +00001673 echo "$as_me:$LINENO: result: no" >&5
1674echo "${ECHO_T}no" >&6
1675fi
1676
1677fi
1678if test -z "$ac_cv_prog_CC"; then
1679 ac_ct_CC=$CC
1680 # Extract the first word of "gcc", so it can be a program name with args.
1681set dummy gcc; ac_word=$2
1682echo "$as_me:$LINENO: checking for $ac_word" >&5
1683echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1684if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1685 echo $ECHO_N "(cached) $ECHO_C" >&6
1686else
1687 if test -n "$ac_ct_CC"; then
1688 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1689else
1690as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1691for as_dir in $PATH
1692do
1693 IFS=$as_save_IFS
1694 test -z "$as_dir" && as_dir=.
1695 for ac_exec_ext in '' $ac_executable_extensions; do
1696 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1697 ac_cv_prog_ac_ct_CC="gcc"
1698 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1699 break 2
1700 fi
1701done
1702done
1703
1704fi
1705fi
1706ac_ct_CC=$ac_cv_prog_ac_ct_CC
1707if test -n "$ac_ct_CC"; then
1708 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1709echo "${ECHO_T}$ac_ct_CC" >&6
1710else
1711 echo "$as_me:$LINENO: result: no" >&5
1712echo "${ECHO_T}no" >&6
1713fi
1714
1715 CC=$ac_ct_CC
1716else
1717 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00001718fi
1719
Jack Jansendd19cf82001-12-06 22:36:17 +00001720if test -z "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001721 if test -n "$ac_tool_prefix"; then
1722 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1723set dummy ${ac_tool_prefix}cc; ac_word=$2
1724echo "$as_me:$LINENO: checking for $ac_word" >&5
1725echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1726if test "${ac_cv_prog_CC+set}" = set; then
1727 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001728else
1729 if test -n "$CC"; then
1730 ac_cv_prog_CC="$CC" # Let the user override the test.
1731else
Martin v. Löwis11437992002-04-12 09:54:03 +00001732as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1733for as_dir in $PATH
1734do
1735 IFS=$as_save_IFS
1736 test -z "$as_dir" && as_dir=.
1737 for ac_exec_ext in '' $ac_executable_extensions; do
1738 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1739 ac_cv_prog_CC="${ac_tool_prefix}cc"
1740 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1741 break 2
1742 fi
1743done
1744done
1745
1746fi
1747fi
1748CC=$ac_cv_prog_CC
1749if test -n "$CC"; then
1750 echo "$as_me:$LINENO: result: $CC" >&5
1751echo "${ECHO_T}$CC" >&6
1752else
1753 echo "$as_me:$LINENO: result: no" >&5
1754echo "${ECHO_T}no" >&6
1755fi
1756
1757fi
1758if test -z "$ac_cv_prog_CC"; then
1759 ac_ct_CC=$CC
1760 # Extract the first word of "cc", so it can be a program name with args.
1761set dummy cc; ac_word=$2
1762echo "$as_me:$LINENO: checking for $ac_word" >&5
1763echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1764if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1765 echo $ECHO_N "(cached) $ECHO_C" >&6
1766else
1767 if test -n "$ac_ct_CC"; then
1768 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1769else
1770as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1771for as_dir in $PATH
1772do
1773 IFS=$as_save_IFS
1774 test -z "$as_dir" && as_dir=.
1775 for ac_exec_ext in '' $ac_executable_extensions; do
1776 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1777 ac_cv_prog_ac_ct_CC="cc"
1778 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1779 break 2
1780 fi
1781done
1782done
1783
1784fi
1785fi
1786ac_ct_CC=$ac_cv_prog_ac_ct_CC
1787if test -n "$ac_ct_CC"; then
1788 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1789echo "${ECHO_T}$ac_ct_CC" >&6
1790else
1791 echo "$as_me:$LINENO: result: no" >&5
1792echo "${ECHO_T}no" >&6
1793fi
1794
1795 CC=$ac_ct_CC
1796else
1797 CC="$ac_cv_prog_CC"
1798fi
1799
1800fi
1801if test -z "$CC"; then
1802 # Extract the first word of "cc", so it can be a program name with args.
1803set dummy cc; ac_word=$2
1804echo "$as_me:$LINENO: checking for $ac_word" >&5
1805echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1806if test "${ac_cv_prog_CC+set}" = set; then
1807 echo $ECHO_N "(cached) $ECHO_C" >&6
1808else
1809 if test -n "$CC"; then
1810 ac_cv_prog_CC="$CC" # Let the user override the test.
1811else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001812 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00001813as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1814for as_dir in $PATH
1815do
1816 IFS=$as_save_IFS
1817 test -z "$as_dir" && as_dir=.
1818 for ac_exec_ext in '' $ac_executable_extensions; do
1819 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1820 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1821 ac_prog_rejected=yes
1822 continue
1823 fi
1824 ac_cv_prog_CC="cc"
1825 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1826 break 2
1827 fi
1828done
1829done
1830
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001831if test $ac_prog_rejected = yes; then
1832 # We found a bogon in the path, so make sure we never use it.
1833 set dummy $ac_cv_prog_CC
1834 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00001835 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001836 # We chose a different compiler from the bogus one.
1837 # However, it has the same basename, so the bogon will be chosen
1838 # first if we set CC to just the basename; use the full file name.
1839 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00001840 set dummy "$as_dir/$ac_word" ${1+"$@"}
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001841 shift
1842 ac_cv_prog_CC="$@"
1843 fi
1844fi
1845fi
1846fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001847CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001848if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001849 echo "$as_me:$LINENO: result: $CC" >&5
1850echo "${ECHO_T}$CC" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001851else
Martin v. Löwis11437992002-04-12 09:54:03 +00001852 echo "$as_me:$LINENO: result: no" >&5
1853echo "${ECHO_T}no" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001854fi
1855
Martin v. Löwis11437992002-04-12 09:54:03 +00001856fi
1857if test -z "$CC"; then
1858 if test -n "$ac_tool_prefix"; then
1859 for ac_prog in cl
1860 do
1861 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1862set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1863echo "$as_me:$LINENO: checking for $ac_word" >&5
1864echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1865if test "${ac_cv_prog_CC+set}" = set; then
1866 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00001867else
1868 if test -n "$CC"; then
1869 ac_cv_prog_CC="$CC" # Let the user override the test.
1870else
Martin v. Löwis11437992002-04-12 09:54:03 +00001871as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1872for as_dir in $PATH
1873do
1874 IFS=$as_save_IFS
1875 test -z "$as_dir" && as_dir=.
1876 for ac_exec_ext in '' $ac_executable_extensions; do
1877 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1878 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1879 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1880 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00001881 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001882done
1883done
1884
1885fi
1886fi
1887CC=$ac_cv_prog_CC
1888if test -n "$CC"; then
1889 echo "$as_me:$LINENO: result: $CC" >&5
1890echo "${ECHO_T}$CC" >&6
1891else
1892 echo "$as_me:$LINENO: result: no" >&5
1893echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001894fi
1895
Martin v. Löwis11437992002-04-12 09:54:03 +00001896 test -n "$CC" && break
1897 done
1898fi
1899if test -z "$CC"; then
1900 ac_ct_CC=$CC
1901 for ac_prog in cl
1902do
1903 # Extract the first word of "$ac_prog", so it can be a program name with args.
1904set dummy $ac_prog; ac_word=$2
1905echo "$as_me:$LINENO: checking for $ac_word" >&5
1906echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1907if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1908 echo $ECHO_N "(cached) $ECHO_C" >&6
1909else
1910 if test -n "$ac_ct_CC"; then
1911 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1912else
1913as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1914for as_dir in $PATH
1915do
1916 IFS=$as_save_IFS
1917 test -z "$as_dir" && as_dir=.
1918 for ac_exec_ext in '' $ac_executable_extensions; do
1919 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1920 ac_cv_prog_ac_ct_CC="$ac_prog"
1921 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1922 break 2
1923 fi
1924done
1925done
Jack Jansendd19cf82001-12-06 22:36:17 +00001926
Martin v. Löwis11437992002-04-12 09:54:03 +00001927fi
1928fi
1929ac_ct_CC=$ac_cv_prog_ac_ct_CC
1930if test -n "$ac_ct_CC"; then
1931 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1932echo "${ECHO_T}$ac_ct_CC" >&6
1933else
1934 echo "$as_me:$LINENO: result: no" >&5
1935echo "${ECHO_T}no" >&6
1936fi
Michael W. Hudson54241132001-12-07 15:38:26 +00001937
Martin v. Löwis11437992002-04-12 09:54:03 +00001938 test -n "$ac_ct_CC" && break
1939done
Michael W. Hudson54241132001-12-07 15:38:26 +00001940
Martin v. Löwis11437992002-04-12 09:54:03 +00001941 CC=$ac_ct_CC
1942fi
1943
1944fi
1945
1946
1947test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH" >&5
1948echo "$as_me: error: no acceptable C compiler found in \$PATH" >&2;}
1949 { (exit 1); exit 1; }; }
1950
1951# Provide some information about the compiler.
1952echo "$as_me:$LINENO:" \
1953 "checking for C compiler version" >&5
1954ac_compiler=`set X $ac_compile; echo $2`
1955{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1956 (eval $ac_compiler --version </dev/null >&5) 2>&5
1957 ac_status=$?
1958 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1959 (exit $ac_status); }
1960{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1961 (eval $ac_compiler -v </dev/null >&5) 2>&5
1962 ac_status=$?
1963 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1964 (exit $ac_status); }
1965{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1966 (eval $ac_compiler -V </dev/null >&5) 2>&5
1967 ac_status=$?
1968 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1969 (exit $ac_status); }
1970
1971cat >conftest.$ac_ext <<_ACEOF
1972#line $LINENO "configure"
Jack Jansendd19cf82001-12-06 22:36:17 +00001973#include "confdefs.h"
1974
Martin v. Löwis11437992002-04-12 09:54:03 +00001975#ifdef F77_DUMMY_MAIN
1976# ifdef __cplusplus
1977 extern "C"
1978# endif
1979 int F77_DUMMY_MAIN() { return 1; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00001980#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00001981int
1982main ()
1983{
1984
1985 ;
1986 return 0;
1987}
1988_ACEOF
1989ac_clean_files_save=$ac_clean_files
1990ac_clean_files="$ac_clean_files a.out a.exe"
1991# Try to create an executable without -o first, disregard a.out.
1992# It will help us diagnose broken compilers, and finding out an intuition
1993# of exeext.
1994echo "$as_me:$LINENO: checking for C compiler default output" >&5
1995echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
1996ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1997if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1998 (eval $ac_link_default) 2>&5
1999 ac_status=$?
2000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2001 (exit $ac_status); }; then
2002 # Find the output, starting from the most likely. This scheme is
2003# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2004# resort.
2005
2006# Be careful to initialize this variable, since it used to be cached.
2007# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2008ac_cv_exeext=
2009for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
2010 ls a.out conftest 2>/dev/null;
2011 ls a.* conftest.* 2>/dev/null`; do
2012 case $ac_file in
2013 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
2014 a.out ) # We found the default executable, but exeext='' is most
2015 # certainly right.
2016 break;;
2017 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2018 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
2019 export ac_cv_exeext
2020 break;;
2021 * ) break;;
2022 esac
2023done
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002024else
Martin v. Löwis11437992002-04-12 09:54:03 +00002025 echo "$as_me: failed program was:" >&5
2026cat conftest.$ac_ext >&5
2027{ { echo "$as_me:$LINENO: error: C compiler cannot create executables" >&5
2028echo "$as_me: error: C compiler cannot create executables" >&2;}
2029 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002030fi
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002031
Martin v. Löwis11437992002-04-12 09:54:03 +00002032ac_exeext=$ac_cv_exeext
2033echo "$as_me:$LINENO: result: $ac_file" >&5
2034echo "${ECHO_T}$ac_file" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002035
Martin v. Löwis11437992002-04-12 09:54:03 +00002036# Check the compiler produces executables we can run. If not, either
2037# the compiler is broken, or we cross compile.
2038echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2039echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2040# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2041# If not cross compiling, check that we can run a simple program.
2042if test "$cross_compiling" != yes; then
2043 if { ac_try='./$ac_file'
2044 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2045 (eval $ac_try) 2>&5
2046 ac_status=$?
2047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2048 (exit $ac_status); }; }; then
2049 cross_compiling=no
2050 else
2051 if test "$cross_compiling" = maybe; then
2052 cross_compiling=yes
2053 else
2054 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2055If you meant to cross compile, use \`--host'." >&5
2056echo "$as_me: error: cannot run C compiled programs.
2057If you meant to cross compile, use \`--host'." >&2;}
2058 { (exit 1); exit 1; }; }
2059 fi
2060 fi
2061fi
2062echo "$as_me:$LINENO: result: yes" >&5
2063echo "${ECHO_T}yes" >&6
2064
2065rm -f a.out a.exe conftest$ac_cv_exeext
2066ac_clean_files=$ac_clean_files_save
2067# Check the compiler produces executables we can run. If not, either
2068# the compiler is broken, or we cross compile.
2069echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2070echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2071echo "$as_me:$LINENO: result: $cross_compiling" >&5
2072echo "${ECHO_T}$cross_compiling" >&6
2073
2074echo "$as_me:$LINENO: checking for suffix of executables" >&5
2075echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2076if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2077 (eval $ac_link) 2>&5
2078 ac_status=$?
2079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2080 (exit $ac_status); }; then
2081 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2082# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2083# work properly (i.e., refer to `conftest.exe'), while it won't with
2084# `rm'.
2085for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
2086 case $ac_file in
2087 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
2088 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2089 export ac_cv_exeext
2090 break;;
2091 * ) break;;
2092 esac
2093done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002094else
Martin v. Löwis11437992002-04-12 09:54:03 +00002095 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
2096echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
2097 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002098fi
Jack Jansendd19cf82001-12-06 22:36:17 +00002099
Martin v. Löwis11437992002-04-12 09:54:03 +00002100rm -f conftest$ac_cv_exeext
2101echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2102echo "${ECHO_T}$ac_cv_exeext" >&6
2103
2104rm -f conftest.$ac_ext
2105EXEEXT=$ac_cv_exeext
2106ac_exeext=$EXEEXT
2107echo "$as_me:$LINENO: checking for suffix of object files" >&5
2108echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2109if test "${ac_cv_objext+set}" = set; then
2110 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002111else
Martin v. Löwis11437992002-04-12 09:54:03 +00002112 cat >conftest.$ac_ext <<_ACEOF
2113#line $LINENO "configure"
2114#include "confdefs.h"
2115
2116#ifdef F77_DUMMY_MAIN
2117# ifdef __cplusplus
2118 extern "C"
2119# endif
2120 int F77_DUMMY_MAIN() { return 1; }
2121#endif
2122int
2123main ()
2124{
2125
2126 ;
2127 return 0;
2128}
2129_ACEOF
2130rm -f conftest.o conftest.obj
2131if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2132 (eval $ac_compile) 2>&5
2133 ac_status=$?
2134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2135 (exit $ac_status); }; then
2136 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2137 case $ac_file in
2138 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
2139 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2140 break;;
2141 esac
2142done
2143else
2144 echo "$as_me: failed program was:" >&5
2145cat conftest.$ac_ext >&5
2146{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile" >&5
2147echo "$as_me: error: cannot compute suffix of object files: cannot compile" >&2;}
2148 { (exit 1); exit 1; }; }
2149fi
2150
2151rm -f conftest.$ac_cv_objext conftest.$ac_ext
2152fi
2153echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2154echo "${ECHO_T}$ac_cv_objext" >&6
2155OBJEXT=$ac_cv_objext
2156ac_objext=$OBJEXT
2157echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2158echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2159if test "${ac_cv_c_compiler_gnu+set}" = set; then
2160 echo $ECHO_N "(cached) $ECHO_C" >&6
2161else
2162 cat >conftest.$ac_ext <<_ACEOF
2163#line $LINENO "configure"
2164#include "confdefs.h"
2165
2166#ifdef F77_DUMMY_MAIN
2167# ifdef __cplusplus
2168 extern "C"
2169# endif
2170 int F77_DUMMY_MAIN() { return 1; }
2171#endif
2172int
2173main ()
2174{
2175#ifndef __GNUC__
2176 choke me
2177#endif
2178
2179 ;
2180 return 0;
2181}
2182_ACEOF
2183rm -f conftest.$ac_objext
2184if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2185 (eval $ac_compile) 2>&5
2186 ac_status=$?
2187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2188 (exit $ac_status); } &&
2189 { ac_try='test -s conftest.$ac_objext'
2190 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2191 (eval $ac_try) 2>&5
2192 ac_status=$?
2193 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2194 (exit $ac_status); }; }; then
2195 ac_compiler_gnu=yes
2196else
2197 echo "$as_me: failed program was:" >&5
2198cat conftest.$ac_ext >&5
2199ac_compiler_gnu=no
2200fi
2201rm -f conftest.$ac_objext conftest.$ac_ext
2202ac_cv_c_compiler_gnu=$ac_compiler_gnu
2203
2204fi
2205echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2206echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2207GCC=`test $ac_compiler_gnu = yes && echo yes`
2208ac_test_CFLAGS=${CFLAGS+set}
2209ac_save_CFLAGS=$CFLAGS
2210CFLAGS="-g"
2211echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2212echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2213if test "${ac_cv_prog_cc_g+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
2230 ;
2231 return 0;
2232}
2233_ACEOF
2234rm -f conftest.$ac_objext
2235if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2236 (eval $ac_compile) 2>&5
2237 ac_status=$?
2238 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2239 (exit $ac_status); } &&
2240 { ac_try='test -s conftest.$ac_objext'
2241 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2242 (eval $ac_try) 2>&5
2243 ac_status=$?
2244 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2245 (exit $ac_status); }; }; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002246 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002247else
Martin v. Löwis11437992002-04-12 09:54:03 +00002248 echo "$as_me: failed program was:" >&5
2249cat conftest.$ac_ext >&5
2250ac_cv_prog_cc_g=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002251fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002252rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002253fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002254echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2255echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002256if test "$ac_test_CFLAGS" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002257 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002258elif test $ac_cv_prog_cc_g = yes; then
2259 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002260 CFLAGS="-g -O2"
2261 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002262 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002263 fi
2264else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002265 if test "$GCC" = yes; then
2266 CFLAGS="-O2"
2267 else
2268 CFLAGS=
2269 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002270fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002271# Some people use a C++ compiler to compile C. Since we use `exit',
2272# in C++ we need to declare it. In case someone uses the same compiler
2273# for both compiling C and C++ we need to have the C++ compiler decide
2274# the declaration of exit, since it's the most demanding environment.
2275cat >conftest.$ac_ext <<_ACEOF
2276#ifndef __cplusplus
2277 choke me
2278#endif
2279_ACEOF
2280rm -f conftest.$ac_objext
2281if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2282 (eval $ac_compile) 2>&5
2283 ac_status=$?
2284 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2285 (exit $ac_status); } &&
2286 { ac_try='test -s conftest.$ac_objext'
2287 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2288 (eval $ac_try) 2>&5
2289 ac_status=$?
2290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2291 (exit $ac_status); }; }; then
2292 for ac_declaration in \
2293 ''\
2294 '#include <stdlib.h>' \
2295 'extern "C" void std::exit (int) throw (); using std::exit;' \
2296 'extern "C" void std::exit (int); using std::exit;' \
2297 'extern "C" void exit (int) throw ();' \
2298 'extern "C" void exit (int);' \
2299 'void exit (int);'
2300do
2301 cat >conftest.$ac_ext <<_ACEOF
2302#line $LINENO "configure"
2303#include "confdefs.h"
2304#include <stdlib.h>
2305$ac_declaration
2306#ifdef F77_DUMMY_MAIN
2307# ifdef __cplusplus
2308 extern "C"
2309# endif
2310 int F77_DUMMY_MAIN() { return 1; }
2311#endif
2312int
2313main ()
2314{
2315exit (42);
2316 ;
2317 return 0;
2318}
2319_ACEOF
2320rm -f conftest.$ac_objext
2321if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2322 (eval $ac_compile) 2>&5
2323 ac_status=$?
2324 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2325 (exit $ac_status); } &&
2326 { ac_try='test -s conftest.$ac_objext'
2327 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2328 (eval $ac_try) 2>&5
2329 ac_status=$?
2330 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2331 (exit $ac_status); }; }; then
2332 :
2333else
2334 echo "$as_me: failed program was:" >&5
2335cat conftest.$ac_ext >&5
2336continue
2337fi
2338rm -f conftest.$ac_objext conftest.$ac_ext
2339 cat >conftest.$ac_ext <<_ACEOF
2340#line $LINENO "configure"
2341#include "confdefs.h"
2342$ac_declaration
2343#ifdef F77_DUMMY_MAIN
2344# ifdef __cplusplus
2345 extern "C"
2346# endif
2347 int F77_DUMMY_MAIN() { return 1; }
2348#endif
2349int
2350main ()
2351{
2352exit (42);
2353 ;
2354 return 0;
2355}
2356_ACEOF
2357rm -f conftest.$ac_objext
2358if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2359 (eval $ac_compile) 2>&5
2360 ac_status=$?
2361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2362 (exit $ac_status); } &&
2363 { ac_try='test -s conftest.$ac_objext'
2364 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2365 (eval $ac_try) 2>&5
2366 ac_status=$?
2367 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2368 (exit $ac_status); }; }; then
2369 break
2370else
2371 echo "$as_me: failed program was:" >&5
2372cat conftest.$ac_ext >&5
2373fi
2374rm -f conftest.$ac_objext conftest.$ac_ext
2375done
2376rm -f conftest*
2377if test -n "$ac_declaration"; then
2378 echo '#ifdef __cplusplus' >>confdefs.h
2379 echo $ac_declaration >>confdefs.h
2380 echo '#endif' >>confdefs.h
2381fi
2382
2383else
2384 echo "$as_me: failed program was:" >&5
2385cat conftest.$ac_ext >&5
2386fi
2387rm -f conftest.$ac_objext conftest.$ac_ext
2388ac_ext=c
2389ac_cpp='$CPP $CPPFLAGS'
2390ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2391ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2392ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002393
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002394
2395# checks for UNIX variants that set C preprocessor variables
Martin v. Löwis11437992002-04-12 09:54:03 +00002396
2397ac_ext=c
2398ac_cpp='$CPP $CPPFLAGS'
2399ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2400ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2401ac_compiler_gnu=$ac_cv_c_compiler_gnu
2402echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2403echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002404# On Suns, sometimes $CPP names a directory.
2405if test -n "$CPP" && test -d "$CPP"; then
2406 CPP=
2407fi
2408if test -z "$CPP"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002409 if test "${ac_cv_prog_CPP+set}" = set; then
2410 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002411else
Martin v. Löwis11437992002-04-12 09:54:03 +00002412 # Double quotes because CPP needs to be expanded
2413 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2414 do
2415 ac_preproc_ok=false
2416for ac_c_preproc_warn_flag in '' yes
2417do
2418 # Use a header file that comes with gcc, so configuring glibc
2419 # with a fresh cross-compiler works.
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002420 # On the NeXT, cc -E runs the code through the compiler's parser,
Martin v. Löwis11437992002-04-12 09:54:03 +00002421 # not just through cpp. "Syntax error" is here to catch this case.
2422 cat >conftest.$ac_ext <<_ACEOF
2423#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002424#include "confdefs.h"
2425#include <assert.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00002426 Syntax error
2427_ACEOF
2428if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2429 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2430 ac_status=$?
2431 egrep -v '^ *\+' conftest.er1 >conftest.err
2432 rm -f conftest.er1
2433 cat conftest.err >&5
2434 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2435 (exit $ac_status); } >/dev/null; then
2436 if test -s conftest.err; then
2437 ac_cpp_err=$ac_c_preproc_warn_flag
2438 else
2439 ac_cpp_err=
2440 fi
2441else
2442 ac_cpp_err=yes
2443fi
2444if test -z "$ac_cpp_err"; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002445 :
2446else
Martin v. Löwis11437992002-04-12 09:54:03 +00002447 echo "$as_me: failed program was:" >&5
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002448 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002449 # Broken: fails on valid input.
2450continue
Jack Jansendd19cf82001-12-06 22:36:17 +00002451fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002452rm -f conftest.err conftest.$ac_ext
Jack Jansendd19cf82001-12-06 22:36:17 +00002453
Martin v. Löwis11437992002-04-12 09:54:03 +00002454 # OK, works on sane cases. Now check whether non-existent headers
2455 # can be detected and how.
2456 cat >conftest.$ac_ext <<_ACEOF
2457#line $LINENO "configure"
2458#include "confdefs.h"
2459#include <ac_nonexistent.h>
2460_ACEOF
2461if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2462 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2463 ac_status=$?
2464 egrep -v '^ *\+' conftest.er1 >conftest.err
2465 rm -f conftest.er1
2466 cat conftest.err >&5
2467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2468 (exit $ac_status); } >/dev/null; then
2469 if test -s conftest.err; then
2470 ac_cpp_err=$ac_c_preproc_warn_flag
2471 else
2472 ac_cpp_err=
2473 fi
2474else
2475 ac_cpp_err=yes
2476fi
2477if test -z "$ac_cpp_err"; then
2478 # Broken: success on invalid input.
2479continue
2480else
2481 echo "$as_me: failed program was:" >&5
2482 cat conftest.$ac_ext >&5
2483 # Passes both tests.
2484ac_preproc_ok=:
2485break
2486fi
2487rm -f conftest.err conftest.$ac_ext
2488
2489done
2490# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2491rm -f conftest.err conftest.$ac_ext
2492if $ac_preproc_ok; then
2493 break
2494fi
2495
2496 done
2497 ac_cv_prog_CPP=$CPP
2498
2499fi
2500 CPP=$ac_cv_prog_CPP
2501else
2502 ac_cv_prog_CPP=$CPP
2503fi
2504echo "$as_me:$LINENO: result: $CPP" >&5
2505echo "${ECHO_T}$CPP" >&6
2506ac_preproc_ok=false
2507for ac_c_preproc_warn_flag in '' yes
2508do
2509 # Use a header file that comes with gcc, so configuring glibc
2510 # with a fresh cross-compiler works.
2511 # On the NeXT, cc -E runs the code through the compiler's parser,
2512 # not just through cpp. "Syntax error" is here to catch this case.
2513 cat >conftest.$ac_ext <<_ACEOF
2514#line $LINENO "configure"
2515#include "confdefs.h"
2516#include <assert.h>
2517 Syntax error
2518_ACEOF
2519if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2520 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2521 ac_status=$?
2522 egrep -v '^ *\+' conftest.er1 >conftest.err
2523 rm -f conftest.er1
2524 cat conftest.err >&5
2525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2526 (exit $ac_status); } >/dev/null; then
2527 if test -s conftest.err; then
2528 ac_cpp_err=$ac_c_preproc_warn_flag
2529 else
2530 ac_cpp_err=
2531 fi
2532else
2533 ac_cpp_err=yes
2534fi
2535if test -z "$ac_cpp_err"; then
2536 :
2537else
2538 echo "$as_me: failed program was:" >&5
2539 cat conftest.$ac_ext >&5
2540 # Broken: fails on valid input.
2541continue
2542fi
2543rm -f conftest.err conftest.$ac_ext
2544
2545 # OK, works on sane cases. Now check whether non-existent headers
2546 # can be detected and how.
2547 cat >conftest.$ac_ext <<_ACEOF
2548#line $LINENO "configure"
2549#include "confdefs.h"
2550#include <ac_nonexistent.h>
2551_ACEOF
2552if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2553 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2554 ac_status=$?
2555 egrep -v '^ *\+' conftest.er1 >conftest.err
2556 rm -f conftest.er1
2557 cat conftest.err >&5
2558 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2559 (exit $ac_status); } >/dev/null; then
2560 if test -s conftest.err; then
2561 ac_cpp_err=$ac_c_preproc_warn_flag
2562 else
2563 ac_cpp_err=
2564 fi
2565else
2566 ac_cpp_err=yes
2567fi
2568if test -z "$ac_cpp_err"; then
2569 # Broken: success on invalid input.
2570continue
2571else
2572 echo "$as_me: failed program was:" >&5
2573 cat conftest.$ac_ext >&5
2574 # Passes both tests.
2575ac_preproc_ok=:
2576break
2577fi
2578rm -f conftest.err conftest.$ac_ext
2579
2580done
2581# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2582rm -f conftest.err conftest.$ac_ext
2583if $ac_preproc_ok; then
2584 :
2585else
2586 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check" >&5
2587echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2588 { (exit 1); exit 1; }; }
2589fi
2590
2591ac_ext=c
2592ac_cpp='$CPP $CPPFLAGS'
2593ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2594ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2595ac_compiler_gnu=$ac_cv_c_compiler_gnu
2596
2597
2598
2599echo "$as_me:$LINENO: checking for AIX" >&5
2600echo $ECHO_N "checking for AIX... $ECHO_C" >&6
2601cat >conftest.$ac_ext <<_ACEOF
2602#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002603#include "confdefs.h"
2604#ifdef _AIX
2605 yes
2606#endif
2607
Martin v. Löwis11437992002-04-12 09:54:03 +00002608_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002609if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2610 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002611 echo "$as_me:$LINENO: result: yes" >&5
2612echo "${ECHO_T}yes" >&6
2613cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002614#define _ALL_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002615_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002616
2617else
Martin v. Löwis11437992002-04-12 09:54:03 +00002618 echo "$as_me:$LINENO: result: no" >&5
2619echo "${ECHO_T}no" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002620fi
2621rm -f conftest*
2622
Michael W. Hudson54241132001-12-07 15:38:26 +00002623
Martin v. Löwis11437992002-04-12 09:54:03 +00002624echo "$as_me:$LINENO: checking for ANSI C header files" >&5
2625echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2626if test "${ac_cv_header_stdc+set}" = set; then
2627 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002628else
Martin v. Löwis11437992002-04-12 09:54:03 +00002629 cat >conftest.$ac_ext <<_ACEOF
2630#line $LINENO "configure"
2631#include "confdefs.h"
2632#include <stdlib.h>
2633#include <stdarg.h>
2634#include <string.h>
2635#include <float.h>
2636
2637_ACEOF
2638if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2639 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2640 ac_status=$?
2641 egrep -v '^ *\+' conftest.er1 >conftest.err
2642 rm -f conftest.er1
2643 cat conftest.err >&5
2644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2645 (exit $ac_status); } >/dev/null; then
2646 if test -s conftest.err; then
2647 ac_cpp_err=$ac_c_preproc_warn_flag
2648 else
2649 ac_cpp_err=
2650 fi
2651else
2652 ac_cpp_err=yes
2653fi
2654if test -z "$ac_cpp_err"; then
2655 ac_cv_header_stdc=yes
2656else
2657 echo "$as_me: failed program was:" >&5
2658 cat conftest.$ac_ext >&5
2659 ac_cv_header_stdc=no
2660fi
2661rm -f conftest.err conftest.$ac_ext
2662
2663if test $ac_cv_header_stdc = yes; then
2664 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2665 cat >conftest.$ac_ext <<_ACEOF
2666#line $LINENO "configure"
2667#include "confdefs.h"
2668#include <string.h>
2669
2670_ACEOF
2671if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2672 egrep "memchr" >/dev/null 2>&1; then
2673 :
2674else
2675 ac_cv_header_stdc=no
2676fi
2677rm -f conftest*
2678
2679fi
2680
2681if test $ac_cv_header_stdc = yes; then
2682 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2683 cat >conftest.$ac_ext <<_ACEOF
2684#line $LINENO "configure"
2685#include "confdefs.h"
2686#include <stdlib.h>
2687
2688_ACEOF
2689if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2690 egrep "free" >/dev/null 2>&1; then
2691 :
2692else
2693 ac_cv_header_stdc=no
2694fi
2695rm -f conftest*
2696
2697fi
2698
2699if test $ac_cv_header_stdc = yes; then
2700 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2701 if test "$cross_compiling" = yes; then
2702 :
2703else
2704 cat >conftest.$ac_ext <<_ACEOF
2705#line $LINENO "configure"
2706#include "confdefs.h"
2707#include <ctype.h>
2708#if ((' ' & 0x0FF) == 0x020)
2709# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2710# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2711#else
2712# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2713 || ('j' <= (c) && (c) <= 'r') \
2714 || ('s' <= (c) && (c) <= 'z'))
2715# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2716#endif
2717
2718#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2719int
2720main ()
2721{
2722 int i;
2723 for (i = 0; i < 256; i++)
2724 if (XOR (islower (i), ISLOWER (i))
2725 || toupper (i) != TOUPPER (i))
2726 exit(2);
2727 exit (0);
2728}
2729_ACEOF
2730rm -f conftest$ac_exeext
2731if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2732 (eval $ac_link) 2>&5
2733 ac_status=$?
2734 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2735 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2736 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2737 (eval $ac_try) 2>&5
2738 ac_status=$?
2739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2740 (exit $ac_status); }; }; then
2741 :
2742else
2743 echo "$as_me: program exited with status $ac_status" >&5
2744echo "$as_me: failed program was:" >&5
2745cat conftest.$ac_ext >&5
2746( exit $ac_status )
2747ac_cv_header_stdc=no
2748fi
2749rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2750fi
2751fi
2752fi
2753echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
2754echo "${ECHO_T}$ac_cv_header_stdc" >&6
2755if test $ac_cv_header_stdc = yes; then
2756
2757cat >>confdefs.h <<\_ACEOF
2758#define STDC_HEADERS 1
2759_ACEOF
2760
2761fi
2762
2763# On IRIX 5.3, sys/types and inttypes.h are conflicting.
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
2774 inttypes.h stdint.h unistd.h
2775do
2776as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
2777echo "$as_me:$LINENO: checking for $ac_header" >&5
2778echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
2779if eval "test \"\${$as_ac_Header+set}\" = set"; then
2780 echo $ECHO_N "(cached) $ECHO_C" >&6
2781else
2782 cat >conftest.$ac_ext <<_ACEOF
2783#line $LINENO "configure"
2784#include "confdefs.h"
2785$ac_includes_default
2786
2787#include <$ac_header>
2788_ACEOF
2789rm -f conftest.$ac_objext
2790if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2791 (eval $ac_compile) 2>&5
2792 ac_status=$?
2793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2794 (exit $ac_status); } &&
2795 { ac_try='test -s conftest.$ac_objext'
2796 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2797 (eval $ac_try) 2>&5
2798 ac_status=$?
2799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2800 (exit $ac_status); }; }; then
2801 eval "$as_ac_Header=yes"
2802else
2803 echo "$as_me: failed program was:" >&5
2804cat conftest.$ac_ext >&5
2805eval "$as_ac_Header=no"
2806fi
2807rm -f conftest.$ac_objext conftest.$ac_ext
2808fi
2809echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
2810echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2811if test `eval echo '${'$as_ac_Header'}'` = yes; then
2812 cat >>confdefs.h <<_ACEOF
2813#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
2814_ACEOF
2815
2816fi
2817
2818done
2819
2820
2821if test "${ac_cv_header_minix_config_h+set}" = set; then
2822 echo "$as_me:$LINENO: checking for minix/config.h" >&5
2823echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2824if test "${ac_cv_header_minix_config_h+set}" = set; then
2825 echo $ECHO_N "(cached) $ECHO_C" >&6
2826fi
2827echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
2828echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2829else
2830 # Is the header compilable?
2831echo "$as_me:$LINENO: checking minix/config.h usability" >&5
2832echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6
2833cat >conftest.$ac_ext <<_ACEOF
2834#line $LINENO "configure"
2835#include "confdefs.h"
2836$ac_includes_default
2837#include <minix/config.h>
2838_ACEOF
2839rm -f conftest.$ac_objext
2840if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2841 (eval $ac_compile) 2>&5
2842 ac_status=$?
2843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2844 (exit $ac_status); } &&
2845 { ac_try='test -s conftest.$ac_objext'
2846 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2847 (eval $ac_try) 2>&5
2848 ac_status=$?
2849 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2850 (exit $ac_status); }; }; then
2851 ac_header_compiler=yes
2852else
2853 echo "$as_me: failed program was:" >&5
2854cat conftest.$ac_ext >&5
2855ac_header_compiler=no
2856fi
2857rm -f conftest.$ac_objext conftest.$ac_ext
2858echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
2859echo "${ECHO_T}$ac_header_compiler" >&6
2860
2861# Is the header present?
2862echo "$as_me:$LINENO: checking minix/config.h presence" >&5
2863echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6
2864cat >conftest.$ac_ext <<_ACEOF
2865#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002866#include "confdefs.h"
2867#include <minix/config.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00002868_ACEOF
2869if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2870 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2871 ac_status=$?
2872 egrep -v '^ *\+' conftest.er1 >conftest.err
2873 rm -f conftest.er1
2874 cat conftest.err >&5
2875 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2876 (exit $ac_status); } >/dev/null; then
2877 if test -s conftest.err; then
2878 ac_cpp_err=$ac_c_preproc_warn_flag
2879 else
2880 ac_cpp_err=
2881 fi
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002882else
Martin v. Löwis11437992002-04-12 09:54:03 +00002883 ac_cpp_err=yes
2884fi
2885if test -z "$ac_cpp_err"; then
2886 ac_header_preproc=yes
2887else
2888 echo "$as_me: failed program was:" >&5
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002889 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002890 ac_header_preproc=no
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002891fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002892rm -f conftest.err conftest.$ac_ext
2893echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
2894echo "${ECHO_T}$ac_header_preproc" >&6
2895
2896# So? What about this header?
2897case $ac_header_compiler:$ac_header_preproc in
2898 yes:no )
2899 { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
2900echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
2901 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
2902echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;};;
2903 no:yes )
2904 { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
2905echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
2906 { echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5
2907echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;}
2908 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
2909echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;};;
2910esac
2911echo "$as_me:$LINENO: checking for minix/config.h" >&5
2912echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2913if test "${ac_cv_header_minix_config_h+set}" = set; then
2914 echo $ECHO_N "(cached) $ECHO_C" >&6
2915else
2916 ac_cv_header_minix_config_h=$ac_header_preproc
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002917fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002918echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
2919echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2920
2921fi
2922if test $ac_cv_header_minix_config_h = yes; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002923 MINIX=yes
2924else
Martin v. Löwis11437992002-04-12 09:54:03 +00002925 MINIX=
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002926fi
2927
Martin v. Löwis11437992002-04-12 09:54:03 +00002928
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002929if test "$MINIX" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002930
2931cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002932#define _POSIX_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002933_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002934
Martin v. Löwis11437992002-04-12 09:54:03 +00002935
2936cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002937#define _POSIX_1_SOURCE 2
Martin v. Löwis11437992002-04-12 09:54:03 +00002938_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002939
Martin v. Löwis11437992002-04-12 09:54:03 +00002940
2941cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002942#define _MINIX 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002943_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002944
2945fi
2946
2947
Michael W. Hudson54241132001-12-07 15:38:26 +00002948
Martin v. Löwis11437992002-04-12 09:54:03 +00002949echo "$as_me:$LINENO: checking for --with-suffix" >&5
2950echo $ECHO_N "checking for --with-suffix... $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002951
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00002952# Check whether --with-suffix or --without-suffix was given.
2953if test "${with_suffix+set}" = set; then
2954 withval="$with_suffix"
Martin v. Löwis11437992002-04-12 09:54:03 +00002955
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00002956 case $withval in
2957 no) EXEEXT=;;
2958 yes) EXEEXT=.exe;;
2959 *) EXEEXT=$withval;;
2960 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00002961fi;
2962echo "$as_me:$LINENO: result: $EXEEXT" >&5
2963echo "${ECHO_T}$EXEEXT" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00002964
Jack Jansen9a66b6d2001-08-08 13:56:14 +00002965# Test whether we're running on a non-case-sensitive system, in which
2966# case we give a warning if no ext is given
Jack Jansen1999ef42001-12-06 21:47:20 +00002967
Martin v. Löwis11437992002-04-12 09:54:03 +00002968echo "$as_me:$LINENO: checking for case-insensitive build directory" >&5
2969echo $ECHO_N "checking for case-insensitive build directory... $ECHO_C" >&6
Jack Jansen0b06be72002-06-21 14:48:38 +00002970if test -d "${srcdir}/python"
Jack Jansen9a66b6d2001-08-08 13:56:14 +00002971then
Martin v. Löwis11437992002-04-12 09:54:03 +00002972 echo "$as_me:$LINENO: result: yes" >&5
2973echo "${ECHO_T}yes" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00002974 BUILDEXEEXT=.exe
2975else
Martin v. Löwis11437992002-04-12 09:54:03 +00002976 echo "$as_me:$LINENO: result: no" >&5
2977echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00002978 BUILDEXEEXT=$EXEEXT
Jack Jansen9a66b6d2001-08-08 13:56:14 +00002979fi
Guido van Rossumff555e32000-09-22 15:38:21 +00002980
Guido van Rossumdd997f71998-10-07 19:58:26 +00002981case $MACHDEP in
2982bsdos*)
2983 case $CC in
2984 gcc) CC="$CC -D_HAVE_BSDI";;
2985 esac;;
2986esac
2987
Guido van Rossum24b1e751997-08-21 02:29:16 +00002988case $ac_sys_system in
2989hp*|HP*)
2990 case $CC in
Guido van Rossumcd5ff9f2000-09-22 16:15:54 +00002991 cc|*/cc) CC="$CC -Ae";;
Guido van Rossum24b1e751997-08-21 02:29:16 +00002992 esac;;
Trent Mick635f6fb2000-08-23 21:33:05 +00002993Monterey*)
2994 case $CC in
2995 cc) CC="$CC -Wl,-Bexport";;
2996 esac;;
Martin v. Löwisa30c1002001-03-06 12:10:20 +00002997SunOS*)
2998 # Some functions have a prototype only with that define, e.g. confstr
Martin v. Löwis11437992002-04-12 09:54:03 +00002999
3000cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003001#define __EXTENSIONS__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003002_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003003
3004 ;;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003005esac
3006
Michael W. Hudson54241132001-12-07 15:38:26 +00003007
3008
Martin v. Löwis11437992002-04-12 09:54:03 +00003009echo "$as_me:$LINENO: checking LIBRARY" >&5
3010echo $ECHO_N "checking LIBRARY... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003011if test -z "$LIBRARY"
3012then
3013 LIBRARY='libpython$(VERSION).a'
3014fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003015echo "$as_me:$LINENO: result: $LIBRARY" >&5
3016echo "${ECHO_T}$LIBRARY" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003017
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003018# LDLIBRARY is the name of the library to link against (as opposed to the
Jack Jansene578a632001-08-15 01:27:14 +00003019# name of the library into which to insert object files). BLDLIBRARY is also
3020# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
3021# is blank as the main program is not linked directly against LDLIBRARY.
3022# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
3023# systems without shared libraries, LDLIBRARY is the same as LIBRARY
3024# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
3025# DLLLIBRARY is the shared (i.e., DLL) library.
Martin v. Löwis11437992002-04-12 09:54:03 +00003026#
Martin v. Löwis1142de32002-03-29 16:28:31 +00003027# RUNSHARED is used to run shared python without installed libraries
3028#
3029# INSTSONAME is the name of the shared library that will be use to install
3030# on the system - some systems like version suffix, others don't
3031
3032
Michael W. Hudson54241132001-12-07 15:38:26 +00003033
3034
3035
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003036
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003037LDLIBRARY="$LIBRARY"
Jack Jansene578a632001-08-15 01:27:14 +00003038BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis09bdf722002-05-08 08:51:29 +00003039INSTSONAME='$(LDLIBRARY)'
Guido van Rossumca563f22001-01-23 01:52:44 +00003040DLLLIBRARY=''
Jack Jansene578a632001-08-15 01:27:14 +00003041LDLIBRARYDIR=''
Martin v. Löwis1142de32002-03-29 16:28:31 +00003042RUNSHARED=''
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003043
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003044# LINKCC is the command that links the python executable -- default is $(CC).
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003045# If CXX is set, and if it is needed to link a main function that was
3046# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
3047# python might then depend on the C++ runtime
Martin v. Löwis11437992002-04-12 09:54:03 +00003048# This is altered for AIX in order to build the export list before
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003049# linking.
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003050
Martin v. Löwis11437992002-04-12 09:54:03 +00003051echo "$as_me:$LINENO: checking LINKCC" >&5
3052echo $ECHO_N "checking LINKCC... $ECHO_C" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003053if test -z "$LINKCC"
3054then
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003055 if test -z "$CXX"; then
3056 LINKCC="\$(PURIFY) \$(CC)"
3057 else
Martin v. Löwis1931ca72002-06-01 21:39:58 +00003058 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003059 $CXX -c conftest.$ac_ext 2>&5
3060 if $CC -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
3061 && test -s conftest$ac_exeext && ./conftest$ac_exeext
3062 then
3063 LINKCC="\$(PURIFY) \$(CC)"
3064 else
3065 LINKCC="\$(PURIFY) \$(CXX)"
3066 fi
3067 rm -fr conftest*
3068 fi
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003069 case $ac_sys_system in
3070 AIX*)
Jack Jansen524a0982002-03-12 15:25:52 +00003071 LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp \"\" \$(LIBRARY); $LINKCC";;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00003072 dgux*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003073 LINKCC="LD_RUN_PATH=$libdir $LINKCC";;
Trent Mick635f6fb2000-08-23 21:33:05 +00003074 Monterey64*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003075 LINKCC="$LINKCC -L/usr/lib/ia64l64";;
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003076 esac
3077fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003078echo "$as_me:$LINENO: result: $LINKCC" >&5
3079echo "${ECHO_T}$LINKCC" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003080
Martin v. Löwis11437992002-04-12 09:54:03 +00003081echo "$as_me:$LINENO: checking for --enable-shared" >&5
3082echo $ECHO_N "checking for --enable-shared... $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003083# Check whether --enable-shared or --disable-shared was given.
3084if test "${enable_shared+set}" = set; then
3085 enableval="$enable_shared"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003086
Martin v. Löwis11437992002-04-12 09:54:03 +00003087fi;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003088
3089if test -z "$enable_shared"
Martin v. Löwis11437992002-04-12 09:54:03 +00003090then
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003091 case $ac_sys_system in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003092 CYGWIN* | atheos*)
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003093 enable_shared="yes";;
3094 *)
3095 enable_shared="no";;
3096 esac
Martin v. Löwis1142de32002-03-29 16:28:31 +00003097fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003098echo "$as_me:$LINENO: result: $enable_shared" >&5
3099echo "${ECHO_T}$enable_shared" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003100
3101
Martin v. Löwis11437992002-04-12 09:54:03 +00003102echo "$as_me:$LINENO: checking LDLIBRARY" >&5
3103echo $ECHO_N "checking LDLIBRARY... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00003104
Guido van Rossumb8552162001-09-05 14:58:11 +00003105# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
3106# library that we build, but we do not want to link against it (we
3107# will find it with a -framework option). For this reason there is an
3108# extra variable BLDLIBRARY against which Python and the extension
3109# modules are linked, BLDLIBRARY. This is normally the same as
3110# LDLIBRARY, but empty for MacOSX framework builds.
Jack Jansene578a632001-08-15 01:27:14 +00003111if test "$enable_framework"
3112then
3113 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
3114 LDLIBRARYDIR='$(PYTHONFRAMEWORKDIR)'
3115 BLDLIBRARY=''
3116else
3117 BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis11437992002-04-12 09:54:03 +00003118fi
Jack Jansene578a632001-08-15 01:27:14 +00003119
Martin v. Löwis1142de32002-03-29 16:28:31 +00003120# Other platforms follow
3121if test $enable_shared = "yes"; then
Mark Hammond8235ea12002-07-19 06:55:41 +00003122
3123cat >>confdefs.h <<\_ACEOF
3124#define Py_ENABLE_SHARED 1
3125_ACEOF
3126
Martin v. Löwis1142de32002-03-29 16:28:31 +00003127 case $ac_sys_system in
3128 BeOS*)
3129 LDLIBRARY='libpython$(VERSION).so'
3130 ;;
3131 CYGWIN*)
3132 LDLIBRARY='libpython$(VERSION).dll.a'
3133 DLLLIBRARY='libpython$(VERSION).dll'
3134 ;;
3135 SunOS*)
3136 LDLIBRARY='libpython$(VERSION).so'
3137 BLDLIBRARY='-Wl,-rpath,$(LIBDIR) -L. -lpython$(VERSION)'
3138 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3139 ;;
Martin v. Löwis1bc894b2002-07-30 20:19:58 +00003140 Linux*|GNU*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00003141 LDLIBRARY='libpython$(VERSION).so'
3142 BLDLIBRARY='-L. -lpython$(VERSION)'
3143 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3144 INSTSONAME="$LDLIBRARY".$SOVERSION
3145 ;;
3146 hp*|HP*)
3147 LDLIBRARY='libpython$(VERSION).sl'
3148 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
3149 RUNSHARED=SHLIB_PATH=`pwd`:$SHLIB_PATH
3150 ;;
3151 OSF*)
3152 LDLIBRARY='libpython$(VERSION).so'
3153 BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
3154 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3155 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003156 atheos*)
3157 LDLIBRARY='libpython$(VERSION).so'
3158 BLDLIBRARY='-L. -lpython$(VERSION)'
3159 RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
3160 ;;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003161 esac
3162 # DG/UX requires some fancy ld contortions to produce a .so from an .a
3163 case $MACHDEP in
3164 dguxR4)
3165 LDLIBRARY='libpython$(VERSION).so'
3166 OPT="$OPT -pic"
3167 ;;
3168 esac
3169fi
3170
Martin v. Löwis11437992002-04-12 09:54:03 +00003171echo "$as_me:$LINENO: result: $LDLIBRARY" >&5
3172echo "${ECHO_T}$LDLIBRARY" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003173
Martin v. Löwis11437992002-04-12 09:54:03 +00003174if test -n "$ac_tool_prefix"; then
3175 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3176set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3177echo "$as_me:$LINENO: checking for $ac_word" >&5
3178echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3179if test "${ac_cv_prog_RANLIB+set}" = set; then
3180 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003181else
3182 if test -n "$RANLIB"; then
3183 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3184else
Martin v. Löwis11437992002-04-12 09:54:03 +00003185as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3186for as_dir in $PATH
3187do
3188 IFS=$as_save_IFS
3189 test -z "$as_dir" && as_dir=.
3190 for ac_exec_ext in '' $ac_executable_extensions; do
3191 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3192 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3193 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3194 break 2
3195 fi
3196done
3197done
3198
Guido van Rossum627b2d71993-12-24 10:39:16 +00003199fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003200fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003201RANLIB=$ac_cv_prog_RANLIB
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003202if test -n "$RANLIB"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003203 echo "$as_me:$LINENO: result: $RANLIB" >&5
3204echo "${ECHO_T}$RANLIB" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003205else
Martin v. Löwis11437992002-04-12 09:54:03 +00003206 echo "$as_me:$LINENO: result: no" >&5
3207echo "${ECHO_T}no" >&6
3208fi
3209
3210fi
3211if test -z "$ac_cv_prog_RANLIB"; then
3212 ac_ct_RANLIB=$RANLIB
3213 # Extract the first word of "ranlib", so it can be a program name with args.
3214set dummy ranlib; ac_word=$2
3215echo "$as_me:$LINENO: checking for $ac_word" >&5
3216echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3217if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3218 echo $ECHO_N "(cached) $ECHO_C" >&6
3219else
3220 if test -n "$ac_ct_RANLIB"; then
3221 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3222else
3223as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3224for as_dir in $PATH
3225do
3226 IFS=$as_save_IFS
3227 test -z "$as_dir" && as_dir=.
3228 for ac_exec_ext in '' $ac_executable_extensions; do
3229 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3230 ac_cv_prog_ac_ct_RANLIB="ranlib"
3231 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3232 break 2
3233 fi
3234done
3235done
3236
3237 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3238fi
3239fi
3240ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3241if test -n "$ac_ct_RANLIB"; then
3242 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3243echo "${ECHO_T}$ac_ct_RANLIB" >&6
3244else
3245 echo "$as_me:$LINENO: result: no" >&5
3246echo "${ECHO_T}no" >&6
3247fi
3248
3249 RANLIB=$ac_ct_RANLIB
3250else
3251 RANLIB="$ac_cv_prog_RANLIB"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003252fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003253
3254
Guido van Rossum7f43da71994-08-01 12:15:30 +00003255for ac_prog in ar aal
3256do
Martin v. Löwis11437992002-04-12 09:54:03 +00003257 # Extract the first word of "$ac_prog", so it can be a program name with args.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003258set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00003259echo "$as_me:$LINENO: checking for $ac_word" >&5
3260echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3261if test "${ac_cv_prog_AR+set}" = set; then
3262 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003263else
3264 if test -n "$AR"; then
3265 ac_cv_prog_AR="$AR" # Let the user override the test.
3266else
Martin v. Löwis11437992002-04-12 09:54:03 +00003267as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3268for as_dir in $PATH
3269do
3270 IFS=$as_save_IFS
3271 test -z "$as_dir" && as_dir=.
3272 for ac_exec_ext in '' $ac_executable_extensions; do
3273 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3274 ac_cv_prog_AR="$ac_prog"
3275 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3276 break 2
3277 fi
3278done
3279done
3280
Guido van Rossum7f43da71994-08-01 12:15:30 +00003281fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003282fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003283AR=$ac_cv_prog_AR
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003284if test -n "$AR"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003285 echo "$as_me:$LINENO: result: $AR" >&5
3286echo "${ECHO_T}$AR" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003287else
Martin v. Löwis11437992002-04-12 09:54:03 +00003288 echo "$as_me:$LINENO: result: no" >&5
3289echo "${ECHO_T}no" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003290fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003291
Martin v. Löwis11437992002-04-12 09:54:03 +00003292 test -n "$AR" && break
Guido van Rossum7f43da71994-08-01 12:15:30 +00003293done
3294test -n "$AR" || AR="ar"
3295
Michael W. Hudson54241132001-12-07 15:38:26 +00003296
Neil Schemenauera42c8272001-03-31 00:01:55 +00003297case $MACHDEP in
Neil Schemenaueraf5567f2001-10-21 22:32:04 +00003298bsdos*|hp*|HP*)
3299 # install -d does not work on BSDI or HP-UX
Neil Schemenauera42c8272001-03-31 00:01:55 +00003300 if test -z "$INSTALL"
3301 then
3302 INSTALL="${srcdir}/install-sh -c"
3303 fi
3304esac
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003305ac_aux_dir=
3306for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
3307 if test -f $ac_dir/install-sh; then
3308 ac_aux_dir=$ac_dir
3309 ac_install_sh="$ac_aux_dir/install-sh -c"
3310 break
3311 elif test -f $ac_dir/install.sh; then
3312 ac_aux_dir=$ac_dir
3313 ac_install_sh="$ac_aux_dir/install.sh -c"
3314 break
Martin v. Löwis11437992002-04-12 09:54:03 +00003315 elif test -f $ac_dir/shtool; then
3316 ac_aux_dir=$ac_dir
3317 ac_install_sh="$ac_aux_dir/shtool install -c"
3318 break
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003319 fi
3320done
3321if test -z "$ac_aux_dir"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003322 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
3323echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
3324 { (exit 1); exit 1; }; }
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003325fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003326ac_config_guess="$SHELL $ac_aux_dir/config.guess"
3327ac_config_sub="$SHELL $ac_aux_dir/config.sub"
3328ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003329
3330# Find a good install program. We prefer a C program (faster),
3331# so one script is as good as another. But avoid the broken or
3332# incompatible versions:
3333# SysV /etc/install, /usr/sbin/install
3334# SunOS /usr/etc/install
3335# IRIX /sbin/install
3336# AIX /bin/install
Martin v. Löwis11437992002-04-12 09:54:03 +00003337# AmigaOS /C/install, which installs bootblocks on floppy discs
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003338# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3339# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3340# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3341# ./install, which can be erroneously created by make from ./install.sh.
Martin v. Löwis11437992002-04-12 09:54:03 +00003342echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3343echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003344if test -z "$INSTALL"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003345if test "${ac_cv_path_install+set}" = set; then
3346 echo $ECHO_N "(cached) $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003347else
Martin v. Löwis11437992002-04-12 09:54:03 +00003348 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3349for as_dir in $PATH
3350do
3351 IFS=$as_save_IFS
3352 test -z "$as_dir" && as_dir=.
3353 # Account for people who put trailing slashes in PATH elements.
3354case $as_dir/ in
3355 ./ | .// | /cC/* | \
3356 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3357 /usr/ucb/* ) ;;
3358 *)
3359 # OSF1 and SCO ODT 3.0 have their own names for install.
3360 # Don't use installbsd from OSF since it installs stuff as root
3361 # by default.
3362 for ac_prog in ginstall scoinst install; do
3363 for ac_exec_ext in '' $ac_executable_extensions; do
3364 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3365 if test $ac_prog = install &&
3366 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3367 # AIX install. It has an incompatible calling convention.
3368 :
3369 elif test $ac_prog = install &&
3370 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3371 # program-specific install script used by HP pwplus--don't use.
3372 :
3373 else
3374 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3375 break 3
3376 fi
3377 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003378 done
Martin v. Löwis11437992002-04-12 09:54:03 +00003379 done
3380 ;;
3381esac
3382done
3383
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003384
3385fi
3386 if test "${ac_cv_path_install+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003387 INSTALL=$ac_cv_path_install
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003388 else
3389 # As a last resort, use the slow shell script. We don't cache a
3390 # path for INSTALL within a source directory, because that will
3391 # break other packages using the cache if that directory is
3392 # removed, or if the path is relative.
Martin v. Löwis11437992002-04-12 09:54:03 +00003393 INSTALL=$ac_install_sh
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003394 fi
3395fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003396echo "$as_me:$LINENO: result: $INSTALL" >&5
3397echo "${ECHO_T}$INSTALL" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003398
3399# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3400# It thinks the first close brace ends the variable substitution.
3401test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3402
Martin v. Löwis11437992002-04-12 09:54:03 +00003403test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003404
3405test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3406
Michael W. Hudson54241132001-12-07 15:38:26 +00003407
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003408# Not every filesystem supports hard links
3409
3410if test -z "$LN" ; then
3411 case $ac_sys_system in
3412 BeOS*) LN="ln -s";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00003413 CYGWIN*) LN="ln -s";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003414 atheos*) LN="ln -s";;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003415 *) LN=ln;;
3416 esac
3417fi
3418
Fred Drake109d9862001-07-11 06:27:56 +00003419# Check for --with-pydebug
Martin v. Löwis11437992002-04-12 09:54:03 +00003420echo "$as_me:$LINENO: checking for --with-pydebug" >&5
3421echo $ECHO_N "checking for --with-pydebug... $ECHO_C" >&6
3422
Fred Drake109d9862001-07-11 06:27:56 +00003423# Check whether --with-pydebug or --without-pydebug was given.
3424if test "${with_pydebug+set}" = set; then
3425 withval="$with_pydebug"
Martin v. Löwis11437992002-04-12 09:54:03 +00003426
Fred Drake109d9862001-07-11 06:27:56 +00003427if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +00003428then
3429
3430cat >>confdefs.h <<\_ACEOF
Fred Drake109d9862001-07-11 06:27:56 +00003431#define Py_DEBUG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003432_ACEOF
3433
3434 echo "$as_me:$LINENO: result: yes" >&5
3435echo "${ECHO_T}yes" >&6;
Martin v. Löwisc45929e2002-04-06 10:10:49 +00003436 Py_DEBUG='true'
Martin v. Löwis11437992002-04-12 09:54:03 +00003437else echo "$as_me:$LINENO: result: no" >&5
3438echo "${ECHO_T}no" >&6; Py_DEBUG='false'
Fred Drake109d9862001-07-11 06:27:56 +00003439fi
3440else
Martin v. Löwis11437992002-04-12 09:54:03 +00003441 echo "$as_me:$LINENO: result: no" >&5
3442echo "${ECHO_T}no" >&6
3443fi;
Fred Drake109d9862001-07-11 06:27:56 +00003444
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003445# Optimizer/debugger flags
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003446
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003447if test -z "$OPT"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003448then
Neal Norwitzd957f392002-09-25 21:26:19 +00003449 case $GCC in
Guido van Rossumedca74a1997-07-18 23:29:40 +00003450 yes)
3451 case $ac_cv_prog_cc_g in
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003452 yes)
Fred Drake109d9862001-07-11 06:27:56 +00003453 if test "$Py_DEBUG" = 'true' ; then
3454 # Optimization messes up debuggers, so turn it off for
3455 # debug builds.
3456 OPT="-g -Wall -Wstrict-prototypes"
3457 else
3458 OPT="-g -O3 -Wall -Wstrict-prototypes"
3459 fi;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003460 *)
Fred Drake109d9862001-07-11 06:27:56 +00003461 OPT="-O3 -Wall -Wstrict-prototypes";;
3462 esac
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003463 case $ac_sys_system in
3464 SCO_SV*) OPT="$OPT -m486 -DSCO5";;
3465 esac
Fred Drake109d9862001-07-11 06:27:56 +00003466 ;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003467 *)
3468 case $ac_sys_system in
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00003469 OpenUNIX*|UnixWare*)
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003470 OPT="-O -K pentium,host,inline,loop_unroll,alloca ";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003471 SCO_SV*)
3472 CFLAGS="$CFLAGS -belf"
3473 OPT="-belf -O -Ki486 -DSCO5";;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003474 *)
3475 OPT="-O";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003476 esac
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003477 esac
Jack Jansenca06bc62001-08-03 15:32:23 +00003478 case $ac_sys_system in
3479 Darwin*)
Jack Jansen524a0982002-03-12 15:25:52 +00003480 OPT="$OPT -Wno-long-double -no-cpp-precomp";;
Jack Jansenca06bc62001-08-03 15:32:23 +00003481 esac
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003482fi
3483
Fred Drakee1ceaa02001-12-04 20:55:47 +00003484if test "$Py_DEBUG" = 'true'; then
3485 :
3486else
3487 OPT="-DNDEBUG $OPT"
3488fi
3489
Trent Mick635f6fb2000-08-23 21:33:05 +00003490# The current (beta) Monterey compiler dies with optimizations
3491case $ac_sys_system in
3492Monterey*) OPT="";;
3493esac
3494
Guido van Rossum563e7081996-09-10 18:20:48 +00003495if test "$ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +00003496then
3497 OPT="$OPT $ac_arch_flags"
3498fi
Guido van Rossumda88dad1995-01-26 00:46:29 +00003499
Martin v. Löwis11437992002-04-12 09:54:03 +00003500echo "$as_me:$LINENO: checking whether $CC accepts -OPT:Olimit=0" >&5
3501echo $ECHO_N "checking whether $CC accepts -OPT:Olimit=0... $ECHO_C" >&6
3502if test "${ac_cv_opt_olimit_ok+set}" = set; then
3503 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum91922671997-10-09 20:24:13 +00003504else
3505 ac_save_cc="$CC"
3506CC="$CC -OPT:Olimit=0"
3507if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00003508 ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00003509else
Martin v. Löwis11437992002-04-12 09:54:03 +00003510 cat >conftest.$ac_ext <<_ACEOF
3511#line $LINENO "configure"
Guido van Rossum91922671997-10-09 20:24:13 +00003512#include "confdefs.h"
3513int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003514_ACEOF
3515rm -f conftest$ac_exeext
3516if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3517 (eval $ac_link) 2>&5
3518 ac_status=$?
3519 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3520 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3521 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3522 (eval $ac_try) 2>&5
3523 ac_status=$?
3524 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3525 (exit $ac_status); }; }; then
Guido van Rossum91922671997-10-09 20:24:13 +00003526 ac_cv_opt_olimit_ok=yes
3527else
Martin v. Löwis11437992002-04-12 09:54:03 +00003528 echo "$as_me: program exited with status $ac_status" >&5
3529echo "$as_me: failed program was:" >&5
3530cat conftest.$ac_ext >&5
3531( exit $ac_status )
3532ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00003533fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003534rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum91922671997-10-09 20:24:13 +00003535fi
Guido van Rossum91922671997-10-09 20:24:13 +00003536CC="$ac_save_cc"
3537fi
3538
Martin v. Löwis11437992002-04-12 09:54:03 +00003539echo "$as_me:$LINENO: result: $ac_cv_opt_olimit_ok" >&5
3540echo "${ECHO_T}$ac_cv_opt_olimit_ok" >&6
Guido van Rossum2efa34b1997-10-23 17:43:11 +00003541if test $ac_cv_opt_olimit_ok = yes; then
Guido van Rossum5839e582000-10-09 19:52:35 +00003542 case $ac_sys_system in
3543 Darwin*) OPT="$OPT" ;;
3544 *) OPT="$OPT -OPT:Olimit=0";;
3545 esac
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003546else
Martin v. Löwis11437992002-04-12 09:54:03 +00003547 echo "$as_me:$LINENO: checking whether $CC accepts -Olimit 1500" >&5
3548echo $ECHO_N "checking whether $CC accepts -Olimit 1500... $ECHO_C" >&6
3549 if test "${ac_cv_olimit_ok+set}" = set; then
3550 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003551else
3552 ac_save_cc="$CC"
3553 CC="$CC -Olimit 1500"
3554 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00003555 ac_cv_olimit_ok=no
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003556else
Martin v. Löwis11437992002-04-12 09:54:03 +00003557 cat >conftest.$ac_ext <<_ACEOF
3558#line $LINENO "configure"
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003559#include "confdefs.h"
3560int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003561_ACEOF
3562rm -f conftest$ac_exeext
3563if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3564 (eval $ac_link) 2>&5
3565 ac_status=$?
3566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3567 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3568 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3569 (eval $ac_try) 2>&5
3570 ac_status=$?
3571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3572 (exit $ac_status); }; }; then
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003573 ac_cv_olimit_ok=yes
3574else
Martin v. Löwis11437992002-04-12 09:54:03 +00003575 echo "$as_me: program exited with status $ac_status" >&5
3576echo "$as_me: failed program was:" >&5
3577cat conftest.$ac_ext >&5
3578( exit $ac_status )
3579ac_cv_olimit_ok=no
Guido van Rossum201afe51997-05-14 21:14:44 +00003580fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003581rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003582fi
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003583 CC="$ac_save_cc"
3584fi
3585
Martin v. Löwis11437992002-04-12 09:54:03 +00003586 echo "$as_me:$LINENO: result: $ac_cv_olimit_ok" >&5
3587echo "${ECHO_T}$ac_cv_olimit_ok" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003588 if test $ac_cv_olimit_ok = yes; then
3589 OPT="$OPT -Olimit 1500"
3590 fi
3591fi
3592
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003593# On some compilers, pthreads are available without further options
3594# (e.g. MacOS X). On some of these systems, the compiler will not
3595# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
3596# So we have to see first whether pthreads are available without
3597# options before we can check whether -Kpthread improves anything.
Martin v. Löwis11437992002-04-12 09:54:03 +00003598echo "$as_me:$LINENO: checking whether pthreads are available without options" >&5
3599echo $ECHO_N "checking whether pthreads are available without options... $ECHO_C" >&6
3600if test "${ac_cv_pthread_is_default+set}" = set; then
3601 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis130fb172001-07-19 11:00:41 +00003602else
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003603 if test "$cross_compiling" = yes; then
3604 ac_cv_pthread_is_default=no
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003605else
Martin v. Löwis11437992002-04-12 09:54:03 +00003606 cat >conftest.$ac_ext <<_ACEOF
3607#line $LINENO "configure"
Martin v. Löwis130fb172001-07-19 11:00:41 +00003608#include "confdefs.h"
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003609
Martin v. Löwis130fb172001-07-19 11:00:41 +00003610#include <pthread.h>
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003611
3612void* routine(void* p){return NULL;}
3613
3614int main(){
3615 pthread_t p;
3616 if(pthread_create(&p,NULL,routine,NULL)!=0)
3617 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00003618 (void)pthread_detach(p);
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003619 return 0;
3620}
3621
Martin v. Löwis11437992002-04-12 09:54:03 +00003622_ACEOF
3623rm -f conftest$ac_exeext
3624if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3625 (eval $ac_link) 2>&5
3626 ac_status=$?
3627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3628 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3629 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3630 (eval $ac_try) 2>&5
3631 ac_status=$?
3632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3633 (exit $ac_status); }; }; then
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003634 ac_cv_pthread_is_default=yes
3635else
Martin v. Löwis11437992002-04-12 09:54:03 +00003636 echo "$as_me: program exited with status $ac_status" >&5
3637echo "$as_me: failed program was:" >&5
3638cat conftest.$ac_ext >&5
3639( exit $ac_status )
3640ac_cv_pthread_is_default=no
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003641fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003642rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003643fi
3644
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003645fi
3646
Martin v. Löwis11437992002-04-12 09:54:03 +00003647echo "$as_me:$LINENO: result: $ac_cv_pthread_is_default" >&5
3648echo "${ECHO_T}$ac_cv_pthread_is_default" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003649
Michael W. Hudson54241132001-12-07 15:38:26 +00003650
Martin v. Löwis11437992002-04-12 09:54:03 +00003651if test $ac_cv_pthread_is_default = yes
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003652then
3653 ac_cv_kpthread=no
3654else
3655# -Kpthread, if available, provides the right #defines
3656# and linker options to make pthread_create available
3657# Some compilers won't report that they do not support -Kpthread,
3658# so we need to run a program to see whether it really made the
3659# function available.
Martin v. Löwis11437992002-04-12 09:54:03 +00003660echo "$as_me:$LINENO: checking whether $CC accepts -Kpthread" >&5
3661echo $ECHO_N "checking whether $CC accepts -Kpthread... $ECHO_C" >&6
3662if test "${ac_cv_kpthread+set}" = set; then
3663 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003664else
3665 ac_save_cc="$CC"
3666CC="$CC -Kpthread"
3667if test "$cross_compiling" = yes; then
3668 ac_cv_kpthread=no
3669else
Martin v. Löwis11437992002-04-12 09:54:03 +00003670 cat >conftest.$ac_ext <<_ACEOF
3671#line $LINENO "configure"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003672#include "confdefs.h"
3673
3674#include <pthread.h>
3675
3676void* routine(void* p){return NULL;}
3677
3678int main(){
3679 pthread_t p;
3680 if(pthread_create(&p,NULL,routine,NULL)!=0)
3681 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00003682 (void)pthread_detach(p);
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003683 return 0;
3684}
3685
Martin v. Löwis11437992002-04-12 09:54:03 +00003686_ACEOF
3687rm -f conftest$ac_exeext
3688if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3689 (eval $ac_link) 2>&5
3690 ac_status=$?
3691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3692 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3693 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3694 (eval $ac_try) 2>&5
3695 ac_status=$?
3696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3697 (exit $ac_status); }; }; then
Martin v. Löwis130fb172001-07-19 11:00:41 +00003698 ac_cv_kpthread=yes
3699else
Martin v. Löwis11437992002-04-12 09:54:03 +00003700 echo "$as_me: program exited with status $ac_status" >&5
3701echo "$as_me: failed program was:" >&5
3702cat conftest.$ac_ext >&5
3703( exit $ac_status )
3704ac_cv_kpthread=no
Martin v. Löwis130fb172001-07-19 11:00:41 +00003705fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003706rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003707fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00003708CC="$ac_save_cc"
3709fi
3710
Martin v. Löwis11437992002-04-12 09:54:03 +00003711echo "$as_me:$LINENO: result: $ac_cv_kpthread" >&5
3712echo "${ECHO_T}$ac_cv_kpthread" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003713fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00003714
Michael W. Hudson54241132001-12-07 15:38:26 +00003715
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003716# checks for header files
Martin v. Löwis11437992002-04-12 09:54:03 +00003717echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3718echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
3719if test "${ac_cv_header_stdc+set}" = set; then
3720 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003721else
Martin v. Löwis11437992002-04-12 09:54:03 +00003722 cat >conftest.$ac_ext <<_ACEOF
3723#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003724#include "confdefs.h"
3725#include <stdlib.h>
3726#include <stdarg.h>
3727#include <string.h>
3728#include <float.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003729
3730_ACEOF
3731if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3732 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3733 ac_status=$?
3734 egrep -v '^ *\+' conftest.er1 >conftest.err
3735 rm -f conftest.er1
3736 cat conftest.err >&5
3737 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3738 (exit $ac_status); } >/dev/null; then
3739 if test -s conftest.err; then
3740 ac_cpp_err=$ac_c_preproc_warn_flag
3741 else
3742 ac_cpp_err=
3743 fi
3744else
3745 ac_cpp_err=yes
3746fi
3747if test -z "$ac_cpp_err"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003748 ac_cv_header_stdc=yes
3749else
Martin v. Löwis11437992002-04-12 09:54:03 +00003750 echo "$as_me: failed program was:" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00003751 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003752 ac_cv_header_stdc=no
3753fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003754rm -f conftest.err conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003755
3756if test $ac_cv_header_stdc = yes; then
3757 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00003758 cat >conftest.$ac_ext <<_ACEOF
3759#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003760#include "confdefs.h"
3761#include <string.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003762
3763_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003764if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3765 egrep "memchr" >/dev/null 2>&1; then
3766 :
3767else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003768 ac_cv_header_stdc=no
3769fi
3770rm -f conftest*
3771
3772fi
3773
3774if test $ac_cv_header_stdc = yes; then
3775 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00003776 cat >conftest.$ac_ext <<_ACEOF
3777#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003778#include "confdefs.h"
3779#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003780
3781_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003782if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3783 egrep "free" >/dev/null 2>&1; then
3784 :
3785else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003786 ac_cv_header_stdc=no
3787fi
3788rm -f conftest*
3789
3790fi
3791
3792if test $ac_cv_header_stdc = yes; then
3793 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
Martin v. Löwis11437992002-04-12 09:54:03 +00003794 if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003795 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003796else
Martin v. Löwis11437992002-04-12 09:54:03 +00003797 cat >conftest.$ac_ext <<_ACEOF
3798#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003799#include "confdefs.h"
3800#include <ctype.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003801#if ((' ' & 0x0FF) == 0x020)
3802# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3803# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3804#else
3805# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
3806 || ('j' <= (c) && (c) <= 'r') \
3807 || ('s' <= (c) && (c) <= 'z'))
3808# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3809#endif
Michael W. Hudson54241132001-12-07 15:38:26 +00003810
Martin v. Löwis11437992002-04-12 09:54:03 +00003811#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3812int
3813main ()
3814{
3815 int i;
3816 for (i = 0; i < 256; i++)
3817 if (XOR (islower (i), ISLOWER (i))
3818 || toupper (i) != TOUPPER (i))
3819 exit(2);
3820 exit (0);
3821}
3822_ACEOF
3823rm -f conftest$ac_exeext
3824if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3825 (eval $ac_link) 2>&5
3826 ac_status=$?
3827 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3828 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3829 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3830 (eval $ac_try) 2>&5
3831 ac_status=$?
3832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3833 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003834 :
3835else
Martin v. Löwis11437992002-04-12 09:54:03 +00003836 echo "$as_me: program exited with status $ac_status" >&5
3837echo "$as_me: failed program was:" >&5
3838cat conftest.$ac_ext >&5
3839( exit $ac_status )
3840ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00003841fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003842rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00003843fi
3844fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003845fi
3846echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3847echo "${ECHO_T}$ac_cv_header_stdc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00003848if test $ac_cv_header_stdc = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003849
3850cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003851#define STDC_HEADERS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003852_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00003853
3854fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003855
Martin v. Löwis11437992002-04-12 09:54:03 +00003856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
Martin v. Löwis11437992002-04-12 09:54:03 +00003893for ac_header in dlfcn.h fcntl.h grp.h limits.h langinfo.h \
Martin v. Löwis2e64c342002-03-27 18:49:02 +00003894libintl.h locale.h ncurses.h poll.h pthread.h \
Eric S. Raymondd2d75d32001-01-16 15:26:34 +00003895signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h termios.h \
Skip Montanaro57454e52002-06-14 20:30:31 +00003896sys/audioio.h sys/file.h sys/lock.h sys/mkdev.h sys/modem.h \
Andrew M. Kuchling881fd902001-07-14 20:55:52 +00003897sys/param.h sys/poll.h sys/select.h sys/socket.h sys/time.h sys/times.h \
Martin v. Löwis69532332001-10-13 09:12:41 +00003898sys/un.h sys/utsname.h sys/wait.h pty.h term.h libutil.h \
Skip Montanaro8345f712002-06-25 05:53:48 +00003899sys/resource.h netpacket/packet.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00003900do
Martin v. Löwis11437992002-04-12 09:54:03 +00003901as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3902if eval "test \"\${$as_ac_Header+set}\" = set"; then
3903 echo "$as_me:$LINENO: checking for $ac_header" >&5
3904echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3905if eval "test \"\${$as_ac_Header+set}\" = set"; then
3906 echo $ECHO_N "(cached) $ECHO_C" >&6
3907fi
3908echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3909echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003910else
Martin v. Löwis11437992002-04-12 09:54:03 +00003911 # Is the header compilable?
3912echo "$as_me:$LINENO: checking $ac_header usability" >&5
3913echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
3914cat >conftest.$ac_ext <<_ACEOF
3915#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003916#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00003917$ac_includes_default
3918#include <$ac_header>
3919_ACEOF
3920rm -f conftest.$ac_objext
3921if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3922 (eval $ac_compile) 2>&5
3923 ac_status=$?
3924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3925 (exit $ac_status); } &&
3926 { ac_try='test -s conftest.$ac_objext'
3927 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3928 (eval $ac_try) 2>&5
3929 ac_status=$?
3930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3931 (exit $ac_status); }; }; then
3932 ac_header_compiler=yes
Michael W. Hudson54241132001-12-07 15:38:26 +00003933else
Martin v. Löwis11437992002-04-12 09:54:03 +00003934 echo "$as_me: failed program was:" >&5
3935cat conftest.$ac_ext >&5
3936ac_header_compiler=no
3937fi
3938rm -f conftest.$ac_objext conftest.$ac_ext
3939echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
3940echo "${ECHO_T}$ac_header_compiler" >&6
3941
3942# Is the header present?
3943echo "$as_me:$LINENO: checking $ac_header presence" >&5
3944echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
3945cat >conftest.$ac_ext <<_ACEOF
3946#line $LINENO "configure"
3947#include "confdefs.h"
3948#include <$ac_header>
3949_ACEOF
3950if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3951 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3952 ac_status=$?
3953 egrep -v '^ *\+' conftest.er1 >conftest.err
3954 rm -f conftest.er1
3955 cat conftest.err >&5
3956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3957 (exit $ac_status); } >/dev/null; then
3958 if test -s conftest.err; then
3959 ac_cpp_err=$ac_c_preproc_warn_flag
3960 else
3961 ac_cpp_err=
3962 fi
3963else
3964 ac_cpp_err=yes
3965fi
3966if test -z "$ac_cpp_err"; then
3967 ac_header_preproc=yes
3968else
3969 echo "$as_me: failed program was:" >&5
Michael W. Hudson54241132001-12-07 15:38:26 +00003970 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00003971 ac_header_preproc=no
Michael W. Hudson54241132001-12-07 15:38:26 +00003972fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003973rm -f conftest.err conftest.$ac_ext
3974echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
3975echo "${ECHO_T}$ac_header_preproc" >&6
3976
3977# So? What about this header?
3978case $ac_header_compiler:$ac_header_preproc in
3979 yes:no )
3980 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
3981echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
3982 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
3983echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
3984 no:yes )
3985 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
3986echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
3987 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
3988echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
3989 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
3990echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
3991esac
3992echo "$as_me:$LINENO: checking for $ac_header" >&5
3993echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3994if eval "test \"\${$as_ac_Header+set}\" = set"; then
3995 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00003996else
Martin v. Löwis11437992002-04-12 09:54:03 +00003997 eval "$as_ac_Header=$ac_header_preproc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003998fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003999echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4000echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4001
4002fi
4003if test `eval echo '${'$as_ac_Header'}'` = yes; then
4004 cat >>confdefs.h <<_ACEOF
4005#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4006_ACEOF
4007
4008fi
4009
Guido van Rossum627b2d71993-12-24 10:39:16 +00004010done
4011
Martin v. Löwis11437992002-04-12 09:54:03 +00004012
4013
4014
4015
4016
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004017ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004018for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
4019 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
4020echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
4021echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
4022if eval "test \"\${$as_ac_Header+set}\" = set"; then
4023 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00004024else
Martin v. Löwis11437992002-04-12 09:54:03 +00004025 cat >conftest.$ac_ext <<_ACEOF
4026#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004027#include "confdefs.h"
4028#include <sys/types.h>
4029#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00004030
4031#ifdef F77_DUMMY_MAIN
4032# ifdef __cplusplus
4033 extern "C"
4034# endif
4035 int F77_DUMMY_MAIN() { return 1; }
4036#endif
4037int
4038main ()
4039{
4040if ((DIR *) 0)
4041return 0;
4042 ;
4043 return 0;
4044}
4045_ACEOF
4046rm -f conftest.$ac_objext
4047if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4048 (eval $ac_compile) 2>&5
4049 ac_status=$?
4050 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4051 (exit $ac_status); } &&
4052 { ac_try='test -s conftest.$ac_objext'
4053 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4054 (eval $ac_try) 2>&5
4055 ac_status=$?
4056 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4057 (exit $ac_status); }; }; then
4058 eval "$as_ac_Header=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +00004059else
Martin v. Löwis11437992002-04-12 09:54:03 +00004060 echo "$as_me: failed program was:" >&5
4061cat conftest.$ac_ext >&5
4062eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004063fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004064rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004065fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004066echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4067echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4068if test `eval echo '${'$as_ac_Header'}'` = yes; then
4069 cat >>confdefs.h <<_ACEOF
4070#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
4071_ACEOF
4072
4073ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00004074fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004075
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004076done
4077# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4078if test $ac_header_dirent = dirent.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004079 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4080echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4081if test "${ac_cv_search_opendir+set}" = set; then
4082 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004083else
Martin v. Löwis11437992002-04-12 09:54:03 +00004084 ac_func_search_save_LIBS=$LIBS
4085ac_cv_search_opendir=no
4086cat >conftest.$ac_ext <<_ACEOF
4087#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004088#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004089
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004090/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004091#ifdef __cplusplus
4092extern "C"
4093#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004094/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004095 builtin and then its argument prototype would still apply. */
4096char opendir ();
4097#ifdef F77_DUMMY_MAIN
4098# ifdef __cplusplus
4099 extern "C"
4100# endif
4101 int F77_DUMMY_MAIN() { return 1; }
4102#endif
4103int
4104main ()
4105{
4106opendir ();
4107 ;
4108 return 0;
4109}
4110_ACEOF
4111rm -f conftest.$ac_objext conftest$ac_exeext
4112if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4113 (eval $ac_link) 2>&5
4114 ac_status=$?
4115 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4116 (exit $ac_status); } &&
4117 { ac_try='test -s conftest$ac_exeext'
4118 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4119 (eval $ac_try) 2>&5
4120 ac_status=$?
4121 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4122 (exit $ac_status); }; }; then
4123 ac_cv_search_opendir="none required"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004124else
Martin v. Löwis11437992002-04-12 09:54:03 +00004125 echo "$as_me: failed program was:" >&5
4126cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004127fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004128rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4129if test "$ac_cv_search_opendir" = no; then
4130 for ac_lib in dir; do
4131 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4132 cat >conftest.$ac_ext <<_ACEOF
4133#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004134#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004135
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004136/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004137#ifdef __cplusplus
4138extern "C"
4139#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004140/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004141 builtin and then its argument prototype would still apply. */
4142char opendir ();
4143#ifdef F77_DUMMY_MAIN
4144# ifdef __cplusplus
4145 extern "C"
4146# endif
4147 int F77_DUMMY_MAIN() { return 1; }
4148#endif
4149int
4150main ()
4151{
4152opendir ();
4153 ;
4154 return 0;
4155}
4156_ACEOF
4157rm -f conftest.$ac_objext conftest$ac_exeext
4158if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4159 (eval $ac_link) 2>&5
4160 ac_status=$?
4161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4162 (exit $ac_status); } &&
4163 { ac_try='test -s conftest$ac_exeext'
4164 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4165 (eval $ac_try) 2>&5
4166 ac_status=$?
4167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4168 (exit $ac_status); }; }; then
4169 ac_cv_search_opendir="-l$ac_lib"
4170break
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004171else
Martin v. Löwis11437992002-04-12 09:54:03 +00004172 echo "$as_me: failed program was:" >&5
4173cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004174fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004175rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4176 done
4177fi
4178LIBS=$ac_func_search_save_LIBS
4179fi
4180echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4181echo "${ECHO_T}$ac_cv_search_opendir" >&6
4182if test "$ac_cv_search_opendir" != no; then
4183 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00004184
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004185fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004186
Michael W. Hudson54241132001-12-07 15:38:26 +00004187else
Martin v. Löwis11437992002-04-12 09:54:03 +00004188 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4189echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4190if test "${ac_cv_search_opendir+set}" = set; then
4191 echo $ECHO_N "(cached) $ECHO_C" >&6
4192else
4193 ac_func_search_save_LIBS=$LIBS
4194ac_cv_search_opendir=no
4195cat >conftest.$ac_ext <<_ACEOF
4196#line $LINENO "configure"
4197#include "confdefs.h"
4198
4199/* Override any gcc2 internal prototype to avoid an error. */
4200#ifdef __cplusplus
4201extern "C"
4202#endif
4203/* We use char because int might match the return type of a gcc2
4204 builtin and then its argument prototype would still apply. */
4205char opendir ();
4206#ifdef F77_DUMMY_MAIN
4207# ifdef __cplusplus
4208 extern "C"
4209# endif
4210 int F77_DUMMY_MAIN() { return 1; }
4211#endif
4212int
4213main ()
4214{
4215opendir ();
4216 ;
4217 return 0;
4218}
4219_ACEOF
4220rm -f conftest.$ac_objext conftest$ac_exeext
4221if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4222 (eval $ac_link) 2>&5
4223 ac_status=$?
4224 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4225 (exit $ac_status); } &&
4226 { ac_try='test -s conftest$ac_exeext'
4227 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4228 (eval $ac_try) 2>&5
4229 ac_status=$?
4230 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4231 (exit $ac_status); }; }; then
4232 ac_cv_search_opendir="none required"
4233else
4234 echo "$as_me: failed program was:" >&5
4235cat conftest.$ac_ext >&5
4236fi
4237rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4238if test "$ac_cv_search_opendir" = no; then
4239 for ac_lib in x; do
4240 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4241 cat >conftest.$ac_ext <<_ACEOF
4242#line $LINENO "configure"
4243#include "confdefs.h"
4244
4245/* Override any gcc2 internal prototype to avoid an error. */
4246#ifdef __cplusplus
4247extern "C"
4248#endif
4249/* We use char because int might match the return type of a gcc2
4250 builtin and then its argument prototype would still apply. */
4251char opendir ();
4252#ifdef F77_DUMMY_MAIN
4253# ifdef __cplusplus
4254 extern "C"
4255# endif
4256 int F77_DUMMY_MAIN() { return 1; }
4257#endif
4258int
4259main ()
4260{
4261opendir ();
4262 ;
4263 return 0;
4264}
4265_ACEOF
4266rm -f conftest.$ac_objext conftest$ac_exeext
4267if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4268 (eval $ac_link) 2>&5
4269 ac_status=$?
4270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4271 (exit $ac_status); } &&
4272 { ac_try='test -s conftest$ac_exeext'
4273 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4274 (eval $ac_try) 2>&5
4275 ac_status=$?
4276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4277 (exit $ac_status); }; }; then
4278 ac_cv_search_opendir="-l$ac_lib"
4279break
4280else
4281 echo "$as_me: failed program was:" >&5
4282cat conftest.$ac_ext >&5
4283fi
4284rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4285 done
4286fi
4287LIBS=$ac_func_search_save_LIBS
4288fi
4289echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4290echo "${ECHO_T}$ac_cv_search_opendir" >&6
4291if test "$ac_cv_search_opendir" != no; then
4292 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
4293
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004294fi
4295
4296fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00004297
Michael W. Hudson54241132001-12-07 15:38:26 +00004298
Guido van Rossum627b2d71993-12-24 10:39:16 +00004299# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00004300was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004301echo "$as_me:$LINENO: checking for clock_t in time.h" >&5
4302echo $ECHO_N "checking for clock_t in time.h... $ECHO_C" >&6
4303cat >conftest.$ac_ext <<_ACEOF
4304#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004305#include "confdefs.h"
4306#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004307
4308_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004309if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4310 egrep "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00004311 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004312else
Martin v. Löwis11437992002-04-12 09:54:03 +00004313
4314
4315cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004316#define clock_t long
Martin v. Löwis11437992002-04-12 09:54:03 +00004317_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004318
Martin v. Löwisc45929e2002-04-06 10:10:49 +00004319
Guido van Rossum627b2d71993-12-24 10:39:16 +00004320fi
4321rm -f conftest*
4322
Martin v. Löwis11437992002-04-12 09:54:03 +00004323echo "$as_me:$LINENO: result: $was_it_defined" >&5
4324echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00004325
Neal Norwitz11690112002-07-30 01:08:28 +00004326# Check whether using makedev requires defining _OSF_SOURCE
4327echo "$as_me:$LINENO: checking for makedev" >&5
4328echo $ECHO_N "checking for makedev... $ECHO_C" >&6
4329cat >conftest.$ac_ext <<_ACEOF
4330#line $LINENO "configure"
4331#include "confdefs.h"
4332 #include <sys/types.h>
4333#ifdef F77_DUMMY_MAIN
4334# ifdef __cplusplus
4335 extern "C"
4336# endif
4337 int F77_DUMMY_MAIN() { return 1; }
4338#endif
4339int
4340main ()
4341{
4342 makedev(0, 0)
4343 ;
4344 return 0;
4345}
4346_ACEOF
4347rm -f conftest.$ac_objext conftest$ac_exeext
4348if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4349 (eval $ac_link) 2>&5
4350 ac_status=$?
4351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4352 (exit $ac_status); } &&
4353 { ac_try='test -s conftest$ac_exeext'
4354 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4355 (eval $ac_try) 2>&5
4356 ac_status=$?
4357 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4358 (exit $ac_status); }; }; then
4359 ac_cv_has_makedev=yes
4360else
4361 echo "$as_me: failed program was:" >&5
4362cat conftest.$ac_ext >&5
4363ac_cv_has_makedev=no
4364fi
4365rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4366if test "$ac_cv_has_makedev" = "no"; then
4367 # we didn't link, try if _OSF_SOURCE will allow us to link
4368 cat >conftest.$ac_ext <<_ACEOF
4369#line $LINENO "configure"
4370#include "confdefs.h"
4371
4372 #define _OSF_SOURCE 1
4373 #include <sys/types.h>
4374
4375#ifdef F77_DUMMY_MAIN
4376# ifdef __cplusplus
4377 extern "C"
4378# endif
4379 int F77_DUMMY_MAIN() { return 1; }
4380#endif
4381int
4382main ()
4383{
4384 makedev(0, 0)
4385 ;
4386 return 0;
4387}
4388_ACEOF
4389rm -f conftest.$ac_objext conftest$ac_exeext
4390if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4391 (eval $ac_link) 2>&5
4392 ac_status=$?
4393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4394 (exit $ac_status); } &&
4395 { ac_try='test -s conftest$ac_exeext'
4396 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4397 (eval $ac_try) 2>&5
4398 ac_status=$?
4399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4400 (exit $ac_status); }; }; then
4401 ac_cv_has_makedev=yes
4402else
4403 echo "$as_me: failed program was:" >&5
4404cat conftest.$ac_ext >&5
4405ac_cv_has_makedev=no
4406fi
4407rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4408 if test "$ac_cv_has_makedev" = "yes"; then
4409
4410cat >>confdefs.h <<\_ACEOF
4411#define _OSF_SOURCE 1
4412_ACEOF
4413
4414 fi
4415fi
4416echo "$as_me:$LINENO: result: $ac_cv_has_makedev" >&5
4417echo "${ECHO_T}$ac_cv_has_makedev" >&6
4418if test "$ac_cv_has_makedev" = "yes"; then
4419
4420cat >>confdefs.h <<\_ACEOF
4421#define HAVE_MAKEDEV 1
4422_ACEOF
4423
4424fi
4425
Martin v. Löwis399a6892002-10-04 10:22:02 +00004426# Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in
4427# the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are
4428# defined, but the compiler does not support pragma redefine_extname,
4429# and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit
4430# structures (such as rlimit64) without declaring them. As a
4431# work-around, disable LFS on such configurations
4432
4433use_lfs=yes
4434echo "$as_me:$LINENO: checking Solaris LFS bug" >&5
4435echo $ECHO_N "checking Solaris LFS bug... $ECHO_C" >&6
4436cat >conftest.$ac_ext <<_ACEOF
4437#line $LINENO "configure"
4438#include "confdefs.h"
4439
4440#define _LARGEFILE_SOURCE 1
4441#define _FILE_OFFSET_BITS 64
4442#include <sys/resource.h>
4443
4444#ifdef F77_DUMMY_MAIN
4445# ifdef __cplusplus
4446 extern "C"
4447# endif
4448 int F77_DUMMY_MAIN() { return 1; }
4449#endif
4450int
4451main ()
4452{
4453struct rlimit foo;
4454 ;
4455 return 0;
4456}
4457_ACEOF
4458rm -f conftest.$ac_objext
4459if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4460 (eval $ac_compile) 2>&5
4461 ac_status=$?
4462 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4463 (exit $ac_status); } &&
4464 { ac_try='test -s conftest.$ac_objext'
4465 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4466 (eval $ac_try) 2>&5
4467 ac_status=$?
4468 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4469 (exit $ac_status); }; }; then
4470 sol_lfs_bug=no
4471else
4472 echo "$as_me: failed program was:" >&5
4473cat conftest.$ac_ext >&5
4474sol_lfs_bug=yes
4475fi
4476rm -f conftest.$ac_objext conftest.$ac_ext
4477echo "$as_me:$LINENO: result: $sol_lfs_bug" >&5
4478echo "${ECHO_T}$sol_lfs_bug" >&6
4479if test "$sol_lfs_bug" = "yes"; then
4480 use_lfs=no
4481fi
4482
4483if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00004484# Two defines needed to enable largefile support on various platforms
4485# These may affect some typedefs
Guido van Rossum810cc512001-09-09 23:51:39 +00004486
Martin v. Löwis11437992002-04-12 09:54:03 +00004487cat >>confdefs.h <<\_ACEOF
4488#define _LARGEFILE_SOURCE 1
4489_ACEOF
4490
4491
4492cat >>confdefs.h <<\_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00004493#define _FILE_OFFSET_BITS 64
Martin v. Löwis11437992002-04-12 09:54:03 +00004494_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00004495
Martin v. Löwis399a6892002-10-04 10:22:02 +00004496fi
Michael W. Hudson54241132001-12-07 15:38:26 +00004497
Guido van Rossum84e7b241996-08-19 21:59:00 +00004498# Add some code to confdefs.h so that the test for off_t works on SCO
4499cat >> confdefs.h <<\EOF
4500#if defined(SCO_DS)
4501#undef _OFF_T
4502#endif
4503EOF
4504
Guido van Rossumef2255b2000-03-10 22:30:29 +00004505# Type availability checks
Martin v. Löwis11437992002-04-12 09:54:03 +00004506echo "$as_me:$LINENO: checking for mode_t" >&5
4507echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
4508if test "${ac_cv_type_mode_t+set}" = set; then
4509 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004510else
Martin v. Löwis11437992002-04-12 09:54:03 +00004511 cat >conftest.$ac_ext <<_ACEOF
4512#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004513#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004514$ac_includes_default
4515#ifdef F77_DUMMY_MAIN
4516# ifdef __cplusplus
4517 extern "C"
4518# endif
4519 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004520#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004521int
4522main ()
4523{
4524if ((mode_t *) 0)
4525 return 0;
4526if (sizeof (mode_t))
4527 return 0;
4528 ;
4529 return 0;
4530}
4531_ACEOF
4532rm -f conftest.$ac_objext
4533if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4534 (eval $ac_compile) 2>&5
4535 ac_status=$?
4536 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4537 (exit $ac_status); } &&
4538 { ac_try='test -s conftest.$ac_objext'
4539 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4540 (eval $ac_try) 2>&5
4541 ac_status=$?
4542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4543 (exit $ac_status); }; }; then
Jack Jansendd19cf82001-12-06 22:36:17 +00004544 ac_cv_type_mode_t=yes
4545else
Martin v. Löwis11437992002-04-12 09:54:03 +00004546 echo "$as_me: failed program was:" >&5
4547cat conftest.$ac_ext >&5
4548ac_cv_type_mode_t=no
Jack Jansendd19cf82001-12-06 22:36:17 +00004549fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004550rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004551fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004552echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
4553echo "${ECHO_T}$ac_cv_type_mode_t" >&6
4554if test $ac_cv_type_mode_t = yes; then
4555 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004556else
Martin v. Löwis11437992002-04-12 09:54:03 +00004557
4558cat >>confdefs.h <<_ACEOF
4559#define mode_t int
4560_ACEOF
4561
4562fi
4563
4564echo "$as_me:$LINENO: checking for off_t" >&5
4565echo $ECHO_N "checking for off_t... $ECHO_C" >&6
4566if test "${ac_cv_type_off_t+set}" = set; then
4567 echo $ECHO_N "(cached) $ECHO_C" >&6
4568else
4569 cat >conftest.$ac_ext <<_ACEOF
4570#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004571#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004572$ac_includes_default
4573#ifdef F77_DUMMY_MAIN
4574# ifdef __cplusplus
4575 extern "C"
4576# endif
4577 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004578#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004579int
4580main ()
4581{
4582if ((off_t *) 0)
4583 return 0;
4584if (sizeof (off_t))
4585 return 0;
4586 ;
4587 return 0;
4588}
4589_ACEOF
4590rm -f conftest.$ac_objext
4591if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4592 (eval $ac_compile) 2>&5
4593 ac_status=$?
4594 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4595 (exit $ac_status); } &&
4596 { ac_try='test -s conftest.$ac_objext'
4597 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4598 (eval $ac_try) 2>&5
4599 ac_status=$?
4600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4601 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00004602 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004603else
Martin v. Löwis11437992002-04-12 09:54:03 +00004604 echo "$as_me: failed program was:" >&5
4605cat conftest.$ac_ext >&5
4606ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004607fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004608rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004609fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004610echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
4611echo "${ECHO_T}$ac_cv_type_off_t" >&6
4612if test $ac_cv_type_off_t = yes; then
4613 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004614else
Martin v. Löwis11437992002-04-12 09:54:03 +00004615
4616cat >>confdefs.h <<_ACEOF
4617#define off_t long
4618_ACEOF
4619
4620fi
4621
4622echo "$as_me:$LINENO: checking for pid_t" >&5
4623echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
4624if test "${ac_cv_type_pid_t+set}" = set; then
4625 echo $ECHO_N "(cached) $ECHO_C" >&6
4626else
4627 cat >conftest.$ac_ext <<_ACEOF
4628#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004629#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004630$ac_includes_default
4631#ifdef F77_DUMMY_MAIN
4632# ifdef __cplusplus
4633 extern "C"
4634# endif
4635 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004636#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004637int
4638main ()
4639{
4640if ((pid_t *) 0)
4641 return 0;
4642if (sizeof (pid_t))
4643 return 0;
4644 ;
4645 return 0;
4646}
4647_ACEOF
4648rm -f conftest.$ac_objext
4649if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4650 (eval $ac_compile) 2>&5
4651 ac_status=$?
4652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4653 (exit $ac_status); } &&
4654 { ac_try='test -s conftest.$ac_objext'
4655 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4656 (eval $ac_try) 2>&5
4657 ac_status=$?
4658 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4659 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00004660 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004661else
Martin v. Löwis11437992002-04-12 09:54:03 +00004662 echo "$as_me: failed program was:" >&5
4663cat conftest.$ac_ext >&5
4664ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004665fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004666rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004667fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004668echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
4669echo "${ECHO_T}$ac_cv_type_pid_t" >&6
4670if test $ac_cv_type_pid_t = yes; then
4671 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004672else
Martin v. Löwis11437992002-04-12 09:54:03 +00004673
4674cat >>confdefs.h <<_ACEOF
4675#define pid_t int
4676_ACEOF
4677
4678fi
4679
4680echo "$as_me:$LINENO: checking return type of signal handlers" >&5
4681echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
4682if test "${ac_cv_type_signal+set}" = set; then
4683 echo $ECHO_N "(cached) $ECHO_C" >&6
4684else
4685 cat >conftest.$ac_ext <<_ACEOF
4686#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00004687#include "confdefs.h"
4688#include <sys/types.h>
4689#include <signal.h>
4690#ifdef signal
Martin v. Löwis11437992002-04-12 09:54:03 +00004691# undef signal
Guido van Rossum627b2d71993-12-24 10:39:16 +00004692#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00004693#ifdef __cplusplus
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004694extern "C" void (*signal (int, void (*)(int)))(int);
4695#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00004696void (*signal ()) ();
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004697#endif
4698
Martin v. Löwis11437992002-04-12 09:54:03 +00004699#ifdef F77_DUMMY_MAIN
4700# ifdef __cplusplus
4701 extern "C"
4702# endif
4703 int F77_DUMMY_MAIN() { return 1; }
4704#endif
4705int
4706main ()
4707{
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004708int i;
Martin v. Löwis11437992002-04-12 09:54:03 +00004709 ;
4710 return 0;
4711}
4712_ACEOF
4713rm -f conftest.$ac_objext
4714if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4715 (eval $ac_compile) 2>&5
4716 ac_status=$?
4717 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4718 (exit $ac_status); } &&
4719 { ac_try='test -s conftest.$ac_objext'
4720 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4721 (eval $ac_try) 2>&5
4722 ac_status=$?
4723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4724 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004725 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00004726else
Martin v. Löwis11437992002-04-12 09:54:03 +00004727 echo "$as_me: failed program was:" >&5
4728cat conftest.$ac_ext >&5
4729ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00004730fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004731rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004732fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004733echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
4734echo "${ECHO_T}$ac_cv_type_signal" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004735
Martin v. Löwis11437992002-04-12 09:54:03 +00004736cat >>confdefs.h <<_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004737#define RETSIGTYPE $ac_cv_type_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00004738_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004739
Michael W. Hudson54241132001-12-07 15:38:26 +00004740
Martin v. Löwis11437992002-04-12 09:54:03 +00004741echo "$as_me:$LINENO: checking for size_t" >&5
4742echo $ECHO_N "checking for size_t... $ECHO_C" >&6
4743if test "${ac_cv_type_size_t+set}" = set; then
4744 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004745else
Martin v. Löwis11437992002-04-12 09:54:03 +00004746 cat >conftest.$ac_ext <<_ACEOF
4747#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004748#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004749$ac_includes_default
4750#ifdef F77_DUMMY_MAIN
4751# ifdef __cplusplus
4752 extern "C"
4753# endif
4754 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004755#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004756int
4757main ()
4758{
4759if ((size_t *) 0)
4760 return 0;
4761if (sizeof (size_t))
4762 return 0;
4763 ;
4764 return 0;
4765}
4766_ACEOF
4767rm -f conftest.$ac_objext
4768if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4769 (eval $ac_compile) 2>&5
4770 ac_status=$?
4771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4772 (exit $ac_status); } &&
4773 { ac_try='test -s conftest.$ac_objext'
4774 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4775 (eval $ac_try) 2>&5
4776 ac_status=$?
4777 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4778 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00004779 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004780else
Martin v. Löwis11437992002-04-12 09:54:03 +00004781 echo "$as_me: failed program was:" >&5
4782cat conftest.$ac_ext >&5
4783ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004784fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004785rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004786fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004787echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
4788echo "${ECHO_T}$ac_cv_type_size_t" >&6
4789if test $ac_cv_type_size_t = yes; then
4790 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004791else
Martin v. Löwis11437992002-04-12 09:54:03 +00004792
4793cat >>confdefs.h <<_ACEOF
4794#define size_t unsigned
4795_ACEOF
4796
4797fi
4798
4799echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
4800echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
4801if test "${ac_cv_type_uid_t+set}" = set; then
4802 echo $ECHO_N "(cached) $ECHO_C" >&6
4803else
4804 cat >conftest.$ac_ext <<_ACEOF
4805#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004806#include "confdefs.h"
4807#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004808
4809_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004810if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4811 egrep "uid_t" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004812 ac_cv_type_uid_t=yes
4813else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004814 ac_cv_type_uid_t=no
4815fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00004816rm -f conftest*
4817
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004818fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004819echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
4820echo "${ECHO_T}$ac_cv_type_uid_t" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00004821if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004822
Martin v. Löwis11437992002-04-12 09:54:03 +00004823cat >>confdefs.h <<\_ACEOF
4824#define uid_t int
4825_ACEOF
4826
4827
4828cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004829#define gid_t int
Martin v. Löwis11437992002-04-12 09:54:03 +00004830_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004831
4832fi
4833
Jack Jansendd19cf82001-12-06 22:36:17 +00004834
Michael W. Hudson54241132001-12-07 15:38:26 +00004835# Sizes of various common basic types
Martin v. Löwis11437992002-04-12 09:54:03 +00004836echo "$as_me:$LINENO: checking for int" >&5
4837echo $ECHO_N "checking for int... $ECHO_C" >&6
4838if test "${ac_cv_type_int+set}" = set; then
4839 echo $ECHO_N "(cached) $ECHO_C" >&6
4840else
4841 cat >conftest.$ac_ext <<_ACEOF
4842#line $LINENO "configure"
4843#include "confdefs.h"
4844$ac_includes_default
4845#ifdef F77_DUMMY_MAIN
4846# ifdef __cplusplus
4847 extern "C"
4848# endif
4849 int F77_DUMMY_MAIN() { return 1; }
4850#endif
4851int
4852main ()
4853{
4854if ((int *) 0)
4855 return 0;
4856if (sizeof (int))
4857 return 0;
4858 ;
4859 return 0;
4860}
4861_ACEOF
4862rm -f conftest.$ac_objext
4863if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4864 (eval $ac_compile) 2>&5
4865 ac_status=$?
4866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4867 (exit $ac_status); } &&
4868 { ac_try='test -s conftest.$ac_objext'
4869 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4870 (eval $ac_try) 2>&5
4871 ac_status=$?
4872 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4873 (exit $ac_status); }; }; then
4874 ac_cv_type_int=yes
4875else
4876 echo "$as_me: failed program was:" >&5
4877cat conftest.$ac_ext >&5
4878ac_cv_type_int=no
4879fi
4880rm -f conftest.$ac_objext conftest.$ac_ext
4881fi
4882echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
4883echo "${ECHO_T}$ac_cv_type_int" >&6
4884
4885echo "$as_me:$LINENO: checking size of int" >&5
4886echo $ECHO_N "checking size of int... $ECHO_C" >&6
4887if test "${ac_cv_sizeof_int+set}" = set; then
4888 echo $ECHO_N "(cached) $ECHO_C" >&6
4889else
4890 if test "$ac_cv_type_int" = yes; then
4891 # The cast to unsigned long works around a bug in the HP C Compiler
4892 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
4893 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
4894 # This bug is HP SR number 8606223364.
4895 if test "$cross_compiling" = yes; then
4896 # Depending upon the size, compute the lo and hi bounds.
4897cat >conftest.$ac_ext <<_ACEOF
4898#line $LINENO "configure"
4899#include "confdefs.h"
4900$ac_includes_default
4901#ifdef F77_DUMMY_MAIN
4902# ifdef __cplusplus
4903 extern "C"
4904# endif
4905 int F77_DUMMY_MAIN() { return 1; }
4906#endif
4907int
4908main ()
4909{
4910static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
4911test_array [0] = 0
4912
4913 ;
4914 return 0;
4915}
4916_ACEOF
4917rm -f conftest.$ac_objext
4918if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4919 (eval $ac_compile) 2>&5
4920 ac_status=$?
4921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4922 (exit $ac_status); } &&
4923 { ac_try='test -s conftest.$ac_objext'
4924 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4925 (eval $ac_try) 2>&5
4926 ac_status=$?
4927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4928 (exit $ac_status); }; }; then
4929 ac_lo=0 ac_mid=0
4930 while :; do
4931 cat >conftest.$ac_ext <<_ACEOF
4932#line $LINENO "configure"
4933#include "confdefs.h"
4934$ac_includes_default
4935#ifdef F77_DUMMY_MAIN
4936# ifdef __cplusplus
4937 extern "C"
4938# endif
4939 int F77_DUMMY_MAIN() { return 1; }
4940#endif
4941int
4942main ()
4943{
4944static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
4945test_array [0] = 0
4946
4947 ;
4948 return 0;
4949}
4950_ACEOF
4951rm -f conftest.$ac_objext
4952if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4953 (eval $ac_compile) 2>&5
4954 ac_status=$?
4955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4956 (exit $ac_status); } &&
4957 { ac_try='test -s conftest.$ac_objext'
4958 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4959 (eval $ac_try) 2>&5
4960 ac_status=$?
4961 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4962 (exit $ac_status); }; }; then
4963 ac_hi=$ac_mid; break
4964else
4965 echo "$as_me: failed program was:" >&5
4966cat conftest.$ac_ext >&5
4967ac_lo=`expr $ac_mid + 1`
4968 if test $ac_lo -le $ac_mid; then
4969 ac_lo= ac_hi=
4970 break
4971 fi
4972 ac_mid=`expr 2 '*' $ac_mid + 1`
4973fi
4974rm -f conftest.$ac_objext conftest.$ac_ext
4975 done
4976else
4977 echo "$as_me: failed program was:" >&5
4978cat conftest.$ac_ext >&5
4979cat >conftest.$ac_ext <<_ACEOF
4980#line $LINENO "configure"
4981#include "confdefs.h"
4982$ac_includes_default
4983#ifdef F77_DUMMY_MAIN
4984# ifdef __cplusplus
4985 extern "C"
4986# endif
4987 int F77_DUMMY_MAIN() { return 1; }
4988#endif
4989int
4990main ()
4991{
4992static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
4993test_array [0] = 0
4994
4995 ;
4996 return 0;
4997}
4998_ACEOF
4999rm -f conftest.$ac_objext
5000if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5001 (eval $ac_compile) 2>&5
5002 ac_status=$?
5003 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5004 (exit $ac_status); } &&
5005 { ac_try='test -s conftest.$ac_objext'
5006 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5007 (eval $ac_try) 2>&5
5008 ac_status=$?
5009 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5010 (exit $ac_status); }; }; then
5011 ac_hi=-1 ac_mid=-1
5012 while :; do
5013 cat >conftest.$ac_ext <<_ACEOF
5014#line $LINENO "configure"
5015#include "confdefs.h"
5016$ac_includes_default
5017#ifdef F77_DUMMY_MAIN
5018# ifdef __cplusplus
5019 extern "C"
5020# endif
5021 int F77_DUMMY_MAIN() { return 1; }
5022#endif
5023int
5024main ()
5025{
5026static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
5027test_array [0] = 0
5028
5029 ;
5030 return 0;
5031}
5032_ACEOF
5033rm -f conftest.$ac_objext
5034if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5035 (eval $ac_compile) 2>&5
5036 ac_status=$?
5037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5038 (exit $ac_status); } &&
5039 { ac_try='test -s conftest.$ac_objext'
5040 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5041 (eval $ac_try) 2>&5
5042 ac_status=$?
5043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5044 (exit $ac_status); }; }; then
5045 ac_lo=$ac_mid; break
5046else
5047 echo "$as_me: failed program was:" >&5
5048cat conftest.$ac_ext >&5
5049ac_hi=`expr '(' $ac_mid ')' - 1`
5050 if test $ac_mid -le $ac_hi; then
5051 ac_lo= ac_hi=
5052 break
5053 fi
5054 ac_mid=`expr 2 '*' $ac_mid`
5055fi
5056rm -f conftest.$ac_objext conftest.$ac_ext
5057 done
5058else
5059 echo "$as_me: failed program was:" >&5
5060cat conftest.$ac_ext >&5
5061ac_lo= ac_hi=
5062fi
5063rm -f conftest.$ac_objext conftest.$ac_ext
5064fi
5065rm -f conftest.$ac_objext conftest.$ac_ext
5066# Binary search between lo and hi bounds.
5067while test "x$ac_lo" != "x$ac_hi"; do
5068 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5069 cat >conftest.$ac_ext <<_ACEOF
5070#line $LINENO "configure"
5071#include "confdefs.h"
5072$ac_includes_default
5073#ifdef F77_DUMMY_MAIN
5074# ifdef __cplusplus
5075 extern "C"
5076# endif
5077 int F77_DUMMY_MAIN() { return 1; }
5078#endif
5079int
5080main ()
5081{
5082static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
5083test_array [0] = 0
5084
5085 ;
5086 return 0;
5087}
5088_ACEOF
5089rm -f conftest.$ac_objext
5090if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5091 (eval $ac_compile) 2>&5
5092 ac_status=$?
5093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5094 (exit $ac_status); } &&
5095 { ac_try='test -s conftest.$ac_objext'
5096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5097 (eval $ac_try) 2>&5
5098 ac_status=$?
5099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5100 (exit $ac_status); }; }; then
5101 ac_hi=$ac_mid
5102else
5103 echo "$as_me: failed program was:" >&5
5104cat conftest.$ac_ext >&5
5105ac_lo=`expr '(' $ac_mid ')' + 1`
5106fi
5107rm -f conftest.$ac_objext conftest.$ac_ext
5108done
5109case $ac_lo in
5110?*) ac_cv_sizeof_int=$ac_lo;;
5111'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77" >&5
5112echo "$as_me: error: cannot compute sizeof (int), 77" >&2;}
5113 { (exit 1); exit 1; }; } ;;
5114esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005115else
5116 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005117 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5118echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5119 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005120else
Martin v. Löwis11437992002-04-12 09:54:03 +00005121 cat >conftest.$ac_ext <<_ACEOF
5122#line $LINENO "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005123#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005124$ac_includes_default
5125long longval () { return (long) (sizeof (int)); }
5126unsigned long ulongval () { return (long) (sizeof (int)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005127#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005128#include <stdlib.h>
5129#ifdef F77_DUMMY_MAIN
5130# ifdef __cplusplus
5131 extern "C"
5132# endif
5133 int F77_DUMMY_MAIN() { return 1; }
5134#endif
5135int
5136main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005137{
Martin v. Löwis11437992002-04-12 09:54:03 +00005138
5139 FILE *f = fopen ("conftest.val", "w");
5140 if (! f)
5141 exit (1);
5142 if (((long) (sizeof (int))) < 0)
5143 {
5144 long i = longval ();
5145 if (i != ((long) (sizeof (int))))
5146 exit (1);
5147 fprintf (f, "%ld\n", i);
5148 }
5149 else
5150 {
5151 unsigned long i = ulongval ();
5152 if (i != ((long) (sizeof (int))))
5153 exit (1);
5154 fprintf (f, "%lu\n", i);
5155 }
5156 exit (ferror (f) || fclose (f) != 0);
5157
5158 ;
5159 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005160}
Martin v. Löwis11437992002-04-12 09:54:03 +00005161_ACEOF
5162rm -f conftest$ac_exeext
5163if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5164 (eval $ac_link) 2>&5
5165 ac_status=$?
5166 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5167 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5168 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5169 (eval $ac_try) 2>&5
5170 ac_status=$?
5171 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5172 (exit $ac_status); }; }; then
5173 ac_cv_sizeof_int=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005174else
Martin v. Löwis11437992002-04-12 09:54:03 +00005175 echo "$as_me: program exited with status $ac_status" >&5
5176echo "$as_me: failed program was:" >&5
5177cat conftest.$ac_ext >&5
5178( exit $ac_status )
5179{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77" >&5
5180echo "$as_me: error: cannot compute sizeof (int), 77" >&2;}
5181 { (exit 1); exit 1; }; }
5182fi
5183rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5184fi
5185fi
5186rm -f conftest.val
5187else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005188 ac_cv_sizeof_int=0
5189fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005190fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005191echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
5192echo "${ECHO_T}$ac_cv_sizeof_int" >&6
5193cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005194#define SIZEOF_INT $ac_cv_sizeof_int
Martin v. Löwis11437992002-04-12 09:54:03 +00005195_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005196
5197
Martin v. Löwis11437992002-04-12 09:54:03 +00005198echo "$as_me:$LINENO: checking for long" >&5
5199echo $ECHO_N "checking for long... $ECHO_C" >&6
5200if test "${ac_cv_type_long+set}" = set; then
5201 echo $ECHO_N "(cached) $ECHO_C" >&6
5202else
5203 cat >conftest.$ac_ext <<_ACEOF
5204#line $LINENO "configure"
5205#include "confdefs.h"
5206$ac_includes_default
5207#ifdef F77_DUMMY_MAIN
5208# ifdef __cplusplus
5209 extern "C"
5210# endif
5211 int F77_DUMMY_MAIN() { return 1; }
5212#endif
5213int
5214main ()
5215{
5216if ((long *) 0)
5217 return 0;
5218if (sizeof (long))
5219 return 0;
5220 ;
5221 return 0;
5222}
5223_ACEOF
5224rm -f conftest.$ac_objext
5225if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5226 (eval $ac_compile) 2>&5
5227 ac_status=$?
5228 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5229 (exit $ac_status); } &&
5230 { ac_try='test -s conftest.$ac_objext'
5231 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5232 (eval $ac_try) 2>&5
5233 ac_status=$?
5234 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5235 (exit $ac_status); }; }; then
5236 ac_cv_type_long=yes
5237else
5238 echo "$as_me: failed program was:" >&5
5239cat conftest.$ac_ext >&5
5240ac_cv_type_long=no
5241fi
5242rm -f conftest.$ac_objext conftest.$ac_ext
5243fi
5244echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
5245echo "${ECHO_T}$ac_cv_type_long" >&6
5246
5247echo "$as_me:$LINENO: checking size of long" >&5
5248echo $ECHO_N "checking size of long... $ECHO_C" >&6
5249if test "${ac_cv_sizeof_long+set}" = set; then
5250 echo $ECHO_N "(cached) $ECHO_C" >&6
5251else
5252 if test "$ac_cv_type_long" = yes; then
5253 # The cast to unsigned long works around a bug in the HP C Compiler
5254 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5255 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5256 # This bug is HP SR number 8606223364.
5257 if test "$cross_compiling" = yes; then
5258 # Depending upon the size, compute the lo and hi bounds.
5259cat >conftest.$ac_ext <<_ACEOF
5260#line $LINENO "configure"
5261#include "confdefs.h"
5262$ac_includes_default
5263#ifdef F77_DUMMY_MAIN
5264# ifdef __cplusplus
5265 extern "C"
5266# endif
5267 int F77_DUMMY_MAIN() { return 1; }
5268#endif
5269int
5270main ()
5271{
5272static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
5273test_array [0] = 0
5274
5275 ;
5276 return 0;
5277}
5278_ACEOF
5279rm -f conftest.$ac_objext
5280if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5281 (eval $ac_compile) 2>&5
5282 ac_status=$?
5283 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5284 (exit $ac_status); } &&
5285 { ac_try='test -s conftest.$ac_objext'
5286 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5287 (eval $ac_try) 2>&5
5288 ac_status=$?
5289 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5290 (exit $ac_status); }; }; then
5291 ac_lo=0 ac_mid=0
5292 while :; do
5293 cat >conftest.$ac_ext <<_ACEOF
5294#line $LINENO "configure"
5295#include "confdefs.h"
5296$ac_includes_default
5297#ifdef F77_DUMMY_MAIN
5298# ifdef __cplusplus
5299 extern "C"
5300# endif
5301 int F77_DUMMY_MAIN() { return 1; }
5302#endif
5303int
5304main ()
5305{
5306static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5307test_array [0] = 0
5308
5309 ;
5310 return 0;
5311}
5312_ACEOF
5313rm -f conftest.$ac_objext
5314if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5315 (eval $ac_compile) 2>&5
5316 ac_status=$?
5317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5318 (exit $ac_status); } &&
5319 { ac_try='test -s conftest.$ac_objext'
5320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5321 (eval $ac_try) 2>&5
5322 ac_status=$?
5323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5324 (exit $ac_status); }; }; then
5325 ac_hi=$ac_mid; break
5326else
5327 echo "$as_me: failed program was:" >&5
5328cat conftest.$ac_ext >&5
5329ac_lo=`expr $ac_mid + 1`
5330 if test $ac_lo -le $ac_mid; then
5331 ac_lo= ac_hi=
5332 break
5333 fi
5334 ac_mid=`expr 2 '*' $ac_mid + 1`
5335fi
5336rm -f conftest.$ac_objext conftest.$ac_ext
5337 done
5338else
5339 echo "$as_me: failed program was:" >&5
5340cat conftest.$ac_ext >&5
5341cat >conftest.$ac_ext <<_ACEOF
5342#line $LINENO "configure"
5343#include "confdefs.h"
5344$ac_includes_default
5345#ifdef F77_DUMMY_MAIN
5346# ifdef __cplusplus
5347 extern "C"
5348# endif
5349 int F77_DUMMY_MAIN() { return 1; }
5350#endif
5351int
5352main ()
5353{
5354static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
5355test_array [0] = 0
5356
5357 ;
5358 return 0;
5359}
5360_ACEOF
5361rm -f conftest.$ac_objext
5362if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5363 (eval $ac_compile) 2>&5
5364 ac_status=$?
5365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5366 (exit $ac_status); } &&
5367 { ac_try='test -s conftest.$ac_objext'
5368 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5369 (eval $ac_try) 2>&5
5370 ac_status=$?
5371 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5372 (exit $ac_status); }; }; then
5373 ac_hi=-1 ac_mid=-1
5374 while :; do
5375 cat >conftest.$ac_ext <<_ACEOF
5376#line $LINENO "configure"
5377#include "confdefs.h"
5378$ac_includes_default
5379#ifdef F77_DUMMY_MAIN
5380# ifdef __cplusplus
5381 extern "C"
5382# endif
5383 int F77_DUMMY_MAIN() { return 1; }
5384#endif
5385int
5386main ()
5387{
5388static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
5389test_array [0] = 0
5390
5391 ;
5392 return 0;
5393}
5394_ACEOF
5395rm -f conftest.$ac_objext
5396if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5397 (eval $ac_compile) 2>&5
5398 ac_status=$?
5399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5400 (exit $ac_status); } &&
5401 { ac_try='test -s conftest.$ac_objext'
5402 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5403 (eval $ac_try) 2>&5
5404 ac_status=$?
5405 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5406 (exit $ac_status); }; }; then
5407 ac_lo=$ac_mid; break
5408else
5409 echo "$as_me: failed program was:" >&5
5410cat conftest.$ac_ext >&5
5411ac_hi=`expr '(' $ac_mid ')' - 1`
5412 if test $ac_mid -le $ac_hi; then
5413 ac_lo= ac_hi=
5414 break
5415 fi
5416 ac_mid=`expr 2 '*' $ac_mid`
5417fi
5418rm -f conftest.$ac_objext conftest.$ac_ext
5419 done
5420else
5421 echo "$as_me: failed program was:" >&5
5422cat conftest.$ac_ext >&5
5423ac_lo= ac_hi=
5424fi
5425rm -f conftest.$ac_objext conftest.$ac_ext
5426fi
5427rm -f conftest.$ac_objext conftest.$ac_ext
5428# Binary search between lo and hi bounds.
5429while test "x$ac_lo" != "x$ac_hi"; do
5430 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5431 cat >conftest.$ac_ext <<_ACEOF
5432#line $LINENO "configure"
5433#include "confdefs.h"
5434$ac_includes_default
5435#ifdef F77_DUMMY_MAIN
5436# ifdef __cplusplus
5437 extern "C"
5438# endif
5439 int F77_DUMMY_MAIN() { return 1; }
5440#endif
5441int
5442main ()
5443{
5444static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5445test_array [0] = 0
5446
5447 ;
5448 return 0;
5449}
5450_ACEOF
5451rm -f conftest.$ac_objext
5452if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5453 (eval $ac_compile) 2>&5
5454 ac_status=$?
5455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5456 (exit $ac_status); } &&
5457 { ac_try='test -s conftest.$ac_objext'
5458 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5459 (eval $ac_try) 2>&5
5460 ac_status=$?
5461 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5462 (exit $ac_status); }; }; then
5463 ac_hi=$ac_mid
5464else
5465 echo "$as_me: failed program was:" >&5
5466cat conftest.$ac_ext >&5
5467ac_lo=`expr '(' $ac_mid ')' + 1`
5468fi
5469rm -f conftest.$ac_objext conftest.$ac_ext
5470done
5471case $ac_lo in
5472?*) ac_cv_sizeof_long=$ac_lo;;
5473'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77" >&5
5474echo "$as_me: error: cannot compute sizeof (long), 77" >&2;}
5475 { (exit 1); exit 1; }; } ;;
5476esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005477else
5478 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005479 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5480echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5481 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005482else
Martin v. Löwis11437992002-04-12 09:54:03 +00005483 cat >conftest.$ac_ext <<_ACEOF
5484#line $LINENO "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005485#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005486$ac_includes_default
5487long longval () { return (long) (sizeof (long)); }
5488unsigned long ulongval () { return (long) (sizeof (long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005489#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005490#include <stdlib.h>
5491#ifdef F77_DUMMY_MAIN
5492# ifdef __cplusplus
5493 extern "C"
5494# endif
5495 int F77_DUMMY_MAIN() { return 1; }
5496#endif
5497int
5498main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005499{
Martin v. Löwis11437992002-04-12 09:54:03 +00005500
5501 FILE *f = fopen ("conftest.val", "w");
5502 if (! f)
5503 exit (1);
5504 if (((long) (sizeof (long))) < 0)
5505 {
5506 long i = longval ();
5507 if (i != ((long) (sizeof (long))))
5508 exit (1);
5509 fprintf (f, "%ld\n", i);
5510 }
5511 else
5512 {
5513 unsigned long i = ulongval ();
5514 if (i != ((long) (sizeof (long))))
5515 exit (1);
5516 fprintf (f, "%lu\n", i);
5517 }
5518 exit (ferror (f) || fclose (f) != 0);
5519
5520 ;
5521 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005522}
Martin v. Löwis11437992002-04-12 09:54:03 +00005523_ACEOF
5524rm -f conftest$ac_exeext
5525if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5526 (eval $ac_link) 2>&5
5527 ac_status=$?
5528 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5529 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5530 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5531 (eval $ac_try) 2>&5
5532 ac_status=$?
5533 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5534 (exit $ac_status); }; }; then
5535 ac_cv_sizeof_long=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005536else
Martin v. Löwis11437992002-04-12 09:54:03 +00005537 echo "$as_me: program exited with status $ac_status" >&5
5538echo "$as_me: failed program was:" >&5
5539cat conftest.$ac_ext >&5
5540( exit $ac_status )
5541{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77" >&5
5542echo "$as_me: error: cannot compute sizeof (long), 77" >&2;}
5543 { (exit 1); exit 1; }; }
5544fi
5545rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5546fi
5547fi
5548rm -f conftest.val
5549else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005550 ac_cv_sizeof_long=0
5551fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005552fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005553echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
5554echo "${ECHO_T}$ac_cv_sizeof_long" >&6
5555cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005556#define SIZEOF_LONG $ac_cv_sizeof_long
Martin v. Löwis11437992002-04-12 09:54:03 +00005557_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005558
5559
Martin v. Löwis11437992002-04-12 09:54:03 +00005560echo "$as_me:$LINENO: checking for void *" >&5
5561echo $ECHO_N "checking for void *... $ECHO_C" >&6
5562if test "${ac_cv_type_void_p+set}" = set; then
5563 echo $ECHO_N "(cached) $ECHO_C" >&6
5564else
5565 cat >conftest.$ac_ext <<_ACEOF
5566#line $LINENO "configure"
5567#include "confdefs.h"
5568$ac_includes_default
5569#ifdef F77_DUMMY_MAIN
5570# ifdef __cplusplus
5571 extern "C"
5572# endif
5573 int F77_DUMMY_MAIN() { return 1; }
5574#endif
5575int
5576main ()
5577{
5578if ((void * *) 0)
5579 return 0;
5580if (sizeof (void *))
5581 return 0;
5582 ;
5583 return 0;
5584}
5585_ACEOF
5586rm -f conftest.$ac_objext
5587if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5588 (eval $ac_compile) 2>&5
5589 ac_status=$?
5590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5591 (exit $ac_status); } &&
5592 { ac_try='test -s conftest.$ac_objext'
5593 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5594 (eval $ac_try) 2>&5
5595 ac_status=$?
5596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5597 (exit $ac_status); }; }; then
5598 ac_cv_type_void_p=yes
5599else
5600 echo "$as_me: failed program was:" >&5
5601cat conftest.$ac_ext >&5
5602ac_cv_type_void_p=no
5603fi
5604rm -f conftest.$ac_objext conftest.$ac_ext
5605fi
5606echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
5607echo "${ECHO_T}$ac_cv_type_void_p" >&6
5608
5609echo "$as_me:$LINENO: checking size of void *" >&5
5610echo $ECHO_N "checking size of void *... $ECHO_C" >&6
5611if test "${ac_cv_sizeof_void_p+set}" = set; then
5612 echo $ECHO_N "(cached) $ECHO_C" >&6
5613else
5614 if test "$ac_cv_type_void_p" = yes; then
5615 # The cast to unsigned long works around a bug in the HP C Compiler
5616 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5617 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5618 # This bug is HP SR number 8606223364.
5619 if test "$cross_compiling" = yes; then
5620 # Depending upon the size, compute the lo and hi bounds.
5621cat >conftest.$ac_ext <<_ACEOF
5622#line $LINENO "configure"
5623#include "confdefs.h"
5624$ac_includes_default
5625#ifdef F77_DUMMY_MAIN
5626# ifdef __cplusplus
5627 extern "C"
5628# endif
5629 int F77_DUMMY_MAIN() { return 1; }
5630#endif
5631int
5632main ()
5633{
5634static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
5635test_array [0] = 0
5636
5637 ;
5638 return 0;
5639}
5640_ACEOF
5641rm -f conftest.$ac_objext
5642if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5643 (eval $ac_compile) 2>&5
5644 ac_status=$?
5645 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5646 (exit $ac_status); } &&
5647 { ac_try='test -s conftest.$ac_objext'
5648 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5649 (eval $ac_try) 2>&5
5650 ac_status=$?
5651 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5652 (exit $ac_status); }; }; then
5653 ac_lo=0 ac_mid=0
5654 while :; do
5655 cat >conftest.$ac_ext <<_ACEOF
5656#line $LINENO "configure"
5657#include "confdefs.h"
5658$ac_includes_default
5659#ifdef F77_DUMMY_MAIN
5660# ifdef __cplusplus
5661 extern "C"
5662# endif
5663 int F77_DUMMY_MAIN() { return 1; }
5664#endif
5665int
5666main ()
5667{
5668static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
5669test_array [0] = 0
5670
5671 ;
5672 return 0;
5673}
5674_ACEOF
5675rm -f conftest.$ac_objext
5676if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5677 (eval $ac_compile) 2>&5
5678 ac_status=$?
5679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5680 (exit $ac_status); } &&
5681 { ac_try='test -s conftest.$ac_objext'
5682 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5683 (eval $ac_try) 2>&5
5684 ac_status=$?
5685 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5686 (exit $ac_status); }; }; then
5687 ac_hi=$ac_mid; break
5688else
5689 echo "$as_me: failed program was:" >&5
5690cat conftest.$ac_ext >&5
5691ac_lo=`expr $ac_mid + 1`
5692 if test $ac_lo -le $ac_mid; then
5693 ac_lo= ac_hi=
5694 break
5695 fi
5696 ac_mid=`expr 2 '*' $ac_mid + 1`
5697fi
5698rm -f conftest.$ac_objext conftest.$ac_ext
5699 done
5700else
5701 echo "$as_me: failed program was:" >&5
5702cat conftest.$ac_ext >&5
5703cat >conftest.$ac_ext <<_ACEOF
5704#line $LINENO "configure"
5705#include "confdefs.h"
5706$ac_includes_default
5707#ifdef F77_DUMMY_MAIN
5708# ifdef __cplusplus
5709 extern "C"
5710# endif
5711 int F77_DUMMY_MAIN() { return 1; }
5712#endif
5713int
5714main ()
5715{
5716static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
5717test_array [0] = 0
5718
5719 ;
5720 return 0;
5721}
5722_ACEOF
5723rm -f conftest.$ac_objext
5724if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5725 (eval $ac_compile) 2>&5
5726 ac_status=$?
5727 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5728 (exit $ac_status); } &&
5729 { ac_try='test -s conftest.$ac_objext'
5730 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5731 (eval $ac_try) 2>&5
5732 ac_status=$?
5733 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5734 (exit $ac_status); }; }; then
5735 ac_hi=-1 ac_mid=-1
5736 while :; do
5737 cat >conftest.$ac_ext <<_ACEOF
5738#line $LINENO "configure"
5739#include "confdefs.h"
5740$ac_includes_default
5741#ifdef F77_DUMMY_MAIN
5742# ifdef __cplusplus
5743 extern "C"
5744# endif
5745 int F77_DUMMY_MAIN() { return 1; }
5746#endif
5747int
5748main ()
5749{
5750static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
5751test_array [0] = 0
5752
5753 ;
5754 return 0;
5755}
5756_ACEOF
5757rm -f conftest.$ac_objext
5758if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5759 (eval $ac_compile) 2>&5
5760 ac_status=$?
5761 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5762 (exit $ac_status); } &&
5763 { ac_try='test -s conftest.$ac_objext'
5764 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5765 (eval $ac_try) 2>&5
5766 ac_status=$?
5767 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5768 (exit $ac_status); }; }; then
5769 ac_lo=$ac_mid; break
5770else
5771 echo "$as_me: failed program was:" >&5
5772cat conftest.$ac_ext >&5
5773ac_hi=`expr '(' $ac_mid ')' - 1`
5774 if test $ac_mid -le $ac_hi; then
5775 ac_lo= ac_hi=
5776 break
5777 fi
5778 ac_mid=`expr 2 '*' $ac_mid`
5779fi
5780rm -f conftest.$ac_objext conftest.$ac_ext
5781 done
5782else
5783 echo "$as_me: failed program was:" >&5
5784cat conftest.$ac_ext >&5
5785ac_lo= ac_hi=
5786fi
5787rm -f conftest.$ac_objext conftest.$ac_ext
5788fi
5789rm -f conftest.$ac_objext conftest.$ac_ext
5790# Binary search between lo and hi bounds.
5791while test "x$ac_lo" != "x$ac_hi"; do
5792 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5793 cat >conftest.$ac_ext <<_ACEOF
5794#line $LINENO "configure"
5795#include "confdefs.h"
5796$ac_includes_default
5797#ifdef F77_DUMMY_MAIN
5798# ifdef __cplusplus
5799 extern "C"
5800# endif
5801 int F77_DUMMY_MAIN() { return 1; }
5802#endif
5803int
5804main ()
5805{
5806static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
5807test_array [0] = 0
5808
5809 ;
5810 return 0;
5811}
5812_ACEOF
5813rm -f conftest.$ac_objext
5814if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5815 (eval $ac_compile) 2>&5
5816 ac_status=$?
5817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5818 (exit $ac_status); } &&
5819 { ac_try='test -s conftest.$ac_objext'
5820 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5821 (eval $ac_try) 2>&5
5822 ac_status=$?
5823 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5824 (exit $ac_status); }; }; then
5825 ac_hi=$ac_mid
5826else
5827 echo "$as_me: failed program was:" >&5
5828cat conftest.$ac_ext >&5
5829ac_lo=`expr '(' $ac_mid ')' + 1`
5830fi
5831rm -f conftest.$ac_objext conftest.$ac_ext
5832done
5833case $ac_lo in
5834?*) ac_cv_sizeof_void_p=$ac_lo;;
5835'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77" >&5
5836echo "$as_me: error: cannot compute sizeof (void *), 77" >&2;}
5837 { (exit 1); exit 1; }; } ;;
5838esac
Guido van Rossumad678af1998-10-02 14:42:15 +00005839else
5840 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005841 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5842echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5843 { (exit 1); exit 1; }; }
Guido van Rossumad678af1998-10-02 14:42:15 +00005844else
Martin v. Löwis11437992002-04-12 09:54:03 +00005845 cat >conftest.$ac_ext <<_ACEOF
5846#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +00005847#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005848$ac_includes_default
5849long longval () { return (long) (sizeof (void *)); }
5850unsigned long ulongval () { return (long) (sizeof (void *)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005851#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005852#include <stdlib.h>
5853#ifdef F77_DUMMY_MAIN
5854# ifdef __cplusplus
5855 extern "C"
5856# endif
5857 int F77_DUMMY_MAIN() { return 1; }
5858#endif
5859int
5860main ()
Guido van Rossumad678af1998-10-02 14:42:15 +00005861{
Martin v. Löwis11437992002-04-12 09:54:03 +00005862
5863 FILE *f = fopen ("conftest.val", "w");
5864 if (! f)
5865 exit (1);
5866 if (((long) (sizeof (void *))) < 0)
5867 {
5868 long i = longval ();
5869 if (i != ((long) (sizeof (void *))))
5870 exit (1);
5871 fprintf (f, "%ld\n", i);
5872 }
5873 else
5874 {
5875 unsigned long i = ulongval ();
5876 if (i != ((long) (sizeof (void *))))
5877 exit (1);
5878 fprintf (f, "%lu\n", i);
5879 }
5880 exit (ferror (f) || fclose (f) != 0);
5881
5882 ;
5883 return 0;
Guido van Rossumad678af1998-10-02 14:42:15 +00005884}
Martin v. Löwis11437992002-04-12 09:54:03 +00005885_ACEOF
5886rm -f conftest$ac_exeext
5887if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5888 (eval $ac_link) 2>&5
5889 ac_status=$?
5890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5891 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5892 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5893 (eval $ac_try) 2>&5
5894 ac_status=$?
5895 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5896 (exit $ac_status); }; }; then
5897 ac_cv_sizeof_void_p=`cat conftest.val`
Guido van Rossumad678af1998-10-02 14:42:15 +00005898else
Martin v. Löwis11437992002-04-12 09:54:03 +00005899 echo "$as_me: program exited with status $ac_status" >&5
5900echo "$as_me: failed program was:" >&5
5901cat conftest.$ac_ext >&5
5902( exit $ac_status )
5903{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77" >&5
5904echo "$as_me: error: cannot compute sizeof (void *), 77" >&2;}
5905 { (exit 1); exit 1; }; }
5906fi
5907rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5908fi
5909fi
5910rm -f conftest.val
5911else
Guido van Rossumad678af1998-10-02 14:42:15 +00005912 ac_cv_sizeof_void_p=0
5913fi
Guido van Rossumad678af1998-10-02 14:42:15 +00005914fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005915echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
5916echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
5917cat >>confdefs.h <<_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00005918#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
Martin v. Löwis11437992002-04-12 09:54:03 +00005919_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00005920
5921
Martin v. Löwis11437992002-04-12 09:54:03 +00005922echo "$as_me:$LINENO: checking for char" >&5
5923echo $ECHO_N "checking for char... $ECHO_C" >&6
5924if test "${ac_cv_type_char+set}" = set; then
5925 echo $ECHO_N "(cached) $ECHO_C" >&6
5926else
5927 cat >conftest.$ac_ext <<_ACEOF
5928#line $LINENO "configure"
5929#include "confdefs.h"
5930$ac_includes_default
5931#ifdef F77_DUMMY_MAIN
5932# ifdef __cplusplus
5933 extern "C"
5934# endif
5935 int F77_DUMMY_MAIN() { return 1; }
5936#endif
5937int
5938main ()
5939{
5940if ((char *) 0)
5941 return 0;
5942if (sizeof (char))
5943 return 0;
5944 ;
5945 return 0;
5946}
5947_ACEOF
5948rm -f conftest.$ac_objext
5949if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5950 (eval $ac_compile) 2>&5
5951 ac_status=$?
5952 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5953 (exit $ac_status); } &&
5954 { ac_try='test -s conftest.$ac_objext'
5955 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5956 (eval $ac_try) 2>&5
5957 ac_status=$?
5958 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5959 (exit $ac_status); }; }; then
5960 ac_cv_type_char=yes
5961else
5962 echo "$as_me: failed program was:" >&5
5963cat conftest.$ac_ext >&5
5964ac_cv_type_char=no
5965fi
5966rm -f conftest.$ac_objext conftest.$ac_ext
5967fi
5968echo "$as_me:$LINENO: result: $ac_cv_type_char" >&5
5969echo "${ECHO_T}$ac_cv_type_char" >&6
5970
5971echo "$as_me:$LINENO: checking size of char" >&5
5972echo $ECHO_N "checking size of char... $ECHO_C" >&6
5973if test "${ac_cv_sizeof_char+set}" = set; then
5974 echo $ECHO_N "(cached) $ECHO_C" >&6
5975else
5976 if test "$ac_cv_type_char" = yes; then
5977 # The cast to unsigned long works around a bug in the HP C Compiler
5978 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5979 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5980 # This bug is HP SR number 8606223364.
5981 if test "$cross_compiling" = yes; then
5982 # Depending upon the size, compute the lo and hi bounds.
5983cat >conftest.$ac_ext <<_ACEOF
5984#line $LINENO "configure"
5985#include "confdefs.h"
5986$ac_includes_default
5987#ifdef F77_DUMMY_MAIN
5988# ifdef __cplusplus
5989 extern "C"
5990# endif
5991 int F77_DUMMY_MAIN() { return 1; }
5992#endif
5993int
5994main ()
5995{
5996static int test_array [1 - 2 * !(((long) (sizeof (char))) >= 0)];
5997test_array [0] = 0
5998
5999 ;
6000 return 0;
6001}
6002_ACEOF
6003rm -f conftest.$ac_objext
6004if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6005 (eval $ac_compile) 2>&5
6006 ac_status=$?
6007 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6008 (exit $ac_status); } &&
6009 { ac_try='test -s conftest.$ac_objext'
6010 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6011 (eval $ac_try) 2>&5
6012 ac_status=$?
6013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6014 (exit $ac_status); }; }; then
6015 ac_lo=0 ac_mid=0
6016 while :; do
6017 cat >conftest.$ac_ext <<_ACEOF
6018#line $LINENO "configure"
6019#include "confdefs.h"
6020$ac_includes_default
6021#ifdef F77_DUMMY_MAIN
6022# ifdef __cplusplus
6023 extern "C"
6024# endif
6025 int F77_DUMMY_MAIN() { return 1; }
6026#endif
6027int
6028main ()
6029{
6030static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
6031test_array [0] = 0
6032
6033 ;
6034 return 0;
6035}
6036_ACEOF
6037rm -f conftest.$ac_objext
6038if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6039 (eval $ac_compile) 2>&5
6040 ac_status=$?
6041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6042 (exit $ac_status); } &&
6043 { ac_try='test -s conftest.$ac_objext'
6044 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6045 (eval $ac_try) 2>&5
6046 ac_status=$?
6047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6048 (exit $ac_status); }; }; then
6049 ac_hi=$ac_mid; break
6050else
6051 echo "$as_me: failed program was:" >&5
6052cat conftest.$ac_ext >&5
6053ac_lo=`expr $ac_mid + 1`
6054 if test $ac_lo -le $ac_mid; then
6055 ac_lo= ac_hi=
6056 break
6057 fi
6058 ac_mid=`expr 2 '*' $ac_mid + 1`
6059fi
6060rm -f conftest.$ac_objext conftest.$ac_ext
6061 done
6062else
6063 echo "$as_me: failed program was:" >&5
6064cat conftest.$ac_ext >&5
6065cat >conftest.$ac_ext <<_ACEOF
6066#line $LINENO "configure"
6067#include "confdefs.h"
6068$ac_includes_default
6069#ifdef F77_DUMMY_MAIN
6070# ifdef __cplusplus
6071 extern "C"
6072# endif
6073 int F77_DUMMY_MAIN() { return 1; }
6074#endif
6075int
6076main ()
6077{
6078static int test_array [1 - 2 * !(((long) (sizeof (char))) < 0)];
6079test_array [0] = 0
6080
6081 ;
6082 return 0;
6083}
6084_ACEOF
6085rm -f conftest.$ac_objext
6086if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6087 (eval $ac_compile) 2>&5
6088 ac_status=$?
6089 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6090 (exit $ac_status); } &&
6091 { ac_try='test -s conftest.$ac_objext'
6092 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6093 (eval $ac_try) 2>&5
6094 ac_status=$?
6095 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6096 (exit $ac_status); }; }; then
6097 ac_hi=-1 ac_mid=-1
6098 while :; do
6099 cat >conftest.$ac_ext <<_ACEOF
6100#line $LINENO "configure"
6101#include "confdefs.h"
6102$ac_includes_default
6103#ifdef F77_DUMMY_MAIN
6104# ifdef __cplusplus
6105 extern "C"
6106# endif
6107 int F77_DUMMY_MAIN() { return 1; }
6108#endif
6109int
6110main ()
6111{
6112static int test_array [1 - 2 * !(((long) (sizeof (char))) >= $ac_mid)];
6113test_array [0] = 0
6114
6115 ;
6116 return 0;
6117}
6118_ACEOF
6119rm -f conftest.$ac_objext
6120if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6121 (eval $ac_compile) 2>&5
6122 ac_status=$?
6123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6124 (exit $ac_status); } &&
6125 { ac_try='test -s conftest.$ac_objext'
6126 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6127 (eval $ac_try) 2>&5
6128 ac_status=$?
6129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6130 (exit $ac_status); }; }; then
6131 ac_lo=$ac_mid; break
6132else
6133 echo "$as_me: failed program was:" >&5
6134cat conftest.$ac_ext >&5
6135ac_hi=`expr '(' $ac_mid ')' - 1`
6136 if test $ac_mid -le $ac_hi; then
6137 ac_lo= ac_hi=
6138 break
6139 fi
6140 ac_mid=`expr 2 '*' $ac_mid`
6141fi
6142rm -f conftest.$ac_objext conftest.$ac_ext
6143 done
6144else
6145 echo "$as_me: failed program was:" >&5
6146cat conftest.$ac_ext >&5
6147ac_lo= ac_hi=
6148fi
6149rm -f conftest.$ac_objext conftest.$ac_ext
6150fi
6151rm -f conftest.$ac_objext conftest.$ac_ext
6152# Binary search between lo and hi bounds.
6153while test "x$ac_lo" != "x$ac_hi"; do
6154 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6155 cat >conftest.$ac_ext <<_ACEOF
6156#line $LINENO "configure"
6157#include "confdefs.h"
6158$ac_includes_default
6159#ifdef F77_DUMMY_MAIN
6160# ifdef __cplusplus
6161 extern "C"
6162# endif
6163 int F77_DUMMY_MAIN() { return 1; }
6164#endif
6165int
6166main ()
6167{
6168static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
6169test_array [0] = 0
6170
6171 ;
6172 return 0;
6173}
6174_ACEOF
6175rm -f conftest.$ac_objext
6176if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6177 (eval $ac_compile) 2>&5
6178 ac_status=$?
6179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6180 (exit $ac_status); } &&
6181 { ac_try='test -s conftest.$ac_objext'
6182 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6183 (eval $ac_try) 2>&5
6184 ac_status=$?
6185 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6186 (exit $ac_status); }; }; then
6187 ac_hi=$ac_mid
6188else
6189 echo "$as_me: failed program was:" >&5
6190cat conftest.$ac_ext >&5
6191ac_lo=`expr '(' $ac_mid ')' + 1`
6192fi
6193rm -f conftest.$ac_objext conftest.$ac_ext
6194done
6195case $ac_lo in
6196?*) ac_cv_sizeof_char=$ac_lo;;
6197'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77" >&5
6198echo "$as_me: error: cannot compute sizeof (char), 77" >&2;}
6199 { (exit 1); exit 1; }; } ;;
6200esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006201else
6202 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006203 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6204echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6205 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006206else
Martin v. Löwis11437992002-04-12 09:54:03 +00006207 cat >conftest.$ac_ext <<_ACEOF
6208#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006209#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006210$ac_includes_default
6211long longval () { return (long) (sizeof (char)); }
6212unsigned long ulongval () { return (long) (sizeof (char)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006213#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006214#include <stdlib.h>
6215#ifdef F77_DUMMY_MAIN
6216# ifdef __cplusplus
6217 extern "C"
6218# endif
6219 int F77_DUMMY_MAIN() { return 1; }
6220#endif
6221int
6222main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006223{
Martin v. Löwis11437992002-04-12 09:54:03 +00006224
6225 FILE *f = fopen ("conftest.val", "w");
6226 if (! f)
6227 exit (1);
6228 if (((long) (sizeof (char))) < 0)
6229 {
6230 long i = longval ();
6231 if (i != ((long) (sizeof (char))))
6232 exit (1);
6233 fprintf (f, "%ld\n", i);
6234 }
6235 else
6236 {
6237 unsigned long i = ulongval ();
6238 if (i != ((long) (sizeof (char))))
6239 exit (1);
6240 fprintf (f, "%lu\n", i);
6241 }
6242 exit (ferror (f) || fclose (f) != 0);
6243
6244 ;
6245 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006246}
Martin v. Löwis11437992002-04-12 09:54:03 +00006247_ACEOF
6248rm -f conftest$ac_exeext
6249if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6250 (eval $ac_link) 2>&5
6251 ac_status=$?
6252 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6253 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6254 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6255 (eval $ac_try) 2>&5
6256 ac_status=$?
6257 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6258 (exit $ac_status); }; }; then
6259 ac_cv_sizeof_char=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006260else
Martin v. Löwis11437992002-04-12 09:54:03 +00006261 echo "$as_me: program exited with status $ac_status" >&5
6262echo "$as_me: failed program was:" >&5
6263cat conftest.$ac_ext >&5
6264( exit $ac_status )
6265{ { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77" >&5
6266echo "$as_me: error: cannot compute sizeof (char), 77" >&2;}
6267 { (exit 1); exit 1; }; }
6268fi
6269rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6270fi
6271fi
6272rm -f conftest.val
6273else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006274 ac_cv_sizeof_char=0
6275fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00006276fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006277echo "$as_me:$LINENO: result: $ac_cv_sizeof_char" >&5
6278echo "${ECHO_T}$ac_cv_sizeof_char" >&6
6279cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006280#define SIZEOF_CHAR $ac_cv_sizeof_char
Martin v. Löwis11437992002-04-12 09:54:03 +00006281_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006282
6283
Martin v. Löwis11437992002-04-12 09:54:03 +00006284echo "$as_me:$LINENO: checking for short" >&5
6285echo $ECHO_N "checking for short... $ECHO_C" >&6
6286if test "${ac_cv_type_short+set}" = set; then
6287 echo $ECHO_N "(cached) $ECHO_C" >&6
6288else
6289 cat >conftest.$ac_ext <<_ACEOF
6290#line $LINENO "configure"
6291#include "confdefs.h"
6292$ac_includes_default
6293#ifdef F77_DUMMY_MAIN
6294# ifdef __cplusplus
6295 extern "C"
6296# endif
6297 int F77_DUMMY_MAIN() { return 1; }
6298#endif
6299int
6300main ()
6301{
6302if ((short *) 0)
6303 return 0;
6304if (sizeof (short))
6305 return 0;
6306 ;
6307 return 0;
6308}
6309_ACEOF
6310rm -f conftest.$ac_objext
6311if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6312 (eval $ac_compile) 2>&5
6313 ac_status=$?
6314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6315 (exit $ac_status); } &&
6316 { ac_try='test -s conftest.$ac_objext'
6317 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6318 (eval $ac_try) 2>&5
6319 ac_status=$?
6320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6321 (exit $ac_status); }; }; then
6322 ac_cv_type_short=yes
6323else
6324 echo "$as_me: failed program was:" >&5
6325cat conftest.$ac_ext >&5
6326ac_cv_type_short=no
6327fi
6328rm -f conftest.$ac_objext conftest.$ac_ext
6329fi
6330echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
6331echo "${ECHO_T}$ac_cv_type_short" >&6
6332
6333echo "$as_me:$LINENO: checking size of short" >&5
6334echo $ECHO_N "checking size of short... $ECHO_C" >&6
6335if test "${ac_cv_sizeof_short+set}" = set; then
6336 echo $ECHO_N "(cached) $ECHO_C" >&6
6337else
6338 if test "$ac_cv_type_short" = yes; then
6339 # The cast to unsigned long works around a bug in the HP C Compiler
6340 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6341 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6342 # This bug is HP SR number 8606223364.
6343 if test "$cross_compiling" = yes; then
6344 # Depending upon the size, compute the lo and hi bounds.
6345cat >conftest.$ac_ext <<_ACEOF
6346#line $LINENO "configure"
6347#include "confdefs.h"
6348$ac_includes_default
6349#ifdef F77_DUMMY_MAIN
6350# ifdef __cplusplus
6351 extern "C"
6352# endif
6353 int F77_DUMMY_MAIN() { return 1; }
6354#endif
6355int
6356main ()
6357{
6358static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
6359test_array [0] = 0
6360
6361 ;
6362 return 0;
6363}
6364_ACEOF
6365rm -f conftest.$ac_objext
6366if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6367 (eval $ac_compile) 2>&5
6368 ac_status=$?
6369 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6370 (exit $ac_status); } &&
6371 { ac_try='test -s conftest.$ac_objext'
6372 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6373 (eval $ac_try) 2>&5
6374 ac_status=$?
6375 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6376 (exit $ac_status); }; }; then
6377 ac_lo=0 ac_mid=0
6378 while :; do
6379 cat >conftest.$ac_ext <<_ACEOF
6380#line $LINENO "configure"
6381#include "confdefs.h"
6382$ac_includes_default
6383#ifdef F77_DUMMY_MAIN
6384# ifdef __cplusplus
6385 extern "C"
6386# endif
6387 int F77_DUMMY_MAIN() { return 1; }
6388#endif
6389int
6390main ()
6391{
6392static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
6393test_array [0] = 0
6394
6395 ;
6396 return 0;
6397}
6398_ACEOF
6399rm -f conftest.$ac_objext
6400if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6401 (eval $ac_compile) 2>&5
6402 ac_status=$?
6403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6404 (exit $ac_status); } &&
6405 { ac_try='test -s conftest.$ac_objext'
6406 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6407 (eval $ac_try) 2>&5
6408 ac_status=$?
6409 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6410 (exit $ac_status); }; }; then
6411 ac_hi=$ac_mid; break
6412else
6413 echo "$as_me: failed program was:" >&5
6414cat conftest.$ac_ext >&5
6415ac_lo=`expr $ac_mid + 1`
6416 if test $ac_lo -le $ac_mid; then
6417 ac_lo= ac_hi=
6418 break
6419 fi
6420 ac_mid=`expr 2 '*' $ac_mid + 1`
6421fi
6422rm -f conftest.$ac_objext conftest.$ac_ext
6423 done
6424else
6425 echo "$as_me: failed program was:" >&5
6426cat conftest.$ac_ext >&5
6427cat >conftest.$ac_ext <<_ACEOF
6428#line $LINENO "configure"
6429#include "confdefs.h"
6430$ac_includes_default
6431#ifdef F77_DUMMY_MAIN
6432# ifdef __cplusplus
6433 extern "C"
6434# endif
6435 int F77_DUMMY_MAIN() { return 1; }
6436#endif
6437int
6438main ()
6439{
6440static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
6441test_array [0] = 0
6442
6443 ;
6444 return 0;
6445}
6446_ACEOF
6447rm -f conftest.$ac_objext
6448if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6449 (eval $ac_compile) 2>&5
6450 ac_status=$?
6451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6452 (exit $ac_status); } &&
6453 { ac_try='test -s conftest.$ac_objext'
6454 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6455 (eval $ac_try) 2>&5
6456 ac_status=$?
6457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6458 (exit $ac_status); }; }; then
6459 ac_hi=-1 ac_mid=-1
6460 while :; do
6461 cat >conftest.$ac_ext <<_ACEOF
6462#line $LINENO "configure"
6463#include "confdefs.h"
6464$ac_includes_default
6465#ifdef F77_DUMMY_MAIN
6466# ifdef __cplusplus
6467 extern "C"
6468# endif
6469 int F77_DUMMY_MAIN() { return 1; }
6470#endif
6471int
6472main ()
6473{
6474static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
6475test_array [0] = 0
6476
6477 ;
6478 return 0;
6479}
6480_ACEOF
6481rm -f conftest.$ac_objext
6482if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6483 (eval $ac_compile) 2>&5
6484 ac_status=$?
6485 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6486 (exit $ac_status); } &&
6487 { ac_try='test -s conftest.$ac_objext'
6488 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6489 (eval $ac_try) 2>&5
6490 ac_status=$?
6491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6492 (exit $ac_status); }; }; then
6493 ac_lo=$ac_mid; break
6494else
6495 echo "$as_me: failed program was:" >&5
6496cat conftest.$ac_ext >&5
6497ac_hi=`expr '(' $ac_mid ')' - 1`
6498 if test $ac_mid -le $ac_hi; then
6499 ac_lo= ac_hi=
6500 break
6501 fi
6502 ac_mid=`expr 2 '*' $ac_mid`
6503fi
6504rm -f conftest.$ac_objext conftest.$ac_ext
6505 done
6506else
6507 echo "$as_me: failed program was:" >&5
6508cat conftest.$ac_ext >&5
6509ac_lo= ac_hi=
6510fi
6511rm -f conftest.$ac_objext conftest.$ac_ext
6512fi
6513rm -f conftest.$ac_objext conftest.$ac_ext
6514# Binary search between lo and hi bounds.
6515while test "x$ac_lo" != "x$ac_hi"; do
6516 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6517 cat >conftest.$ac_ext <<_ACEOF
6518#line $LINENO "configure"
6519#include "confdefs.h"
6520$ac_includes_default
6521#ifdef F77_DUMMY_MAIN
6522# ifdef __cplusplus
6523 extern "C"
6524# endif
6525 int F77_DUMMY_MAIN() { return 1; }
6526#endif
6527int
6528main ()
6529{
6530static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
6531test_array [0] = 0
6532
6533 ;
6534 return 0;
6535}
6536_ACEOF
6537rm -f conftest.$ac_objext
6538if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6539 (eval $ac_compile) 2>&5
6540 ac_status=$?
6541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6542 (exit $ac_status); } &&
6543 { ac_try='test -s conftest.$ac_objext'
6544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6545 (eval $ac_try) 2>&5
6546 ac_status=$?
6547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6548 (exit $ac_status); }; }; then
6549 ac_hi=$ac_mid
6550else
6551 echo "$as_me: failed program was:" >&5
6552cat conftest.$ac_ext >&5
6553ac_lo=`expr '(' $ac_mid ')' + 1`
6554fi
6555rm -f conftest.$ac_objext conftest.$ac_ext
6556done
6557case $ac_lo in
6558?*) ac_cv_sizeof_short=$ac_lo;;
6559'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77" >&5
6560echo "$as_me: error: cannot compute sizeof (short), 77" >&2;}
6561 { (exit 1); exit 1; }; } ;;
6562esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006563else
6564 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006565 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6566echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6567 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006568else
Martin v. Löwis11437992002-04-12 09:54:03 +00006569 cat >conftest.$ac_ext <<_ACEOF
6570#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006571#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006572$ac_includes_default
6573long longval () { return (long) (sizeof (short)); }
6574unsigned long ulongval () { return (long) (sizeof (short)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006575#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006576#include <stdlib.h>
6577#ifdef F77_DUMMY_MAIN
6578# ifdef __cplusplus
6579 extern "C"
6580# endif
6581 int F77_DUMMY_MAIN() { return 1; }
6582#endif
6583int
6584main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006585{
Martin v. Löwis11437992002-04-12 09:54:03 +00006586
6587 FILE *f = fopen ("conftest.val", "w");
6588 if (! f)
6589 exit (1);
6590 if (((long) (sizeof (short))) < 0)
6591 {
6592 long i = longval ();
6593 if (i != ((long) (sizeof (short))))
6594 exit (1);
6595 fprintf (f, "%ld\n", i);
6596 }
6597 else
6598 {
6599 unsigned long i = ulongval ();
6600 if (i != ((long) (sizeof (short))))
6601 exit (1);
6602 fprintf (f, "%lu\n", i);
6603 }
6604 exit (ferror (f) || fclose (f) != 0);
6605
6606 ;
6607 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006608}
Martin v. Löwis11437992002-04-12 09:54:03 +00006609_ACEOF
6610rm -f conftest$ac_exeext
6611if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6612 (eval $ac_link) 2>&5
6613 ac_status=$?
6614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6615 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6616 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6617 (eval $ac_try) 2>&5
6618 ac_status=$?
6619 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6620 (exit $ac_status); }; }; then
6621 ac_cv_sizeof_short=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006622else
Martin v. Löwis11437992002-04-12 09:54:03 +00006623 echo "$as_me: program exited with status $ac_status" >&5
6624echo "$as_me: failed program was:" >&5
6625cat conftest.$ac_ext >&5
6626( exit $ac_status )
6627{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77" >&5
6628echo "$as_me: error: cannot compute sizeof (short), 77" >&2;}
6629 { (exit 1); exit 1; }; }
6630fi
6631rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6632fi
6633fi
6634rm -f conftest.val
6635else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006636 ac_cv_sizeof_short=0
6637fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00006638fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006639echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
6640echo "${ECHO_T}$ac_cv_sizeof_short" >&6
6641cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006642#define SIZEOF_SHORT $ac_cv_sizeof_short
Martin v. Löwis11437992002-04-12 09:54:03 +00006643_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006644
6645
Martin v. Löwis11437992002-04-12 09:54:03 +00006646echo "$as_me:$LINENO: checking for float" >&5
6647echo $ECHO_N "checking for float... $ECHO_C" >&6
6648if test "${ac_cv_type_float+set}" = set; then
6649 echo $ECHO_N "(cached) $ECHO_C" >&6
6650else
6651 cat >conftest.$ac_ext <<_ACEOF
6652#line $LINENO "configure"
6653#include "confdefs.h"
6654$ac_includes_default
6655#ifdef F77_DUMMY_MAIN
6656# ifdef __cplusplus
6657 extern "C"
6658# endif
6659 int F77_DUMMY_MAIN() { return 1; }
6660#endif
6661int
6662main ()
6663{
6664if ((float *) 0)
6665 return 0;
6666if (sizeof (float))
6667 return 0;
6668 ;
6669 return 0;
6670}
6671_ACEOF
6672rm -f conftest.$ac_objext
6673if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6674 (eval $ac_compile) 2>&5
6675 ac_status=$?
6676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6677 (exit $ac_status); } &&
6678 { ac_try='test -s conftest.$ac_objext'
6679 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6680 (eval $ac_try) 2>&5
6681 ac_status=$?
6682 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6683 (exit $ac_status); }; }; then
6684 ac_cv_type_float=yes
6685else
6686 echo "$as_me: failed program was:" >&5
6687cat conftest.$ac_ext >&5
6688ac_cv_type_float=no
6689fi
6690rm -f conftest.$ac_objext conftest.$ac_ext
6691fi
6692echo "$as_me:$LINENO: result: $ac_cv_type_float" >&5
6693echo "${ECHO_T}$ac_cv_type_float" >&6
6694
6695echo "$as_me:$LINENO: checking size of float" >&5
6696echo $ECHO_N "checking size of float... $ECHO_C" >&6
6697if test "${ac_cv_sizeof_float+set}" = set; then
6698 echo $ECHO_N "(cached) $ECHO_C" >&6
6699else
6700 if test "$ac_cv_type_float" = yes; then
6701 # The cast to unsigned long works around a bug in the HP C Compiler
6702 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6703 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6704 # This bug is HP SR number 8606223364.
6705 if test "$cross_compiling" = yes; then
6706 # Depending upon the size, compute the lo and hi bounds.
6707cat >conftest.$ac_ext <<_ACEOF
6708#line $LINENO "configure"
6709#include "confdefs.h"
6710$ac_includes_default
6711#ifdef F77_DUMMY_MAIN
6712# ifdef __cplusplus
6713 extern "C"
6714# endif
6715 int F77_DUMMY_MAIN() { return 1; }
6716#endif
6717int
6718main ()
6719{
6720static int test_array [1 - 2 * !(((long) (sizeof (float))) >= 0)];
6721test_array [0] = 0
6722
6723 ;
6724 return 0;
6725}
6726_ACEOF
6727rm -f conftest.$ac_objext
6728if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6729 (eval $ac_compile) 2>&5
6730 ac_status=$?
6731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6732 (exit $ac_status); } &&
6733 { ac_try='test -s conftest.$ac_objext'
6734 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6735 (eval $ac_try) 2>&5
6736 ac_status=$?
6737 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6738 (exit $ac_status); }; }; then
6739 ac_lo=0 ac_mid=0
6740 while :; do
6741 cat >conftest.$ac_ext <<_ACEOF
6742#line $LINENO "configure"
6743#include "confdefs.h"
6744$ac_includes_default
6745#ifdef F77_DUMMY_MAIN
6746# ifdef __cplusplus
6747 extern "C"
6748# endif
6749 int F77_DUMMY_MAIN() { return 1; }
6750#endif
6751int
6752main ()
6753{
6754static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
6755test_array [0] = 0
6756
6757 ;
6758 return 0;
6759}
6760_ACEOF
6761rm -f conftest.$ac_objext
6762if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6763 (eval $ac_compile) 2>&5
6764 ac_status=$?
6765 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6766 (exit $ac_status); } &&
6767 { ac_try='test -s conftest.$ac_objext'
6768 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6769 (eval $ac_try) 2>&5
6770 ac_status=$?
6771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6772 (exit $ac_status); }; }; then
6773 ac_hi=$ac_mid; break
6774else
6775 echo "$as_me: failed program was:" >&5
6776cat conftest.$ac_ext >&5
6777ac_lo=`expr $ac_mid + 1`
6778 if test $ac_lo -le $ac_mid; then
6779 ac_lo= ac_hi=
6780 break
6781 fi
6782 ac_mid=`expr 2 '*' $ac_mid + 1`
6783fi
6784rm -f conftest.$ac_objext conftest.$ac_ext
6785 done
6786else
6787 echo "$as_me: failed program was:" >&5
6788cat conftest.$ac_ext >&5
6789cat >conftest.$ac_ext <<_ACEOF
6790#line $LINENO "configure"
6791#include "confdefs.h"
6792$ac_includes_default
6793#ifdef F77_DUMMY_MAIN
6794# ifdef __cplusplus
6795 extern "C"
6796# endif
6797 int F77_DUMMY_MAIN() { return 1; }
6798#endif
6799int
6800main ()
6801{
6802static int test_array [1 - 2 * !(((long) (sizeof (float))) < 0)];
6803test_array [0] = 0
6804
6805 ;
6806 return 0;
6807}
6808_ACEOF
6809rm -f conftest.$ac_objext
6810if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6811 (eval $ac_compile) 2>&5
6812 ac_status=$?
6813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6814 (exit $ac_status); } &&
6815 { ac_try='test -s conftest.$ac_objext'
6816 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6817 (eval $ac_try) 2>&5
6818 ac_status=$?
6819 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6820 (exit $ac_status); }; }; then
6821 ac_hi=-1 ac_mid=-1
6822 while :; do
6823 cat >conftest.$ac_ext <<_ACEOF
6824#line $LINENO "configure"
6825#include "confdefs.h"
6826$ac_includes_default
6827#ifdef F77_DUMMY_MAIN
6828# ifdef __cplusplus
6829 extern "C"
6830# endif
6831 int F77_DUMMY_MAIN() { return 1; }
6832#endif
6833int
6834main ()
6835{
6836static int test_array [1 - 2 * !(((long) (sizeof (float))) >= $ac_mid)];
6837test_array [0] = 0
6838
6839 ;
6840 return 0;
6841}
6842_ACEOF
6843rm -f conftest.$ac_objext
6844if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6845 (eval $ac_compile) 2>&5
6846 ac_status=$?
6847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6848 (exit $ac_status); } &&
6849 { ac_try='test -s conftest.$ac_objext'
6850 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6851 (eval $ac_try) 2>&5
6852 ac_status=$?
6853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6854 (exit $ac_status); }; }; then
6855 ac_lo=$ac_mid; break
6856else
6857 echo "$as_me: failed program was:" >&5
6858cat conftest.$ac_ext >&5
6859ac_hi=`expr '(' $ac_mid ')' - 1`
6860 if test $ac_mid -le $ac_hi; then
6861 ac_lo= ac_hi=
6862 break
6863 fi
6864 ac_mid=`expr 2 '*' $ac_mid`
6865fi
6866rm -f conftest.$ac_objext conftest.$ac_ext
6867 done
6868else
6869 echo "$as_me: failed program was:" >&5
6870cat conftest.$ac_ext >&5
6871ac_lo= ac_hi=
6872fi
6873rm -f conftest.$ac_objext conftest.$ac_ext
6874fi
6875rm -f conftest.$ac_objext conftest.$ac_ext
6876# Binary search between lo and hi bounds.
6877while test "x$ac_lo" != "x$ac_hi"; do
6878 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6879 cat >conftest.$ac_ext <<_ACEOF
6880#line $LINENO "configure"
6881#include "confdefs.h"
6882$ac_includes_default
6883#ifdef F77_DUMMY_MAIN
6884# ifdef __cplusplus
6885 extern "C"
6886# endif
6887 int F77_DUMMY_MAIN() { return 1; }
6888#endif
6889int
6890main ()
6891{
6892static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
6893test_array [0] = 0
6894
6895 ;
6896 return 0;
6897}
6898_ACEOF
6899rm -f conftest.$ac_objext
6900if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6901 (eval $ac_compile) 2>&5
6902 ac_status=$?
6903 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6904 (exit $ac_status); } &&
6905 { ac_try='test -s conftest.$ac_objext'
6906 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6907 (eval $ac_try) 2>&5
6908 ac_status=$?
6909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6910 (exit $ac_status); }; }; then
6911 ac_hi=$ac_mid
6912else
6913 echo "$as_me: failed program was:" >&5
6914cat conftest.$ac_ext >&5
6915ac_lo=`expr '(' $ac_mid ')' + 1`
6916fi
6917rm -f conftest.$ac_objext conftest.$ac_ext
6918done
6919case $ac_lo in
6920?*) ac_cv_sizeof_float=$ac_lo;;
6921'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77" >&5
6922echo "$as_me: error: cannot compute sizeof (float), 77" >&2;}
6923 { (exit 1); exit 1; }; } ;;
6924esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006925else
6926 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006927 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6928echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6929 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006930else
Martin v. Löwis11437992002-04-12 09:54:03 +00006931 cat >conftest.$ac_ext <<_ACEOF
6932#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006933#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006934$ac_includes_default
6935long longval () { return (long) (sizeof (float)); }
6936unsigned long ulongval () { return (long) (sizeof (float)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006937#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006938#include <stdlib.h>
6939#ifdef F77_DUMMY_MAIN
6940# ifdef __cplusplus
6941 extern "C"
6942# endif
6943 int F77_DUMMY_MAIN() { return 1; }
6944#endif
6945int
6946main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006947{
Martin v. Löwis11437992002-04-12 09:54:03 +00006948
6949 FILE *f = fopen ("conftest.val", "w");
6950 if (! f)
6951 exit (1);
6952 if (((long) (sizeof (float))) < 0)
6953 {
6954 long i = longval ();
6955 if (i != ((long) (sizeof (float))))
6956 exit (1);
6957 fprintf (f, "%ld\n", i);
6958 }
6959 else
6960 {
6961 unsigned long i = ulongval ();
6962 if (i != ((long) (sizeof (float))))
6963 exit (1);
6964 fprintf (f, "%lu\n", i);
6965 }
6966 exit (ferror (f) || fclose (f) != 0);
6967
6968 ;
6969 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006970}
Martin v. Löwis11437992002-04-12 09:54:03 +00006971_ACEOF
6972rm -f conftest$ac_exeext
6973if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6974 (eval $ac_link) 2>&5
6975 ac_status=$?
6976 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6977 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6978 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6979 (eval $ac_try) 2>&5
6980 ac_status=$?
6981 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6982 (exit $ac_status); }; }; then
6983 ac_cv_sizeof_float=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006984else
Martin v. Löwis11437992002-04-12 09:54:03 +00006985 echo "$as_me: program exited with status $ac_status" >&5
6986echo "$as_me: failed program was:" >&5
6987cat conftest.$ac_ext >&5
6988( exit $ac_status )
6989{ { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77" >&5
6990echo "$as_me: error: cannot compute sizeof (float), 77" >&2;}
6991 { (exit 1); exit 1; }; }
6992fi
6993rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6994fi
6995fi
6996rm -f conftest.val
6997else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006998 ac_cv_sizeof_float=0
6999fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007000fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007001echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5
7002echo "${ECHO_T}$ac_cv_sizeof_float" >&6
7003cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007004#define SIZEOF_FLOAT $ac_cv_sizeof_float
Martin v. Löwis11437992002-04-12 09:54:03 +00007005_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007006
7007
Martin v. Löwis11437992002-04-12 09:54:03 +00007008echo "$as_me:$LINENO: checking for double" >&5
7009echo $ECHO_N "checking for double... $ECHO_C" >&6
7010if test "${ac_cv_type_double+set}" = set; then
7011 echo $ECHO_N "(cached) $ECHO_C" >&6
7012else
7013 cat >conftest.$ac_ext <<_ACEOF
7014#line $LINENO "configure"
7015#include "confdefs.h"
7016$ac_includes_default
7017#ifdef F77_DUMMY_MAIN
7018# ifdef __cplusplus
7019 extern "C"
7020# endif
7021 int F77_DUMMY_MAIN() { return 1; }
7022#endif
7023int
7024main ()
7025{
7026if ((double *) 0)
7027 return 0;
7028if (sizeof (double))
7029 return 0;
7030 ;
7031 return 0;
7032}
7033_ACEOF
7034rm -f conftest.$ac_objext
7035if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7036 (eval $ac_compile) 2>&5
7037 ac_status=$?
7038 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7039 (exit $ac_status); } &&
7040 { ac_try='test -s conftest.$ac_objext'
7041 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7042 (eval $ac_try) 2>&5
7043 ac_status=$?
7044 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7045 (exit $ac_status); }; }; then
7046 ac_cv_type_double=yes
7047else
7048 echo "$as_me: failed program was:" >&5
7049cat conftest.$ac_ext >&5
7050ac_cv_type_double=no
7051fi
7052rm -f conftest.$ac_objext conftest.$ac_ext
7053fi
7054echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
7055echo "${ECHO_T}$ac_cv_type_double" >&6
7056
7057echo "$as_me:$LINENO: checking size of double" >&5
7058echo $ECHO_N "checking size of double... $ECHO_C" >&6
7059if test "${ac_cv_sizeof_double+set}" = set; then
7060 echo $ECHO_N "(cached) $ECHO_C" >&6
7061else
7062 if test "$ac_cv_type_double" = yes; then
7063 # The cast to unsigned long works around a bug in the HP C Compiler
7064 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7065 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7066 # This bug is HP SR number 8606223364.
7067 if test "$cross_compiling" = yes; then
7068 # Depending upon the size, compute the lo and hi bounds.
7069cat >conftest.$ac_ext <<_ACEOF
7070#line $LINENO "configure"
7071#include "confdefs.h"
7072$ac_includes_default
7073#ifdef F77_DUMMY_MAIN
7074# ifdef __cplusplus
7075 extern "C"
7076# endif
7077 int F77_DUMMY_MAIN() { return 1; }
7078#endif
7079int
7080main ()
7081{
7082static int test_array [1 - 2 * !(((long) (sizeof (double))) >= 0)];
7083test_array [0] = 0
7084
7085 ;
7086 return 0;
7087}
7088_ACEOF
7089rm -f conftest.$ac_objext
7090if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7091 (eval $ac_compile) 2>&5
7092 ac_status=$?
7093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7094 (exit $ac_status); } &&
7095 { ac_try='test -s conftest.$ac_objext'
7096 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7097 (eval $ac_try) 2>&5
7098 ac_status=$?
7099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7100 (exit $ac_status); }; }; then
7101 ac_lo=0 ac_mid=0
7102 while :; do
7103 cat >conftest.$ac_ext <<_ACEOF
7104#line $LINENO "configure"
7105#include "confdefs.h"
7106$ac_includes_default
7107#ifdef F77_DUMMY_MAIN
7108# ifdef __cplusplus
7109 extern "C"
7110# endif
7111 int F77_DUMMY_MAIN() { return 1; }
7112#endif
7113int
7114main ()
7115{
7116static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
7117test_array [0] = 0
7118
7119 ;
7120 return 0;
7121}
7122_ACEOF
7123rm -f conftest.$ac_objext
7124if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7125 (eval $ac_compile) 2>&5
7126 ac_status=$?
7127 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7128 (exit $ac_status); } &&
7129 { ac_try='test -s conftest.$ac_objext'
7130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7131 (eval $ac_try) 2>&5
7132 ac_status=$?
7133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7134 (exit $ac_status); }; }; then
7135 ac_hi=$ac_mid; break
7136else
7137 echo "$as_me: failed program was:" >&5
7138cat conftest.$ac_ext >&5
7139ac_lo=`expr $ac_mid + 1`
7140 if test $ac_lo -le $ac_mid; then
7141 ac_lo= ac_hi=
7142 break
7143 fi
7144 ac_mid=`expr 2 '*' $ac_mid + 1`
7145fi
7146rm -f conftest.$ac_objext conftest.$ac_ext
7147 done
7148else
7149 echo "$as_me: failed program was:" >&5
7150cat conftest.$ac_ext >&5
7151cat >conftest.$ac_ext <<_ACEOF
7152#line $LINENO "configure"
7153#include "confdefs.h"
7154$ac_includes_default
7155#ifdef F77_DUMMY_MAIN
7156# ifdef __cplusplus
7157 extern "C"
7158# endif
7159 int F77_DUMMY_MAIN() { return 1; }
7160#endif
7161int
7162main ()
7163{
7164static int test_array [1 - 2 * !(((long) (sizeof (double))) < 0)];
7165test_array [0] = 0
7166
7167 ;
7168 return 0;
7169}
7170_ACEOF
7171rm -f conftest.$ac_objext
7172if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7173 (eval $ac_compile) 2>&5
7174 ac_status=$?
7175 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7176 (exit $ac_status); } &&
7177 { ac_try='test -s conftest.$ac_objext'
7178 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7179 (eval $ac_try) 2>&5
7180 ac_status=$?
7181 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7182 (exit $ac_status); }; }; then
7183 ac_hi=-1 ac_mid=-1
7184 while :; do
7185 cat >conftest.$ac_ext <<_ACEOF
7186#line $LINENO "configure"
7187#include "confdefs.h"
7188$ac_includes_default
7189#ifdef F77_DUMMY_MAIN
7190# ifdef __cplusplus
7191 extern "C"
7192# endif
7193 int F77_DUMMY_MAIN() { return 1; }
7194#endif
7195int
7196main ()
7197{
7198static int test_array [1 - 2 * !(((long) (sizeof (double))) >= $ac_mid)];
7199test_array [0] = 0
7200
7201 ;
7202 return 0;
7203}
7204_ACEOF
7205rm -f conftest.$ac_objext
7206if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7207 (eval $ac_compile) 2>&5
7208 ac_status=$?
7209 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7210 (exit $ac_status); } &&
7211 { ac_try='test -s conftest.$ac_objext'
7212 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7213 (eval $ac_try) 2>&5
7214 ac_status=$?
7215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7216 (exit $ac_status); }; }; then
7217 ac_lo=$ac_mid; break
7218else
7219 echo "$as_me: failed program was:" >&5
7220cat conftest.$ac_ext >&5
7221ac_hi=`expr '(' $ac_mid ')' - 1`
7222 if test $ac_mid -le $ac_hi; then
7223 ac_lo= ac_hi=
7224 break
7225 fi
7226 ac_mid=`expr 2 '*' $ac_mid`
7227fi
7228rm -f conftest.$ac_objext conftest.$ac_ext
7229 done
7230else
7231 echo "$as_me: failed program was:" >&5
7232cat conftest.$ac_ext >&5
7233ac_lo= ac_hi=
7234fi
7235rm -f conftest.$ac_objext conftest.$ac_ext
7236fi
7237rm -f conftest.$ac_objext conftest.$ac_ext
7238# Binary search between lo and hi bounds.
7239while test "x$ac_lo" != "x$ac_hi"; do
7240 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7241 cat >conftest.$ac_ext <<_ACEOF
7242#line $LINENO "configure"
7243#include "confdefs.h"
7244$ac_includes_default
7245#ifdef F77_DUMMY_MAIN
7246# ifdef __cplusplus
7247 extern "C"
7248# endif
7249 int F77_DUMMY_MAIN() { return 1; }
7250#endif
7251int
7252main ()
7253{
7254static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
7255test_array [0] = 0
7256
7257 ;
7258 return 0;
7259}
7260_ACEOF
7261rm -f conftest.$ac_objext
7262if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7263 (eval $ac_compile) 2>&5
7264 ac_status=$?
7265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7266 (exit $ac_status); } &&
7267 { ac_try='test -s conftest.$ac_objext'
7268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7269 (eval $ac_try) 2>&5
7270 ac_status=$?
7271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7272 (exit $ac_status); }; }; then
7273 ac_hi=$ac_mid
7274else
7275 echo "$as_me: failed program was:" >&5
7276cat conftest.$ac_ext >&5
7277ac_lo=`expr '(' $ac_mid ')' + 1`
7278fi
7279rm -f conftest.$ac_objext conftest.$ac_ext
7280done
7281case $ac_lo in
7282?*) ac_cv_sizeof_double=$ac_lo;;
7283'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77" >&5
7284echo "$as_me: error: cannot compute sizeof (double), 77" >&2;}
7285 { (exit 1); exit 1; }; } ;;
7286esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007287else
7288 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007289 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7290echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7291 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007292else
Martin v. Löwis11437992002-04-12 09:54:03 +00007293 cat >conftest.$ac_ext <<_ACEOF
7294#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00007295#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007296$ac_includes_default
7297long longval () { return (long) (sizeof (double)); }
7298unsigned long ulongval () { return (long) (sizeof (double)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007299#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007300#include <stdlib.h>
7301#ifdef F77_DUMMY_MAIN
7302# ifdef __cplusplus
7303 extern "C"
7304# endif
7305 int F77_DUMMY_MAIN() { return 1; }
7306#endif
7307int
7308main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007309{
Martin v. Löwis11437992002-04-12 09:54:03 +00007310
7311 FILE *f = fopen ("conftest.val", "w");
7312 if (! f)
7313 exit (1);
7314 if (((long) (sizeof (double))) < 0)
7315 {
7316 long i = longval ();
7317 if (i != ((long) (sizeof (double))))
7318 exit (1);
7319 fprintf (f, "%ld\n", i);
7320 }
7321 else
7322 {
7323 unsigned long i = ulongval ();
7324 if (i != ((long) (sizeof (double))))
7325 exit (1);
7326 fprintf (f, "%lu\n", i);
7327 }
7328 exit (ferror (f) || fclose (f) != 0);
7329
7330 ;
7331 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007332}
Martin v. Löwis11437992002-04-12 09:54:03 +00007333_ACEOF
7334rm -f conftest$ac_exeext
7335if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7336 (eval $ac_link) 2>&5
7337 ac_status=$?
7338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7339 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7340 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7341 (eval $ac_try) 2>&5
7342 ac_status=$?
7343 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7344 (exit $ac_status); }; }; then
7345 ac_cv_sizeof_double=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007346else
Martin v. Löwis11437992002-04-12 09:54:03 +00007347 echo "$as_me: program exited with status $ac_status" >&5
7348echo "$as_me: failed program was:" >&5
7349cat conftest.$ac_ext >&5
7350( exit $ac_status )
7351{ { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77" >&5
7352echo "$as_me: error: cannot compute sizeof (double), 77" >&2;}
7353 { (exit 1); exit 1; }; }
7354fi
7355rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7356fi
7357fi
7358rm -f conftest.val
7359else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007360 ac_cv_sizeof_double=0
7361fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007362fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007363echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5
7364echo "${ECHO_T}$ac_cv_sizeof_double" >&6
7365cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007366#define SIZEOF_DOUBLE $ac_cv_sizeof_double
Martin v. Löwis11437992002-04-12 09:54:03 +00007367_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007368
7369
Martin v. Löwis11437992002-04-12 09:54:03 +00007370echo "$as_me:$LINENO: checking for fpos_t" >&5
7371echo $ECHO_N "checking for fpos_t... $ECHO_C" >&6
7372if test "${ac_cv_type_fpos_t+set}" = set; then
7373 echo $ECHO_N "(cached) $ECHO_C" >&6
7374else
7375 cat >conftest.$ac_ext <<_ACEOF
7376#line $LINENO "configure"
7377#include "confdefs.h"
7378$ac_includes_default
7379#ifdef F77_DUMMY_MAIN
7380# ifdef __cplusplus
7381 extern "C"
7382# endif
7383 int F77_DUMMY_MAIN() { return 1; }
7384#endif
7385int
7386main ()
7387{
7388if ((fpos_t *) 0)
7389 return 0;
7390if (sizeof (fpos_t))
7391 return 0;
7392 ;
7393 return 0;
7394}
7395_ACEOF
7396rm -f conftest.$ac_objext
7397if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7398 (eval $ac_compile) 2>&5
7399 ac_status=$?
7400 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7401 (exit $ac_status); } &&
7402 { ac_try='test -s conftest.$ac_objext'
7403 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7404 (eval $ac_try) 2>&5
7405 ac_status=$?
7406 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7407 (exit $ac_status); }; }; then
7408 ac_cv_type_fpos_t=yes
7409else
7410 echo "$as_me: failed program was:" >&5
7411cat conftest.$ac_ext >&5
7412ac_cv_type_fpos_t=no
7413fi
7414rm -f conftest.$ac_objext conftest.$ac_ext
7415fi
7416echo "$as_me:$LINENO: result: $ac_cv_type_fpos_t" >&5
7417echo "${ECHO_T}$ac_cv_type_fpos_t" >&6
7418
7419echo "$as_me:$LINENO: checking size of fpos_t" >&5
7420echo $ECHO_N "checking size of fpos_t... $ECHO_C" >&6
7421if test "${ac_cv_sizeof_fpos_t+set}" = set; then
7422 echo $ECHO_N "(cached) $ECHO_C" >&6
7423else
7424 if test "$ac_cv_type_fpos_t" = yes; then
7425 # The cast to unsigned long works around a bug in the HP C Compiler
7426 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7427 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7428 # This bug is HP SR number 8606223364.
7429 if test "$cross_compiling" = yes; then
7430 # Depending upon the size, compute the lo and hi bounds.
7431cat >conftest.$ac_ext <<_ACEOF
7432#line $LINENO "configure"
7433#include "confdefs.h"
7434$ac_includes_default
7435#ifdef F77_DUMMY_MAIN
7436# ifdef __cplusplus
7437 extern "C"
7438# endif
7439 int F77_DUMMY_MAIN() { return 1; }
7440#endif
7441int
7442main ()
7443{
7444static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= 0)];
7445test_array [0] = 0
7446
7447 ;
7448 return 0;
7449}
7450_ACEOF
7451rm -f conftest.$ac_objext
7452if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7453 (eval $ac_compile) 2>&5
7454 ac_status=$?
7455 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7456 (exit $ac_status); } &&
7457 { ac_try='test -s conftest.$ac_objext'
7458 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7459 (eval $ac_try) 2>&5
7460 ac_status=$?
7461 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7462 (exit $ac_status); }; }; then
7463 ac_lo=0 ac_mid=0
7464 while :; do
7465 cat >conftest.$ac_ext <<_ACEOF
7466#line $LINENO "configure"
7467#include "confdefs.h"
7468$ac_includes_default
7469#ifdef F77_DUMMY_MAIN
7470# ifdef __cplusplus
7471 extern "C"
7472# endif
7473 int F77_DUMMY_MAIN() { return 1; }
7474#endif
7475int
7476main ()
7477{
7478static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
7479test_array [0] = 0
7480
7481 ;
7482 return 0;
7483}
7484_ACEOF
7485rm -f conftest.$ac_objext
7486if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7487 (eval $ac_compile) 2>&5
7488 ac_status=$?
7489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7490 (exit $ac_status); } &&
7491 { ac_try='test -s conftest.$ac_objext'
7492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7493 (eval $ac_try) 2>&5
7494 ac_status=$?
7495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7496 (exit $ac_status); }; }; then
7497 ac_hi=$ac_mid; break
7498else
7499 echo "$as_me: failed program was:" >&5
7500cat conftest.$ac_ext >&5
7501ac_lo=`expr $ac_mid + 1`
7502 if test $ac_lo -le $ac_mid; then
7503 ac_lo= ac_hi=
7504 break
7505 fi
7506 ac_mid=`expr 2 '*' $ac_mid + 1`
7507fi
7508rm -f conftest.$ac_objext conftest.$ac_ext
7509 done
7510else
7511 echo "$as_me: failed program was:" >&5
7512cat conftest.$ac_ext >&5
7513cat >conftest.$ac_ext <<_ACEOF
7514#line $LINENO "configure"
7515#include "confdefs.h"
7516$ac_includes_default
7517#ifdef F77_DUMMY_MAIN
7518# ifdef __cplusplus
7519 extern "C"
7520# endif
7521 int F77_DUMMY_MAIN() { return 1; }
7522#endif
7523int
7524main ()
7525{
7526static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) < 0)];
7527test_array [0] = 0
7528
7529 ;
7530 return 0;
7531}
7532_ACEOF
7533rm -f conftest.$ac_objext
7534if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7535 (eval $ac_compile) 2>&5
7536 ac_status=$?
7537 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7538 (exit $ac_status); } &&
7539 { ac_try='test -s conftest.$ac_objext'
7540 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7541 (eval $ac_try) 2>&5
7542 ac_status=$?
7543 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7544 (exit $ac_status); }; }; then
7545 ac_hi=-1 ac_mid=-1
7546 while :; do
7547 cat >conftest.$ac_ext <<_ACEOF
7548#line $LINENO "configure"
7549#include "confdefs.h"
7550$ac_includes_default
7551#ifdef F77_DUMMY_MAIN
7552# ifdef __cplusplus
7553 extern "C"
7554# endif
7555 int F77_DUMMY_MAIN() { return 1; }
7556#endif
7557int
7558main ()
7559{
7560static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= $ac_mid)];
7561test_array [0] = 0
7562
7563 ;
7564 return 0;
7565}
7566_ACEOF
7567rm -f conftest.$ac_objext
7568if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7569 (eval $ac_compile) 2>&5
7570 ac_status=$?
7571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7572 (exit $ac_status); } &&
7573 { ac_try='test -s conftest.$ac_objext'
7574 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7575 (eval $ac_try) 2>&5
7576 ac_status=$?
7577 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7578 (exit $ac_status); }; }; then
7579 ac_lo=$ac_mid; break
7580else
7581 echo "$as_me: failed program was:" >&5
7582cat conftest.$ac_ext >&5
7583ac_hi=`expr '(' $ac_mid ')' - 1`
7584 if test $ac_mid -le $ac_hi; then
7585 ac_lo= ac_hi=
7586 break
7587 fi
7588 ac_mid=`expr 2 '*' $ac_mid`
7589fi
7590rm -f conftest.$ac_objext conftest.$ac_ext
7591 done
7592else
7593 echo "$as_me: failed program was:" >&5
7594cat conftest.$ac_ext >&5
7595ac_lo= ac_hi=
7596fi
7597rm -f conftest.$ac_objext conftest.$ac_ext
7598fi
7599rm -f conftest.$ac_objext conftest.$ac_ext
7600# Binary search between lo and hi bounds.
7601while test "x$ac_lo" != "x$ac_hi"; do
7602 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7603 cat >conftest.$ac_ext <<_ACEOF
7604#line $LINENO "configure"
7605#include "confdefs.h"
7606$ac_includes_default
7607#ifdef F77_DUMMY_MAIN
7608# ifdef __cplusplus
7609 extern "C"
7610# endif
7611 int F77_DUMMY_MAIN() { return 1; }
7612#endif
7613int
7614main ()
7615{
7616static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
7617test_array [0] = 0
7618
7619 ;
7620 return 0;
7621}
7622_ACEOF
7623rm -f conftest.$ac_objext
7624if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7625 (eval $ac_compile) 2>&5
7626 ac_status=$?
7627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7628 (exit $ac_status); } &&
7629 { ac_try='test -s conftest.$ac_objext'
7630 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7631 (eval $ac_try) 2>&5
7632 ac_status=$?
7633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7634 (exit $ac_status); }; }; then
7635 ac_hi=$ac_mid
7636else
7637 echo "$as_me: failed program was:" >&5
7638cat conftest.$ac_ext >&5
7639ac_lo=`expr '(' $ac_mid ')' + 1`
7640fi
7641rm -f conftest.$ac_objext conftest.$ac_ext
7642done
7643case $ac_lo in
7644?*) ac_cv_sizeof_fpos_t=$ac_lo;;
7645'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77" >&5
7646echo "$as_me: error: cannot compute sizeof (fpos_t), 77" >&2;}
7647 { (exit 1); exit 1; }; } ;;
7648esac
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007649else
7650 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007651 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7652echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7653 { (exit 1); exit 1; }; }
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007654else
Martin v. Löwis11437992002-04-12 09:54:03 +00007655 cat >conftest.$ac_ext <<_ACEOF
7656#line $LINENO "configure"
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007657#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007658$ac_includes_default
7659long longval () { return (long) (sizeof (fpos_t)); }
7660unsigned long ulongval () { return (long) (sizeof (fpos_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007661#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007662#include <stdlib.h>
7663#ifdef F77_DUMMY_MAIN
7664# ifdef __cplusplus
7665 extern "C"
7666# endif
7667 int F77_DUMMY_MAIN() { return 1; }
7668#endif
7669int
7670main ()
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007671{
Martin v. Löwis11437992002-04-12 09:54:03 +00007672
7673 FILE *f = fopen ("conftest.val", "w");
7674 if (! f)
7675 exit (1);
7676 if (((long) (sizeof (fpos_t))) < 0)
7677 {
7678 long i = longval ();
7679 if (i != ((long) (sizeof (fpos_t))))
7680 exit (1);
7681 fprintf (f, "%ld\n", i);
7682 }
7683 else
7684 {
7685 unsigned long i = ulongval ();
7686 if (i != ((long) (sizeof (fpos_t))))
7687 exit (1);
7688 fprintf (f, "%lu\n", i);
7689 }
7690 exit (ferror (f) || fclose (f) != 0);
7691
7692 ;
7693 return 0;
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007694}
Martin v. Löwis11437992002-04-12 09:54:03 +00007695_ACEOF
7696rm -f conftest$ac_exeext
7697if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7698 (eval $ac_link) 2>&5
7699 ac_status=$?
7700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7701 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7702 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7703 (eval $ac_try) 2>&5
7704 ac_status=$?
7705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7706 (exit $ac_status); }; }; then
7707 ac_cv_sizeof_fpos_t=`cat conftest.val`
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007708else
Martin v. Löwis11437992002-04-12 09:54:03 +00007709 echo "$as_me: program exited with status $ac_status" >&5
7710echo "$as_me: failed program was:" >&5
7711cat conftest.$ac_ext >&5
7712( exit $ac_status )
7713{ { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77" >&5
7714echo "$as_me: error: cannot compute sizeof (fpos_t), 77" >&2;}
7715 { (exit 1); exit 1; }; }
7716fi
7717rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7718fi
7719fi
7720rm -f conftest.val
7721else
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007722 ac_cv_sizeof_fpos_t=0
7723fi
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007724fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007725echo "$as_me:$LINENO: result: $ac_cv_sizeof_fpos_t" >&5
7726echo "${ECHO_T}$ac_cv_sizeof_fpos_t" >&6
7727cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007728#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
Martin v. Löwis11437992002-04-12 09:54:03 +00007729_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007730
Michael W. Hudson54241132001-12-07 15:38:26 +00007731
7732
Martin v. Löwis11437992002-04-12 09:54:03 +00007733echo "$as_me:$LINENO: checking for long long support" >&5
7734echo $ECHO_N "checking for long long support... $ECHO_C" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +00007735have_long_long=no
Martin v. Löwis11437992002-04-12 09:54:03 +00007736cat >conftest.$ac_ext <<_ACEOF
7737#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00007738#include "confdefs.h"
7739
Martin v. Löwis11437992002-04-12 09:54:03 +00007740#ifdef F77_DUMMY_MAIN
7741# ifdef __cplusplus
7742 extern "C"
7743# endif
7744 int F77_DUMMY_MAIN() { return 1; }
7745#endif
7746int
7747main ()
7748{
Guido van Rossumec95c7b1998-08-04 17:59:56 +00007749long long x; x = (long long)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00007750 ;
7751 return 0;
7752}
7753_ACEOF
7754rm -f conftest.$ac_objext
7755if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7756 (eval $ac_compile) 2>&5
7757 ac_status=$?
7758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7759 (exit $ac_status); } &&
7760 { ac_try='test -s conftest.$ac_objext'
7761 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7762 (eval $ac_try) 2>&5
7763 ac_status=$?
7764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7765 (exit $ac_status); }; }; then
7766
7767
7768cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00007769#define HAVE_LONG_LONG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00007770_ACEOF
7771
Martin v. Löwisc45929e2002-04-06 10:10:49 +00007772 have_long_long=yes
7773
Guido van Rossumec95c7b1998-08-04 17:59:56 +00007774else
Martin v. Löwis11437992002-04-12 09:54:03 +00007775 echo "$as_me: failed program was:" >&5
7776cat conftest.$ac_ext >&5
Guido van Rossumec95c7b1998-08-04 17:59:56 +00007777fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007778rm -f conftest.$ac_objext conftest.$ac_ext
7779echo "$as_me:$LINENO: result: $have_long_long" >&5
7780echo "${ECHO_T}$have_long_long" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00007781if test "$have_long_long" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007782echo "$as_me:$LINENO: checking for long long" >&5
7783echo $ECHO_N "checking for long long... $ECHO_C" >&6
7784if test "${ac_cv_type_long_long+set}" = set; then
7785 echo $ECHO_N "(cached) $ECHO_C" >&6
7786else
7787 cat >conftest.$ac_ext <<_ACEOF
7788#line $LINENO "configure"
7789#include "confdefs.h"
7790$ac_includes_default
7791#ifdef F77_DUMMY_MAIN
7792# ifdef __cplusplus
7793 extern "C"
7794# endif
7795 int F77_DUMMY_MAIN() { return 1; }
7796#endif
7797int
7798main ()
7799{
7800if ((long long *) 0)
7801 return 0;
7802if (sizeof (long long))
7803 return 0;
7804 ;
7805 return 0;
7806}
7807_ACEOF
7808rm -f conftest.$ac_objext
7809if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7810 (eval $ac_compile) 2>&5
7811 ac_status=$?
7812 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7813 (exit $ac_status); } &&
7814 { ac_try='test -s conftest.$ac_objext'
7815 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7816 (eval $ac_try) 2>&5
7817 ac_status=$?
7818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7819 (exit $ac_status); }; }; then
7820 ac_cv_type_long_long=yes
7821else
7822 echo "$as_me: failed program was:" >&5
7823cat conftest.$ac_ext >&5
7824ac_cv_type_long_long=no
7825fi
7826rm -f conftest.$ac_objext conftest.$ac_ext
7827fi
7828echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
7829echo "${ECHO_T}$ac_cv_type_long_long" >&6
7830
7831echo "$as_me:$LINENO: checking size of long long" >&5
7832echo $ECHO_N "checking size of long long... $ECHO_C" >&6
7833if test "${ac_cv_sizeof_long_long+set}" = set; then
7834 echo $ECHO_N "(cached) $ECHO_C" >&6
7835else
7836 if test "$ac_cv_type_long_long" = yes; then
7837 # The cast to unsigned long works around a bug in the HP C Compiler
7838 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7839 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7840 # This bug is HP SR number 8606223364.
7841 if test "$cross_compiling" = yes; then
7842 # Depending upon the size, compute the lo and hi bounds.
7843cat >conftest.$ac_ext <<_ACEOF
7844#line $LINENO "configure"
7845#include "confdefs.h"
7846$ac_includes_default
7847#ifdef F77_DUMMY_MAIN
7848# ifdef __cplusplus
7849 extern "C"
7850# endif
7851 int F77_DUMMY_MAIN() { return 1; }
7852#endif
7853int
7854main ()
7855{
7856static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
7857test_array [0] = 0
7858
7859 ;
7860 return 0;
7861}
7862_ACEOF
7863rm -f conftest.$ac_objext
7864if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7865 (eval $ac_compile) 2>&5
7866 ac_status=$?
7867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7868 (exit $ac_status); } &&
7869 { ac_try='test -s conftest.$ac_objext'
7870 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7871 (eval $ac_try) 2>&5
7872 ac_status=$?
7873 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7874 (exit $ac_status); }; }; then
7875 ac_lo=0 ac_mid=0
7876 while :; do
7877 cat >conftest.$ac_ext <<_ACEOF
7878#line $LINENO "configure"
7879#include "confdefs.h"
7880$ac_includes_default
7881#ifdef F77_DUMMY_MAIN
7882# ifdef __cplusplus
7883 extern "C"
7884# endif
7885 int F77_DUMMY_MAIN() { return 1; }
7886#endif
7887int
7888main ()
7889{
7890static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
7891test_array [0] = 0
7892
7893 ;
7894 return 0;
7895}
7896_ACEOF
7897rm -f conftest.$ac_objext
7898if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7899 (eval $ac_compile) 2>&5
7900 ac_status=$?
7901 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7902 (exit $ac_status); } &&
7903 { ac_try='test -s conftest.$ac_objext'
7904 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7905 (eval $ac_try) 2>&5
7906 ac_status=$?
7907 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7908 (exit $ac_status); }; }; then
7909 ac_hi=$ac_mid; break
7910else
7911 echo "$as_me: failed program was:" >&5
7912cat conftest.$ac_ext >&5
7913ac_lo=`expr $ac_mid + 1`
7914 if test $ac_lo -le $ac_mid; then
7915 ac_lo= ac_hi=
7916 break
7917 fi
7918 ac_mid=`expr 2 '*' $ac_mid + 1`
7919fi
7920rm -f conftest.$ac_objext conftest.$ac_ext
7921 done
7922else
7923 echo "$as_me: failed program was:" >&5
7924cat conftest.$ac_ext >&5
7925cat >conftest.$ac_ext <<_ACEOF
7926#line $LINENO "configure"
7927#include "confdefs.h"
7928$ac_includes_default
7929#ifdef F77_DUMMY_MAIN
7930# ifdef __cplusplus
7931 extern "C"
7932# endif
7933 int F77_DUMMY_MAIN() { return 1; }
7934#endif
7935int
7936main ()
7937{
7938static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
7939test_array [0] = 0
7940
7941 ;
7942 return 0;
7943}
7944_ACEOF
7945rm -f conftest.$ac_objext
7946if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7947 (eval $ac_compile) 2>&5
7948 ac_status=$?
7949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7950 (exit $ac_status); } &&
7951 { ac_try='test -s conftest.$ac_objext'
7952 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7953 (eval $ac_try) 2>&5
7954 ac_status=$?
7955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7956 (exit $ac_status); }; }; then
7957 ac_hi=-1 ac_mid=-1
7958 while :; do
7959 cat >conftest.$ac_ext <<_ACEOF
7960#line $LINENO "configure"
7961#include "confdefs.h"
7962$ac_includes_default
7963#ifdef F77_DUMMY_MAIN
7964# ifdef __cplusplus
7965 extern "C"
7966# endif
7967 int F77_DUMMY_MAIN() { return 1; }
7968#endif
7969int
7970main ()
7971{
7972static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
7973test_array [0] = 0
7974
7975 ;
7976 return 0;
7977}
7978_ACEOF
7979rm -f conftest.$ac_objext
7980if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7981 (eval $ac_compile) 2>&5
7982 ac_status=$?
7983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7984 (exit $ac_status); } &&
7985 { ac_try='test -s conftest.$ac_objext'
7986 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7987 (eval $ac_try) 2>&5
7988 ac_status=$?
7989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7990 (exit $ac_status); }; }; then
7991 ac_lo=$ac_mid; break
7992else
7993 echo "$as_me: failed program was:" >&5
7994cat conftest.$ac_ext >&5
7995ac_hi=`expr '(' $ac_mid ')' - 1`
7996 if test $ac_mid -le $ac_hi; then
7997 ac_lo= ac_hi=
7998 break
7999 fi
8000 ac_mid=`expr 2 '*' $ac_mid`
8001fi
8002rm -f conftest.$ac_objext conftest.$ac_ext
8003 done
8004else
8005 echo "$as_me: failed program was:" >&5
8006cat conftest.$ac_ext >&5
8007ac_lo= ac_hi=
8008fi
8009rm -f conftest.$ac_objext conftest.$ac_ext
8010fi
8011rm -f conftest.$ac_objext conftest.$ac_ext
8012# Binary search between lo and hi bounds.
8013while test "x$ac_lo" != "x$ac_hi"; do
8014 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8015 cat >conftest.$ac_ext <<_ACEOF
8016#line $LINENO "configure"
8017#include "confdefs.h"
8018$ac_includes_default
8019#ifdef F77_DUMMY_MAIN
8020# ifdef __cplusplus
8021 extern "C"
8022# endif
8023 int F77_DUMMY_MAIN() { return 1; }
8024#endif
8025int
8026main ()
8027{
8028static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
8029test_array [0] = 0
8030
8031 ;
8032 return 0;
8033}
8034_ACEOF
8035rm -f conftest.$ac_objext
8036if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8037 (eval $ac_compile) 2>&5
8038 ac_status=$?
8039 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8040 (exit $ac_status); } &&
8041 { ac_try='test -s conftest.$ac_objext'
8042 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8043 (eval $ac_try) 2>&5
8044 ac_status=$?
8045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8046 (exit $ac_status); }; }; then
8047 ac_hi=$ac_mid
8048else
8049 echo "$as_me: failed program was:" >&5
8050cat conftest.$ac_ext >&5
8051ac_lo=`expr '(' $ac_mid ')' + 1`
8052fi
8053rm -f conftest.$ac_objext conftest.$ac_ext
8054done
8055case $ac_lo in
8056?*) ac_cv_sizeof_long_long=$ac_lo;;
8057'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77" >&5
8058echo "$as_me: error: cannot compute sizeof (long long), 77" >&2;}
8059 { (exit 1); exit 1; }; } ;;
8060esac
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008061else
8062 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008063 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
8064echo "$as_me: error: cannot run test program while cross compiling" >&2;}
8065 { (exit 1); exit 1; }; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008066else
Martin v. Löwis11437992002-04-12 09:54:03 +00008067 cat >conftest.$ac_ext <<_ACEOF
8068#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008069#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008070$ac_includes_default
8071long longval () { return (long) (sizeof (long long)); }
8072unsigned long ulongval () { return (long) (sizeof (long long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008073#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008074#include <stdlib.h>
8075#ifdef F77_DUMMY_MAIN
8076# ifdef __cplusplus
8077 extern "C"
8078# endif
8079 int F77_DUMMY_MAIN() { return 1; }
8080#endif
8081int
8082main ()
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008083{
Martin v. Löwis11437992002-04-12 09:54:03 +00008084
8085 FILE *f = fopen ("conftest.val", "w");
8086 if (! f)
8087 exit (1);
8088 if (((long) (sizeof (long long))) < 0)
8089 {
8090 long i = longval ();
8091 if (i != ((long) (sizeof (long long))))
8092 exit (1);
8093 fprintf (f, "%ld\n", i);
8094 }
8095 else
8096 {
8097 unsigned long i = ulongval ();
8098 if (i != ((long) (sizeof (long long))))
8099 exit (1);
8100 fprintf (f, "%lu\n", i);
8101 }
8102 exit (ferror (f) || fclose (f) != 0);
8103
8104 ;
8105 return 0;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008106}
Martin v. Löwis11437992002-04-12 09:54:03 +00008107_ACEOF
8108rm -f conftest$ac_exeext
8109if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8110 (eval $ac_link) 2>&5
8111 ac_status=$?
8112 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8113 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8114 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8115 (eval $ac_try) 2>&5
8116 ac_status=$?
8117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8118 (exit $ac_status); }; }; then
8119 ac_cv_sizeof_long_long=`cat conftest.val`
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008120else
Martin v. Löwis11437992002-04-12 09:54:03 +00008121 echo "$as_me: program exited with status $ac_status" >&5
8122echo "$as_me: failed program was:" >&5
8123cat conftest.$ac_ext >&5
8124( exit $ac_status )
8125{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77" >&5
8126echo "$as_me: error: cannot compute sizeof (long long), 77" >&2;}
8127 { (exit 1); exit 1; }; }
8128fi
8129rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8130fi
8131fi
8132rm -f conftest.val
8133else
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008134 ac_cv_sizeof_long_long=0
8135fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008136fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008137echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
8138echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
8139cat >>confdefs.h <<_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008140#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
Martin v. Löwis11437992002-04-12 09:54:03 +00008141_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008142
Michael W. Hudson54241132001-12-07 15:38:26 +00008143
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008144fi
8145
Martin v. Löwis11437992002-04-12 09:54:03 +00008146echo "$as_me:$LINENO: checking for uintptr_t support" >&5
8147echo $ECHO_N "checking for uintptr_t support... $ECHO_C" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008148have_uintptr_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008149cat >conftest.$ac_ext <<_ACEOF
8150#line $LINENO "configure"
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008151#include "confdefs.h"
8152
Martin v. Löwis11437992002-04-12 09:54:03 +00008153#ifdef F77_DUMMY_MAIN
8154# ifdef __cplusplus
8155 extern "C"
8156# endif
8157 int F77_DUMMY_MAIN() { return 1; }
8158#endif
8159int
8160main ()
8161{
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008162uintptr_t x; x = (uintptr_t)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008163 ;
8164 return 0;
8165}
8166_ACEOF
8167rm -f conftest.$ac_objext
8168if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8169 (eval $ac_compile) 2>&5
8170 ac_status=$?
8171 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8172 (exit $ac_status); } &&
8173 { ac_try='test -s conftest.$ac_objext'
8174 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8175 (eval $ac_try) 2>&5
8176 ac_status=$?
8177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8178 (exit $ac_status); }; }; then
8179
8180
8181cat >>confdefs.h <<\_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008182#define HAVE_UINTPTR_T 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008183_ACEOF
8184
Martin v. Löwisc45929e2002-04-06 10:10:49 +00008185 have_uintptr_t=yes
8186
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008187else
Martin v. Löwis11437992002-04-12 09:54:03 +00008188 echo "$as_me: failed program was:" >&5
8189cat conftest.$ac_ext >&5
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008190fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008191rm -f conftest.$ac_objext conftest.$ac_ext
8192echo "$as_me:$LINENO: result: $have_uintptr_t" >&5
8193echo "${ECHO_T}$have_uintptr_t" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008194if test "$have_uintptr_t" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008195echo "$as_me:$LINENO: checking for uintptr_t" >&5
8196echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6
8197if test "${ac_cv_type_uintptr_t+set}" = set; then
8198 echo $ECHO_N "(cached) $ECHO_C" >&6
8199else
8200 cat >conftest.$ac_ext <<_ACEOF
8201#line $LINENO "configure"
8202#include "confdefs.h"
8203$ac_includes_default
8204#ifdef F77_DUMMY_MAIN
8205# ifdef __cplusplus
8206 extern "C"
8207# endif
8208 int F77_DUMMY_MAIN() { return 1; }
8209#endif
8210int
8211main ()
8212{
8213if ((uintptr_t *) 0)
8214 return 0;
8215if (sizeof (uintptr_t))
8216 return 0;
8217 ;
8218 return 0;
8219}
8220_ACEOF
8221rm -f conftest.$ac_objext
8222if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8223 (eval $ac_compile) 2>&5
8224 ac_status=$?
8225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8226 (exit $ac_status); } &&
8227 { ac_try='test -s conftest.$ac_objext'
8228 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8229 (eval $ac_try) 2>&5
8230 ac_status=$?
8231 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8232 (exit $ac_status); }; }; then
8233 ac_cv_type_uintptr_t=yes
8234else
8235 echo "$as_me: failed program was:" >&5
8236cat conftest.$ac_ext >&5
8237ac_cv_type_uintptr_t=no
8238fi
8239rm -f conftest.$ac_objext conftest.$ac_ext
8240fi
8241echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
8242echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6
8243
8244echo "$as_me:$LINENO: checking size of uintptr_t" >&5
8245echo $ECHO_N "checking size of uintptr_t... $ECHO_C" >&6
8246if test "${ac_cv_sizeof_uintptr_t+set}" = set; then
8247 echo $ECHO_N "(cached) $ECHO_C" >&6
8248else
8249 if test "$ac_cv_type_uintptr_t" = yes; then
8250 # The cast to unsigned long works around a bug in the HP C Compiler
8251 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8252 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8253 # This bug is HP SR number 8606223364.
8254 if test "$cross_compiling" = yes; then
8255 # Depending upon the size, compute the lo and hi bounds.
8256cat >conftest.$ac_ext <<_ACEOF
8257#line $LINENO "configure"
8258#include "confdefs.h"
8259$ac_includes_default
8260#ifdef F77_DUMMY_MAIN
8261# ifdef __cplusplus
8262 extern "C"
8263# endif
8264 int F77_DUMMY_MAIN() { return 1; }
8265#endif
8266int
8267main ()
8268{
8269static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= 0)];
8270test_array [0] = 0
8271
8272 ;
8273 return 0;
8274}
8275_ACEOF
8276rm -f conftest.$ac_objext
8277if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8278 (eval $ac_compile) 2>&5
8279 ac_status=$?
8280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8281 (exit $ac_status); } &&
8282 { ac_try='test -s conftest.$ac_objext'
8283 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8284 (eval $ac_try) 2>&5
8285 ac_status=$?
8286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8287 (exit $ac_status); }; }; then
8288 ac_lo=0 ac_mid=0
8289 while :; do
8290 cat >conftest.$ac_ext <<_ACEOF
8291#line $LINENO "configure"
8292#include "confdefs.h"
8293$ac_includes_default
8294#ifdef F77_DUMMY_MAIN
8295# ifdef __cplusplus
8296 extern "C"
8297# endif
8298 int F77_DUMMY_MAIN() { return 1; }
8299#endif
8300int
8301main ()
8302{
8303static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
8304test_array [0] = 0
8305
8306 ;
8307 return 0;
8308}
8309_ACEOF
8310rm -f conftest.$ac_objext
8311if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8312 (eval $ac_compile) 2>&5
8313 ac_status=$?
8314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8315 (exit $ac_status); } &&
8316 { ac_try='test -s conftest.$ac_objext'
8317 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8318 (eval $ac_try) 2>&5
8319 ac_status=$?
8320 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8321 (exit $ac_status); }; }; then
8322 ac_hi=$ac_mid; break
8323else
8324 echo "$as_me: failed program was:" >&5
8325cat conftest.$ac_ext >&5
8326ac_lo=`expr $ac_mid + 1`
8327 if test $ac_lo -le $ac_mid; then
8328 ac_lo= ac_hi=
8329 break
8330 fi
8331 ac_mid=`expr 2 '*' $ac_mid + 1`
8332fi
8333rm -f conftest.$ac_objext conftest.$ac_ext
8334 done
8335else
8336 echo "$as_me: failed program was:" >&5
8337cat conftest.$ac_ext >&5
8338cat >conftest.$ac_ext <<_ACEOF
8339#line $LINENO "configure"
8340#include "confdefs.h"
8341$ac_includes_default
8342#ifdef F77_DUMMY_MAIN
8343# ifdef __cplusplus
8344 extern "C"
8345# endif
8346 int F77_DUMMY_MAIN() { return 1; }
8347#endif
8348int
8349main ()
8350{
8351static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) < 0)];
8352test_array [0] = 0
8353
8354 ;
8355 return 0;
8356}
8357_ACEOF
8358rm -f conftest.$ac_objext
8359if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8360 (eval $ac_compile) 2>&5
8361 ac_status=$?
8362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8363 (exit $ac_status); } &&
8364 { ac_try='test -s conftest.$ac_objext'
8365 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8366 (eval $ac_try) 2>&5
8367 ac_status=$?
8368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8369 (exit $ac_status); }; }; then
8370 ac_hi=-1 ac_mid=-1
8371 while :; do
8372 cat >conftest.$ac_ext <<_ACEOF
8373#line $LINENO "configure"
8374#include "confdefs.h"
8375$ac_includes_default
8376#ifdef F77_DUMMY_MAIN
8377# ifdef __cplusplus
8378 extern "C"
8379# endif
8380 int F77_DUMMY_MAIN() { return 1; }
8381#endif
8382int
8383main ()
8384{
8385static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= $ac_mid)];
8386test_array [0] = 0
8387
8388 ;
8389 return 0;
8390}
8391_ACEOF
8392rm -f conftest.$ac_objext
8393if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8394 (eval $ac_compile) 2>&5
8395 ac_status=$?
8396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8397 (exit $ac_status); } &&
8398 { ac_try='test -s conftest.$ac_objext'
8399 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8400 (eval $ac_try) 2>&5
8401 ac_status=$?
8402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8403 (exit $ac_status); }; }; then
8404 ac_lo=$ac_mid; break
8405else
8406 echo "$as_me: failed program was:" >&5
8407cat conftest.$ac_ext >&5
8408ac_hi=`expr '(' $ac_mid ')' - 1`
8409 if test $ac_mid -le $ac_hi; then
8410 ac_lo= ac_hi=
8411 break
8412 fi
8413 ac_mid=`expr 2 '*' $ac_mid`
8414fi
8415rm -f conftest.$ac_objext conftest.$ac_ext
8416 done
8417else
8418 echo "$as_me: failed program was:" >&5
8419cat conftest.$ac_ext >&5
8420ac_lo= ac_hi=
8421fi
8422rm -f conftest.$ac_objext conftest.$ac_ext
8423fi
8424rm -f conftest.$ac_objext conftest.$ac_ext
8425# Binary search between lo and hi bounds.
8426while test "x$ac_lo" != "x$ac_hi"; do
8427 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8428 cat >conftest.$ac_ext <<_ACEOF
8429#line $LINENO "configure"
8430#include "confdefs.h"
8431$ac_includes_default
8432#ifdef F77_DUMMY_MAIN
8433# ifdef __cplusplus
8434 extern "C"
8435# endif
8436 int F77_DUMMY_MAIN() { return 1; }
8437#endif
8438int
8439main ()
8440{
8441static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
8442test_array [0] = 0
8443
8444 ;
8445 return 0;
8446}
8447_ACEOF
8448rm -f conftest.$ac_objext
8449if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8450 (eval $ac_compile) 2>&5
8451 ac_status=$?
8452 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8453 (exit $ac_status); } &&
8454 { ac_try='test -s conftest.$ac_objext'
8455 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8456 (eval $ac_try) 2>&5
8457 ac_status=$?
8458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8459 (exit $ac_status); }; }; then
8460 ac_hi=$ac_mid
8461else
8462 echo "$as_me: failed program was:" >&5
8463cat conftest.$ac_ext >&5
8464ac_lo=`expr '(' $ac_mid ')' + 1`
8465fi
8466rm -f conftest.$ac_objext conftest.$ac_ext
8467done
8468case $ac_lo in
8469?*) ac_cv_sizeof_uintptr_t=$ac_lo;;
8470'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77" >&5
8471echo "$as_me: error: cannot compute sizeof (uintptr_t), 77" >&2;}
8472 { (exit 1); exit 1; }; } ;;
8473esac
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008474else
8475 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008476 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
8477echo "$as_me: error: cannot run test program while cross compiling" >&2;}
8478 { (exit 1); exit 1; }; }
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008479else
Martin v. Löwis11437992002-04-12 09:54:03 +00008480 cat >conftest.$ac_ext <<_ACEOF
8481#line $LINENO "configure"
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008482#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008483$ac_includes_default
8484long longval () { return (long) (sizeof (uintptr_t)); }
8485unsigned long ulongval () { return (long) (sizeof (uintptr_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008486#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008487#include <stdlib.h>
8488#ifdef F77_DUMMY_MAIN
8489# ifdef __cplusplus
8490 extern "C"
8491# endif
8492 int F77_DUMMY_MAIN() { return 1; }
8493#endif
8494int
8495main ()
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008496{
Martin v. Löwis11437992002-04-12 09:54:03 +00008497
8498 FILE *f = fopen ("conftest.val", "w");
8499 if (! f)
8500 exit (1);
8501 if (((long) (sizeof (uintptr_t))) < 0)
8502 {
8503 long i = longval ();
8504 if (i != ((long) (sizeof (uintptr_t))))
8505 exit (1);
8506 fprintf (f, "%ld\n", i);
8507 }
8508 else
8509 {
8510 unsigned long i = ulongval ();
8511 if (i != ((long) (sizeof (uintptr_t))))
8512 exit (1);
8513 fprintf (f, "%lu\n", i);
8514 }
8515 exit (ferror (f) || fclose (f) != 0);
8516
8517 ;
8518 return 0;
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008519}
Martin v. Löwis11437992002-04-12 09:54:03 +00008520_ACEOF
8521rm -f conftest$ac_exeext
8522if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8523 (eval $ac_link) 2>&5
8524 ac_status=$?
8525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8526 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8527 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8528 (eval $ac_try) 2>&5
8529 ac_status=$?
8530 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8531 (exit $ac_status); }; }; then
8532 ac_cv_sizeof_uintptr_t=`cat conftest.val`
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008533else
Martin v. Löwis11437992002-04-12 09:54:03 +00008534 echo "$as_me: program exited with status $ac_status" >&5
8535echo "$as_me: failed program was:" >&5
8536cat conftest.$ac_ext >&5
8537( exit $ac_status )
8538{ { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77" >&5
8539echo "$as_me: error: cannot compute sizeof (uintptr_t), 77" >&2;}
8540 { (exit 1); exit 1; }; }
8541fi
8542rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8543fi
8544fi
8545rm -f conftest.val
8546else
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008547 ac_cv_sizeof_uintptr_t=0
8548fi
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008549fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008550echo "$as_me:$LINENO: result: $ac_cv_sizeof_uintptr_t" >&5
8551echo "${ECHO_T}$ac_cv_sizeof_uintptr_t" >&6
8552cat >>confdefs.h <<_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008553#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008554_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008555
Michael W. Hudson54241132001-12-07 15:38:26 +00008556
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008557fi
8558
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008559# Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008560echo "$as_me:$LINENO: checking size of off_t" >&5
8561echo $ECHO_N "checking size of off_t... $ECHO_C" >&6
8562if test "${ac_cv_sizeof_off_t+set}" = set; then
8563 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008564else
8565 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008566 ac_cv_sizeof_off_t=4
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008567else
Martin v. Löwis11437992002-04-12 09:54:03 +00008568 cat >conftest.$ac_ext <<_ACEOF
8569#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008570#include "confdefs.h"
8571#include <stdio.h>
8572#include <sys/types.h>
8573main()
8574{
8575 FILE *f=fopen("conftestval", "w");
8576 if (!f) exit(1);
8577 fprintf(f, "%d\n", sizeof(off_t));
8578 exit(0);
8579}
Martin v. Löwis11437992002-04-12 09:54:03 +00008580_ACEOF
8581rm -f conftest$ac_exeext
8582if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8583 (eval $ac_link) 2>&5
8584 ac_status=$?
8585 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8586 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8587 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8588 (eval $ac_try) 2>&5
8589 ac_status=$?
8590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8591 (exit $ac_status); }; }; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008592 ac_cv_sizeof_off_t=`cat conftestval`
8593else
Martin v. Löwis11437992002-04-12 09:54:03 +00008594 echo "$as_me: program exited with status $ac_status" >&5
8595echo "$as_me: failed program was:" >&5
8596cat conftest.$ac_ext >&5
8597( exit $ac_status )
8598ac_cv_sizeof_off_t=0
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008599fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008600rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008601fi
8602
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008603fi
8604
Martin v. Löwis11437992002-04-12 09:54:03 +00008605echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
8606echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6
8607
8608cat >>confdefs.h <<_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008609#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008610_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008611
Michael W. Hudson54241132001-12-07 15:38:26 +00008612
Martin v. Löwis11437992002-04-12 09:54:03 +00008613echo "$as_me:$LINENO: checking whether to enable large file support" >&5
8614echo $ECHO_N "checking whether to enable large file support... $ECHO_C" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00008615if test "$have_long_long" = yes -a \
8616 "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
8617 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008618
Martin v. Löwis11437992002-04-12 09:54:03 +00008619cat >>confdefs.h <<\_ACEOF
8620#define HAVE_LARGEFILE_SUPPORT 1
8621_ACEOF
8622
8623 echo "$as_me:$LINENO: result: yes" >&5
8624echo "${ECHO_T}yes" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008625else
Martin v. Löwis11437992002-04-12 09:54:03 +00008626 echo "$as_me:$LINENO: result: no" >&5
8627echo "${ECHO_T}no" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008628fi
8629
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008630# AC_CHECK_SIZEOF() doesn't include <time.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008631echo "$as_me:$LINENO: checking size of time_t" >&5
8632echo $ECHO_N "checking size of time_t... $ECHO_C" >&6
8633if test "${ac_cv_sizeof_time_t+set}" = set; then
8634 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008635else
8636 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008637 ac_cv_sizeof_time_t=4
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008638else
Martin v. Löwis11437992002-04-12 09:54:03 +00008639 cat >conftest.$ac_ext <<_ACEOF
8640#line $LINENO "configure"
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008641#include "confdefs.h"
8642#include <stdio.h>
8643#include <time.h>
8644main()
8645{
8646 FILE *f=fopen("conftestval", "w");
8647 if (!f) exit(1);
8648 fprintf(f, "%d\n", sizeof(time_t));
8649 exit(0);
8650}
Martin v. Löwis11437992002-04-12 09:54:03 +00008651_ACEOF
8652rm -f conftest$ac_exeext
8653if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8654 (eval $ac_link) 2>&5
8655 ac_status=$?
8656 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8657 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8658 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8659 (eval $ac_try) 2>&5
8660 ac_status=$?
8661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8662 (exit $ac_status); }; }; then
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008663 ac_cv_sizeof_time_t=`cat conftestval`
8664else
Martin v. Löwis11437992002-04-12 09:54:03 +00008665 echo "$as_me: program exited with status $ac_status" >&5
8666echo "$as_me: failed program was:" >&5
8667cat conftest.$ac_ext >&5
8668( exit $ac_status )
8669ac_cv_sizeof_time_t=0
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008670fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008671rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008672fi
8673
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008674fi
8675
Martin v. Löwis11437992002-04-12 09:54:03 +00008676echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5
8677echo "${ECHO_T}$ac_cv_sizeof_time_t" >&6
8678
8679cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008680#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008681_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008682
Michael W. Hudson54241132001-12-07 15:38:26 +00008683
8684
Trent Mick635f6fb2000-08-23 21:33:05 +00008685# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +00008686ac_save_cc="$CC"
8687if test "$ac_cv_kpthread" = "yes"
8688then CC="$CC -Kpthread"
8689fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008690echo "$as_me:$LINENO: checking for pthread_t" >&5
8691echo $ECHO_N "checking for pthread_t... $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00008692have_pthread_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008693cat >conftest.$ac_ext <<_ACEOF
8694#line $LINENO "configure"
Trent Mick635f6fb2000-08-23 21:33:05 +00008695#include "confdefs.h"
8696#include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008697#ifdef F77_DUMMY_MAIN
8698# ifdef __cplusplus
8699 extern "C"
8700# endif
8701 int F77_DUMMY_MAIN() { return 1; }
8702#endif
8703int
8704main ()
8705{
Guido van Rossum12580492000-09-24 16:47:19 +00008706pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008707 ;
8708 return 0;
8709}
8710_ACEOF
8711rm -f conftest.$ac_objext
8712if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8713 (eval $ac_compile) 2>&5
8714 ac_status=$?
8715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8716 (exit $ac_status); } &&
8717 { ac_try='test -s conftest.$ac_objext'
8718 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8719 (eval $ac_try) 2>&5
8720 ac_status=$?
8721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8722 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00008723 have_pthread_t=yes
8724else
Martin v. Löwis11437992002-04-12 09:54:03 +00008725 echo "$as_me: failed program was:" >&5
8726cat conftest.$ac_ext >&5
Trent Mick635f6fb2000-08-23 21:33:05 +00008727fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008728rm -f conftest.$ac_objext conftest.$ac_ext
8729echo "$as_me:$LINENO: result: $have_pthread_t" >&5
8730echo "${ECHO_T}$have_pthread_t" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00008731if test "$have_pthread_t" = yes ; then
8732 # AC_CHECK_SIZEOF() doesn't include <pthread.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008733 echo "$as_me:$LINENO: checking size of pthread_t" >&5
8734echo $ECHO_N "checking size of pthread_t... $ECHO_C" >&6
8735 if test "${ac_cv_sizeof_pthread_t+set}" = set; then
8736 echo $ECHO_N "(cached) $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00008737else
8738 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008739 ac_cv_sizeof_pthread_t=4
Trent Mick635f6fb2000-08-23 21:33:05 +00008740else
Martin v. Löwis11437992002-04-12 09:54:03 +00008741 cat >conftest.$ac_ext <<_ACEOF
8742#line $LINENO "configure"
Trent Mick635f6fb2000-08-23 21:33:05 +00008743#include "confdefs.h"
8744#include <stdio.h>
8745 #include <pthread.h>
8746 main()
8747 {
8748 FILE *f=fopen("conftestval", "w");
8749 if (!f) exit(1);
8750 fprintf(f, "%d\n", sizeof(pthread_t));
8751 exit(0);
8752 }
Martin v. Löwis11437992002-04-12 09:54:03 +00008753_ACEOF
8754rm -f conftest$ac_exeext
8755if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8756 (eval $ac_link) 2>&5
8757 ac_status=$?
8758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8759 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8760 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8761 (eval $ac_try) 2>&5
8762 ac_status=$?
8763 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8764 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00008765 ac_cv_sizeof_pthread_t=`cat conftestval`
8766else
Martin v. Löwis11437992002-04-12 09:54:03 +00008767 echo "$as_me: program exited with status $ac_status" >&5
8768echo "$as_me: failed program was:" >&5
8769cat conftest.$ac_ext >&5
8770( exit $ac_status )
8771ac_cv_sizeof_pthread_t=0
Trent Mick635f6fb2000-08-23 21:33:05 +00008772fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008773rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Trent Mick635f6fb2000-08-23 21:33:05 +00008774fi
8775
Trent Mick635f6fb2000-08-23 21:33:05 +00008776fi
8777
Martin v. Löwis11437992002-04-12 09:54:03 +00008778 echo "$as_me:$LINENO: result: $ac_cv_sizeof_pthread_t" >&5
8779echo "${ECHO_T}$ac_cv_sizeof_pthread_t" >&6
8780
8781cat >>confdefs.h <<_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00008782#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008783_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00008784
8785fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +00008786CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +00008787
Martin v. Löwis11437992002-04-12 09:54:03 +00008788echo "$as_me:$LINENO: checking for --enable-toolbox-glue" >&5
8789echo $ECHO_N "checking for --enable-toolbox-glue... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00008790# Check whether --enable-toolbox-glue or --disable-toolbox-glue was given.
8791if test "${enable_toolbox_glue+set}" = set; then
8792 enableval="$enable_toolbox_glue"
Jack Jansene578a632001-08-15 01:27:14 +00008793
Martin v. Löwis11437992002-04-12 09:54:03 +00008794fi;
Jack Jansene578a632001-08-15 01:27:14 +00008795
8796if test -z "$enable_toolbox_glue"
Martin v. Löwis11437992002-04-12 09:54:03 +00008797then
Jack Jansene578a632001-08-15 01:27:14 +00008798 case $ac_sys_system/$ac_sys_release in
8799 Darwin/*)
8800 enable_toolbox_glue="yes";;
8801 *)
8802 enable_toolbox_glue="no";;
8803 esac
8804fi
8805case "$enable_toolbox_glue" in
8806yes)
Jack Jansen666b1e72001-10-31 12:11:48 +00008807 extra_frameworks="-framework CoreServices -framework Foundation"
Jack Jansene578a632001-08-15 01:27:14 +00008808 extra_machdep_objs="Python/mactoolboxglue.o"
Jack Jansen591cbed2001-08-15 13:55:15 +00008809 extra_undefs="-u __dummy -u _PyMac_Error"
Martin v. Löwis11437992002-04-12 09:54:03 +00008810
8811cat >>confdefs.h <<\_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00008812#define USE_TOOLBOX_OBJECT_GLUE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008813_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00008814
8815 ;;
8816*)
8817 extra_frameworks=""
8818 extra_machdep_objs=""
Jack Jansen591cbed2001-08-15 13:55:15 +00008819 extra_undefs=""
Jack Jansene578a632001-08-15 01:27:14 +00008820 ;;
8821esac
Martin v. Löwis11437992002-04-12 09:54:03 +00008822echo "$as_me:$LINENO: result: $enable_toolbox_glue" >&5
8823echo "${ECHO_T}$enable_toolbox_glue" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00008824
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008825
8826case $ac_sys_system/$ac_sys_release in
Jack Jansen418c3b12001-11-14 10:59:57 +00008827 Darwin/1.3*)
Jack Jansenea0c3822002-08-01 21:57:49 +00008828 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00008829 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansena3891ea2001-09-07 14:25:12 +00008830 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Python'
8831 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +00008832 Darwin/*)
Jack Jansenea0c3822002-08-01 21:57:49 +00008833 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00008834 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansene578a632001-08-15 01:27:14 +00008835 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Python'
8836 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008837esac
8838
Martin v. Löwis11437992002-04-12 09:54:03 +00008839echo "$as_me:$LINENO: checking for --enable-framework" >&5
8840echo $ECHO_N "checking for --enable-framework... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00008841if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008842then
Jack Jansenca06bc62001-08-03 15:32:23 +00008843 OPT="$OPT -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +00008844 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +00008845 # in the build location.
Jack Jansenea0c3822002-08-01 21:57:49 +00008846 LDFLAGS="$LDFLAGS -Wl,-F."
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008847
Martin v. Löwis11437992002-04-12 09:54:03 +00008848cat >>confdefs.h <<\_ACEOF
8849#define WITH_NEXT_FRAMEWORK 1
8850_ACEOF
8851
8852 echo "$as_me:$LINENO: result: yes" >&5
8853echo "${ECHO_T}yes" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008854else
Martin v. Löwis11437992002-04-12 09:54:03 +00008855 echo "$as_me:$LINENO: result: no" >&5
8856echo "${ECHO_T}no" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008857fi
8858
Martin v. Löwis11437992002-04-12 09:54:03 +00008859echo "$as_me:$LINENO: checking for dyld" >&5
8860echo $ECHO_N "checking for dyld... $ECHO_C" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00008861case $ac_sys_system/$ac_sys_release in
8862 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008863
Martin v. Löwis11437992002-04-12 09:54:03 +00008864cat >>confdefs.h <<\_ACEOF
8865#define WITH_DYLD 1
8866_ACEOF
8867
8868 echo "$as_me:$LINENO: result: always on for Darwin" >&5
8869echo "${ECHO_T}always on for Darwin" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00008870 ;;
8871 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00008872 echo "$as_me:$LINENO: result: no" >&5
8873echo "${ECHO_T}no" >&6
Jack Jansene578a632001-08-15 01:27:14 +00008874 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +00008875esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008876
Guido van Rossum0a516c91994-09-12 10:58:40 +00008877# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +00008878
Michael W. Hudson54241132001-12-07 15:38:26 +00008879
8880
8881
8882
Guido van Rossum0a516c91994-09-12 10:58:40 +00008883# SO is the extension of shared libraries `(including the dot!)
Guido van Rossumaef734b2001-01-10 21:09:12 +00008884# -- usually .so, .sl on HP-UX, .dll on Cygwin
Martin v. Löwis11437992002-04-12 09:54:03 +00008885echo "$as_me:$LINENO: checking SO" >&5
8886echo $ECHO_N "checking SO... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00008887if test -z "$SO"
8888then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00008889 case $ac_sys_system in
Guido van Rossum563e7081996-09-10 18:20:48 +00008890 hp*|HP*) SO=.sl;;
Guido van Rossumaef734b2001-01-10 21:09:12 +00008891 CYGWIN*) SO=.dll;;
Guido van Rossum563e7081996-09-10 18:20:48 +00008892 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00008893 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00008894fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008895echo "$as_me:$LINENO: result: $SO" >&5
8896echo "${ECHO_T}$SO" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00008897# LDSHARED is the ld *command* used to create shared library
Martin v. Löwis5b718fc2001-09-10 15:34:42 +00008898# -- "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 +00008899# (Shared libraries in this instance are shared modules to be loaded into
8900# Python, as opposed to building Python itself as a shared library.)
Martin v. Löwis11437992002-04-12 09:54:03 +00008901echo "$as_me:$LINENO: checking LDSHARED" >&5
8902echo $ECHO_N "checking LDSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00008903if test -z "$LDSHARED"
8904then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00008905 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00008906 AIX*)
8907 BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Guido van Rossumce608b02001-09-28 15:59:38 +00008908 LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00008909 ;;
8910 BeOS*)
8911 BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY"
Guido van Rossumce608b02001-09-28 15:59:38 +00008912 LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00008913 ;;
Guido van Rossum07397971997-04-29 21:49:50 +00008914 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +00008915 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00008916 SunOS/4*) LDSHARED="ld";;
Martin v. Löwis11437992002-04-12 09:54:03 +00008917 SunOS/5*)
Greg Ward57c9a6632000-05-26 12:22:54 +00008918 if test "$GCC" = "yes"
Neil Schemenauer8ba94452001-02-19 18:18:48 +00008919 then LDSHARED='$(CC) -shared'
Martin v. Löwis5b718fc2001-09-10 15:34:42 +00008920 else LDSHARED="$(CC) -G";
Greg Ward57c9a6632000-05-26 12:22:54 +00008921 fi ;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00008922 hp*|HP*) LDSHARED="ld -b";;
Guido van Rossumda88dad1995-01-26 00:46:29 +00008923 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
8924 DYNIX/ptx*) LDSHARED="ld -G";;
Jack Jansen418c3b12001-11-14 10:59:57 +00008925 Darwin/1.3*)
Jack Jansena3891ea2001-09-07 14:25:12 +00008926 LDSHARED='$(CC) $(LDFLAGS) -bundle'
8927 if test "$enable_framework" ; then
8928 # Link against the framework. All externals should be defined.
8929 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
8930 else
8931 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +00008932 LDSHARED="$LDSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +00008933 fi ;;
Jack Jansene578a632001-08-15 01:27:14 +00008934 Darwin/*)
8935 LDSHARED='$(CC) $(LDFLAGS) -bundle'
8936 if test "$enable_framework" ; then
8937 # Link against the framework. All externals should be defined.
8938 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
8939 else
Michael W. Hudson594bc802002-03-07 09:59:15 +00008940 # No framework, use the Python app as bundle-loader
8941 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
8942 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/$(PYTHON)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008943 fi ;;
Martin v. Löwis3cba5c02002-09-16 17:50:59 +00008944 Linux*|GNU*) LDSHARED='$(CC) -shared';;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00008945 dgux*) LDSHARED="ld -G";;
Guido van Rossum458e7fa1999-09-17 15:40:40 +00008946 BSD/OS*/4*) LDSHARED="gcc -shared";;
Martin v. Löwisd61888b2002-09-30 11:17:27 +00008947 OpenBSD*|FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +00008948 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +00008949 then
8950 LDSHARED="cc -shared ${LDFLAGS}"
8951 else
8952 LDSHARED="ld -Bshareable ${LDFLAGS}"
8953 fi;;
Martin v. Löwisd61888b2002-09-30 11:17:27 +00008954 NetBSD*) LDSHARED="cc -shared ${LDFLAGS}";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00008955 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +00008956 if test "$GCC" = "yes"
8957 then LDSHARED="$(CC) -shared"
Martin v. Löwis130fb172001-07-19 11:00:41 +00008958 else LDSHARED="$(CC) -G"
Martin v. Löwisbec19582001-03-21 15:57:54 +00008959 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00008960 SCO_SV*) LDSHARED="$(CC) -Wl,-G,-Bexport";;
Trent Mick635f6fb2000-08-23 21:33:05 +00008961 Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00008962 CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00008963 atheos*) LDSHARED="gcc -shared";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00008964 *) LDSHARED="ld";;
8965 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00008966fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008967echo "$as_me:$LINENO: result: $LDSHARED" >&5
8968echo "${ECHO_T}$LDSHARED" >&6
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00008969BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +00008970# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00008971# library (module) -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +00008972echo "$as_me:$LINENO: checking CCSHARED" >&5
8973echo $ECHO_N "checking CCSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00008974if test -z "$CCSHARED"
8975then
Guido van Rossum07397971997-04-29 21:49:50 +00008976 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +00008977 SunOS*) if test "$GCC" = yes;
8978 then CCSHARED="-fPIC";
8979 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +00008980 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +00008981 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +00008982 else CCSHARED="+z";
8983 fi;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +00008984 Linux*|GNU*) CCSHARED="-fPIC";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +00008985 BSD/OS*/4*) CCSHARED="-fpic";;
Martin v. Löwis36546db2001-09-05 14:24:43 +00008986 FreeBSD*|NetBSD*|OpenBSD*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00008987 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +00008988 if test "$GCC" = "yes"
8989 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +00008990 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +00008991 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00008992 SCO_SV*)
8993 if test "$GCC" = "yes"
8994 then CCSHARED="-fPIC"
8995 else CCSHARED="-Kpic -belf"
8996 fi;;
Trent Mick635f6fb2000-08-23 21:33:05 +00008997 Monterey*) CCSHARED="-G";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00008998 IRIX*/6*) case $CC in
8999 *gcc*) CCSHARED="-shared";;
Guido van Rossumee21f411998-04-20 18:51:54 +00009000 *) CCSHARED="";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009001 esac;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009002 atheos*) CCSHARED="-fPIC";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009003 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009004fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009005echo "$as_me:$LINENO: result: $CCSHARED" >&5
9006echo "${ECHO_T}$CCSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009007# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009008# the python executable -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +00009009echo "$as_me:$LINENO: checking LINKFORSHARED" >&5
9010echo $ECHO_N "checking LINKFORSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009011if test -z "$LINKFORSHARED"
9012then
Guido van Rossum07397971997-04-29 21:49:50 +00009013 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009014 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009015 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00009016 LINKFORSHARED="-Wl,-E -Wl,+s";;
9017# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +00009018 BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009019 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009020 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +00009021 Darwin/*)
Jack Jansene578a632001-08-15 01:27:14 +00009022 # -u __dummy makes the linker aware of the objc runtime
9023 # in System.framework; otherwise, __objcInit (referenced in
9024 # crt1.o) gets erroneously defined as common, which breaks dynamic
9025 # loading of any modules which reference it in System.framework.
9026 # -u _PyMac_Error is needed to pull in the mac toolbox glue, which is
9027 # not used by the core itself but which needs to be in the core so
9028 # that dynamically loaded extension modules have access to it.
Jack Jansen591cbed2001-08-15 13:55:15 +00009029 LINKFORSHARED="$extra_undefs -framework System"
Jack Jansene578a632001-08-15 01:27:14 +00009030 if test "$enable_framework"
9031 then
9032 LINKFORSHARED="$LINKFORSHARED -framework Python"
9033 fi
9034 LINKFORSHARED="$LINKFORSHARED $extra_frameworks";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009035 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00009036 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +00009037 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis11437992002-04-12 09:54:03 +00009038 FreeBSD*|NetBSD*|OpenBSD*)
Guido van Rossumdf693651999-01-07 21:50:41 +00009039 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
9040 then
9041 LINKFORSHARED="-Wl,--export-dynamic"
9042 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009043 SunOS/5*) case $CC in
9044 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +00009045 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +00009046 then
9047 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009048 fi;;
9049 esac;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009050 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009051fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009052echo "$as_me:$LINENO: result: $LINKFORSHARED" >&5
9053echo "${ECHO_T}$LINKFORSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009054
Michael W. Hudson54241132001-12-07 15:38:26 +00009055
Martin v. Löwis11437992002-04-12 09:54:03 +00009056echo "$as_me:$LINENO: checking CFLAGSFORSHARED" >&5
9057echo $ECHO_N "checking CFLAGSFORSHARED... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009058if test ! "$LIBRARY" = "$LDLIBRARY"
9059then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +00009060 case $ac_sys_system in
9061 CYGWIN*)
9062 # Cygwin needs CCSHARED when building extension DLLs
9063 # but not when building the interpreter DLL.
9064 CFLAGSFORSHARED='';;
9065 *)
9066 CFLAGSFORSHARED='$(CCSHARED)'
9067 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009068fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009069echo "$as_me:$LINENO: result: $CFLAGSFORSHARED" >&5
9070echo "${ECHO_T}$CFLAGSFORSHARED" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009071
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009072# SHLIBS are libraries (except -lc and -lm) to link to the python shared
9073# library (with --enable-shared).
9074# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +00009075# symbols, this must be set to $(LIBS) (expanded by make). We do this even
9076# if it is not required, since it creates a dependency of the shared library
9077# to LIBS. This, in turn, means that applications linking the shared libpython
9078# don't need to link LIBS explicitly. The default should be only changed
9079# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009080
9081echo "$as_me:$LINENO: checking SHLIBS" >&5
9082echo $ECHO_N "checking SHLIBS... $ECHO_C" >&6
9083case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009084 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +00009085 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009086esac
9087echo "$as_me:$LINENO: result: $SHLIBS" >&5
9088echo "${ECHO_T}$SHLIBS" >&6
9089
9090
Guido van Rossum627b2d71993-12-24 10:39:16 +00009091# checks for libraries
Martin v. Löwis11437992002-04-12 09:54:03 +00009092
9093echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9094echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9095if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9096 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009097else
Martin v. Löwis11437992002-04-12 09:54:03 +00009098 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009099LIBS="-ldl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009100cat >conftest.$ac_ext <<_ACEOF
9101#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00009102#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009103
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009104/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009105#ifdef __cplusplus
9106extern "C"
9107#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009108/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009109 builtin and then its argument prototype would still apply. */
9110char dlopen ();
9111#ifdef F77_DUMMY_MAIN
9112# ifdef __cplusplus
9113 extern "C"
9114# endif
9115 int F77_DUMMY_MAIN() { return 1; }
9116#endif
9117int
9118main ()
9119{
9120dlopen ();
9121 ;
9122 return 0;
9123}
9124_ACEOF
9125rm -f conftest.$ac_objext conftest$ac_exeext
9126if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9127 (eval $ac_link) 2>&5
9128 ac_status=$?
9129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9130 (exit $ac_status); } &&
9131 { ac_try='test -s conftest$ac_exeext'
9132 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9133 (eval $ac_try) 2>&5
9134 ac_status=$?
9135 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9136 (exit $ac_status); }; }; then
9137 ac_cv_lib_dl_dlopen=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009138else
Martin v. Löwis11437992002-04-12 09:54:03 +00009139 echo "$as_me: failed program was:" >&5
9140cat conftest.$ac_ext >&5
9141ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00009142fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009143rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9144LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +00009145fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009146echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9147echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9148if test $ac_cv_lib_dl_dlopen = yes; then
9149 cat >>confdefs.h <<_ACEOF
9150#define HAVE_LIBDL 1
9151_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00009152
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009153 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00009154
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009155fi
9156 # Dynamic linking for SunOS/Solaris and SYSV
Martin v. Löwis11437992002-04-12 09:54:03 +00009157
9158echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9159echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9160if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9161 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009162else
Martin v. Löwis11437992002-04-12 09:54:03 +00009163 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009164LIBS="-ldld $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009165cat >conftest.$ac_ext <<_ACEOF
9166#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00009167#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009168
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009169/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009170#ifdef __cplusplus
9171extern "C"
9172#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009173/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009174 builtin and then its argument prototype would still apply. */
9175char shl_load ();
9176#ifdef F77_DUMMY_MAIN
9177# ifdef __cplusplus
9178 extern "C"
9179# endif
9180 int F77_DUMMY_MAIN() { return 1; }
9181#endif
9182int
9183main ()
9184{
9185shl_load ();
9186 ;
9187 return 0;
9188}
9189_ACEOF
9190rm -f conftest.$ac_objext conftest$ac_exeext
9191if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9192 (eval $ac_link) 2>&5
9193 ac_status=$?
9194 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9195 (exit $ac_status); } &&
9196 { ac_try='test -s conftest$ac_exeext'
9197 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9198 (eval $ac_try) 2>&5
9199 ac_status=$?
9200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9201 (exit $ac_status); }; }; then
9202 ac_cv_lib_dld_shl_load=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009203else
Martin v. Löwis11437992002-04-12 09:54:03 +00009204 echo "$as_me: failed program was:" >&5
9205cat conftest.$ac_ext >&5
9206ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00009207fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009208rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9209LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +00009210fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009211echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9212echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9213if test $ac_cv_lib_dld_shl_load = yes; then
9214 cat >>confdefs.h <<_ACEOF
9215#define HAVE_LIBDLD 1
9216_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00009217
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009218 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009219
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009220fi
9221 # Dynamic linking for HP-UX
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009222echo "$as_me:$LINENO: checking for library containing sem_init" >&5
9223echo $ECHO_N "checking for library containing sem_init... $ECHO_C" >&6
9224if test "${ac_cv_search_sem_init+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009225 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009226else
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009227 ac_func_search_save_LIBS=$LIBS
9228ac_cv_search_sem_init=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009229cat >conftest.$ac_ext <<_ACEOF
9230#line $LINENO "configure"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009231#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009232
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009233/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009234#ifdef __cplusplus
9235extern "C"
9236#endif
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009237/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009238 builtin and then its argument prototype would still apply. */
9239char sem_init ();
9240#ifdef F77_DUMMY_MAIN
9241# ifdef __cplusplus
9242 extern "C"
9243# endif
9244 int F77_DUMMY_MAIN() { return 1; }
9245#endif
9246int
9247main ()
9248{
9249sem_init ();
9250 ;
9251 return 0;
9252}
9253_ACEOF
9254rm -f conftest.$ac_objext conftest$ac_exeext
9255if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9256 (eval $ac_link) 2>&5
9257 ac_status=$?
9258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9259 (exit $ac_status); } &&
9260 { ac_try='test -s conftest$ac_exeext'
9261 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9262 (eval $ac_try) 2>&5
9263 ac_status=$?
9264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9265 (exit $ac_status); }; }; then
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009266 ac_cv_search_sem_init="none required"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009267else
Martin v. Löwis11437992002-04-12 09:54:03 +00009268 echo "$as_me: failed program was:" >&5
9269cat conftest.$ac_ext >&5
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009270fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009271rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009272if test "$ac_cv_search_sem_init" = no; then
9273 for ac_lib in rt posix4; do
9274 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9275 cat >conftest.$ac_ext <<_ACEOF
9276#line $LINENO "configure"
9277#include "confdefs.h"
9278
9279/* Override any gcc2 internal prototype to avoid an error. */
9280#ifdef __cplusplus
9281extern "C"
9282#endif
9283/* We use char because int might match the return type of a gcc2
9284 builtin and then its argument prototype would still apply. */
9285char sem_init ();
9286#ifdef F77_DUMMY_MAIN
9287# ifdef __cplusplus
9288 extern "C"
9289# endif
9290 int F77_DUMMY_MAIN() { return 1; }
9291#endif
9292int
9293main ()
9294{
9295sem_init ();
9296 ;
9297 return 0;
9298}
Martin v. Löwis11437992002-04-12 09:54:03 +00009299_ACEOF
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009300rm -f conftest.$ac_objext conftest$ac_exeext
9301if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9302 (eval $ac_link) 2>&5
9303 ac_status=$?
9304 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9305 (exit $ac_status); } &&
9306 { ac_try='test -s conftest$ac_exeext'
9307 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9308 (eval $ac_try) 2>&5
9309 ac_status=$?
9310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9311 (exit $ac_status); }; }; then
9312 ac_cv_search_sem_init="-l$ac_lib"
9313break
9314else
9315 echo "$as_me: failed program was:" >&5
9316cat conftest.$ac_ext >&5
9317fi
9318rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9319 done
9320fi
9321LIBS=$ac_func_search_save_LIBS
9322fi
9323echo "$as_me:$LINENO: result: $ac_cv_search_sem_init" >&5
9324echo "${ECHO_T}$ac_cv_search_sem_init" >&6
9325if test "$ac_cv_search_sem_init" != no; then
9326 test "$ac_cv_search_sem_init" = "none required" || LIBS="$ac_cv_search_sem_init $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009327
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009328fi
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009329 # 'Real Time' functions on Solaris,
9330 # posix4 on Solaris 2.6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009331
9332# checks for system dependent C++ extensions support
9333case "$ac_sys_system" in
Martin v. Löwis11437992002-04-12 09:54:03 +00009334 AIX*) echo "$as_me:$LINENO: checking for genuine AIX C++ extensions support" >&5
9335echo $ECHO_N "checking for genuine AIX C++ extensions support... $ECHO_C" >&6
9336 cat >conftest.$ac_ext <<_ACEOF
9337#line $LINENO "configure"
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009338#include "confdefs.h"
9339#include "/usr/lpp/xlC/include/load.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009340#ifdef F77_DUMMY_MAIN
9341# ifdef __cplusplus
9342 extern "C"
9343# endif
9344 int F77_DUMMY_MAIN() { return 1; }
9345#endif
9346int
9347main ()
9348{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009349loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +00009350 ;
9351 return 0;
9352}
9353_ACEOF
9354rm -f conftest.$ac_objext conftest$ac_exeext
9355if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9356 (eval $ac_link) 2>&5
9357 ac_status=$?
9358 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9359 (exit $ac_status); } &&
9360 { ac_try='test -s conftest$ac_exeext'
9361 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9362 (eval $ac_try) 2>&5
9363 ac_status=$?
9364 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9365 (exit $ac_status); }; }; then
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009366
Martin v. Löwis11437992002-04-12 09:54:03 +00009367cat >>confdefs.h <<\_ACEOF
9368#define AIX_GENUINE_CPLUSPLUS 1
9369_ACEOF
9370
9371 echo "$as_me:$LINENO: result: yes" >&5
9372echo "${ECHO_T}yes" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009373else
Martin v. Löwis11437992002-04-12 09:54:03 +00009374 echo "$as_me: failed program was:" >&5
9375cat conftest.$ac_ext >&5
9376echo "$as_me:$LINENO: result: no" >&5
9377echo "${ECHO_T}no" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009378fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009379rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009380 *) ;;
9381esac
9382
Guido van Rossum70c7f481998-03-26 18:44:10 +00009383# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
9384# However on SGI IRIX, these exist but are broken.
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009385# BeOS' sockets are stashed in libnet.
9386case "$ac_sys_system" in
9387IRIX*) ;;
Guido van Rossumb93a8621998-05-07 13:27:32 +00009388*)
Martin v. Löwis11437992002-04-12 09:54:03 +00009389echo "$as_me:$LINENO: checking for t_open in -lnsl" >&5
9390echo $ECHO_N "checking for t_open in -lnsl... $ECHO_C" >&6
9391if test "${ac_cv_lib_nsl_t_open+set}" = set; then
9392 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009393else
Martin v. Löwis11437992002-04-12 09:54:03 +00009394 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009395LIBS="-lnsl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009396cat >conftest.$ac_ext <<_ACEOF
9397#line $LINENO "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009398#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009399
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009400/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009401#ifdef __cplusplus
9402extern "C"
9403#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009404/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009405 builtin and then its argument prototype would still apply. */
9406char t_open ();
9407#ifdef F77_DUMMY_MAIN
9408# ifdef __cplusplus
9409 extern "C"
9410# endif
9411 int F77_DUMMY_MAIN() { return 1; }
9412#endif
9413int
9414main ()
9415{
9416t_open ();
9417 ;
9418 return 0;
9419}
9420_ACEOF
9421rm -f conftest.$ac_objext conftest$ac_exeext
9422if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9423 (eval $ac_link) 2>&5
9424 ac_status=$?
9425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9426 (exit $ac_status); } &&
9427 { ac_try='test -s conftest$ac_exeext'
9428 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9429 (eval $ac_try) 2>&5
9430 ac_status=$?
9431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9432 (exit $ac_status); }; }; then
9433 ac_cv_lib_nsl_t_open=yes
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009434else
Martin v. Löwis11437992002-04-12 09:54:03 +00009435 echo "$as_me: failed program was:" >&5
9436cat conftest.$ac_ext >&5
9437ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009438fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009439rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9440LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009441fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009442echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_t_open" >&5
9443echo "${ECHO_T}$ac_cv_lib_nsl_t_open" >&6
9444if test $ac_cv_lib_nsl_t_open = yes; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009445 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009446fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00009447 # SVR4
Martin v. Löwis11437992002-04-12 09:54:03 +00009448echo "$as_me:$LINENO: checking for socket in -lsocket" >&5
9449echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6
9450if test "${ac_cv_lib_socket_socket+set}" = set; then
9451 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009452else
Martin v. Löwis11437992002-04-12 09:54:03 +00009453 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009454LIBS="-lsocket $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009455cat >conftest.$ac_ext <<_ACEOF
9456#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009457#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009458
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009459/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009460#ifdef __cplusplus
9461extern "C"
9462#endif
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009463/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009464 builtin and then its argument prototype would still apply. */
9465char socket ();
9466#ifdef F77_DUMMY_MAIN
9467# ifdef __cplusplus
9468 extern "C"
9469# endif
9470 int F77_DUMMY_MAIN() { return 1; }
9471#endif
9472int
9473main ()
9474{
9475socket ();
9476 ;
9477 return 0;
9478}
9479_ACEOF
9480rm -f conftest.$ac_objext conftest$ac_exeext
9481if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9482 (eval $ac_link) 2>&5
9483 ac_status=$?
9484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9485 (exit $ac_status); } &&
9486 { ac_try='test -s conftest$ac_exeext'
9487 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9488 (eval $ac_try) 2>&5
9489 ac_status=$?
9490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9491 (exit $ac_status); }; }; then
9492 ac_cv_lib_socket_socket=yes
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009493else
Martin v. Löwis11437992002-04-12 09:54:03 +00009494 echo "$as_me: failed program was:" >&5
9495cat conftest.$ac_ext >&5
9496ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009497fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009498rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9499LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009500fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009501echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5
9502echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6
9503if test $ac_cv_lib_socket_socket = yes; then
Guido van Rossumad678af1998-10-02 14:42:15 +00009504 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +00009505fi
9506 # SVR4 sockets
Jeremy Hyltoncb25d5e2000-07-27 21:23:28 +00009507;;
9508esac
9509case "$ac_sys_system" in
9510BeOS*)
Martin v. Löwis11437992002-04-12 09:54:03 +00009511echo "$as_me:$LINENO: checking for socket in -lnet" >&5
9512echo $ECHO_N "checking for socket in -lnet... $ECHO_C" >&6
9513if test "${ac_cv_lib_net_socket+set}" = set; then
9514 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +00009515else
Martin v. Löwis11437992002-04-12 09:54:03 +00009516 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +00009517LIBS="-lnet $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009518cat >conftest.$ac_ext <<_ACEOF
9519#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +00009520#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009521
Guido van Rossumad678af1998-10-02 14:42:15 +00009522/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009523#ifdef __cplusplus
9524extern "C"
9525#endif
Guido van Rossumad678af1998-10-02 14:42:15 +00009526/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009527 builtin and then its argument prototype would still apply. */
9528char socket ();
9529#ifdef F77_DUMMY_MAIN
9530# ifdef __cplusplus
9531 extern "C"
9532# endif
9533 int F77_DUMMY_MAIN() { return 1; }
9534#endif
9535int
9536main ()
9537{
9538socket ();
9539 ;
9540 return 0;
9541}
9542_ACEOF
9543rm -f conftest.$ac_objext conftest$ac_exeext
9544if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9545 (eval $ac_link) 2>&5
9546 ac_status=$?
9547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9548 (exit $ac_status); } &&
9549 { ac_try='test -s conftest$ac_exeext'
9550 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9551 (eval $ac_try) 2>&5
9552 ac_status=$?
9553 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9554 (exit $ac_status); }; }; then
9555 ac_cv_lib_net_socket=yes
Guido van Rossumad678af1998-10-02 14:42:15 +00009556else
Martin v. Löwis11437992002-04-12 09:54:03 +00009557 echo "$as_me: failed program was:" >&5
9558cat conftest.$ac_ext >&5
9559ac_cv_lib_net_socket=no
Guido van Rossumad678af1998-10-02 14:42:15 +00009560fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009561rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9562LIBS=$ac_check_lib_save_LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +00009563fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009564echo "$as_me:$LINENO: result: $ac_cv_lib_net_socket" >&5
9565echo "${ECHO_T}$ac_cv_lib_net_socket" >&6
9566if test $ac_cv_lib_net_socket = yes; then
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009567 LIBS="-lnet $LIBS"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009568fi
9569 # BeOS
9570;;
9571esac
Guido van Rossum70c7f481998-03-26 18:44:10 +00009572
Martin v. Löwis11437992002-04-12 09:54:03 +00009573echo "$as_me:$LINENO: checking for --with-libs" >&5
9574echo $ECHO_N "checking for --with-libs... $ECHO_C" >&6
9575
Guido van Rossuma68acba1996-07-31 17:36:39 +00009576# Check whether --with-libs or --without-libs was given.
9577if test "${with_libs+set}" = set; then
9578 withval="$with_libs"
Martin v. Löwis11437992002-04-12 09:54:03 +00009579
9580echo "$as_me:$LINENO: result: $withval" >&5
9581echo "${ECHO_T}$withval" >&6
Guido van Rossuma68acba1996-07-31 17:36:39 +00009582LIBS="$withval $LIBS"
9583
9584else
Martin v. Löwis11437992002-04-12 09:54:03 +00009585 echo "$as_me:$LINENO: result: no" >&5
9586echo "${ECHO_T}no" >&6
9587fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +00009588
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009589# Determine if signalmodule should be used.
9590
9591
Martin v. Löwis11437992002-04-12 09:54:03 +00009592echo "$as_me:$LINENO: checking for --with-signal-module" >&5
9593echo $ECHO_N "checking for --with-signal-module... $ECHO_C" >&6
9594
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009595# Check whether --with-signal-module or --without-signal-module was given.
9596if test "${with_signal_module+set}" = set; then
9597 withval="$with_signal_module"
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009598
Martin v. Löwis11437992002-04-12 09:54:03 +00009599fi;
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009600
9601if test -z "$with_signal_module"
9602then with_signal_module="yes"
9603fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009604echo "$as_me:$LINENO: result: $with_signal_module" >&5
9605echo "${ECHO_T}$with_signal_module" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009606
9607if test "${with_signal_module}" = "yes"; then
9608 USE_SIGNAL_MODULE=""
9609 SIGNAL_OBJS=""
9610else
9611 USE_SIGNAL_MODULE="#"
9612 SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o"
9613fi
9614
Guido van Rossum3d15bd82001-01-10 18:53:48 +00009615# This is used to generate Setup.config
Guido van Rossum009f7871997-12-04 00:51:42 +00009616
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009617USE_THREAD_MODULE=""
Guido van Rossum009f7871997-12-04 00:51:42 +00009618
Martin v. Löwis11437992002-04-12 09:54:03 +00009619echo "$as_me:$LINENO: checking for --with-dec-threads" >&5
9620echo $ECHO_N "checking for --with-dec-threads... $ECHO_C" >&6
9621
Guido van Rossumec2f0731997-01-22 20:54:01 +00009622
9623# Check whether --with-dec-threads or --without-dec-threads was given.
9624if test "${with_dec_threads+set}" = set; then
9625 withval="$with_dec_threads"
Martin v. Löwis11437992002-04-12 09:54:03 +00009626
9627echo "$as_me:$LINENO: result: $withval" >&5
9628echo "${ECHO_T}$withval" >&6
Guido van Rossumec2f0731997-01-22 20:54:01 +00009629LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +00009630if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +00009631 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +00009632fi
Guido van Rossumec2f0731997-01-22 20:54:01 +00009633else
Martin v. Löwis11437992002-04-12 09:54:03 +00009634 echo "$as_me:$LINENO: result: no" >&5
9635echo "${ECHO_T}no" >&6
9636fi;
9637
9638# Templates for things AC_DEFINEd more than once.
9639# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +00009640
9641
Martin v. Löwis11437992002-04-12 09:54:03 +00009642
9643
9644
9645
9646
9647echo "$as_me:$LINENO: checking for --with-threads" >&5
9648echo $ECHO_N "checking for --with-threads... $ECHO_C" >&6
9649
Guido van Rossumec2f0731997-01-22 20:54:01 +00009650# Check whether --with-threads or --without-threads was given.
9651if test "${with_threads+set}" = set; then
9652 withval="$with_threads"
Guido van Rossumec2f0731997-01-22 20:54:01 +00009653
Martin v. Löwis11437992002-04-12 09:54:03 +00009654fi;
Guido van Rossumec2f0731997-01-22 20:54:01 +00009655
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009656# --with-thread is deprecated, but check for it anyway
Martin v. Löwis11437992002-04-12 09:54:03 +00009657
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009658# Check whether --with-thread or --without-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009659if test "${with_thread+set}" = set; then
9660 withval="$with_thread"
Michael W. Hudson54241132001-12-07 15:38:26 +00009661
Martin v. Löwis11437992002-04-12 09:54:03 +00009662with_threads=$with_thread
9663fi;
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009664
9665if test -z "$with_threads"
9666then with_threads="yes"
9667fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009668echo "$as_me:$LINENO: result: $with_threads" >&5
9669echo "${ECHO_T}$with_threads" >&6
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009670
Martin v. Löwis2d7e2642002-04-05 16:50:53 +00009671
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009672if test "$with_threads" = "no"
9673then
9674 USE_THREAD_MODULE="#"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009675elif test "$ac_cv_pthread_is_default" = yes
9676then
Martin v. Löwis11437992002-04-12 09:54:03 +00009677 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009678#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009679_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009680
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009681 # Defining _REENTRANT on system with POSIX threads should not hurt.
Martin v. Löwis11437992002-04-12 09:54:03 +00009682 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009683#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009684_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009685
9686 posix_threads=yes
Martin v. Löwis11437992002-04-12 09:54:03 +00009687 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009688elif test "$ac_cv_kpthread" = "yes"
9689then
9690 CC="$CC -Kpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +00009691 cat >>confdefs.h <<\_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +00009692#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009693_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +00009694
Guido van Rossumd0b69ec2001-09-10 14:10:54 +00009695 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +00009696 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009697else
9698 if test ! -z "$with_threads" -a -d "$with_threads"
9699 then LDFLAGS="$LDFLAGS -L$with_threads"
9700 fi
9701 if test ! -z "$withval" -a -d "$withval"
9702 then LDFLAGS="$LDFLAGS -L$withval"
9703 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +00009704
9705 # According to the POSIX spec, a pthreads implementation must
9706 # define _POSIX_THREADS in unistd.h. Some apparently don't (which ones?)
Martin v. Löwis11437992002-04-12 09:54:03 +00009707 echo "$as_me:$LINENO: checking for _POSIX_THREADS in unistd.h" >&5
9708echo $ECHO_N "checking for _POSIX_THREADS in unistd.h... $ECHO_C" >&6
9709 cat >conftest.$ac_ext <<_ACEOF
9710#line $LINENO "configure"
Martin v. Löwis69c0ff32001-10-15 14:34:42 +00009711#include "confdefs.h"
9712#include <unistd.h>
9713 #ifdef _POSIX_THREADS
9714 yes
9715 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +00009716
9717_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +00009718if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9719 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +00009720 unistd_defines_pthreads=yes
9721else
Martin v. Löwis69c0ff32001-10-15 14:34:42 +00009722 unistd_defines_pthreads=no
9723fi
9724rm -f conftest*
9725
Martin v. Löwis11437992002-04-12 09:54:03 +00009726 echo "$as_me:$LINENO: result: $unistd_defines_pthreads" >&5
9727echo "${ECHO_T}$unistd_defines_pthreads" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +00009728
Martin v. Löwis11437992002-04-12 09:54:03 +00009729 cat >>confdefs.h <<\_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +00009730#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009731_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +00009732
Martin v. Löwis11437992002-04-12 09:54:03 +00009733 if test "${ac_cv_header_cthreads_h+set}" = set; then
9734 echo "$as_me:$LINENO: checking for cthreads.h" >&5
9735echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
9736if test "${ac_cv_header_cthreads_h+set}" = set; then
9737 echo $ECHO_N "(cached) $ECHO_C" >&6
9738fi
9739echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
9740echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009741else
Martin v. Löwis11437992002-04-12 09:54:03 +00009742 # Is the header compilable?
9743echo "$as_me:$LINENO: checking cthreads.h usability" >&5
9744echo $ECHO_N "checking cthreads.h usability... $ECHO_C" >&6
9745cat >conftest.$ac_ext <<_ACEOF
9746#line $LINENO "configure"
9747#include "confdefs.h"
9748$ac_includes_default
9749#include <cthreads.h>
9750_ACEOF
9751rm -f conftest.$ac_objext
9752if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9753 (eval $ac_compile) 2>&5
9754 ac_status=$?
9755 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9756 (exit $ac_status); } &&
9757 { ac_try='test -s conftest.$ac_objext'
9758 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9759 (eval $ac_try) 2>&5
9760 ac_status=$?
9761 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9762 (exit $ac_status); }; }; then
9763 ac_header_compiler=yes
9764else
9765 echo "$as_me: failed program was:" >&5
9766cat conftest.$ac_ext >&5
9767ac_header_compiler=no
9768fi
9769rm -f conftest.$ac_objext conftest.$ac_ext
9770echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9771echo "${ECHO_T}$ac_header_compiler" >&6
9772
9773# Is the header present?
9774echo "$as_me:$LINENO: checking cthreads.h presence" >&5
9775echo $ECHO_N "checking cthreads.h presence... $ECHO_C" >&6
9776cat >conftest.$ac_ext <<_ACEOF
9777#line $LINENO "configure"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009778#include "confdefs.h"
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009779#include <cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009780_ACEOF
9781if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9782 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9783 ac_status=$?
9784 egrep -v '^ *\+' conftest.er1 >conftest.err
9785 rm -f conftest.er1
9786 cat conftest.err >&5
9787 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9788 (exit $ac_status); } >/dev/null; then
9789 if test -s conftest.err; then
9790 ac_cpp_err=$ac_c_preproc_warn_flag
9791 else
9792 ac_cpp_err=
9793 fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009794else
Martin v. Löwis11437992002-04-12 09:54:03 +00009795 ac_cpp_err=yes
9796fi
9797if test -z "$ac_cpp_err"; then
9798 ac_header_preproc=yes
9799else
9800 echo "$as_me: failed program was:" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00009801 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009802 ac_header_preproc=no
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009803fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009804rm -f conftest.err conftest.$ac_ext
9805echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9806echo "${ECHO_T}$ac_header_preproc" >&6
9807
9808# So? What about this header?
9809case $ac_header_compiler:$ac_header_preproc in
9810 yes:no )
9811 { echo "$as_me:$LINENO: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
9812echo "$as_me: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9813 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
9814echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;};;
9815 no:yes )
9816 { echo "$as_me:$LINENO: WARNING: cthreads.h: present but cannot be compiled" >&5
9817echo "$as_me: WARNING: cthreads.h: present but cannot be compiled" >&2;}
9818 { echo "$as_me:$LINENO: WARNING: cthreads.h: check for missing prerequisite headers?" >&5
9819echo "$as_me: WARNING: cthreads.h: check for missing prerequisite headers?" >&2;}
9820 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
9821echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;};;
9822esac
9823echo "$as_me:$LINENO: checking for cthreads.h" >&5
9824echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
9825if test "${ac_cv_header_cthreads_h+set}" = set; then
9826 echo $ECHO_N "(cached) $ECHO_C" >&6
9827else
9828 ac_cv_header_cthreads_h=$ac_header_preproc
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009829fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009830echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
9831echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
9832
9833fi
9834if test $ac_cv_header_cthreads_h = yes; then
9835 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009836#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009837_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009838
Martin v. Löwis11437992002-04-12 09:54:03 +00009839 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009840#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009841_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009842
Martin v. Löwis11437992002-04-12 09:54:03 +00009843
9844cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009845#define HURD_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009846_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009847
9848 LIBS="$LIBS -lthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +00009849 THREADOBJ="Python/thread.o"
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009850else
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009851
Martin v. Löwis11437992002-04-12 09:54:03 +00009852 if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
9853 echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
9854echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
9855if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
9856 echo $ECHO_N "(cached) $ECHO_C" >&6
9857fi
9858echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
9859echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009860else
Martin v. Löwis11437992002-04-12 09:54:03 +00009861 # Is the header compilable?
9862echo "$as_me:$LINENO: checking mach/cthreads.h usability" >&5
9863echo $ECHO_N "checking mach/cthreads.h usability... $ECHO_C" >&6
9864cat >conftest.$ac_ext <<_ACEOF
9865#line $LINENO "configure"
9866#include "confdefs.h"
9867$ac_includes_default
9868#include <mach/cthreads.h>
9869_ACEOF
9870rm -f conftest.$ac_objext
9871if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9872 (eval $ac_compile) 2>&5
9873 ac_status=$?
9874 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9875 (exit $ac_status); } &&
9876 { ac_try='test -s conftest.$ac_objext'
9877 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9878 (eval $ac_try) 2>&5
9879 ac_status=$?
9880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9881 (exit $ac_status); }; }; then
9882 ac_header_compiler=yes
9883else
9884 echo "$as_me: failed program was:" >&5
9885cat conftest.$ac_ext >&5
9886ac_header_compiler=no
9887fi
9888rm -f conftest.$ac_objext conftest.$ac_ext
9889echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9890echo "${ECHO_T}$ac_header_compiler" >&6
9891
9892# Is the header present?
9893echo "$as_me:$LINENO: checking mach/cthreads.h presence" >&5
9894echo $ECHO_N "checking mach/cthreads.h presence... $ECHO_C" >&6
9895cat >conftest.$ac_ext <<_ACEOF
9896#line $LINENO "configure"
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009897#include "confdefs.h"
9898#include <mach/cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009899_ACEOF
9900if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9901 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9902 ac_status=$?
9903 egrep -v '^ *\+' conftest.er1 >conftest.err
9904 rm -f conftest.er1
9905 cat conftest.err >&5
9906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9907 (exit $ac_status); } >/dev/null; then
9908 if test -s conftest.err; then
9909 ac_cpp_err=$ac_c_preproc_warn_flag
9910 else
9911 ac_cpp_err=
9912 fi
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009913else
Martin v. Löwis11437992002-04-12 09:54:03 +00009914 ac_cpp_err=yes
9915fi
9916if test -z "$ac_cpp_err"; then
9917 ac_header_preproc=yes
9918else
9919 echo "$as_me: failed program was:" >&5
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009920 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009921 ac_header_preproc=no
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009922fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009923rm -f conftest.err conftest.$ac_ext
9924echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9925echo "${ECHO_T}$ac_header_preproc" >&6
9926
9927# So? What about this header?
9928case $ac_header_compiler:$ac_header_preproc in
9929 yes:no )
9930 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
9931echo "$as_me: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9932 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
9933echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;};;
9934 no:yes )
9935 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: present but cannot be compiled" >&5
9936echo "$as_me: WARNING: mach/cthreads.h: present but cannot be compiled" >&2;}
9937 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&5
9938echo "$as_me: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&2;}
9939 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
9940echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;};;
9941esac
9942echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
9943echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
9944if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
9945 echo $ECHO_N "(cached) $ECHO_C" >&6
9946else
9947 ac_cv_header_mach_cthreads_h=$ac_header_preproc
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009948fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009949echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
9950echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
9951
9952fi
9953if test $ac_cv_header_mach_cthreads_h = yes; then
9954 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009955#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009956_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009957
Martin v. Löwis11437992002-04-12 09:54:03 +00009958 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009959#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009960_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009961
Martin v. Löwis11437992002-04-12 09:54:03 +00009962
9963cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009964#define MACH_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009965_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009966
Martin v. Löwis2d7e2642002-04-05 16:50:53 +00009967 THREADOBJ="Python/thread.o"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009968else
Guido van Rossum7b3853f1996-07-30 18:09:35 +00009969
Martin v. Löwis11437992002-04-12 09:54:03 +00009970 echo "$as_me:$LINENO: checking for --with-pth" >&5
9971echo $ECHO_N "checking for --with-pth... $ECHO_C" >&6
9972
9973# Check whether --with-pth or --without-pth was given.
Guido van Rossum9e8181b2000-09-19 00:46:46 +00009974if test "${with_pth+set}" = set; then
9975 withval="$with_pth"
Guido van Rossum9e8181b2000-09-19 00:46:46 +00009976
Martin v. Löwis11437992002-04-12 09:54:03 +00009977 echo "$as_me:$LINENO: result: $withval" >&5
9978echo "${ECHO_T}$withval" >&6
9979 cat >>confdefs.h <<\_ACEOF
9980#define WITH_THREAD 1
9981_ACEOF
9982
9983
9984cat >>confdefs.h <<\_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +00009985#define HAVE_PTH 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009986_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +00009987
Martin v. Löwis130fb172001-07-19 11:00:41 +00009988 LIBS="-lpth $LIBS"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +00009989 THREADOBJ="Python/thread.o"
Guido van Rossum9e8181b2000-09-19 00:46:46 +00009990else
Martin v. Löwis11437992002-04-12 09:54:03 +00009991
9992 echo "$as_me:$LINENO: result: no" >&5
9993echo "${ECHO_T}no" >&6
Martin v. Löwis8158b5a2001-10-08 13:17:28 +00009994
9995 # Just looking for pthread_create in libpthread is not enough:
9996 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
9997 # So we really have to include pthread.h, and then link.
9998 _libs=$LIBS
9999 LIBS="$LIBS -lpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000010000 echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
10001echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6
10002 cat >conftest.$ac_ext <<_ACEOF
10003#line $LINENO "configure"
Guido van Rossum02a1c402000-02-25 19:26:31 +000010004#include "confdefs.h"
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010005#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000010006
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010007void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000010008#ifdef F77_DUMMY_MAIN
10009# ifdef __cplusplus
10010 extern "C"
10011# endif
10012 int F77_DUMMY_MAIN() { return 1; }
10013#endif
10014int
10015main ()
10016{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010017
10018pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000010019 ;
10020 return 0;
10021}
10022_ACEOF
10023rm -f conftest.$ac_objext conftest$ac_exeext
10024if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10025 (eval $ac_link) 2>&5
10026 ac_status=$?
10027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10028 (exit $ac_status); } &&
10029 { ac_try='test -s conftest$ac_exeext'
10030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10031 (eval $ac_try) 2>&5
10032 ac_status=$?
10033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10034 (exit $ac_status); }; }; then
10035
10036 echo "$as_me:$LINENO: result: yes" >&5
10037echo "${ECHO_T}yes" >&6
10038 cat >>confdefs.h <<\_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000010039#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010040_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000010041
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010042 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010043 THREADOBJ="Python/thread.o"
Guido van Rossum02a1c402000-02-25 19:26:31 +000010044else
Martin v. Löwis11437992002-04-12 09:54:03 +000010045 echo "$as_me: failed program was:" >&5
10046cat conftest.$ac_ext >&5
10047
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010048 LIBS=$_libs
Martin v. Löwis11437992002-04-12 09:54:03 +000010049 echo "$as_me:$LINENO: checking for pthread_detach" >&5
10050echo $ECHO_N "checking for pthread_detach... $ECHO_C" >&6
10051if test "${ac_cv_func_pthread_detach+set}" = set; then
10052 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000010053else
Martin v. Löwis11437992002-04-12 09:54:03 +000010054 cat >conftest.$ac_ext <<_ACEOF
10055#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +000010056#include "confdefs.h"
10057/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000010058 which can conflict with char pthread_detach (); below. */
Guido van Rossumad678af1998-10-02 14:42:15 +000010059#include <assert.h>
10060/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010061#ifdef __cplusplus
10062extern "C"
10063#endif
Guido van Rossumad678af1998-10-02 14:42:15 +000010064/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010065 builtin and then its argument prototype would still apply. */
10066char pthread_detach ();
10067char (*f) ();
Guido van Rossumad678af1998-10-02 14:42:15 +000010068
Martin v. Löwis11437992002-04-12 09:54:03 +000010069#ifdef F77_DUMMY_MAIN
10070# ifdef __cplusplus
10071 extern "C"
10072# endif
10073 int F77_DUMMY_MAIN() { return 1; }
10074#endif
10075int
10076main ()
10077{
Guido van Rossumad678af1998-10-02 14:42:15 +000010078/* The GNU C library defines this for functions which it implements
10079 to always fail with ENOSYS. Some functions are actually named
10080 something starting with __ and the normal name is an alias. */
Guido van Rossumea516321998-12-17 18:08:55 +000010081#if defined (__stub_pthread_detach) || defined (__stub___pthread_detach)
Guido van Rossumad678af1998-10-02 14:42:15 +000010082choke me
10083#else
Martin v. Löwis11437992002-04-12 09:54:03 +000010084f = pthread_detach;
Guido van Rossumad678af1998-10-02 14:42:15 +000010085#endif
10086
Martin v. Löwis11437992002-04-12 09:54:03 +000010087 ;
10088 return 0;
10089}
10090_ACEOF
10091rm -f conftest.$ac_objext conftest$ac_exeext
10092if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10093 (eval $ac_link) 2>&5
10094 ac_status=$?
10095 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10096 (exit $ac_status); } &&
10097 { ac_try='test -s conftest$ac_exeext'
10098 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10099 (eval $ac_try) 2>&5
10100 ac_status=$?
10101 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10102 (exit $ac_status); }; }; then
10103 ac_cv_func_pthread_detach=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000010104else
Martin v. Löwis11437992002-04-12 09:54:03 +000010105 echo "$as_me: failed program was:" >&5
10106cat conftest.$ac_ext >&5
10107ac_cv_func_pthread_detach=no
Guido van Rossumad678af1998-10-02 14:42:15 +000010108fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010109rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumad678af1998-10-02 14:42:15 +000010110fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010111echo "$as_me:$LINENO: result: $ac_cv_func_pthread_detach" >&5
10112echo "${ECHO_T}$ac_cv_func_pthread_detach" >&6
10113if test $ac_cv_func_pthread_detach = yes; then
10114 cat >>confdefs.h <<\_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000010115#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010116_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000010117
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010118 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010119 THREADOBJ="Python/thread.o"
Guido van Rossumad678af1998-10-02 14:42:15 +000010120else
Guido van Rossumad678af1998-10-02 14:42:15 +000010121
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010122 if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10123 echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
10124echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
10125if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10126 echo $ECHO_N "(cached) $ECHO_C" >&6
10127fi
10128echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
10129echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
10130else
10131 # Is the header compilable?
10132echo "$as_me:$LINENO: checking atheos/threads.h usability" >&5
10133echo $ECHO_N "checking atheos/threads.h usability... $ECHO_C" >&6
10134cat >conftest.$ac_ext <<_ACEOF
10135#line $LINENO "configure"
10136#include "confdefs.h"
10137$ac_includes_default
10138#include <atheos/threads.h>
10139_ACEOF
10140rm -f conftest.$ac_objext
10141if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10142 (eval $ac_compile) 2>&5
10143 ac_status=$?
10144 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10145 (exit $ac_status); } &&
10146 { ac_try='test -s conftest.$ac_objext'
10147 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10148 (eval $ac_try) 2>&5
10149 ac_status=$?
10150 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10151 (exit $ac_status); }; }; then
10152 ac_header_compiler=yes
10153else
10154 echo "$as_me: failed program was:" >&5
10155cat conftest.$ac_ext >&5
10156ac_header_compiler=no
10157fi
10158rm -f conftest.$ac_objext conftest.$ac_ext
10159echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10160echo "${ECHO_T}$ac_header_compiler" >&6
10161
10162# Is the header present?
10163echo "$as_me:$LINENO: checking atheos/threads.h presence" >&5
10164echo $ECHO_N "checking atheos/threads.h presence... $ECHO_C" >&6
10165cat >conftest.$ac_ext <<_ACEOF
10166#line $LINENO "configure"
10167#include "confdefs.h"
10168#include <atheos/threads.h>
10169_ACEOF
10170if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10171 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10172 ac_status=$?
10173 egrep -v '^ *\+' conftest.er1 >conftest.err
10174 rm -f conftest.er1
10175 cat conftest.err >&5
10176 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10177 (exit $ac_status); } >/dev/null; then
10178 if test -s conftest.err; then
10179 ac_cpp_err=$ac_c_preproc_warn_flag
10180 else
10181 ac_cpp_err=
10182 fi
10183else
10184 ac_cpp_err=yes
10185fi
10186if test -z "$ac_cpp_err"; then
10187 ac_header_preproc=yes
10188else
10189 echo "$as_me: failed program was:" >&5
10190 cat conftest.$ac_ext >&5
10191 ac_header_preproc=no
10192fi
10193rm -f conftest.err conftest.$ac_ext
10194echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10195echo "${ECHO_T}$ac_header_preproc" >&6
10196
10197# So? What about this header?
10198case $ac_header_compiler:$ac_header_preproc in
10199 yes:no )
10200 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10201echo "$as_me: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10202 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
10203echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;};;
10204 no:yes )
10205 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: present but cannot be compiled" >&5
10206echo "$as_me: WARNING: atheos/threads.h: present but cannot be compiled" >&2;}
10207 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&5
10208echo "$as_me: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&2;}
10209 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
10210echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;};;
10211esac
10212echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
10213echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
10214if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10215 echo $ECHO_N "(cached) $ECHO_C" >&6
10216else
10217 ac_cv_header_atheos_threads_h=$ac_header_preproc
10218fi
10219echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
10220echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
10221
10222fi
10223if test $ac_cv_header_atheos_threads_h = yes; then
10224 cat >>confdefs.h <<\_ACEOF
10225#define WITH_THREAD 1
10226_ACEOF
10227
10228
10229cat >>confdefs.h <<\_ACEOF
10230#define ATHEOS_THREADS 1
10231_ACEOF
10232
10233 THREADOBJ="Python/thread.o"
10234else
10235
Martin v. Löwis11437992002-04-12 09:54:03 +000010236 if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10237 echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
10238echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
10239if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10240 echo $ECHO_N "(cached) $ECHO_C" >&6
10241fi
10242echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
10243echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010244else
Martin v. Löwis11437992002-04-12 09:54:03 +000010245 # Is the header compilable?
10246echo "$as_me:$LINENO: checking kernel/OS.h usability" >&5
10247echo $ECHO_N "checking kernel/OS.h usability... $ECHO_C" >&6
10248cat >conftest.$ac_ext <<_ACEOF
10249#line $LINENO "configure"
10250#include "confdefs.h"
10251$ac_includes_default
10252#include <kernel/OS.h>
10253_ACEOF
10254rm -f conftest.$ac_objext
10255if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10256 (eval $ac_compile) 2>&5
10257 ac_status=$?
10258 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10259 (exit $ac_status); } &&
10260 { ac_try='test -s conftest.$ac_objext'
10261 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10262 (eval $ac_try) 2>&5
10263 ac_status=$?
10264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10265 (exit $ac_status); }; }; then
10266 ac_header_compiler=yes
10267else
10268 echo "$as_me: failed program was:" >&5
10269cat conftest.$ac_ext >&5
10270ac_header_compiler=no
10271fi
10272rm -f conftest.$ac_objext conftest.$ac_ext
10273echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10274echo "${ECHO_T}$ac_header_compiler" >&6
10275
10276# Is the header present?
10277echo "$as_me:$LINENO: checking kernel/OS.h presence" >&5
10278echo $ECHO_N "checking kernel/OS.h presence... $ECHO_C" >&6
10279cat >conftest.$ac_ext <<_ACEOF
10280#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010281#include "confdefs.h"
10282#include <kernel/OS.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010283_ACEOF
10284if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10285 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10286 ac_status=$?
10287 egrep -v '^ *\+' conftest.er1 >conftest.err
10288 rm -f conftest.er1
10289 cat conftest.err >&5
10290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10291 (exit $ac_status); } >/dev/null; then
10292 if test -s conftest.err; then
10293 ac_cpp_err=$ac_c_preproc_warn_flag
10294 else
10295 ac_cpp_err=
10296 fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010297else
Martin v. Löwis11437992002-04-12 09:54:03 +000010298 ac_cpp_err=yes
10299fi
10300if test -z "$ac_cpp_err"; then
10301 ac_header_preproc=yes
10302else
10303 echo "$as_me: failed program was:" >&5
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010304 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010305 ac_header_preproc=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010306fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010307rm -f conftest.err conftest.$ac_ext
10308echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10309echo "${ECHO_T}$ac_header_preproc" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010310
Martin v. Löwis11437992002-04-12 09:54:03 +000010311# So? What about this header?
10312case $ac_header_compiler:$ac_header_preproc in
10313 yes:no )
10314 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&5
10315echo "$as_me: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10316 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
10317echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;};;
10318 no:yes )
10319 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: present but cannot be compiled" >&5
10320echo "$as_me: WARNING: kernel/OS.h: present but cannot be compiled" >&2;}
10321 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&5
10322echo "$as_me: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&2;}
10323 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
10324echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;};;
10325esac
10326echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
10327echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
10328if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10329 echo $ECHO_N "(cached) $ECHO_C" >&6
10330else
10331 ac_cv_header_kernel_OS_h=$ac_header_preproc
10332fi
10333echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
10334echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
10335
10336fi
10337if test $ac_cv_header_kernel_OS_h = yes; then
10338 cat >>confdefs.h <<\_ACEOF
10339#define WITH_THREAD 1
10340_ACEOF
10341
10342
10343cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010344#define BEOS_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010345_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010346
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010347 THREADOBJ="Python/thread.o"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010348else
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010349
Martin v. Löwis11437992002-04-12 09:54:03 +000010350 echo "$as_me:$LINENO: checking for pthread_create in -lpthreads" >&5
10351echo $ECHO_N "checking for pthread_create in -lpthreads... $ECHO_C" >&6
10352if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then
10353 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010354else
Martin v. Löwis11437992002-04-12 09:54:03 +000010355 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010356LIBS="-lpthreads $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010357cat >conftest.$ac_ext <<_ACEOF
10358#line $LINENO "configure"
Greg Steinadf63d62000-07-05 10:38:09 +000010359#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010360
Greg Steinadf63d62000-07-05 10:38:09 +000010361/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010362#ifdef __cplusplus
10363extern "C"
10364#endif
Greg Steinadf63d62000-07-05 10:38:09 +000010365/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010366 builtin and then its argument prototype would still apply. */
10367char pthread_create ();
10368#ifdef F77_DUMMY_MAIN
10369# ifdef __cplusplus
10370 extern "C"
10371# endif
10372 int F77_DUMMY_MAIN() { return 1; }
10373#endif
10374int
10375main ()
10376{
10377pthread_create ();
10378 ;
10379 return 0;
10380}
10381_ACEOF
10382rm -f conftest.$ac_objext conftest$ac_exeext
10383if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10384 (eval $ac_link) 2>&5
10385 ac_status=$?
10386 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10387 (exit $ac_status); } &&
10388 { ac_try='test -s conftest$ac_exeext'
10389 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10390 (eval $ac_try) 2>&5
10391 ac_status=$?
10392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10393 (exit $ac_status); }; }; then
10394 ac_cv_lib_pthreads_pthread_create=yes
Greg Steinadf63d62000-07-05 10:38:09 +000010395else
Martin v. Löwis11437992002-04-12 09:54:03 +000010396 echo "$as_me: failed program was:" >&5
10397cat conftest.$ac_ext >&5
10398ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000010399fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010400rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10401LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010402fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010403echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_create" >&5
10404echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_create" >&6
10405if test $ac_cv_lib_pthreads_pthread_create = yes; then
10406 cat >>confdefs.h <<\_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000010407#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010408_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000010409
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010410 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010411 LIBS="$LIBS -lpthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010412 THREADOBJ="Python/thread.o"
Greg Steinadf63d62000-07-05 10:38:09 +000010413else
Greg Steinadf63d62000-07-05 10:38:09 +000010414
Martin v. Löwis11437992002-04-12 09:54:03 +000010415 echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
10416echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6
10417if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
10418 echo $ECHO_N "(cached) $ECHO_C" >&6
Greg Steinadf63d62000-07-05 10:38:09 +000010419else
Martin v. Löwis11437992002-04-12 09:54:03 +000010420 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010421LIBS="-lc_r $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010422cat >conftest.$ac_ext <<_ACEOF
10423#line $LINENO "configure"
Guido van Rossum49545951997-12-02 19:28:29 +000010424#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010425
Guido van Rossum49545951997-12-02 19:28:29 +000010426/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010427#ifdef __cplusplus
10428extern "C"
10429#endif
Guido van Rossum49545951997-12-02 19:28:29 +000010430/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010431 builtin and then its argument prototype would still apply. */
10432char pthread_create ();
10433#ifdef F77_DUMMY_MAIN
10434# ifdef __cplusplus
10435 extern "C"
10436# endif
10437 int F77_DUMMY_MAIN() { return 1; }
10438#endif
10439int
10440main ()
10441{
10442pthread_create ();
10443 ;
10444 return 0;
10445}
10446_ACEOF
10447rm -f conftest.$ac_objext conftest$ac_exeext
10448if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10449 (eval $ac_link) 2>&5
10450 ac_status=$?
10451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10452 (exit $ac_status); } &&
10453 { ac_try='test -s conftest$ac_exeext'
10454 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10455 (eval $ac_try) 2>&5
10456 ac_status=$?
10457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10458 (exit $ac_status); }; }; then
10459 ac_cv_lib_c_r_pthread_create=yes
Guido van Rossum49545951997-12-02 19:28:29 +000010460else
Martin v. Löwis11437992002-04-12 09:54:03 +000010461 echo "$as_me: failed program was:" >&5
10462cat conftest.$ac_ext >&5
10463ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000010464fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010465rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10466LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000010467fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010468echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
10469echo "${ECHO_T}$ac_cv_lib_c_r_pthread_create" >&6
10470if test $ac_cv_lib_c_r_pthread_create = yes; then
10471 cat >>confdefs.h <<\_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000010472#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010473_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000010474
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010475 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010476 LIBS="$LIBS -lc_r"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010477 THREADOBJ="Python/thread.o"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010478else
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010479
Martin v. Löwis11437992002-04-12 09:54:03 +000010480 echo "$as_me:$LINENO: checking for __d6_pthread_create in -lthread" >&5
10481echo $ECHO_N "checking for __d6_pthread_create in -lthread... $ECHO_C" >&6
10482if test "${ac_cv_lib_thread___d6_pthread_create+set}" = set; then
10483 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010484else
Martin v. Löwis11437992002-04-12 09:54:03 +000010485 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010486LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010487cat >conftest.$ac_ext <<_ACEOF
10488#line $LINENO "configure"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010489#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010490
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010491/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010492#ifdef __cplusplus
10493extern "C"
10494#endif
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010495/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010496 builtin and then its argument prototype would still apply. */
10497char __d6_pthread_create ();
10498#ifdef F77_DUMMY_MAIN
10499# ifdef __cplusplus
10500 extern "C"
10501# endif
10502 int F77_DUMMY_MAIN() { return 1; }
10503#endif
10504int
10505main ()
10506{
10507__d6_pthread_create ();
10508 ;
10509 return 0;
10510}
10511_ACEOF
10512rm -f conftest.$ac_objext conftest$ac_exeext
10513if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10514 (eval $ac_link) 2>&5
10515 ac_status=$?
10516 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10517 (exit $ac_status); } &&
10518 { ac_try='test -s conftest$ac_exeext'
10519 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10520 (eval $ac_try) 2>&5
10521 ac_status=$?
10522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10523 (exit $ac_status); }; }; then
10524 ac_cv_lib_thread___d6_pthread_create=yes
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010525else
Martin v. Löwis11437992002-04-12 09:54:03 +000010526 echo "$as_me: failed program was:" >&5
10527cat conftest.$ac_ext >&5
10528ac_cv_lib_thread___d6_pthread_create=no
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010529fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010530rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10531LIBS=$ac_check_lib_save_LIBS
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010532fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010533echo "$as_me:$LINENO: result: $ac_cv_lib_thread___d6_pthread_create" >&5
10534echo "${ECHO_T}$ac_cv_lib_thread___d6_pthread_create" >&6
10535if test $ac_cv_lib_thread___d6_pthread_create = yes; then
10536 cat >>confdefs.h <<\_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010537#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010538_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010539
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010540 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010541 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010542 THREADOBJ="Python/thread.o"
Guido van Rossum49545951997-12-02 19:28:29 +000010543else
Guido van Rossum49545951997-12-02 19:28:29 +000010544
Martin v. Löwis11437992002-04-12 09:54:03 +000010545 echo "$as_me:$LINENO: checking for __pthread_create_system in -lpthread" >&5
10546echo $ECHO_N "checking for __pthread_create_system in -lpthread... $ECHO_C" >&6
10547if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then
10548 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010549else
Martin v. Löwis11437992002-04-12 09:54:03 +000010550 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010551LIBS="-lpthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010552cat >conftest.$ac_ext <<_ACEOF
10553#line $LINENO "configure"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010554#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010555
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010556/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010557#ifdef __cplusplus
10558extern "C"
10559#endif
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010560/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010561 builtin and then its argument prototype would still apply. */
10562char __pthread_create_system ();
10563#ifdef F77_DUMMY_MAIN
10564# ifdef __cplusplus
10565 extern "C"
10566# endif
10567 int F77_DUMMY_MAIN() { return 1; }
10568#endif
10569int
10570main ()
10571{
10572__pthread_create_system ();
10573 ;
10574 return 0;
10575}
10576_ACEOF
10577rm -f conftest.$ac_objext conftest$ac_exeext
10578if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10579 (eval $ac_link) 2>&5
10580 ac_status=$?
10581 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10582 (exit $ac_status); } &&
10583 { ac_try='test -s conftest$ac_exeext'
10584 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10585 (eval $ac_try) 2>&5
10586 ac_status=$?
10587 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10588 (exit $ac_status); }; }; then
10589 ac_cv_lib_pthread___pthread_create_system=yes
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010590else
Martin v. Löwis11437992002-04-12 09:54:03 +000010591 echo "$as_me: failed program was:" >&5
10592cat conftest.$ac_ext >&5
10593ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010594fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010595rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10596LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010597fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010598echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_create_system" >&5
10599echo "${ECHO_T}$ac_cv_lib_pthread___pthread_create_system" >&6
10600if test $ac_cv_lib_pthread___pthread_create_system = yes; then
10601 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010602#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010603_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010604
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010605 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010606 LIBS="$LIBS -lpthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010607 THREADOBJ="Python/thread.o"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010608else
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010609
Martin v. Löwis11437992002-04-12 09:54:03 +000010610 echo "$as_me:$LINENO: checking for pthread_create in -lcma" >&5
10611echo $ECHO_N "checking for pthread_create in -lcma... $ECHO_C" >&6
10612if test "${ac_cv_lib_cma_pthread_create+set}" = set; then
10613 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb93a8621998-05-07 13:27:32 +000010614else
Martin v. Löwis11437992002-04-12 09:54:03 +000010615 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000010616LIBS="-lcma $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010617cat >conftest.$ac_ext <<_ACEOF
10618#line $LINENO "configure"
Guido van Rossumb93a8621998-05-07 13:27:32 +000010619#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010620
Guido van Rossumb93a8621998-05-07 13:27:32 +000010621/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010622#ifdef __cplusplus
10623extern "C"
10624#endif
Guido van Rossumb93a8621998-05-07 13:27:32 +000010625/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010626 builtin and then its argument prototype would still apply. */
10627char pthread_create ();
10628#ifdef F77_DUMMY_MAIN
10629# ifdef __cplusplus
10630 extern "C"
10631# endif
10632 int F77_DUMMY_MAIN() { return 1; }
10633#endif
10634int
10635main ()
10636{
10637pthread_create ();
10638 ;
10639 return 0;
10640}
10641_ACEOF
10642rm -f conftest.$ac_objext conftest$ac_exeext
10643if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10644 (eval $ac_link) 2>&5
10645 ac_status=$?
10646 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10647 (exit $ac_status); } &&
10648 { ac_try='test -s conftest$ac_exeext'
10649 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10650 (eval $ac_try) 2>&5
10651 ac_status=$?
10652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10653 (exit $ac_status); }; }; then
10654 ac_cv_lib_cma_pthread_create=yes
Guido van Rossumb93a8621998-05-07 13:27:32 +000010655else
Martin v. Löwis11437992002-04-12 09:54:03 +000010656 echo "$as_me: failed program was:" >&5
10657cat conftest.$ac_ext >&5
10658ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000010659fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010660rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10661LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000010662fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010663echo "$as_me:$LINENO: result: $ac_cv_lib_cma_pthread_create" >&5
10664echo "${ECHO_T}$ac_cv_lib_cma_pthread_create" >&6
10665if test $ac_cv_lib_cma_pthread_create = yes; then
10666 cat >>confdefs.h <<\_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000010667#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010668_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000010669
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010670 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010671 LIBS="$LIBS -lcma"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010672 THREADOBJ="Python/thread.o"
Guido van Rossumb93a8621998-05-07 13:27:32 +000010673else
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000010674
Martin v. Löwis130fb172001-07-19 11:00:41 +000010675 USE_THREAD_MODULE="#"
Guido van Rossum2d38f911996-06-26 19:47:01 +000010676fi
10677
Guido van Rossum627b2d71993-12-24 10:39:16 +000010678
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010679fi
10680
Guido van Rossum0be3e491997-05-22 20:33:33 +000010681fi
10682
Guido van Rossum49545951997-12-02 19:28:29 +000010683fi
10684
Guido van Rossumb93a8621998-05-07 13:27:32 +000010685fi
10686
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010687fi
10688
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010689
Michael W. Hudson54241132001-12-07 15:38:26 +000010690fi
10691
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010692
10693fi
10694
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010695fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010696rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10697fi;
10698fi
10699
10700
10701fi
10702
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010703
Michael W. Hudson54241132001-12-07 15:38:26 +000010704
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010705 if test "$posix_threads" = "yes"; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010706 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010707
10708cat >>confdefs.h <<\_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010709#define _POSIX_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010710_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010711
10712 fi
10713
Martin v. Löwis11437992002-04-12 09:54:03 +000010714 echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
10715echo $ECHO_N "checking if PTHREAD_SCOPE_SYSTEM is supported... $ECHO_C" >&6
10716 if test "${ac_cv_pthread_system_supported+set}" = set; then
10717 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010718else
10719 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000010720 ac_cv_pthread_system_supported=no
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010721else
Martin v. Löwis11437992002-04-12 09:54:03 +000010722 cat >conftest.$ac_ext <<_ACEOF
10723#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010724#include "confdefs.h"
10725#include <pthread.h>
10726 void *foo(void *parm) {
10727 return NULL;
10728 }
10729 main() {
10730 pthread_attr_t attr;
Martin v. Löwisa82d3472002-02-24 16:05:05 +000010731 pthread_t id;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010732 if (pthread_attr_init(&attr)) exit(-1);
10733 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1);
Martin v. Löwisa82d3472002-02-24 16:05:05 +000010734 if (pthread_create(&id, &attr, foo, NULL)) exit(-1);
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010735 exit(0);
10736 }
Martin v. Löwis11437992002-04-12 09:54:03 +000010737_ACEOF
10738rm -f conftest$ac_exeext
10739if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10740 (eval $ac_link) 2>&5
10741 ac_status=$?
10742 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10743 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10744 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10745 (eval $ac_try) 2>&5
10746 ac_status=$?
10747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10748 (exit $ac_status); }; }; then
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010749 ac_cv_pthread_system_supported=yes
10750else
Martin v. Löwis11437992002-04-12 09:54:03 +000010751 echo "$as_me: program exited with status $ac_status" >&5
10752echo "$as_me: failed program was:" >&5
10753cat conftest.$ac_ext >&5
10754( exit $ac_status )
10755ac_cv_pthread_system_supported=no
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010756fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010757rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010758fi
10759
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010760fi
10761
Martin v. Löwis11437992002-04-12 09:54:03 +000010762 echo "$as_me:$LINENO: result: $ac_cv_pthread_system_supported" >&5
10763echo "${ECHO_T}$ac_cv_pthread_system_supported" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010764 if test "$ac_cv_pthread_system_supported" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010765
10766cat >>confdefs.h <<\_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010767#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010768_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010769
10770 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010771
10772for ac_func in pthread_sigmask
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010773do
Martin v. Löwis11437992002-04-12 09:54:03 +000010774as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10775echo "$as_me:$LINENO: checking for $ac_func" >&5
10776echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10777if eval "test \"\${$as_ac_var+set}\" = set"; then
10778 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010779else
Martin v. Löwis11437992002-04-12 09:54:03 +000010780 cat >conftest.$ac_ext <<_ACEOF
10781#line $LINENO "configure"
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010782#include "confdefs.h"
10783/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000010784 which can conflict with char $ac_func (); below. */
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010785#include <assert.h>
10786/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010787#ifdef __cplusplus
10788extern "C"
10789#endif
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010790/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010791 builtin and then its argument prototype would still apply. */
10792char $ac_func ();
10793char (*f) ();
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010794
Martin v. Löwis11437992002-04-12 09:54:03 +000010795#ifdef F77_DUMMY_MAIN
10796# ifdef __cplusplus
10797 extern "C"
10798# endif
10799 int F77_DUMMY_MAIN() { return 1; }
10800#endif
10801int
10802main ()
10803{
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010804/* The GNU C library defines this for functions which it implements
10805 to always fail with ENOSYS. Some functions are actually named
10806 something starting with __ and the normal name is an alias. */
10807#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10808choke me
10809#else
Martin v. Löwis11437992002-04-12 09:54:03 +000010810f = $ac_func;
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010811#endif
10812
Martin v. Löwis11437992002-04-12 09:54:03 +000010813 ;
10814 return 0;
10815}
10816_ACEOF
10817rm -f conftest.$ac_objext conftest$ac_exeext
10818if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10819 (eval $ac_link) 2>&5
10820 ac_status=$?
10821 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10822 (exit $ac_status); } &&
10823 { ac_try='test -s conftest$ac_exeext'
10824 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10825 (eval $ac_try) 2>&5
10826 ac_status=$?
10827 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10828 (exit $ac_status); }; }; then
10829 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000010830else
Martin v. Löwis11437992002-04-12 09:54:03 +000010831 echo "$as_me: failed program was:" >&5
10832cat conftest.$ac_ext >&5
10833eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000010834fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010835rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000010836fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010837echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10838echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10839if test `eval echo '${'$as_ac_var'}'` = yes; then
10840 cat >>confdefs.h <<_ACEOF
10841#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10842_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010843
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010844fi
10845done
10846
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010847 fi
10848
Martin v. Löwis11437992002-04-12 09:54:03 +000010849 echo "$as_me:$LINENO: checking for usconfig in -lmpc" >&5
10850echo $ECHO_N "checking for usconfig in -lmpc... $ECHO_C" >&6
10851if test "${ac_cv_lib_mpc_usconfig+set}" = set; then
10852 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010853else
Martin v. Löwis11437992002-04-12 09:54:03 +000010854 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010855LIBS="-lmpc $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010856cat >conftest.$ac_ext <<_ACEOF
10857#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000010858#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010859
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010860/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010861#ifdef __cplusplus
10862extern "C"
10863#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010864/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010865 builtin and then its argument prototype would still apply. */
10866char usconfig ();
10867#ifdef F77_DUMMY_MAIN
10868# ifdef __cplusplus
10869 extern "C"
10870# endif
10871 int F77_DUMMY_MAIN() { return 1; }
10872#endif
10873int
10874main ()
10875{
10876usconfig ();
10877 ;
10878 return 0;
10879}
10880_ACEOF
10881rm -f conftest.$ac_objext conftest$ac_exeext
10882if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10883 (eval $ac_link) 2>&5
10884 ac_status=$?
10885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10886 (exit $ac_status); } &&
10887 { ac_try='test -s conftest$ac_exeext'
10888 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10889 (eval $ac_try) 2>&5
10890 ac_status=$?
10891 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10892 (exit $ac_status); }; }; then
10893 ac_cv_lib_mpc_usconfig=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010894else
Martin v. Löwis11437992002-04-12 09:54:03 +000010895 echo "$as_me: failed program was:" >&5
10896cat conftest.$ac_ext >&5
10897ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000010898fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010899rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10900LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010901fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010902echo "$as_me:$LINENO: result: $ac_cv_lib_mpc_usconfig" >&5
10903echo "${ECHO_T}$ac_cv_lib_mpc_usconfig" >&6
10904if test $ac_cv_lib_mpc_usconfig = yes; then
10905 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010906#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010907_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000010908
Martin v. Löwis130fb172001-07-19 11:00:41 +000010909 LIBS="$LIBS -lmpc"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010910 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010911 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000010912fi
10913
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000010914
Martin v. Löwis11437992002-04-12 09:54:03 +000010915 if test $posix_threads != "yes"; then
10916 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
10917echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
10918if test "${ac_cv_lib_thread_thr_create+set}" = set; then
10919 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010920else
Martin v. Löwis11437992002-04-12 09:54:03 +000010921 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010922LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010923cat >conftest.$ac_ext <<_ACEOF
10924#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000010925#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010926
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010927/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010928#ifdef __cplusplus
10929extern "C"
10930#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000010931/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010932 builtin and then its argument prototype would still apply. */
10933char thr_create ();
10934#ifdef F77_DUMMY_MAIN
10935# ifdef __cplusplus
10936 extern "C"
10937# endif
10938 int F77_DUMMY_MAIN() { return 1; }
10939#endif
10940int
10941main ()
10942{
10943thr_create ();
10944 ;
10945 return 0;
10946}
10947_ACEOF
10948rm -f conftest.$ac_objext conftest$ac_exeext
10949if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10950 (eval $ac_link) 2>&5
10951 ac_status=$?
10952 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10953 (exit $ac_status); } &&
10954 { ac_try='test -s conftest$ac_exeext'
10955 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10956 (eval $ac_try) 2>&5
10957 ac_status=$?
10958 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10959 (exit $ac_status); }; }; then
10960 ac_cv_lib_thread_thr_create=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010961else
Martin v. Löwis11437992002-04-12 09:54:03 +000010962 echo "$as_me: failed program was:" >&5
10963cat conftest.$ac_ext >&5
10964ac_cv_lib_thread_thr_create=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000010965fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010966rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10967LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010968fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010969echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
10970echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
10971if test $ac_cv_lib_thread_thr_create = yes; then
10972 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010973#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010974_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000010975
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000010976 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010977 THREADOBJ="Python/thread.o"
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000010978 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000010979fi
10980
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000010981 fi
Michael W. Hudson54241132001-12-07 15:38:26 +000010982
Martin v. Löwis130fb172001-07-19 11:00:41 +000010983 if test "$USE_THREAD_MODULE" != "#"
10984 then
10985 # If the above checks didn't disable threads, (at least) OSF1
10986 # needs this '-threads' argument during linking.
10987 case $ac_sys_system in
10988 OSF1) LDLAST=-threads;;
10989 esac
Jeremy Hylton1a2ca862000-10-16 16:59:12 +000010990 fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000010991
10992 if test "$posix_threads" = yes -a \
10993 "$ac_sys_system" = "SunOS" -a \
10994 "$ac_sys_release" = "5.6"; then
10995
10996cat >>confdefs.h <<\_ACEOF
10997#define HAVE_PTHREAD_DESTRUCTOR 1
10998_ACEOF
10999
11000 fi
11001
Guido van Rossum627b2d71993-12-24 10:39:16 +000011002fi
11003
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011004# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000011005
11006
11007echo "$as_me:$LINENO: checking if --enable-ipv6 is specified" >&5
11008echo $ECHO_N "checking if --enable-ipv6 is specified... $ECHO_C" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011009# Check whether --enable-ipv6 or --disable-ipv6 was given.
11010if test "${enable_ipv6+set}" = set; then
11011 enableval="$enable_ipv6"
11012 case "$enableval" in
11013 no)
Martin v. Löwis11437992002-04-12 09:54:03 +000011014 echo "$as_me:$LINENO: result: no" >&5
11015echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011016 ipv6=no
11017 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011018 *) echo "$as_me:$LINENO: result: yes" >&5
11019echo "${ECHO_T}yes" >&6
11020 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011021#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011022_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011023
11024 ipv6=yes
11025 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011026 esac
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011027else
Martin v. Löwis11437992002-04-12 09:54:03 +000011028
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011029 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011030 echo "$as_me:$LINENO: result: no" >&5
11031echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011032 ipv6=no
11033
11034else
Martin v. Löwis11437992002-04-12 09:54:03 +000011035 cat >conftest.$ac_ext <<_ACEOF
11036#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011037#include "confdefs.h"
11038 /* AF_INET6 available check */
11039#include <sys/types.h>
11040#include <sys/socket.h>
11041main()
11042{
11043 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
11044 exit(1);
11045 else
11046 exit(0);
11047}
11048
Martin v. Löwis11437992002-04-12 09:54:03 +000011049_ACEOF
11050rm -f conftest$ac_exeext
11051if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11052 (eval $ac_link) 2>&5
11053 ac_status=$?
11054 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11055 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11056 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11057 (eval $ac_try) 2>&5
11058 ac_status=$?
11059 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11060 (exit $ac_status); }; }; then
11061 echo "$as_me:$LINENO: result: yes" >&5
11062echo "${ECHO_T}yes" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011063 ipv6=yes
11064else
Martin v. Löwis11437992002-04-12 09:54:03 +000011065 echo "$as_me: program exited with status $ac_status" >&5
11066echo "$as_me: failed program was:" >&5
11067cat conftest.$ac_ext >&5
11068( exit $ac_status )
11069echo "$as_me:$LINENO: result: no" >&5
11070echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011071 ipv6=no
11072fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011073rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011074fi
11075
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011076if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011077 echo "$as_me:$LINENO: checking if RFC2553 API is available" >&5
11078echo $ECHO_N "checking if RFC2553 API is available... $ECHO_C" >&6
11079 cat >conftest.$ac_ext <<_ACEOF
11080#line $LINENO "configure"
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011081#include "confdefs.h"
11082#include <sys/types.h>
11083#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011084#ifdef F77_DUMMY_MAIN
11085# ifdef __cplusplus
11086 extern "C"
11087# endif
11088 int F77_DUMMY_MAIN() { return 1; }
11089#endif
11090int
11091main ()
11092{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011093struct sockaddr_in6 x;
11094x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000011095 ;
11096 return 0;
11097}
11098_ACEOF
11099rm -f conftest.$ac_objext
11100if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11101 (eval $ac_compile) 2>&5
11102 ac_status=$?
11103 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11104 (exit $ac_status); } &&
11105 { ac_try='test -s conftest.$ac_objext'
11106 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11107 (eval $ac_try) 2>&5
11108 ac_status=$?
11109 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11110 (exit $ac_status); }; }; then
11111 echo "$as_me:$LINENO: result: yes" >&5
11112echo "${ECHO_T}yes" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011113 ipv6=yes
11114else
Martin v. Löwis11437992002-04-12 09:54:03 +000011115 echo "$as_me: failed program was:" >&5
11116cat conftest.$ac_ext >&5
11117echo "$as_me:$LINENO: result: no" >&5
11118echo "${ECHO_T}no" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011119 ipv6=no
11120fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011121rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011122fi
11123
11124if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011125 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011126#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011127_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011128
11129fi
11130
Martin v. Löwis11437992002-04-12 09:54:03 +000011131fi;
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011132
11133ipv6type=unknown
11134ipv6lib=none
11135ipv6trylibc=no
11136
11137if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011138 echo "$as_me:$LINENO: checking ipv6 stack type" >&5
11139echo $ECHO_N "checking ipv6 stack type... $ECHO_C" >&6
Guido van Rossumb8552162001-09-05 14:58:11 +000011140 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
11141 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011142 case $i in
11143 inria)
Martin v. Löwis11437992002-04-12 09:54:03 +000011144 cat >conftest.$ac_ext <<_ACEOF
11145#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011146#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011147
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011148#include <netinet/in.h>
11149#ifdef IPV6_INRIA_VERSION
11150yes
11151#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011152_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011153if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11154 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011155 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011156fi
11157rm -f conftest*
11158
11159 ;;
11160 kame)
Martin v. Löwis11437992002-04-12 09:54:03 +000011161 cat >conftest.$ac_ext <<_ACEOF
11162#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011163#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011164
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011165#include <netinet/in.h>
11166#ifdef __KAME__
11167yes
11168#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011169_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011170if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11171 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011172 ipv6type=$i;
11173 ipv6lib=inet6
11174 ipv6libdir=/usr/local/v6/lib
11175 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011176fi
11177rm -f conftest*
11178
11179 ;;
11180 linux-glibc)
Martin v. Löwis11437992002-04-12 09:54:03 +000011181 cat >conftest.$ac_ext <<_ACEOF
11182#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011183#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011184
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011185#include <features.h>
11186#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
11187yes
11188#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011189_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011190if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11191 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011192 ipv6type=$i;
11193 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011194fi
11195rm -f conftest*
11196
11197 ;;
11198 linux-inet6)
11199 if test -d /usr/inet6; then
11200 ipv6type=$i
11201 ipv6lib=inet6
11202 ipv6libdir=/usr/inet6/lib
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011203 OPT="-I/usr/inet6/include $OPT"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011204 fi
11205 ;;
11206 solaris)
11207 if test -f /etc/netconfig; then
11208 if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then
11209 ipv6type=$i
11210 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011211 fi
11212 fi
11213 ;;
11214 toshiba)
Martin v. Löwis11437992002-04-12 09:54:03 +000011215 cat >conftest.$ac_ext <<_ACEOF
11216#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011217#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011218
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011219#include <sys/param.h>
11220#ifdef _TOSHIBA_INET6
11221yes
11222#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011223_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011224if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11225 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011226 ipv6type=$i;
11227 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011228 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011229fi
11230rm -f conftest*
11231
11232 ;;
11233 v6d)
Martin v. Löwis11437992002-04-12 09:54:03 +000011234 cat >conftest.$ac_ext <<_ACEOF
11235#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011236#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011237
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011238#include </usr/local/v6/include/sys/v6config.h>
11239#ifdef __V6D__
11240yes
11241#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011242_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011243if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11244 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011245 ipv6type=$i;
11246 ipv6lib=v6;
11247 ipv6libdir=/usr/local/v6/lib;
11248 OPT="-I/usr/local/v6/include $OPT"
11249fi
11250rm -f conftest*
11251
11252 ;;
11253 zeta)
Martin v. Löwis11437992002-04-12 09:54:03 +000011254 cat >conftest.$ac_ext <<_ACEOF
11255#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011256#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011257
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011258#include <sys/param.h>
11259#ifdef _ZETA_MINAMI_INET6
11260yes
11261#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011262_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011263if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11264 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011265 ipv6type=$i;
11266 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011267 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011268fi
11269rm -f conftest*
11270
11271 ;;
11272 esac
11273 if test "$ipv6type" != "unknown"; then
11274 break
11275 fi
11276 done
Martin v. Löwis11437992002-04-12 09:54:03 +000011277 echo "$as_me:$LINENO: result: $ipv6type" >&5
11278echo "${ECHO_T}$ipv6type" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011279fi
11280
11281if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
11282 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
11283 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
11284 echo "using lib$ipv6lib"
11285 else
11286 if test $ipv6trylibc = "yes"; then
11287 echo "using libc"
11288 else
11289 echo 'Fatal: no $ipv6lib library found. cannot continue.'
11290 echo "You need to fetch lib$ipv6lib.a from appropriate"
11291 echo 'ipv6 kit and compile beforehand.'
11292 exit 1
11293 fi
11294 fi
11295fi
11296
Jack Jansen7b8c7542002-04-14 20:12:41 +000011297# Check for universal newline support
Guido van Rossum402905e2002-08-15 13:56:35 +000011298echo "$as_me:$LINENO: checking for --with-universal-newlines" >&5
11299echo $ECHO_N "checking for --with-universal-newlines... $ECHO_C" >&6
Jack Jansen7b8c7542002-04-14 20:12:41 +000011300
11301# Check whether --with-universal-newlines or --without-universal-newlines was given.
11302if test "${with_universal_newlines+set}" = set; then
11303 withval="$with_universal_newlines"
11304
11305fi;
11306
11307if test -z "$with_universal_newlines"
11308then with_universal_newlines="yes"
11309fi
11310if test "$with_universal_newlines" != "no"
11311then
Martin v. Löwise8aea582002-04-16 05:51:02 +000011312
11313cat >>confdefs.h <<\_ACEOF
Jack Jansen7b8c7542002-04-14 20:12:41 +000011314#define WITH_UNIVERSAL_NEWLINES 1
11315_ACEOF
11316
11317fi
11318echo "$as_me:$LINENO: result: $with_universal_newlines" >&5
11319echo "${ECHO_T}$with_universal_newlines" >&6
11320
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000011321# Check for --with-doc-strings
11322echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
11323echo $ECHO_N "checking for --with-doc-strings... $ECHO_C" >&6
11324
11325# Check whether --with-doc-strings or --without-doc-strings was given.
11326if test "${with_doc_strings+set}" = set; then
11327 withval="$with_doc_strings"
11328
11329fi;
11330
11331if test -z "$with_doc_strings"
11332then with_doc_strings="yes"
11333fi
11334if test "$with_doc_strings" != "no"
11335then
11336
11337cat >>confdefs.h <<\_ACEOF
11338#define WITH_DOC_STRINGS 1
11339_ACEOF
11340
11341fi
11342echo "$as_me:$LINENO: result: $with_doc_strings" >&5
11343echo "${ECHO_T}$with_doc_strings" >&6
11344
Neil Schemenauera35c6882001-02-27 04:45:05 +000011345# Check for Python-specific malloc support
Martin v. Löwis11437992002-04-12 09:54:03 +000011346echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
11347echo $ECHO_N "checking for --with-pymalloc... $ECHO_C" >&6
11348
Neil Schemenauera35c6882001-02-27 04:45:05 +000011349# Check whether --with-pymalloc or --without-pymalloc was given.
11350if test "${with_pymalloc+set}" = set; then
11351 withval="$with_pymalloc"
Michael W. Hudson54241132001-12-07 15:38:26 +000011352
Martin v. Löwis11437992002-04-12 09:54:03 +000011353fi;
Neil Schemenauera35c6882001-02-27 04:45:05 +000011354
Neil Schemenauer16c22972002-03-22 15:34:49 +000011355if test -z "$with_pymalloc"
11356then with_pymalloc="yes"
11357fi
11358if test "$with_pymalloc" != "no"
11359then
Martin v. Löwis11437992002-04-12 09:54:03 +000011360
11361cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011362#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011363_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011364
11365fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011366echo "$as_me:$LINENO: result: $with_pymalloc" >&5
11367echo "${ECHO_T}$with_pymalloc" >&6
Neil Schemenauer16c22972002-03-22 15:34:49 +000011368
Barry Warsawef82cd72000-06-30 16:21:01 +000011369# Check for --with-wctype-functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011370echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
11371echo $ECHO_N "checking for --with-wctype-functions... $ECHO_C" >&6
11372
Barry Warsawef82cd72000-06-30 16:21:01 +000011373# Check whether --with-wctype-functions or --without-wctype-functions was given.
11374if test "${with_wctype_functions+set}" = set; then
11375 withval="$with_wctype_functions"
Martin v. Löwis11437992002-04-12 09:54:03 +000011376
Barry Warsawef82cd72000-06-30 16:21:01 +000011377if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000011378then
11379
11380cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000011381#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011382_ACEOF
11383
11384 echo "$as_me:$LINENO: result: yes" >&5
11385echo "${ECHO_T}yes" >&6
11386else echo "$as_me:$LINENO: result: no" >&5
11387echo "${ECHO_T}no" >&6
Barry Warsawef82cd72000-06-30 16:21:01 +000011388fi
11389else
Martin v. Löwis11437992002-04-12 09:54:03 +000011390 echo "$as_me:$LINENO: result: no" >&5
11391echo "${ECHO_T}no" >&6
11392fi;
Barry Warsawef82cd72000-06-30 16:21:01 +000011393
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011394# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000011395
Guido van Rossum98935bf2001-09-05 19:13:16 +000011396DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000011397
Martin v. Löwis11437992002-04-12 09:54:03 +000011398echo "$as_me:$LINENO: checking for --with-sgi-dl" >&5
11399echo $ECHO_N "checking for --with-sgi-dl... $ECHO_C" >&6
11400
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011401# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011402if test "${with_sgi_dl+set}" = set; then
11403 withval="$with_sgi_dl"
Martin v. Löwis11437992002-04-12 09:54:03 +000011404
11405echo "$as_me:$LINENO: result: $withval" >&5
11406echo "${ECHO_T}$withval" >&6
11407
11408cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011409#define WITH_SGI_DL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011410_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011411
Guido van Rossume97ee181999-12-20 21:27:22 +000011412DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011413dldir=$withval
Guido van Rossum40951012000-10-07 16:21:27 +000011414if test ! -z "$dldir" -a -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011415then LDFLAGS="$LDFLAGS -L$dldir"
Martin v. Löwis11437992002-04-12 09:54:03 +000011416else { { echo "$as_me:$LINENO: error: proper usage is --with-sgi-dl=DIRECTORY" >&5
11417echo "$as_me: error: proper usage is --with-sgi-dl=DIRECTORY" >&2;}
11418 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011419fi
11420DLINCLDIR=${dldir}
11421LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011422else
Martin v. Löwis11437992002-04-12 09:54:03 +000011423 echo "$as_me:$LINENO: result: no" >&5
11424echo "${ECHO_T}no" >&6
11425fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011426
Martin v. Löwis11437992002-04-12 09:54:03 +000011427echo "$as_me:$LINENO: checking for --with-dl-dld" >&5
11428echo $ECHO_N "checking for --with-dl-dld... $ECHO_C" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000011429
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011430# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011431if test "${with_dl_dld+set}" = set; then
11432 withval="$with_dl_dld"
Martin v. Löwis11437992002-04-12 09:54:03 +000011433
11434echo "$as_me:$LINENO: result: $withval" >&5
11435echo "${ECHO_T}$withval" >&6
11436
11437cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011438#define WITH_DL_DLD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011439_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011440
Guido van Rossume97ee181999-12-20 21:27:22 +000011441DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011442dldir=`echo "$withval" | sed 's/,.*//'`
11443dlddir=`echo "$withval" | sed 's/.*,//'`
Barry Warsaw7d1219d2000-10-05 18:45:53 +000011444if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011445then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Martin v. Löwis11437992002-04-12 09:54:03 +000011446else { { echo "$as_me:$LINENO: error: proper usage is --with-dl-dld=DL_DIRECTORY" >&5
11447echo "$as_me: error: proper usage is --with-dl-dld=DL_DIRECTORY" >&2;}
11448 { (exit DLD_DIRECTORY); exit DLD_DIRECTORY; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011449fi
11450DLINCLDIR=${dldir}
11451LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011452else
Martin v. Löwis11437992002-04-12 09:54:03 +000011453 echo "$as_me:$LINENO: result: no" >&5
11454echo "${ECHO_T}no" >&6
11455fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011456
Guido van Rossume97ee181999-12-20 21:27:22 +000011457# the dlopen() function means we might want to use dynload_shlib.o. some
11458# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000011459
Thomas Wouters3a584202000-08-05 23:28:51 +000011460for ac_func in dlopen
11461do
Martin v. Löwis11437992002-04-12 09:54:03 +000011462as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11463echo "$as_me:$LINENO: checking for $ac_func" >&5
11464echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11465if eval "test \"\${$as_ac_var+set}\" = set"; then
11466 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011467else
Martin v. Löwis11437992002-04-12 09:54:03 +000011468 cat >conftest.$ac_ext <<_ACEOF
11469#line $LINENO "configure"
Guido van Rossume97ee181999-12-20 21:27:22 +000011470#include "confdefs.h"
11471/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011472 which can conflict with char $ac_func (); below. */
Guido van Rossume97ee181999-12-20 21:27:22 +000011473#include <assert.h>
11474/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011475#ifdef __cplusplus
11476extern "C"
11477#endif
Guido van Rossume97ee181999-12-20 21:27:22 +000011478/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011479 builtin and then its argument prototype would still apply. */
11480char $ac_func ();
11481char (*f) ();
Guido van Rossume97ee181999-12-20 21:27:22 +000011482
Martin v. Löwis11437992002-04-12 09:54:03 +000011483#ifdef F77_DUMMY_MAIN
11484# ifdef __cplusplus
11485 extern "C"
11486# endif
11487 int F77_DUMMY_MAIN() { return 1; }
11488#endif
11489int
11490main ()
11491{
Guido van Rossume97ee181999-12-20 21:27:22 +000011492/* The GNU C library defines this for functions which it implements
11493 to always fail with ENOSYS. Some functions are actually named
11494 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000011495#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossume97ee181999-12-20 21:27:22 +000011496choke me
11497#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011498f = $ac_func;
Guido van Rossume97ee181999-12-20 21:27:22 +000011499#endif
11500
Martin v. Löwis11437992002-04-12 09:54:03 +000011501 ;
11502 return 0;
11503}
11504_ACEOF
11505rm -f conftest.$ac_objext conftest$ac_exeext
11506if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11507 (eval $ac_link) 2>&5
11508 ac_status=$?
11509 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11510 (exit $ac_status); } &&
11511 { ac_try='test -s conftest$ac_exeext'
11512 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11513 (eval $ac_try) 2>&5
11514 ac_status=$?
11515 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11516 (exit $ac_status); }; }; then
11517 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011518else
Martin v. Löwis11437992002-04-12 09:54:03 +000011519 echo "$as_me: failed program was:" >&5
11520cat conftest.$ac_ext >&5
11521eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011522fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011523rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011524fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011525echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11526echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11527if test `eval echo '${'$as_ac_var'}'` = yes; then
11528 cat >>confdefs.h <<_ACEOF
11529#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11530_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011531
Guido van Rossume97ee181999-12-20 21:27:22 +000011532fi
Thomas Wouters3a584202000-08-05 23:28:51 +000011533done
Guido van Rossume97ee181999-12-20 21:27:22 +000011534
Michael W. Hudson54241132001-12-07 15:38:26 +000011535
Guido van Rossume97ee181999-12-20 21:27:22 +000011536# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
11537# loading of modules.
11538
Martin v. Löwis11437992002-04-12 09:54:03 +000011539echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
11540echo $ECHO_N "checking DYNLOADFILE... $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011541if test -z "$DYNLOADFILE"
11542then
11543 case $ac_sys_system/$ac_sys_release in
11544 AIX*) DYNLOADFILE="dynload_aix.o";;
11545 BeOS*) DYNLOADFILE="dynload_beos.o";;
11546 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Jack Jansene578a632001-08-15 01:27:14 +000011547 Darwin/*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011548 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000011549 *)
11550 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
11551 # out any dynamic loading
11552 if test "$ac_cv_func_dlopen" = yes
11553 then DYNLOADFILE="dynload_shlib.o"
11554 else DYNLOADFILE="dynload_stub.o"
11555 fi
11556 ;;
11557 esac
11558fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011559echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
11560echo "${ECHO_T}$DYNLOADFILE" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011561if test "$DYNLOADFILE" != "dynload_stub.o"
11562then
Martin v. Löwis11437992002-04-12 09:54:03 +000011563
11564cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011565#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011566_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011567
11568fi
11569
Neil Schemenauer4e425612001-06-19 15:44:15 +000011570# MACHDEP_OBJS can be set to platform-specific object files needed by Python
11571
Michael W. Hudson54241132001-12-07 15:38:26 +000011572
Martin v. Löwis11437992002-04-12 09:54:03 +000011573echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
11574echo $ECHO_N "checking MACHDEP_OBJS... $ECHO_C" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011575if test -z "$MACHDEP_OBJS"
11576then
Jack Jansene578a632001-08-15 01:27:14 +000011577 MACHDEP_OBJS=$extra_machdep_objs
11578else
11579 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000011580fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011581echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
11582echo "${ECHO_T}MACHDEP_OBJS" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011583
Guido van Rossum627b2d71993-12-24 10:39:16 +000011584# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011585
11586
11587
11588
11589
11590
11591
11592
11593
11594
11595
11596
11597
11598
11599
11600
11601
11602
11603
11604
11605
11606
11607
11608
11609
11610
11611
11612
11613
11614
11615
11616
11617
11618
11619
11620
11621
11622
11623
11624
11625
11626
11627
11628
11629
11630
11631
11632
11633
11634
11635
11636
11637
11638
11639
11640
11641
11642
11643
11644
11645
11646
11647
11648
11649
11650
11651
11652
11653
11654
11655
11656
11657
Martin v. Löwis06a83e92002-04-14 10:19:44 +000011658
Fred Drake6b3cc522002-04-15 19:20:27 +000011659
Jack Jansen0b06be72002-06-21 14:48:38 +000011660
Martin v. Löwis0cec0ff2002-07-28 16:33:45 +000011661
Martin v. Löwis6aa9fdb2002-09-10 09:16:13 +000011662
Martin v. Löwis244edc82001-10-04 22:44:26 +000011663for ac_func in alarm chown chroot clock confstr ctermid ctermid_r execv \
Fred Drake6b3cc522002-04-15 19:20:27 +000011664 fchdir flock fork fsync fdatasync fpathconf ftime ftruncate \
Martin v. Löwis606edc12002-06-13 21:09:11 +000011665 gai_strerror getgroups getlogin getpeername getpgid getpid getpwent getwd \
Martin v. Löwis0cec0ff2002-07-28 16:33:45 +000011666 hstrerror inet_pton kill killpg lchown link lstat mkfifo mknod mktime \
11667 mremap nice pathconf pause plock poll pthread_init \
Fred Drake35a092f1999-12-13 16:23:35 +000011668 putenv readlink \
Martin v. Löwis61c5edf2001-10-18 04:06:00 +000011669 select setegid seteuid setgid setgroups \
Martin v. Löwis791bfda2001-07-24 06:33:08 +000011670 setlocale setregid setreuid setsid setpgid setuid setvbuf snprintf \
Michael W. Hudson065c1a22002-06-06 13:03:44 +000011671 sigaction siginterrupt sigrelse strftime strptime symlink \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000011672 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Martin v. Löwis6aa9fdb2002-09-10 09:16:13 +000011673 truncate uname unsetenv utimes waitpid _getpty getpriority
Guido van Rossum627b2d71993-12-24 10:39:16 +000011674do
Martin v. Löwis11437992002-04-12 09:54:03 +000011675as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11676echo "$as_me:$LINENO: checking for $ac_func" >&5
11677echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11678if eval "test \"\${$as_ac_var+set}\" = set"; then
11679 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011680else
Martin v. Löwis11437992002-04-12 09:54:03 +000011681 cat >conftest.$ac_ext <<_ACEOF
11682#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000011683#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011684/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011685 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011686#include <assert.h>
11687/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011688#ifdef __cplusplus
11689extern "C"
11690#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011691/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011692 builtin and then its argument prototype would still apply. */
11693char $ac_func ();
11694char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011695
Martin v. Löwis11437992002-04-12 09:54:03 +000011696#ifdef F77_DUMMY_MAIN
11697# ifdef __cplusplus
11698 extern "C"
11699# endif
11700 int F77_DUMMY_MAIN() { return 1; }
11701#endif
11702int
11703main ()
11704{
Guido van Rossum627b2d71993-12-24 10:39:16 +000011705/* The GNU C library defines this for functions which it implements
11706 to always fail with ENOSYS. Some functions are actually named
11707 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011708#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000011709choke me
11710#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011711f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000011712#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011713
Martin v. Löwis11437992002-04-12 09:54:03 +000011714 ;
11715 return 0;
11716}
11717_ACEOF
11718rm -f conftest.$ac_objext conftest$ac_exeext
11719if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11720 (eval $ac_link) 2>&5
11721 ac_status=$?
11722 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11723 (exit $ac_status); } &&
11724 { ac_try='test -s conftest$ac_exeext'
11725 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11726 (eval $ac_try) 2>&5
11727 ac_status=$?
11728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11729 (exit $ac_status); }; }; then
11730 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011731else
Martin v. Löwis11437992002-04-12 09:54:03 +000011732 echo "$as_me: failed program was:" >&5
11733cat conftest.$ac_ext >&5
11734eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011735fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011736rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011737fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011738echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11739echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11740if test `eval echo '${'$as_ac_var'}'` = yes; then
11741 cat >>confdefs.h <<_ACEOF
11742#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11743_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000011744
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011745fi
11746done
11747
Michael W. Hudson54241132001-12-07 15:38:26 +000011748
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011749# check for openpty and forkpty
11750
Martin v. Löwis11437992002-04-12 09:54:03 +000011751
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011752for ac_func in openpty
11753do
Martin v. Löwis11437992002-04-12 09:54:03 +000011754as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11755echo "$as_me:$LINENO: checking for $ac_func" >&5
11756echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11757if eval "test \"\${$as_ac_var+set}\" = set"; then
11758 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011759else
Martin v. Löwis11437992002-04-12 09:54:03 +000011760 cat >conftest.$ac_ext <<_ACEOF
11761#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011762#include "confdefs.h"
11763/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011764 which can conflict with char $ac_func (); below. */
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011765#include <assert.h>
11766/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011767#ifdef __cplusplus
11768extern "C"
11769#endif
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011770/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011771 builtin and then its argument prototype would still apply. */
11772char $ac_func ();
11773char (*f) ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011774
Martin v. Löwis11437992002-04-12 09:54:03 +000011775#ifdef F77_DUMMY_MAIN
11776# ifdef __cplusplus
11777 extern "C"
11778# endif
11779 int F77_DUMMY_MAIN() { return 1; }
11780#endif
11781int
11782main ()
11783{
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011784/* The GNU C library defines this for functions which it implements
11785 to always fail with ENOSYS. Some functions are actually named
11786 something starting with __ and the normal name is an alias. */
11787#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11788choke me
11789#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011790f = $ac_func;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011791#endif
11792
Martin v. Löwis11437992002-04-12 09:54:03 +000011793 ;
11794 return 0;
11795}
11796_ACEOF
11797rm -f conftest.$ac_objext conftest$ac_exeext
11798if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11799 (eval $ac_link) 2>&5
11800 ac_status=$?
11801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11802 (exit $ac_status); } &&
11803 { ac_try='test -s conftest$ac_exeext'
11804 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11805 (eval $ac_try) 2>&5
11806 ac_status=$?
11807 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11808 (exit $ac_status); }; }; then
11809 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011810else
Martin v. Löwis11437992002-04-12 09:54:03 +000011811 echo "$as_me: failed program was:" >&5
11812cat conftest.$ac_ext >&5
11813eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011814fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011815rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011816fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011817echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11818echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11819if test `eval echo '${'$as_ac_var'}'` = yes; then
11820 cat >>confdefs.h <<_ACEOF
11821#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11822_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011823
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011824else
Martin v. Löwis11437992002-04-12 09:54:03 +000011825 echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
11826echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
11827if test "${ac_cv_lib_util_openpty+set}" = set; then
11828 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000011829else
Martin v. Löwis11437992002-04-12 09:54:03 +000011830 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000011831LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011832cat >conftest.$ac_ext <<_ACEOF
11833#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000011834#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000011835
Fred Drake8cef4cf2000-06-28 16:40:38 +000011836/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011837#ifdef __cplusplus
11838extern "C"
11839#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000011840/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011841 builtin and then its argument prototype would still apply. */
11842char openpty ();
11843#ifdef F77_DUMMY_MAIN
11844# ifdef __cplusplus
11845 extern "C"
11846# endif
11847 int F77_DUMMY_MAIN() { return 1; }
11848#endif
11849int
11850main ()
11851{
11852openpty ();
11853 ;
11854 return 0;
11855}
11856_ACEOF
11857rm -f conftest.$ac_objext conftest$ac_exeext
11858if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11859 (eval $ac_link) 2>&5
11860 ac_status=$?
11861 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11862 (exit $ac_status); } &&
11863 { ac_try='test -s conftest$ac_exeext'
11864 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11865 (eval $ac_try) 2>&5
11866 ac_status=$?
11867 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11868 (exit $ac_status); }; }; then
11869 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000011870else
Martin v. Löwis11437992002-04-12 09:54:03 +000011871 echo "$as_me: failed program was:" >&5
11872cat conftest.$ac_ext >&5
11873ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000011874fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011875rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11876LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000011877fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011878echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
11879echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
11880if test $ac_cv_lib_util_openpty = yes; then
11881 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000011882#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011883_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000011884 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000011885fi
11886
11887fi
11888done
11889
Martin v. Löwis11437992002-04-12 09:54:03 +000011890
Fred Drake8cef4cf2000-06-28 16:40:38 +000011891for ac_func in forkpty
11892do
Martin v. Löwis11437992002-04-12 09:54:03 +000011893as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11894echo "$as_me:$LINENO: checking for $ac_func" >&5
11895echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11896if eval "test \"\${$as_ac_var+set}\" = set"; then
11897 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000011898else
Martin v. Löwis11437992002-04-12 09:54:03 +000011899 cat >conftest.$ac_ext <<_ACEOF
11900#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000011901#include "confdefs.h"
11902/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011903 which can conflict with char $ac_func (); below. */
Fred Drake8cef4cf2000-06-28 16:40:38 +000011904#include <assert.h>
11905/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011906#ifdef __cplusplus
11907extern "C"
11908#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000011909/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011910 builtin and then its argument prototype would still apply. */
11911char $ac_func ();
11912char (*f) ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000011913
Martin v. Löwis11437992002-04-12 09:54:03 +000011914#ifdef F77_DUMMY_MAIN
11915# ifdef __cplusplus
11916 extern "C"
11917# endif
11918 int F77_DUMMY_MAIN() { return 1; }
11919#endif
11920int
11921main ()
11922{
Fred Drake8cef4cf2000-06-28 16:40:38 +000011923/* The GNU C library defines this for functions which it implements
11924 to always fail with ENOSYS. Some functions are actually named
11925 something starting with __ and the normal name is an alias. */
11926#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11927choke me
11928#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011929f = $ac_func;
Fred Drake8cef4cf2000-06-28 16:40:38 +000011930#endif
11931
Martin v. Löwis11437992002-04-12 09:54:03 +000011932 ;
11933 return 0;
11934}
11935_ACEOF
11936rm -f conftest.$ac_objext conftest$ac_exeext
11937if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11938 (eval $ac_link) 2>&5
11939 ac_status=$?
11940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11941 (exit $ac_status); } &&
11942 { ac_try='test -s conftest$ac_exeext'
11943 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11944 (eval $ac_try) 2>&5
11945 ac_status=$?
11946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11947 (exit $ac_status); }; }; then
11948 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011949else
Martin v. Löwis11437992002-04-12 09:54:03 +000011950 echo "$as_me: failed program was:" >&5
11951cat conftest.$ac_ext >&5
11952eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011953fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011954rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011955fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011956echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11957echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11958if test `eval echo '${'$as_ac_var'}'` = yes; then
11959 cat >>confdefs.h <<_ACEOF
11960#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11961_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000011962
Fred Drake8cef4cf2000-06-28 16:40:38 +000011963else
Martin v. Löwis11437992002-04-12 09:54:03 +000011964 echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
11965echo $ECHO_N "checking for forkpty in -lutil... $ECHO_C" >&6
11966if test "${ac_cv_lib_util_forkpty+set}" = set; then
11967 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000011968else
Martin v. Löwis11437992002-04-12 09:54:03 +000011969 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000011970LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011971cat >conftest.$ac_ext <<_ACEOF
11972#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000011973#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000011974
Fred Drake8cef4cf2000-06-28 16:40:38 +000011975/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011976#ifdef __cplusplus
11977extern "C"
11978#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000011979/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011980 builtin and then its argument prototype would still apply. */
11981char forkpty ();
11982#ifdef F77_DUMMY_MAIN
11983# ifdef __cplusplus
11984 extern "C"
11985# endif
11986 int F77_DUMMY_MAIN() { return 1; }
11987#endif
11988int
11989main ()
11990{
11991forkpty ();
11992 ;
11993 return 0;
11994}
11995_ACEOF
11996rm -f conftest.$ac_objext conftest$ac_exeext
11997if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11998 (eval $ac_link) 2>&5
11999 ac_status=$?
12000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12001 (exit $ac_status); } &&
12002 { ac_try='test -s conftest$ac_exeext'
12003 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12004 (eval $ac_try) 2>&5
12005 ac_status=$?
12006 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12007 (exit $ac_status); }; }; then
12008 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012009else
Martin v. Löwis11437992002-04-12 09:54:03 +000012010 echo "$as_me: failed program was:" >&5
12011cat conftest.$ac_ext >&5
12012ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012013fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012014rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12015LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012016fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012017echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
12018echo "${ECHO_T}$ac_cv_lib_util_forkpty" >&6
12019if test $ac_cv_lib_util_forkpty = yes; then
12020 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012021#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012022_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012023 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012024fi
12025
12026fi
12027done
12028
Jack Jansendd19cf82001-12-06 22:36:17 +000012029
Michael W. Hudson54241132001-12-07 15:38:26 +000012030# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000012031
12032
12033
12034
12035
12036
Fred Drake8cef4cf2000-06-28 16:40:38 +000012037for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
12038do
Martin v. Löwis11437992002-04-12 09:54:03 +000012039as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12040echo "$as_me:$LINENO: checking for $ac_func" >&5
12041echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12042if eval "test \"\${$as_ac_var+set}\" = set"; then
12043 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012044else
Martin v. Löwis11437992002-04-12 09:54:03 +000012045 cat >conftest.$ac_ext <<_ACEOF
12046#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012047#include "confdefs.h"
12048/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012049 which can conflict with char $ac_func (); below. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012050#include <assert.h>
12051/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012052#ifdef __cplusplus
12053extern "C"
12054#endif
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012055/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012056 builtin and then its argument prototype would still apply. */
12057char $ac_func ();
12058char (*f) ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012059
Martin v. Löwis11437992002-04-12 09:54:03 +000012060#ifdef F77_DUMMY_MAIN
12061# ifdef __cplusplus
12062 extern "C"
12063# endif
12064 int F77_DUMMY_MAIN() { return 1; }
12065#endif
12066int
12067main ()
12068{
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012069/* The GNU C library defines this for functions which it implements
12070 to always fail with ENOSYS. Some functions are actually named
12071 something starting with __ and the normal name is an alias. */
12072#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12073choke me
12074#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012075f = $ac_func;
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012076#endif
12077
Martin v. Löwis11437992002-04-12 09:54:03 +000012078 ;
12079 return 0;
12080}
12081_ACEOF
12082rm -f conftest.$ac_objext conftest$ac_exeext
12083if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12084 (eval $ac_link) 2>&5
12085 ac_status=$?
12086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12087 (exit $ac_status); } &&
12088 { ac_try='test -s conftest$ac_exeext'
12089 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12090 (eval $ac_try) 2>&5
12091 ac_status=$?
12092 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12093 (exit $ac_status); }; }; then
12094 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012095else
Martin v. Löwis11437992002-04-12 09:54:03 +000012096 echo "$as_me: failed program was:" >&5
12097cat conftest.$ac_ext >&5
12098eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012099fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012100rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012101fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012102echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12103echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12104if test `eval echo '${'$as_ac_var'}'` = yes; then
12105 cat >>confdefs.h <<_ACEOF
12106#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12107_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000012108
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012109fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000012110done
12111
Michael W. Hudson54241132001-12-07 15:38:26 +000012112
Martin v. Löwis11437992002-04-12 09:54:03 +000012113
12114
12115
12116
12117
Martin v. Löwis1142de32002-03-29 16:28:31 +000012118for ac_func in dup2 getcwd strdup strerror memmove
Thomas Wouters3a584202000-08-05 23:28:51 +000012119do
Martin v. Löwis11437992002-04-12 09:54:03 +000012120as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12121echo "$as_me:$LINENO: checking for $ac_func" >&5
12122echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12123if eval "test \"\${$as_ac_var+set}\" = set"; then
12124 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012125else
Martin v. Löwis11437992002-04-12 09:54:03 +000012126 cat >conftest.$ac_ext <<_ACEOF
12127#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012128#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012129/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012130 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012131#include <assert.h>
12132/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012133#ifdef __cplusplus
12134extern "C"
12135#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012136/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012137 builtin and then its argument prototype would still apply. */
12138char $ac_func ();
12139char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012140
Martin v. Löwis11437992002-04-12 09:54:03 +000012141#ifdef F77_DUMMY_MAIN
12142# ifdef __cplusplus
12143 extern "C"
12144# endif
12145 int F77_DUMMY_MAIN() { return 1; }
12146#endif
12147int
12148main ()
12149{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012150/* The GNU C library defines this for functions which it implements
12151 to always fail with ENOSYS. Some functions are actually named
12152 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012153#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012154choke me
12155#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012156f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012157#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012158
Martin v. Löwis11437992002-04-12 09:54:03 +000012159 ;
12160 return 0;
12161}
12162_ACEOF
12163rm -f conftest.$ac_objext conftest$ac_exeext
12164if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12165 (eval $ac_link) 2>&5
12166 ac_status=$?
12167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12168 (exit $ac_status); } &&
12169 { ac_try='test -s conftest$ac_exeext'
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 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012176else
Martin v. Löwis11437992002-04-12 09:54:03 +000012177 echo "$as_me: failed program was:" >&5
12178cat conftest.$ac_ext >&5
12179eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012180fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012181rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000012182fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012183echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12184echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12185if test `eval echo '${'$as_ac_var'}'` = yes; then
12186 cat >>confdefs.h <<_ACEOF
12187#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12188_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000012189
Martin v. Löwis1142de32002-03-29 16:28:31 +000012190else
Martin v. Löwis11437992002-04-12 09:54:03 +000012191 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012192fi
12193done
12194
12195
Martin v. Löwis11437992002-04-12 09:54:03 +000012196
Martin v. Löwis1142de32002-03-29 16:28:31 +000012197for ac_func in getpgrp
12198do
Martin v. Löwis11437992002-04-12 09:54:03 +000012199as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12200echo "$as_me:$LINENO: checking for $ac_func" >&5
12201echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12202if eval "test \"\${$as_ac_var+set}\" = set"; then
12203 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000012204else
Martin v. Löwis11437992002-04-12 09:54:03 +000012205 cat >conftest.$ac_ext <<_ACEOF
12206#line $LINENO "configure"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012207#include "confdefs.h"
12208/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012209 which can conflict with char $ac_func (); below. */
Martin v. Löwis1142de32002-03-29 16:28:31 +000012210#include <assert.h>
12211/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012212#ifdef __cplusplus
12213extern "C"
12214#endif
Martin v. Löwis1142de32002-03-29 16:28:31 +000012215/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012216 builtin and then its argument prototype would still apply. */
12217char $ac_func ();
12218char (*f) ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000012219
Martin v. Löwis11437992002-04-12 09:54:03 +000012220#ifdef F77_DUMMY_MAIN
12221# ifdef __cplusplus
12222 extern "C"
12223# endif
12224 int F77_DUMMY_MAIN() { return 1; }
12225#endif
12226int
12227main ()
12228{
Martin v. Löwis1142de32002-03-29 16:28:31 +000012229/* The GNU C library defines this for functions which it implements
12230 to always fail with ENOSYS. Some functions are actually named
12231 something starting with __ and the normal name is an alias. */
12232#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12233choke me
12234#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012235f = $ac_func;
Martin v. Löwis1142de32002-03-29 16:28:31 +000012236#endif
12237
Martin v. Löwis11437992002-04-12 09:54:03 +000012238 ;
12239 return 0;
12240}
12241_ACEOF
12242rm -f conftest.$ac_objext conftest$ac_exeext
12243if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12244 (eval $ac_link) 2>&5
12245 ac_status=$?
12246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12247 (exit $ac_status); } &&
12248 { ac_try='test -s conftest$ac_exeext'
12249 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12250 (eval $ac_try) 2>&5
12251 ac_status=$?
12252 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12253 (exit $ac_status); }; }; then
12254 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012255else
Martin v. Löwis11437992002-04-12 09:54:03 +000012256 echo "$as_me: failed program was:" >&5
12257cat conftest.$ac_ext >&5
12258eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012259fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012260rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012261fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012262echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12263echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12264if test `eval echo '${'$as_ac_var'}'` = yes; then
12265 cat >>confdefs.h <<_ACEOF
12266#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12267_ACEOF
12268 cat >conftest.$ac_ext <<_ACEOF
12269#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012270#include "confdefs.h"
12271#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012272#ifdef F77_DUMMY_MAIN
12273# ifdef __cplusplus
12274 extern "C"
12275# endif
12276 int F77_DUMMY_MAIN() { return 1; }
12277#endif
12278int
12279main ()
12280{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012281getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000012282 ;
12283 return 0;
12284}
12285_ACEOF
12286rm -f conftest.$ac_objext
12287if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12288 (eval $ac_compile) 2>&5
12289 ac_status=$?
12290 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12291 (exit $ac_status); } &&
12292 { ac_try='test -s conftest.$ac_objext'
12293 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12294 (eval $ac_try) 2>&5
12295 ac_status=$?
12296 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12297 (exit $ac_status); }; }; then
12298
12299cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012300#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012301_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012302
Martin v. Löwis11437992002-04-12 09:54:03 +000012303
Guido van Rossumf78abae1997-01-21 22:02:36 +000012304else
Martin v. Löwis11437992002-04-12 09:54:03 +000012305 echo "$as_me: failed program was:" >&5
12306cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000012307fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012308rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000012309
Guido van Rossum627b2d71993-12-24 10:39:16 +000012310fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012311done
Guido van Rossum627b2d71993-12-24 10:39:16 +000012312
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012313echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
12314echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
12315if test "${ac_cv_func_setpgrp_void+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012316 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012317else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012318 if test "$cross_compiling" = yes; then
12319 { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5
12320echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;}
12321 { (exit 1); exit 1; }; }
12322else
Martin v. Löwis11437992002-04-12 09:54:03 +000012323 cat >conftest.$ac_ext <<_ACEOF
12324#line $LINENO "configure"
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012325#include "confdefs.h"
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012326#if HAVE_UNISTD_H
12327# include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012328#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012329
Martin v. Löwis11437992002-04-12 09:54:03 +000012330#ifdef F77_DUMMY_MAIN
12331# ifdef __cplusplus
12332 extern "C"
12333# endif
12334 int F77_DUMMY_MAIN() { return 1; }
12335#endif
12336int
12337main ()
12338{
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012339/* If this system has a BSD-style setpgrp which takes arguments,
12340 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
12341 exit successfully. */
12342 exit (setpgrp (1,1) == -1 ? 0 : 1);
Martin v. Löwis11437992002-04-12 09:54:03 +000012343 ;
12344 return 0;
12345}
12346_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012347rm -f conftest$ac_exeext
Martin v. Löwis11437992002-04-12 09:54:03 +000012348if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12349 (eval $ac_link) 2>&5
12350 ac_status=$?
12351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012352 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwis11437992002-04-12 09:54:03 +000012353 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12354 (eval $ac_try) 2>&5
12355 ac_status=$?
12356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12357 (exit $ac_status); }; }; then
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012358 ac_cv_func_setpgrp_void=no
Michael W. Hudson54241132001-12-07 15:38:26 +000012359else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012360 echo "$as_me: program exited with status $ac_status" >&5
12361echo "$as_me: failed program was:" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012362cat conftest.$ac_ext >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012363( exit $ac_status )
12364ac_cv_func_setpgrp_void=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000012365fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012366rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012367fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012368fi
12369echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
12370echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
12371if test $ac_cv_func_setpgrp_void = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012372
12373cat >>confdefs.h <<\_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012374#define SETPGRP_VOID 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012375_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012376
12377fi
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012378
Martin v. Löwis11437992002-04-12 09:54:03 +000012379
Thomas Wouters3a584202000-08-05 23:28:51 +000012380for ac_func in gettimeofday
12381do
Martin v. Löwis11437992002-04-12 09:54:03 +000012382as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12383echo "$as_me:$LINENO: checking for $ac_func" >&5
12384echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12385if eval "test \"\${$as_ac_var+set}\" = set"; then
12386 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012387else
Martin v. Löwis11437992002-04-12 09:54:03 +000012388 cat >conftest.$ac_ext <<_ACEOF
12389#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012390#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012391/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012392 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012393#include <assert.h>
12394/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012395#ifdef __cplusplus
12396extern "C"
12397#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012398/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012399 builtin and then its argument prototype would still apply. */
12400char $ac_func ();
12401char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012402
Martin v. Löwis11437992002-04-12 09:54:03 +000012403#ifdef F77_DUMMY_MAIN
12404# ifdef __cplusplus
12405 extern "C"
12406# endif
12407 int F77_DUMMY_MAIN() { return 1; }
12408#endif
12409int
12410main ()
12411{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012412/* The GNU C library defines this for functions which it implements
12413 to always fail with ENOSYS. Some functions are actually named
12414 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012415#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012416choke me
12417#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012418f = $ac_func;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012419#endif
12420
Martin v. Löwis11437992002-04-12 09:54:03 +000012421 ;
12422 return 0;
12423}
12424_ACEOF
12425rm -f conftest.$ac_objext conftest$ac_exeext
12426if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12427 (eval $ac_link) 2>&5
12428 ac_status=$?
12429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12430 (exit $ac_status); } &&
12431 { ac_try='test -s conftest$ac_exeext'
12432 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12433 (eval $ac_try) 2>&5
12434 ac_status=$?
12435 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12436 (exit $ac_status); }; }; then
12437 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012438else
Martin v. Löwis11437992002-04-12 09:54:03 +000012439 echo "$as_me: failed program was:" >&5
12440cat conftest.$ac_ext >&5
12441eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012442fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012443rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012444fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012445echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12446echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12447if test `eval echo '${'$as_ac_var'}'` = yes; then
12448 cat >>confdefs.h <<_ACEOF
12449#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12450_ACEOF
12451 cat >conftest.$ac_ext <<_ACEOF
12452#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012453#include "confdefs.h"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012454#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012455#ifdef F77_DUMMY_MAIN
12456# ifdef __cplusplus
12457 extern "C"
12458# endif
12459 int F77_DUMMY_MAIN() { return 1; }
12460#endif
12461int
12462main ()
12463{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012464gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000012465 ;
12466 return 0;
12467}
12468_ACEOF
12469rm -f conftest.$ac_objext
12470if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12471 (eval $ac_compile) 2>&5
12472 ac_status=$?
12473 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12474 (exit $ac_status); } &&
12475 { ac_try='test -s conftest.$ac_objext'
12476 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12477 (eval $ac_try) 2>&5
12478 ac_status=$?
12479 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12480 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000012481 :
12482else
Martin v. Löwis11437992002-04-12 09:54:03 +000012483 echo "$as_me: failed program was:" >&5
12484cat conftest.$ac_ext >&5
12485
12486cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012487#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012488_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012489
Martin v. Löwis11437992002-04-12 09:54:03 +000012490
Guido van Rossum627b2d71993-12-24 10:39:16 +000012491fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012492rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000012493
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012494fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012495done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012496
Michael W. Hudson54241132001-12-07 15:38:26 +000012497
12498
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012499# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000012500# for [no]getaddrinfo in netdb.h.
12501echo "$as_me:$LINENO: checking for getaddrinfo" >&5
12502echo $ECHO_N "checking for getaddrinfo... $ECHO_C" >&6
12503cat >conftest.$ac_ext <<_ACEOF
12504#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012505#include "confdefs.h"
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012506
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000012507#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012508#include <sys/socket.h>
12509#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000012510#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012511
Martin v. Löwis11437992002-04-12 09:54:03 +000012512#ifdef F77_DUMMY_MAIN
12513# ifdef __cplusplus
12514 extern "C"
12515# endif
12516 int F77_DUMMY_MAIN() { return 1; }
12517#endif
12518int
12519main ()
12520{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012521
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012522getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012523
Martin v. Löwis11437992002-04-12 09:54:03 +000012524 ;
12525 return 0;
12526}
12527_ACEOF
12528rm -f conftest.$ac_objext conftest$ac_exeext
12529if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12530 (eval $ac_link) 2>&5
12531 ac_status=$?
12532 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12533 (exit $ac_status); } &&
12534 { ac_try='test -s conftest$ac_exeext'
12535 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12536 (eval $ac_try) 2>&5
12537 ac_status=$?
12538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12539 (exit $ac_status); }; }; then
12540
12541echo "$as_me:$LINENO: result: yes" >&5
12542echo "${ECHO_T}yes" >&6
12543echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
12544echo $ECHO_N "checking getaddrinfo bug... $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012545if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012546 echo "$as_me:$LINENO: result: buggy" >&5
12547echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012548buggygetaddrinfo=yes
12549else
Martin v. Löwis11437992002-04-12 09:54:03 +000012550 cat >conftest.$ac_ext <<_ACEOF
12551#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012552#include "confdefs.h"
12553
12554#include <sys/types.h>
12555#include <netdb.h>
12556#include <string.h>
12557#include <sys/socket.h>
12558#include <netinet/in.h>
12559
12560main()
12561{
12562 int passive, gaierr, inet4 = 0, inet6 = 0;
12563 struct addrinfo hints, *ai, *aitop;
12564 char straddr[INET6_ADDRSTRLEN], strport[16];
12565
12566 for (passive = 0; passive <= 1; passive++) {
12567 memset(&hints, 0, sizeof(hints));
12568 hints.ai_family = AF_UNSPEC;
12569 hints.ai_flags = passive ? AI_PASSIVE : 0;
12570 hints.ai_socktype = SOCK_STREAM;
12571 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
12572 (void)gai_strerror(gaierr);
12573 goto bad;
12574 }
12575 for (ai = aitop; ai; ai = ai->ai_next) {
12576 if (ai->ai_addr == NULL ||
12577 ai->ai_addrlen == 0 ||
12578 getnameinfo(ai->ai_addr, ai->ai_addrlen,
12579 straddr, sizeof(straddr), strport, sizeof(strport),
12580 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
12581 goto bad;
12582 }
12583 switch (ai->ai_family) {
12584 case AF_INET:
12585 if (strcmp(strport, "54321") != 0) {
12586 goto bad;
12587 }
12588 if (passive) {
12589 if (strcmp(straddr, "0.0.0.0") != 0) {
12590 goto bad;
12591 }
12592 } else {
12593 if (strcmp(straddr, "127.0.0.1") != 0) {
12594 goto bad;
12595 }
12596 }
12597 inet4++;
12598 break;
12599 case AF_INET6:
12600 if (strcmp(strport, "54321") != 0) {
12601 goto bad;
12602 }
12603 if (passive) {
12604 if (strcmp(straddr, "::") != 0) {
12605 goto bad;
12606 }
12607 } else {
12608 if (strcmp(straddr, "::1") != 0) {
12609 goto bad;
12610 }
12611 }
12612 inet6++;
12613 break;
12614 case AF_UNSPEC:
12615 goto bad;
12616 break;
12617 default:
12618 /* another family support? */
12619 break;
12620 }
12621 }
12622 }
12623
12624 if (!(inet4 == 0 || inet4 == 2))
12625 goto bad;
12626 if (!(inet6 == 0 || inet6 == 2))
12627 goto bad;
12628
12629 if (aitop)
12630 freeaddrinfo(aitop);
12631 exit(0);
12632
12633 bad:
12634 if (aitop)
12635 freeaddrinfo(aitop);
12636 exit(1);
12637}
12638
Martin v. Löwis11437992002-04-12 09:54:03 +000012639_ACEOF
12640rm -f conftest$ac_exeext
12641if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12642 (eval $ac_link) 2>&5
12643 ac_status=$?
12644 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12645 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12646 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12647 (eval $ac_try) 2>&5
12648 ac_status=$?
12649 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12650 (exit $ac_status); }; }; then
12651 echo "$as_me:$LINENO: result: good" >&5
12652echo "${ECHO_T}good" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012653buggygetaddrinfo=no
12654else
Martin v. Löwis11437992002-04-12 09:54:03 +000012655 echo "$as_me: program exited with status $ac_status" >&5
12656echo "$as_me: failed program was:" >&5
12657cat conftest.$ac_ext >&5
12658( exit $ac_status )
12659echo "$as_me:$LINENO: result: buggy" >&5
12660echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012661buggygetaddrinfo=yes
12662fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012663rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012664fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012665else
Martin v. Löwis11437992002-04-12 09:54:03 +000012666 echo "$as_me: failed program was:" >&5
12667cat conftest.$ac_ext >&5
12668
12669echo "$as_me:$LINENO: result: no" >&5
12670echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012671buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012672
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012673fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012674rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012675
12676if test "$buggygetaddrinfo" = "yes"; then
12677 if test "$ipv6" = "yes"; then
12678 echo 'Fatal: You must get working getaddrinfo() function.'
12679 echo ' or you can specify "--disable-ipv6"'.
12680 exit 1
12681 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012682else
Martin v. Löwis11437992002-04-12 09:54:03 +000012683
12684cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012685#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012686_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000012687
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012688fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012689
Jack Jansen9a66b6d2001-08-08 13:56:14 +000012690for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012691do
Martin v. Löwis11437992002-04-12 09:54:03 +000012692as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12693echo "$as_me:$LINENO: checking for $ac_func" >&5
12694echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12695if eval "test \"\${$as_ac_var+set}\" = set"; then
12696 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012697else
Martin v. Löwis11437992002-04-12 09:54:03 +000012698 cat >conftest.$ac_ext <<_ACEOF
12699#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012700#include "confdefs.h"
12701/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012702 which can conflict with char $ac_func (); below. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012703#include <assert.h>
12704/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012705#ifdef __cplusplus
12706extern "C"
12707#endif
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012708/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012709 builtin and then its argument prototype would still apply. */
12710char $ac_func ();
12711char (*f) ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012712
Martin v. Löwis11437992002-04-12 09:54:03 +000012713#ifdef F77_DUMMY_MAIN
12714# ifdef __cplusplus
12715 extern "C"
12716# endif
12717 int F77_DUMMY_MAIN() { return 1; }
12718#endif
12719int
12720main ()
12721{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012722/* The GNU C library defines this for functions which it implements
12723 to always fail with ENOSYS. Some functions are actually named
12724 something starting with __ and the normal name is an alias. */
12725#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12726choke me
12727#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012728f = $ac_func;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012729#endif
12730
Martin v. Löwis11437992002-04-12 09:54:03 +000012731 ;
12732 return 0;
12733}
12734_ACEOF
12735rm -f conftest.$ac_objext conftest$ac_exeext
12736if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12737 (eval $ac_link) 2>&5
12738 ac_status=$?
12739 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12740 (exit $ac_status); } &&
12741 { ac_try='test -s conftest$ac_exeext'
12742 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12743 (eval $ac_try) 2>&5
12744 ac_status=$?
12745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12746 (exit $ac_status); }; }; then
12747 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012748else
Martin v. Löwis11437992002-04-12 09:54:03 +000012749 echo "$as_me: failed program was:" >&5
12750cat conftest.$ac_ext >&5
12751eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012752fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012753rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012754fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012755echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12756echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12757if test `eval echo '${'$as_ac_var'}'` = yes; then
12758 cat >>confdefs.h <<_ACEOF
12759#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12760_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012761
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000012762fi
12763done
12764
Michael W. Hudson54241132001-12-07 15:38:26 +000012765
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012766# checks for structures
Martin v. Löwis11437992002-04-12 09:54:03 +000012767echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
12768echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
12769if test "${ac_cv_header_time+set}" = set; then
12770 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012771else
Martin v. Löwis11437992002-04-12 09:54:03 +000012772 cat >conftest.$ac_ext <<_ACEOF
12773#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012774#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012775#include <sys/types.h>
12776#include <sys/time.h>
12777#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012778
12779#ifdef F77_DUMMY_MAIN
12780# ifdef __cplusplus
12781 extern "C"
12782# endif
12783 int F77_DUMMY_MAIN() { return 1; }
12784#endif
12785int
12786main ()
12787{
12788if ((struct tm *) 0)
12789return 0;
12790 ;
12791 return 0;
12792}
12793_ACEOF
12794rm -f conftest.$ac_objext
12795if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12796 (eval $ac_compile) 2>&5
12797 ac_status=$?
12798 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12799 (exit $ac_status); } &&
12800 { ac_try='test -s conftest.$ac_objext'
12801 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12802 (eval $ac_try) 2>&5
12803 ac_status=$?
12804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12805 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012806 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000012807else
Martin v. Löwis11437992002-04-12 09:54:03 +000012808 echo "$as_me: failed program was:" >&5
12809cat conftest.$ac_ext >&5
12810ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000012811fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012812rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012813fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012814echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
12815echo "${ECHO_T}$ac_cv_header_time" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000012816if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012817
12818cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012819#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012820_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012821
12822fi
12823
Martin v. Löwis11437992002-04-12 09:54:03 +000012824echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
12825echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
12826if test "${ac_cv_struct_tm+set}" = set; then
12827 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012828else
Martin v. Löwis11437992002-04-12 09:54:03 +000012829 cat >conftest.$ac_ext <<_ACEOF
12830#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012831#include "confdefs.h"
12832#include <sys/types.h>
12833#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012834
12835#ifdef F77_DUMMY_MAIN
12836# ifdef __cplusplus
12837 extern "C"
12838# endif
12839 int F77_DUMMY_MAIN() { return 1; }
12840#endif
12841int
12842main ()
12843{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012844struct tm *tp; tp->tm_sec;
Martin v. Löwis11437992002-04-12 09:54:03 +000012845 ;
12846 return 0;
12847}
12848_ACEOF
12849rm -f conftest.$ac_objext
12850if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12851 (eval $ac_compile) 2>&5
12852 ac_status=$?
12853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12854 (exit $ac_status); } &&
12855 { ac_try='test -s conftest.$ac_objext'
12856 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12857 (eval $ac_try) 2>&5
12858 ac_status=$?
12859 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12860 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012861 ac_cv_struct_tm=time.h
12862else
Martin v. Löwis11437992002-04-12 09:54:03 +000012863 echo "$as_me: failed program was:" >&5
12864cat conftest.$ac_ext >&5
12865ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012866fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012867rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012868fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012869echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
12870echo "${ECHO_T}$ac_cv_struct_tm" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000012871if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012872
12873cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012874#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012875_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012876
12877fi
12878
Martin v. Löwis11437992002-04-12 09:54:03 +000012879echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
12880echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
12881if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
12882 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012883else
Martin v. Löwis11437992002-04-12 09:54:03 +000012884 cat >conftest.$ac_ext <<_ACEOF
12885#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012886#include "confdefs.h"
12887#include <sys/types.h>
12888#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000012889
12890
12891#ifdef F77_DUMMY_MAIN
12892# ifdef __cplusplus
12893 extern "C"
12894# endif
12895 int F77_DUMMY_MAIN() { return 1; }
12896#endif
12897int
12898main ()
12899{
12900static struct tm ac_aggr;
12901if (ac_aggr.tm_zone)
12902return 0;
12903 ;
12904 return 0;
12905}
12906_ACEOF
12907rm -f conftest.$ac_objext
12908if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12909 (eval $ac_compile) 2>&5
12910 ac_status=$?
12911 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12912 (exit $ac_status); } &&
12913 { ac_try='test -s conftest.$ac_objext'
12914 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12915 (eval $ac_try) 2>&5
12916 ac_status=$?
12917 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12918 (exit $ac_status); }; }; then
12919 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000012920else
Martin v. Löwis11437992002-04-12 09:54:03 +000012921 echo "$as_me: failed program was:" >&5
12922cat conftest.$ac_ext >&5
12923ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000012924fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012925rm -f conftest.$ac_objext conftest.$ac_ext
12926fi
12927echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
12928echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
12929if test $ac_cv_member_struct_tm_tm_zone = yes; then
12930
12931cat >>confdefs.h <<_ACEOF
12932#define HAVE_STRUCT_TM_TM_ZONE 1
12933_ACEOF
12934
12935
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012936fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012937
Martin v. Löwis11437992002-04-12 09:54:03 +000012938if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
12939
12940cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012941#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012942_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012943
12944else
Martin v. Löwis11437992002-04-12 09:54:03 +000012945 echo "$as_me:$LINENO: checking for tzname" >&5
12946echo $ECHO_N "checking for tzname... $ECHO_C" >&6
12947if test "${ac_cv_var_tzname+set}" = set; then
12948 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012949else
Martin v. Löwis11437992002-04-12 09:54:03 +000012950 cat >conftest.$ac_ext <<_ACEOF
12951#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012952#include "confdefs.h"
12953#include <time.h>
12954#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012955extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000012956#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000012957
12958#ifdef F77_DUMMY_MAIN
12959# ifdef __cplusplus
12960 extern "C"
12961# endif
12962 int F77_DUMMY_MAIN() { return 1; }
12963#endif
12964int
12965main ()
12966{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012967atoi(*tzname);
Martin v. Löwis11437992002-04-12 09:54:03 +000012968 ;
12969 return 0;
12970}
12971_ACEOF
12972rm -f conftest.$ac_objext conftest$ac_exeext
12973if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12974 (eval $ac_link) 2>&5
12975 ac_status=$?
12976 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12977 (exit $ac_status); } &&
12978 { ac_try='test -s conftest$ac_exeext'
12979 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12980 (eval $ac_try) 2>&5
12981 ac_status=$?
12982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12983 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012984 ac_cv_var_tzname=yes
12985else
Martin v. Löwis11437992002-04-12 09:54:03 +000012986 echo "$as_me: failed program was:" >&5
12987cat conftest.$ac_ext >&5
12988ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000012989fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012990rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000012991fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012992echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
12993echo "${ECHO_T}$ac_cv_var_tzname" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000012994 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012995
12996cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012997#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012998_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012999
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013000 fi
13001fi
13002
Jack Jansendd19cf82001-12-06 22:36:17 +000013003
Martin v. Löwis11437992002-04-12 09:54:03 +000013004echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
13005echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6
13006if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
13007 echo $ECHO_N "(cached) $ECHO_C" >&6
13008else
13009 cat >conftest.$ac_ext <<_ACEOF
13010#line $LINENO "configure"
13011#include "confdefs.h"
13012$ac_includes_default
13013#ifdef F77_DUMMY_MAIN
13014# ifdef __cplusplus
13015 extern "C"
13016# endif
13017 int F77_DUMMY_MAIN() { return 1; }
13018#endif
13019int
13020main ()
13021{
13022static struct stat ac_aggr;
13023if (ac_aggr.st_rdev)
13024return 0;
13025 ;
13026 return 0;
13027}
13028_ACEOF
13029rm -f conftest.$ac_objext
13030if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13031 (eval $ac_compile) 2>&5
13032 ac_status=$?
13033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13034 (exit $ac_status); } &&
13035 { ac_try='test -s conftest.$ac_objext'
13036 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13037 (eval $ac_try) 2>&5
13038 ac_status=$?
13039 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13040 (exit $ac_status); }; }; then
13041 ac_cv_member_struct_stat_st_rdev=yes
13042else
13043 echo "$as_me: failed program was:" >&5
13044cat conftest.$ac_ext >&5
13045ac_cv_member_struct_stat_st_rdev=no
13046fi
13047rm -f conftest.$ac_objext conftest.$ac_ext
13048fi
13049echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
13050echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6
13051if test $ac_cv_member_struct_stat_st_rdev = yes; then
13052
13053cat >>confdefs.h <<_ACEOF
13054#define HAVE_STRUCT_STAT_ST_RDEV 1
13055_ACEOF
13056
13057
13058cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013059#define HAVE_ST_RDEV 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013060_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013061
13062fi
13063
Martin v. Löwis11437992002-04-12 09:54:03 +000013064
13065
13066echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
13067echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
13068if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
13069 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013070else
Martin v. Löwis11437992002-04-12 09:54:03 +000013071 cat >conftest.$ac_ext <<_ACEOF
13072#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013073#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013074$ac_includes_default
13075#ifdef F77_DUMMY_MAIN
13076# ifdef __cplusplus
13077 extern "C"
13078# endif
13079 int F77_DUMMY_MAIN() { return 1; }
13080#endif
13081int
13082main ()
13083{
13084static struct stat ac_aggr;
13085if (ac_aggr.st_blksize)
13086return 0;
13087 ;
13088 return 0;
13089}
13090_ACEOF
13091rm -f conftest.$ac_objext
13092if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13093 (eval $ac_compile) 2>&5
13094 ac_status=$?
13095 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13096 (exit $ac_status); } &&
13097 { ac_try='test -s conftest.$ac_objext'
13098 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13099 (eval $ac_try) 2>&5
13100 ac_status=$?
13101 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13102 (exit $ac_status); }; }; then
13103 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013104else
Martin v. Löwis11437992002-04-12 09:54:03 +000013105 echo "$as_me: failed program was:" >&5
13106cat conftest.$ac_ext >&5
13107ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013108fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013109rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013110fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013111echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
13112echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
13113if test $ac_cv_member_struct_stat_st_blksize = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013114
Martin v. Löwis11437992002-04-12 09:54:03 +000013115cat >>confdefs.h <<_ACEOF
13116#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13117_ACEOF
13118
13119
13120cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013121#define HAVE_ST_BLKSIZE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013122_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013123
13124fi
13125
Martin v. Löwis11437992002-04-12 09:54:03 +000013126
13127echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
13128echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6
13129if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
13130 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013131else
Martin v. Löwis11437992002-04-12 09:54:03 +000013132 cat >conftest.$ac_ext <<_ACEOF
13133#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013134#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013135$ac_includes_default
13136#ifdef F77_DUMMY_MAIN
13137# ifdef __cplusplus
13138 extern "C"
13139# endif
13140 int F77_DUMMY_MAIN() { return 1; }
13141#endif
13142int
13143main ()
13144{
13145static struct stat ac_aggr;
13146if (ac_aggr.st_blocks)
13147return 0;
13148 ;
13149 return 0;
13150}
13151_ACEOF
13152rm -f conftest.$ac_objext
13153if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13154 (eval $ac_compile) 2>&5
13155 ac_status=$?
13156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13157 (exit $ac_status); } &&
13158 { ac_try='test -s conftest.$ac_objext'
13159 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13160 (eval $ac_try) 2>&5
13161 ac_status=$?
13162 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13163 (exit $ac_status); }; }; then
13164 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013165else
Martin v. Löwis11437992002-04-12 09:54:03 +000013166 echo "$as_me: failed program was:" >&5
13167cat conftest.$ac_ext >&5
13168ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013169fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013170rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013171fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013172echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
13173echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6
13174if test $ac_cv_member_struct_stat_st_blocks = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013175
Martin v. Löwis11437992002-04-12 09:54:03 +000013176cat >>confdefs.h <<_ACEOF
13177#define HAVE_STRUCT_STAT_ST_BLOCKS 1
13178_ACEOF
13179
13180
13181cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013182#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013183_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013184
13185else
Martin v. Löwis11437992002-04-12 09:54:03 +000013186 LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013187fi
13188
Michael W. Hudson54241132001-12-07 15:38:26 +000013189
Martin v. Löwis11437992002-04-12 09:54:03 +000013190
13191echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
13192echo $ECHO_N "checking for time.h that defines altzone... $ECHO_C" >&6
13193if test "${ac_cv_header_time_altzone+set}" = set; then
13194 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013195else
Martin v. Löwis11437992002-04-12 09:54:03 +000013196 cat >conftest.$ac_ext <<_ACEOF
13197#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013198#include "confdefs.h"
13199#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013200#ifdef F77_DUMMY_MAIN
13201# ifdef __cplusplus
13202 extern "C"
13203# endif
13204 int F77_DUMMY_MAIN() { return 1; }
13205#endif
13206int
13207main ()
13208{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013209return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000013210 ;
13211 return 0;
13212}
13213_ACEOF
13214rm -f conftest.$ac_objext
13215if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13216 (eval $ac_compile) 2>&5
13217 ac_status=$?
13218 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13219 (exit $ac_status); } &&
13220 { ac_try='test -s conftest.$ac_objext'
13221 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13222 (eval $ac_try) 2>&5
13223 ac_status=$?
13224 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13225 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013226 ac_cv_header_time_altzone=yes
13227else
Martin v. Löwis11437992002-04-12 09:54:03 +000013228 echo "$as_me: failed program was:" >&5
13229cat conftest.$ac_ext >&5
13230ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +000013231fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013232rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013233fi
13234
Martin v. Löwis11437992002-04-12 09:54:03 +000013235echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
13236echo "${ECHO_T}$ac_cv_header_time_altzone" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013237if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013238
13239cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013240#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013241_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013242
13243fi
13244
Guido van Rossumda88dad1995-01-26 00:46:29 +000013245was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013246echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
13247echo $ECHO_N "checking whether sys/select.h and sys/time.h may both be included... $ECHO_C" >&6
13248cat >conftest.$ac_ext <<_ACEOF
13249#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013250#include "confdefs.h"
13251
13252#include <sys/types.h>
13253#include <sys/select.h>
13254#include <sys/time.h>
13255
Martin v. Löwis11437992002-04-12 09:54:03 +000013256#ifdef F77_DUMMY_MAIN
13257# ifdef __cplusplus
13258 extern "C"
13259# endif
13260 int F77_DUMMY_MAIN() { return 1; }
13261#endif
13262int
13263main ()
13264{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013265;
Martin v. Löwis11437992002-04-12 09:54:03 +000013266 ;
13267 return 0;
13268}
13269_ACEOF
13270rm -f conftest.$ac_objext
13271if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13272 (eval $ac_compile) 2>&5
13273 ac_status=$?
13274 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13275 (exit $ac_status); } &&
13276 { ac_try='test -s conftest.$ac_objext'
13277 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13278 (eval $ac_try) 2>&5
13279 ac_status=$?
13280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13281 (exit $ac_status); }; }; then
13282
13283
13284cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013285#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013286_ACEOF
13287
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013288 was_it_defined=yes
13289
Guido van Rossumf78abae1997-01-21 22:02:36 +000013290else
Martin v. Löwis11437992002-04-12 09:54:03 +000013291 echo "$as_me: failed program was:" >&5
13292cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000013293fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013294rm -f conftest.$ac_objext conftest.$ac_ext
13295echo "$as_me:$LINENO: result: $was_it_defined" >&5
13296echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000013297
Martin v. Löwis11437992002-04-12 09:54:03 +000013298echo "$as_me:$LINENO: checking for addrinfo" >&5
13299echo $ECHO_N "checking for addrinfo... $ECHO_C" >&6
13300if test "${ac_cv_struct_addrinfo+set}" = set; then
13301 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013302else
Martin v. Löwis11437992002-04-12 09:54:03 +000013303 cat >conftest.$ac_ext <<_ACEOF
13304#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013305#include "confdefs.h"
13306
13307# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013308#ifdef F77_DUMMY_MAIN
13309# ifdef __cplusplus
13310 extern "C"
13311# endif
13312 int F77_DUMMY_MAIN() { return 1; }
13313#endif
13314int
13315main ()
13316{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013317struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000013318 ;
13319 return 0;
13320}
13321_ACEOF
13322rm -f conftest.$ac_objext
13323if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13324 (eval $ac_compile) 2>&5
13325 ac_status=$?
13326 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13327 (exit $ac_status); } &&
13328 { ac_try='test -s conftest.$ac_objext'
13329 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13330 (eval $ac_try) 2>&5
13331 ac_status=$?
13332 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13333 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013334 ac_cv_struct_addrinfo=yes
13335else
Martin v. Löwis11437992002-04-12 09:54:03 +000013336 echo "$as_me: failed program was:" >&5
13337cat conftest.$ac_ext >&5
13338ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013339fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013340rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013341fi
13342
Martin v. Löwis11437992002-04-12 09:54:03 +000013343echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
13344echo "${ECHO_T}$ac_cv_struct_addrinfo" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013345if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013346
13347cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013348#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013349_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013350
13351fi
13352
Martin v. Löwis11437992002-04-12 09:54:03 +000013353echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
13354echo $ECHO_N "checking for sockaddr_storage... $ECHO_C" >&6
13355if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
13356 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013357else
Martin v. Löwis11437992002-04-12 09:54:03 +000013358 cat >conftest.$ac_ext <<_ACEOF
13359#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013360#include "confdefs.h"
13361
13362# include <sys/types.h>
13363# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013364#ifdef F77_DUMMY_MAIN
13365# ifdef __cplusplus
13366 extern "C"
13367# endif
13368 int F77_DUMMY_MAIN() { return 1; }
13369#endif
13370int
13371main ()
13372{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013373struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000013374 ;
13375 return 0;
13376}
13377_ACEOF
13378rm -f conftest.$ac_objext
13379if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13380 (eval $ac_compile) 2>&5
13381 ac_status=$?
13382 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13383 (exit $ac_status); } &&
13384 { ac_try='test -s conftest.$ac_objext'
13385 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13386 (eval $ac_try) 2>&5
13387 ac_status=$?
13388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13389 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013390 ac_cv_struct_sockaddr_storage=yes
13391else
Martin v. Löwis11437992002-04-12 09:54:03 +000013392 echo "$as_me: failed program was:" >&5
13393cat conftest.$ac_ext >&5
13394ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013395fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013396rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013397fi
13398
Martin v. Löwis11437992002-04-12 09:54:03 +000013399echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
13400echo "${ECHO_T}$ac_cv_struct_sockaddr_storage" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013401if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013402
13403cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013404#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013405_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013406
13407fi
13408
Guido van Rossum627b2d71993-12-24 10:39:16 +000013409# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000013410
Michael W. Hudson54241132001-12-07 15:38:26 +000013411
Martin v. Löwis11437992002-04-12 09:54:03 +000013412echo "$as_me:$LINENO: checking whether char is unsigned" >&5
13413echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
13414if test "${ac_cv_c_char_unsigned+set}" = set; then
13415 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000013416else
Martin v. Löwis11437992002-04-12 09:54:03 +000013417 cat >conftest.$ac_ext <<_ACEOF
13418#line $LINENO "configure"
Michael W. Hudson54241132001-12-07 15:38:26 +000013419#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013420$ac_includes_default
13421#ifdef F77_DUMMY_MAIN
13422# ifdef __cplusplus
13423 extern "C"
13424# endif
13425 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000013426#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013427int
13428main ()
13429{
13430static int test_array [1 - 2 * !(((char) -1) < 0)];
13431test_array [0] = 0
13432
13433 ;
13434 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000013435}
Martin v. Löwis11437992002-04-12 09:54:03 +000013436_ACEOF
13437rm -f conftest.$ac_objext
13438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13439 (eval $ac_compile) 2>&5
13440 ac_status=$?
13441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13442 (exit $ac_status); } &&
13443 { ac_try='test -s conftest.$ac_objext'
13444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13445 (eval $ac_try) 2>&5
13446 ac_status=$?
13447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13448 (exit $ac_status); }; }; then
Michael W. Hudson54241132001-12-07 15:38:26 +000013449 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013450else
13451 echo "$as_me: failed program was:" >&5
13452cat conftest.$ac_ext >&5
13453ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013454fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013455rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013456fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013457echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
13458echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013459if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013460 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013461#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013462_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013463
13464fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000013465
Martin v. Löwis11437992002-04-12 09:54:03 +000013466echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
13467echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
13468if test "${ac_cv_prog_cc_stdc+set}" = set; then
13469 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013470else
Martin v. Löwis11437992002-04-12 09:54:03 +000013471 ac_cv_prog_cc_stdc=no
13472ac_save_CC=$CC
13473cat >conftest.$ac_ext <<_ACEOF
13474#line $LINENO "configure"
13475#include "confdefs.h"
13476#include <stdarg.h>
13477#include <stdio.h>
13478#include <sys/types.h>
13479#include <sys/stat.h>
13480/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
13481struct buf { int x; };
13482FILE * (*rcsopen) (struct buf *, struct stat *, int);
13483static char *e (p, i)
13484 char **p;
13485 int i;
13486{
13487 return p[i];
13488}
13489static char *f (char * (*g) (char **, int), char **p, ...)
13490{
13491 char *s;
13492 va_list v;
13493 va_start (v,p);
13494 s = g (p, va_arg (v,int));
13495 va_end (v);
13496 return s;
13497}
13498int test (int i, double x);
13499struct s1 {int (*f) (int a);};
13500struct s2 {int (*f) (double a);};
13501int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
13502int argc;
13503char **argv;
13504#ifdef F77_DUMMY_MAIN
13505# ifdef __cplusplus
13506 extern "C"
13507# endif
13508 int F77_DUMMY_MAIN() { return 1; }
13509#endif
13510int
13511main ()
13512{
13513return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
13514 ;
13515 return 0;
13516}
13517_ACEOF
13518# Don't try gcc -ansi; that turns off useful extensions and
13519# breaks some systems' header files.
13520# AIX -qlanglvl=ansi
13521# Ultrix and OSF/1 -std1
13522# HP-UX 10.20 and later -Ae
13523# HP-UX older versions -Aa -D_HPUX_SOURCE
13524# SVR4 -Xc -D__EXTENSIONS__
13525for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
13526do
13527 CC="$ac_save_CC $ac_arg"
13528 rm -f conftest.$ac_objext
13529if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13530 (eval $ac_compile) 2>&5
13531 ac_status=$?
13532 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13533 (exit $ac_status); } &&
13534 { ac_try='test -s conftest.$ac_objext'
13535 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13536 (eval $ac_try) 2>&5
13537 ac_status=$?
13538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13539 (exit $ac_status); }; }; then
13540 ac_cv_prog_cc_stdc=$ac_arg
13541break
13542else
13543 echo "$as_me: failed program was:" >&5
13544cat conftest.$ac_ext >&5
13545fi
13546rm -f conftest.$ac_objext
13547done
13548rm -f conftest.$ac_ext conftest.$ac_objext
13549CC=$ac_save_CC
13550
13551fi
13552
13553case "x$ac_cv_prog_cc_stdc" in
13554 x|xno)
13555 echo "$as_me:$LINENO: result: none needed" >&5
13556echo "${ECHO_T}none needed" >&6 ;;
13557 *)
13558 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
13559echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
13560 CC="$CC $ac_cv_prog_cc_stdc" ;;
13561esac
13562
13563echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
13564echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
13565if test "${ac_cv_c_const+set}" = set; then
13566 echo $ECHO_N "(cached) $ECHO_C" >&6
13567else
13568 cat >conftest.$ac_ext <<_ACEOF
13569#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013570#include "confdefs.h"
13571
Martin v. Löwis11437992002-04-12 09:54:03 +000013572#ifdef F77_DUMMY_MAIN
13573# ifdef __cplusplus
13574 extern "C"
13575# endif
13576 int F77_DUMMY_MAIN() { return 1; }
13577#endif
13578int
13579main ()
13580{
13581/* FIXME: Include the comments suggested by Paul. */
13582#ifndef __cplusplus
13583 /* Ultrix mips cc rejects this. */
13584 typedef int charset[2];
13585 const charset x;
13586 /* SunOS 4.1.1 cc rejects this. */
13587 char const *const *ccp;
13588 char **p;
13589 /* NEC SVR4.0.2 mips cc rejects this. */
13590 struct point {int x, y;};
13591 static struct point const zero = {0,0};
13592 /* AIX XL C 1.02.0.0 rejects this.
13593 It does not let you subtract one const X* pointer from another in
13594 an arm of an if-expression whose if-part is not a constant
13595 expression */
13596 const char *g = "string";
13597 ccp = &g + (g ? g-g : 0);
13598 /* HPUX 7.0 cc rejects these. */
13599 ++ccp;
13600 p = (char**) ccp;
13601 ccp = (char const *const *) p;
13602 { /* SCO 3.2v4 cc rejects this. */
13603 char *t;
13604 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013605
Martin v. Löwis11437992002-04-12 09:54:03 +000013606 *t++ = 0;
13607 }
13608 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
13609 int x[] = {25, 17};
13610 const int *foo = &x[0];
13611 ++foo;
13612 }
13613 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
13614 typedef const int *iptr;
13615 iptr p = 0;
13616 ++p;
13617 }
13618 { /* AIX XL C 1.02.0.0 rejects this saying
13619 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
13620 struct s { int j; const int *ap[3]; };
13621 struct s *b; b->j = 5;
13622 }
13623 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
13624 const int foo = 10;
13625 }
13626#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000013627
Martin v. Löwis11437992002-04-12 09:54:03 +000013628 ;
13629 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000013630}
Martin v. Löwis11437992002-04-12 09:54:03 +000013631_ACEOF
13632rm -f conftest.$ac_objext
13633if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13634 (eval $ac_compile) 2>&5
13635 ac_status=$?
13636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13637 (exit $ac_status); } &&
13638 { ac_try='test -s conftest.$ac_objext'
13639 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13640 (eval $ac_try) 2>&5
13641 ac_status=$?
13642 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13643 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013644 ac_cv_c_const=yes
13645else
Martin v. Löwis11437992002-04-12 09:54:03 +000013646 echo "$as_me: failed program was:" >&5
13647cat conftest.$ac_ext >&5
13648ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013649fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013650rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013651fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013652echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
13653echo "${ECHO_T}$ac_cv_c_const" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013654if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013655
13656cat >>confdefs.h <<\_ACEOF
13657#define const
13658_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013659
13660fi
13661
Michael W. Hudson54241132001-12-07 15:38:26 +000013662
Guido van Rossumda88dad1995-01-26 00:46:29 +000013663works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013664echo "$as_me:$LINENO: checking for working volatile" >&5
13665echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
13666cat >conftest.$ac_ext <<_ACEOF
13667#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013668#include "confdefs.h"
13669
Martin v. Löwis11437992002-04-12 09:54:03 +000013670#ifdef F77_DUMMY_MAIN
13671# ifdef __cplusplus
13672 extern "C"
13673# endif
13674 int F77_DUMMY_MAIN() { return 1; }
13675#endif
13676int
13677main ()
13678{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013679volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000013680 ;
13681 return 0;
13682}
13683_ACEOF
13684rm -f conftest.$ac_objext
13685if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13686 (eval $ac_compile) 2>&5
13687 ac_status=$?
13688 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13689 (exit $ac_status); } &&
13690 { ac_try='test -s conftest.$ac_objext'
13691 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13692 (eval $ac_try) 2>&5
13693 ac_status=$?
13694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13695 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000013696 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000013697else
Martin v. Löwis11437992002-04-12 09:54:03 +000013698 echo "$as_me: failed program was:" >&5
13699cat conftest.$ac_ext >&5
13700
13701cat >>confdefs.h <<\_ACEOF
13702#define volatile
13703_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013704
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013705
Guido van Rossum627b2d71993-12-24 10:39:16 +000013706fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013707rm -f conftest.$ac_objext conftest.$ac_ext
13708echo "$as_me:$LINENO: result: $works" >&5
13709echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000013710
Guido van Rossumda88dad1995-01-26 00:46:29 +000013711works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013712echo "$as_me:$LINENO: checking for working signed char" >&5
13713echo $ECHO_N "checking for working signed char... $ECHO_C" >&6
13714cat >conftest.$ac_ext <<_ACEOF
13715#line $LINENO "configure"
Guido van Rossumdabb11b1994-10-11 15:04:27 +000013716#include "confdefs.h"
13717
Martin v. Löwis11437992002-04-12 09:54:03 +000013718#ifdef F77_DUMMY_MAIN
13719# ifdef __cplusplus
13720 extern "C"
13721# endif
13722 int F77_DUMMY_MAIN() { return 1; }
13723#endif
13724int
13725main ()
13726{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013727signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000013728 ;
13729 return 0;
13730}
13731_ACEOF
13732rm -f conftest.$ac_objext
13733if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13734 (eval $ac_compile) 2>&5
13735 ac_status=$?
13736 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13737 (exit $ac_status); } &&
13738 { ac_try='test -s conftest.$ac_objext'
13739 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13740 (eval $ac_try) 2>&5
13741 ac_status=$?
13742 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13743 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000013744 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000013745else
Martin v. Löwis11437992002-04-12 09:54:03 +000013746 echo "$as_me: failed program was:" >&5
13747cat conftest.$ac_ext >&5
13748
13749cat >>confdefs.h <<\_ACEOF
13750#define signed
13751_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000013752
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013753
Guido van Rossum7f43da71994-08-01 12:15:30 +000013754fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013755rm -f conftest.$ac_objext conftest.$ac_ext
13756echo "$as_me:$LINENO: result: $works" >&5
13757echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000013758
Guido van Rossumda88dad1995-01-26 00:46:29 +000013759have_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013760echo "$as_me:$LINENO: checking for prototypes" >&5
13761echo $ECHO_N "checking for prototypes... $ECHO_C" >&6
13762cat >conftest.$ac_ext <<_ACEOF
13763#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013764#include "confdefs.h"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013765int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013766#ifdef F77_DUMMY_MAIN
13767# ifdef __cplusplus
13768 extern "C"
13769# endif
13770 int F77_DUMMY_MAIN() { return 1; }
13771#endif
13772int
13773main ()
13774{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013775return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000013776 ;
13777 return 0;
13778}
13779_ACEOF
13780rm -f conftest.$ac_objext
13781if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13782 (eval $ac_compile) 2>&5
13783 ac_status=$?
13784 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13785 (exit $ac_status); } &&
13786 { ac_try='test -s conftest.$ac_objext'
13787 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13788 (eval $ac_try) 2>&5
13789 ac_status=$?
13790 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13791 (exit $ac_status); }; }; then
13792
13793
13794cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013795#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013796_ACEOF
13797
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013798 have_prototypes=yes
13799
Guido van Rossumf78abae1997-01-21 22:02:36 +000013800else
Martin v. Löwis11437992002-04-12 09:54:03 +000013801 echo "$as_me: failed program was:" >&5
13802cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000013803fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013804rm -f conftest.$ac_objext conftest.$ac_ext
13805echo "$as_me:$LINENO: result: $have_prototypes" >&5
13806echo "${ECHO_T}$have_prototypes" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013807
Guido van Rossumda88dad1995-01-26 00:46:29 +000013808works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013809echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
13810echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6
13811cat >conftest.$ac_ext <<_ACEOF
13812#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013813#include "confdefs.h"
13814
13815#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000013816int foo(int x, ...) {
13817 va_list va;
13818 va_start(va, x);
13819 va_arg(va, int);
13820 va_arg(va, char *);
13821 va_arg(va, double);
13822 return 0;
13823}
Guido van Rossum7f43da71994-08-01 12:15:30 +000013824
Martin v. Löwis11437992002-04-12 09:54:03 +000013825#ifdef F77_DUMMY_MAIN
13826# ifdef __cplusplus
13827 extern "C"
13828# endif
13829 int F77_DUMMY_MAIN() { return 1; }
13830#endif
13831int
13832main ()
13833{
Guido van Rossum90eea071996-08-30 20:58:57 +000013834return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000013835 ;
13836 return 0;
13837}
13838_ACEOF
13839rm -f conftest.$ac_objext
13840if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13841 (eval $ac_compile) 2>&5
13842 ac_status=$?
13843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13844 (exit $ac_status); } &&
13845 { ac_try='test -s conftest.$ac_objext'
13846 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13847 (eval $ac_try) 2>&5
13848 ac_status=$?
13849 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13850 (exit $ac_status); }; }; then
13851
13852
13853cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013854#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013855_ACEOF
13856
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013857 works=yes
13858
Guido van Rossumf78abae1997-01-21 22:02:36 +000013859else
Martin v. Löwis11437992002-04-12 09:54:03 +000013860 echo "$as_me: failed program was:" >&5
13861cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000013862fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013863rm -f conftest.$ac_objext conftest.$ac_ext
13864echo "$as_me:$LINENO: result: $works" >&5
13865echo "${ECHO_T}$works" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013866
Guido van Rossumda88dad1995-01-26 00:46:29 +000013867if test "$have_prototypes" = yes; then
13868bad_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013869echo "$as_me:$LINENO: checking for bad exec* prototypes" >&5
13870echo $ECHO_N "checking for bad exec* prototypes... $ECHO_C" >&6
13871cat >conftest.$ac_ext <<_ACEOF
13872#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013873#include "confdefs.h"
13874#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013875#ifdef F77_DUMMY_MAIN
13876# ifdef __cplusplus
13877 extern "C"
13878# endif
13879 int F77_DUMMY_MAIN() { return 1; }
13880#endif
13881int
13882main ()
13883{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013884char **t;execve("@",t,t);
Martin v. Löwis11437992002-04-12 09:54:03 +000013885 ;
13886 return 0;
13887}
13888_ACEOF
13889rm -f conftest.$ac_objext
13890if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13891 (eval $ac_compile) 2>&5
13892 ac_status=$?
13893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13894 (exit $ac_status); } &&
13895 { ac_try='test -s conftest.$ac_objext'
13896 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13897 (eval $ac_try) 2>&5
13898 ac_status=$?
13899 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13900 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000013901 :
13902else
Martin v. Löwis11437992002-04-12 09:54:03 +000013903 echo "$as_me: failed program was:" >&5
13904cat conftest.$ac_ext >&5
13905
13906cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013907#define BAD_EXEC_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013908_ACEOF
13909
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013910 bad_prototypes=yes
13911
Guido van Rossum627b2d71993-12-24 10:39:16 +000013912fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013913rm -f conftest.$ac_objext conftest.$ac_ext
13914echo "$as_me:$LINENO: result: $bad_prototypes" >&5
13915echo "${ECHO_T}$bad_prototypes" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000013916fi
13917
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013918# check if sockaddr has sa_len member
Martin v. Löwis11437992002-04-12 09:54:03 +000013919echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
13920echo $ECHO_N "checking if sockaddr has sa_len member... $ECHO_C" >&6
13921cat >conftest.$ac_ext <<_ACEOF
13922#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013923#include "confdefs.h"
13924#include <sys/types.h>
13925#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013926#ifdef F77_DUMMY_MAIN
13927# ifdef __cplusplus
13928 extern "C"
13929# endif
13930 int F77_DUMMY_MAIN() { return 1; }
13931#endif
13932int
13933main ()
13934{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013935struct sockaddr x;
13936x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000013937 ;
13938 return 0;
13939}
13940_ACEOF
13941rm -f conftest.$ac_objext
13942if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13943 (eval $ac_compile) 2>&5
13944 ac_status=$?
13945 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13946 (exit $ac_status); } &&
13947 { ac_try='test -s conftest.$ac_objext'
13948 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13949 (eval $ac_try) 2>&5
13950 ac_status=$?
13951 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13952 (exit $ac_status); }; }; then
13953 echo "$as_me:$LINENO: result: yes" >&5
13954echo "${ECHO_T}yes" >&6
13955
13956cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013957#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013958_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013959
13960else
Martin v. Löwis11437992002-04-12 09:54:03 +000013961 echo "$as_me: failed program was:" >&5
13962cat conftest.$ac_ext >&5
13963echo "$as_me:$LINENO: result: no" >&5
13964echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013965fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013966rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013967
Guido van Rossumda88dad1995-01-26 00:46:29 +000013968va_list_is_array=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013969echo "$as_me:$LINENO: checking whether va_list is an array" >&5
13970echo $ECHO_N "checking whether va_list is an array... $ECHO_C" >&6
13971cat >conftest.$ac_ext <<_ACEOF
13972#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013973#include "confdefs.h"
13974
13975#ifdef HAVE_STDARG_PROTOTYPES
13976#include <stdarg.h>
13977#else
13978#include <varargs.h>
13979#endif
13980
Martin v. Löwis11437992002-04-12 09:54:03 +000013981#ifdef F77_DUMMY_MAIN
13982# ifdef __cplusplus
13983 extern "C"
13984# endif
13985 int F77_DUMMY_MAIN() { return 1; }
13986#endif
13987int
13988main ()
13989{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013990va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000013991 ;
13992 return 0;
13993}
13994_ACEOF
13995rm -f conftest.$ac_objext
13996if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13997 (eval $ac_compile) 2>&5
13998 ac_status=$?
13999 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14000 (exit $ac_status); } &&
14001 { ac_try='test -s conftest.$ac_objext'
14002 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14003 (eval $ac_try) 2>&5
14004 ac_status=$?
14005 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14006 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014007 :
14008else
Martin v. Löwis11437992002-04-12 09:54:03 +000014009 echo "$as_me: failed program was:" >&5
14010cat conftest.$ac_ext >&5
14011
14012
14013cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014014#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014015_ACEOF
14016
Guido van Rossumda88dad1995-01-26 00:46:29 +000014017 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014018
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014019fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014020rm -f conftest.$ac_objext conftest.$ac_ext
14021echo "$as_me:$LINENO: result: $va_list_is_array" >&5
14022echo "${ECHO_T}$va_list_is_array" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014023
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014024# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000014025
14026
14027
14028echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
14029echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
14030if test "${ac_cv_func_gethostbyname_r+set}" = set; then
14031 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014032else
Martin v. Löwis11437992002-04-12 09:54:03 +000014033 cat >conftest.$ac_ext <<_ACEOF
14034#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014035#include "confdefs.h"
14036/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014037 which can conflict with char gethostbyname_r (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014038#include <assert.h>
14039/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014040#ifdef __cplusplus
14041extern "C"
14042#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014043/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014044 builtin and then its argument prototype would still apply. */
14045char gethostbyname_r ();
14046char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014047
Martin v. Löwis11437992002-04-12 09:54:03 +000014048#ifdef F77_DUMMY_MAIN
14049# ifdef __cplusplus
14050 extern "C"
14051# endif
14052 int F77_DUMMY_MAIN() { return 1; }
14053#endif
14054int
14055main ()
14056{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014057/* The GNU C library defines this for functions which it implements
14058 to always fail with ENOSYS. Some functions are actually named
14059 something starting with __ and the normal name is an alias. */
14060#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
14061choke me
14062#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014063f = gethostbyname_r;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014064#endif
14065
Martin v. Löwis11437992002-04-12 09:54:03 +000014066 ;
14067 return 0;
14068}
14069_ACEOF
14070rm -f conftest.$ac_objext conftest$ac_exeext
14071if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14072 (eval $ac_link) 2>&5
14073 ac_status=$?
14074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14075 (exit $ac_status); } &&
14076 { ac_try='test -s conftest$ac_exeext'
14077 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14078 (eval $ac_try) 2>&5
14079 ac_status=$?
14080 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14081 (exit $ac_status); }; }; then
14082 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014083else
Martin v. Löwis11437992002-04-12 09:54:03 +000014084 echo "$as_me: failed program was:" >&5
14085cat conftest.$ac_ext >&5
14086ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014087fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014088rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014089fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014090echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
14091echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
14092if test $ac_cv_func_gethostbyname_r = yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014093
Martin v. Löwis11437992002-04-12 09:54:03 +000014094 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014095#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014096_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014097
Martin v. Löwis11437992002-04-12 09:54:03 +000014098 echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
14099echo $ECHO_N "checking gethostbyname_r with 6 args... $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014100 OLD_CFLAGS=$CFLAGS
14101 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014102 cat >conftest.$ac_ext <<_ACEOF
14103#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014104#include "confdefs.h"
14105
14106# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014107
14108#ifdef F77_DUMMY_MAIN
14109# ifdef __cplusplus
14110 extern "C"
14111# endif
14112 int F77_DUMMY_MAIN() { return 1; }
14113#endif
14114int
14115main ()
14116{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014117
14118 char *name;
14119 struct hostent *he, *res;
14120 char buffer[2048];
14121 int buflen = 2048;
14122 int h_errnop;
14123
14124 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014125
14126 ;
14127 return 0;
14128}
14129_ACEOF
14130rm -f conftest.$ac_objext
14131if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14132 (eval $ac_compile) 2>&5
14133 ac_status=$?
14134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14135 (exit $ac_status); } &&
14136 { ac_try='test -s conftest.$ac_objext'
14137 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14138 (eval $ac_try) 2>&5
14139 ac_status=$?
14140 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14141 (exit $ac_status); }; }; then
14142
14143 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014144#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014145_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014146
Martin v. Löwis11437992002-04-12 09:54:03 +000014147
14148cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014149#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014150_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014151
Martin v. Löwis11437992002-04-12 09:54:03 +000014152 echo "$as_me:$LINENO: result: yes" >&5
14153echo "${ECHO_T}yes" >&6
14154
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014155else
Martin v. Löwis11437992002-04-12 09:54:03 +000014156 echo "$as_me: failed program was:" >&5
14157cat conftest.$ac_ext >&5
14158
14159 echo "$as_me:$LINENO: result: no" >&5
14160echo "${ECHO_T}no" >&6
14161 echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
14162echo $ECHO_N "checking gethostbyname_r with 5 args... $ECHO_C" >&6
14163 cat >conftest.$ac_ext <<_ACEOF
14164#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014165#include "confdefs.h"
14166
14167# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014168
14169#ifdef F77_DUMMY_MAIN
14170# ifdef __cplusplus
14171 extern "C"
14172# endif
14173 int F77_DUMMY_MAIN() { return 1; }
14174#endif
14175int
14176main ()
14177{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014178
14179 char *name;
14180 struct hostent *he;
14181 char buffer[2048];
14182 int buflen = 2048;
14183 int h_errnop;
14184
14185 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014186
14187 ;
14188 return 0;
14189}
14190_ACEOF
14191rm -f conftest.$ac_objext
14192if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14193 (eval $ac_compile) 2>&5
14194 ac_status=$?
14195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14196 (exit $ac_status); } &&
14197 { ac_try='test -s conftest.$ac_objext'
14198 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14199 (eval $ac_try) 2>&5
14200 ac_status=$?
14201 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14202 (exit $ac_status); }; }; then
14203
14204 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014205#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014206_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014207
Martin v. Löwis11437992002-04-12 09:54:03 +000014208
14209cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014210#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014211_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014212
Martin v. Löwis11437992002-04-12 09:54:03 +000014213 echo "$as_me:$LINENO: result: yes" >&5
14214echo "${ECHO_T}yes" >&6
14215
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014216else
Martin v. Löwis11437992002-04-12 09:54:03 +000014217 echo "$as_me: failed program was:" >&5
14218cat conftest.$ac_ext >&5
14219
14220 echo "$as_me:$LINENO: result: no" >&5
14221echo "${ECHO_T}no" >&6
14222 echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
14223echo $ECHO_N "checking gethostbyname_r with 3 args... $ECHO_C" >&6
14224 cat >conftest.$ac_ext <<_ACEOF
14225#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014226#include "confdefs.h"
14227
14228# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014229
14230#ifdef F77_DUMMY_MAIN
14231# ifdef __cplusplus
14232 extern "C"
14233# endif
14234 int F77_DUMMY_MAIN() { return 1; }
14235#endif
14236int
14237main ()
14238{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014239
14240 char *name;
14241 struct hostent *he;
14242 struct hostent_data data;
14243
14244 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000014245
14246 ;
14247 return 0;
14248}
14249_ACEOF
14250rm -f conftest.$ac_objext
14251if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14252 (eval $ac_compile) 2>&5
14253 ac_status=$?
14254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14255 (exit $ac_status); } &&
14256 { ac_try='test -s conftest.$ac_objext'
14257 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14258 (eval $ac_try) 2>&5
14259 ac_status=$?
14260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14261 (exit $ac_status); }; }; then
14262
14263 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014264#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014265_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014266
Martin v. Löwis11437992002-04-12 09:54:03 +000014267
14268cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014269#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014270_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014271
Martin v. Löwis11437992002-04-12 09:54:03 +000014272 echo "$as_me:$LINENO: result: yes" >&5
14273echo "${ECHO_T}yes" >&6
14274
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014275else
Martin v. Löwis11437992002-04-12 09:54:03 +000014276 echo "$as_me: failed program was:" >&5
14277cat conftest.$ac_ext >&5
14278
14279 echo "$as_me:$LINENO: result: no" >&5
14280echo "${ECHO_T}no" >&6
14281
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014282fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014283rm -f conftest.$ac_objext conftest.$ac_ext
14284
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014285fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014286rm -f conftest.$ac_objext conftest.$ac_ext
14287
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014288fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014289rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014290 CFLAGS=$OLD_CFLAGS
14291
14292else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014293
Martin v. Löwis11437992002-04-12 09:54:03 +000014294
14295for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000014296do
Martin v. Löwis11437992002-04-12 09:54:03 +000014297as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14298echo "$as_me:$LINENO: checking for $ac_func" >&5
14299echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14300if eval "test \"\${$as_ac_var+set}\" = set"; then
14301 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014302else
Martin v. Löwis11437992002-04-12 09:54:03 +000014303 cat >conftest.$ac_ext <<_ACEOF
14304#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014305#include "confdefs.h"
14306/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014307 which can conflict with char $ac_func (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014308#include <assert.h>
14309/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014310#ifdef __cplusplus
14311extern "C"
14312#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014313/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014314 builtin and then its argument prototype would still apply. */
14315char $ac_func ();
14316char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014317
Martin v. Löwis11437992002-04-12 09:54:03 +000014318#ifdef F77_DUMMY_MAIN
14319# ifdef __cplusplus
14320 extern "C"
14321# endif
14322 int F77_DUMMY_MAIN() { return 1; }
14323#endif
14324int
14325main ()
14326{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014327/* The GNU C library defines this for functions which it implements
14328 to always fail with ENOSYS. Some functions are actually named
14329 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000014330#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014331choke me
14332#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014333f = $ac_func;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014334#endif
14335
Martin v. Löwis11437992002-04-12 09:54:03 +000014336 ;
14337 return 0;
14338}
14339_ACEOF
14340rm -f conftest.$ac_objext conftest$ac_exeext
14341if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14342 (eval $ac_link) 2>&5
14343 ac_status=$?
14344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14345 (exit $ac_status); } &&
14346 { ac_try='test -s conftest$ac_exeext'
14347 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14348 (eval $ac_try) 2>&5
14349 ac_status=$?
14350 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14351 (exit $ac_status); }; }; then
14352 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014353else
Martin v. Löwis11437992002-04-12 09:54:03 +000014354 echo "$as_me: failed program was:" >&5
14355cat conftest.$ac_ext >&5
14356eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014357fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014358rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014359fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014360echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14361echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14362if test `eval echo '${'$as_ac_var'}'` = yes; then
14363 cat >>confdefs.h <<_ACEOF
14364#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14365_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014366
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014367fi
Thomas Wouters3a584202000-08-05 23:28:51 +000014368done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014369
Michael W. Hudson54241132001-12-07 15:38:26 +000014370
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014371fi
14372
Michael W. Hudson54241132001-12-07 15:38:26 +000014373
14374
14375
14376
14377
14378
Guido van Rossum627b2d71993-12-24 10:39:16 +000014379# checks for system services
14380# (none yet)
14381
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014382# Linux requires this for correct f.p. operations
Martin v. Löwis11437992002-04-12 09:54:03 +000014383echo "$as_me:$LINENO: checking for __fpu_control" >&5
14384echo $ECHO_N "checking for __fpu_control... $ECHO_C" >&6
14385if test "${ac_cv_func___fpu_control+set}" = set; then
14386 echo $ECHO_N "(cached) $ECHO_C" >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014387else
Martin v. Löwis11437992002-04-12 09:54:03 +000014388 cat >conftest.$ac_ext <<_ACEOF
14389#line $LINENO "configure"
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014390#include "confdefs.h"
14391/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014392 which can conflict with char __fpu_control (); below. */
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014393#include <assert.h>
14394/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014395#ifdef __cplusplus
14396extern "C"
14397#endif
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014398/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014399 builtin and then its argument prototype would still apply. */
14400char __fpu_control ();
14401char (*f) ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014402
Martin v. Löwis11437992002-04-12 09:54:03 +000014403#ifdef F77_DUMMY_MAIN
14404# ifdef __cplusplus
14405 extern "C"
14406# endif
14407 int F77_DUMMY_MAIN() { return 1; }
14408#endif
14409int
14410main ()
14411{
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014412/* The GNU C library defines this for functions which it implements
14413 to always fail with ENOSYS. Some functions are actually named
14414 something starting with __ and the normal name is an alias. */
14415#if defined (__stub___fpu_control) || defined (__stub_____fpu_control)
14416choke me
14417#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014418f = __fpu_control;
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014419#endif
14420
Martin v. Löwis11437992002-04-12 09:54:03 +000014421 ;
14422 return 0;
14423}
14424_ACEOF
14425rm -f conftest.$ac_objext conftest$ac_exeext
14426if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14427 (eval $ac_link) 2>&5
14428 ac_status=$?
14429 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14430 (exit $ac_status); } &&
14431 { ac_try='test -s conftest$ac_exeext'
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 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014438else
Martin v. Löwis11437992002-04-12 09:54:03 +000014439 echo "$as_me: failed program was:" >&5
14440cat conftest.$ac_ext >&5
14441ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014442fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014443rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014444fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014445echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
14446echo "${ECHO_T}$ac_cv_func___fpu_control" >&6
14447if test $ac_cv_func___fpu_control = yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014448 :
14449else
Martin v. Löwis11437992002-04-12 09:54:03 +000014450
14451echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
14452echo $ECHO_N "checking for __fpu_control in -lieee... $ECHO_C" >&6
14453if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
14454 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014455else
Martin v. Löwis11437992002-04-12 09:54:03 +000014456 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014457LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014458cat >conftest.$ac_ext <<_ACEOF
14459#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014460#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000014461
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014462/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014463#ifdef __cplusplus
14464extern "C"
14465#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014466/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014467 builtin and then its argument prototype would still apply. */
14468char __fpu_control ();
14469#ifdef F77_DUMMY_MAIN
14470# ifdef __cplusplus
14471 extern "C"
14472# endif
14473 int F77_DUMMY_MAIN() { return 1; }
14474#endif
14475int
14476main ()
14477{
14478__fpu_control ();
14479 ;
14480 return 0;
14481}
14482_ACEOF
14483rm -f conftest.$ac_objext conftest$ac_exeext
14484if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14485 (eval $ac_link) 2>&5
14486 ac_status=$?
14487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14488 (exit $ac_status); } &&
14489 { ac_try='test -s conftest$ac_exeext'
14490 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14491 (eval $ac_try) 2>&5
14492 ac_status=$?
14493 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14494 (exit $ac_status); }; }; then
14495 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000014496else
Martin v. Löwis11437992002-04-12 09:54:03 +000014497 echo "$as_me: failed program was:" >&5
14498cat conftest.$ac_ext >&5
14499ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000014500fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014501rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14502LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014503fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014504echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
14505echo "${ECHO_T}$ac_cv_lib_ieee___fpu_control" >&6
14506if test $ac_cv_lib_ieee___fpu_control = yes; then
14507 cat >>confdefs.h <<_ACEOF
14508#define HAVE_LIBIEEE 1
14509_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014510
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014511 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014512
Guido van Rossum627b2d71993-12-24 10:39:16 +000014513fi
14514
Michael W. Hudson54241132001-12-07 15:38:26 +000014515
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014516fi
14517
Michael W. Hudson54241132001-12-07 15:38:26 +000014518
Guido van Rossum7f253911997-05-09 02:42:48 +000014519# Check for --with-fpectl
Martin v. Löwis11437992002-04-12 09:54:03 +000014520echo "$as_me:$LINENO: checking for --with-fpectl" >&5
14521echo $ECHO_N "checking for --with-fpectl... $ECHO_C" >&6
14522
Guido van Rossum7f253911997-05-09 02:42:48 +000014523# Check whether --with-fpectl or --without-fpectl was given.
14524if test "${with_fpectl+set}" = set; then
14525 withval="$with_fpectl"
Martin v. Löwis11437992002-04-12 09:54:03 +000014526
Guido van Rossum7f253911997-05-09 02:42:48 +000014527if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000014528then
14529
14530cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000014531#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014532_ACEOF
14533
14534 echo "$as_me:$LINENO: result: yes" >&5
14535echo "${ECHO_T}yes" >&6
14536else echo "$as_me:$LINENO: result: no" >&5
14537echo "${ECHO_T}no" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000014538fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000014539else
Martin v. Löwis11437992002-04-12 09:54:03 +000014540 echo "$as_me:$LINENO: result: no" >&5
14541echo "${ECHO_T}no" >&6
14542fi;
Guido van Rossum7f253911997-05-09 02:42:48 +000014543
Guido van Rossum7f43da71994-08-01 12:15:30 +000014544# check for --with-libm=...
14545
Guido van Rossum563e7081996-09-10 18:20:48 +000014546case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000014547Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014548BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000014549*) LIBM=-lm
14550esac
Martin v. Löwis11437992002-04-12 09:54:03 +000014551echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
14552echo $ECHO_N "checking for --with-libm=STRING... $ECHO_C" >&6
14553
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014554# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014555if test "${with_libm+set}" = set; then
14556 withval="$with_libm"
Martin v. Löwis11437992002-04-12 09:54:03 +000014557
Guido van Rossum7f253911997-05-09 02:42:48 +000014558if test "$withval" = no
14559then LIBM=
Martin v. Löwis11437992002-04-12 09:54:03 +000014560 echo "$as_me:$LINENO: result: force LIBM empty" >&5
14561echo "${ECHO_T}force LIBM empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000014562elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000014563then LIBM=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000014564 echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
14565echo "${ECHO_T}set LIBM=\"$withval\"" >&6
14566else { { echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
14567echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
14568 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000014569fi
Guido van Rossum7f253911997-05-09 02:42:48 +000014570else
Martin v. Löwis11437992002-04-12 09:54:03 +000014571 echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
14572echo "${ECHO_T}default LIBM=\"$LIBM\"" >&6
14573fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000014574
14575# check for --with-libc=...
14576
Martin v. Löwis11437992002-04-12 09:54:03 +000014577echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
14578echo $ECHO_N "checking for --with-libc=STRING... $ECHO_C" >&6
14579
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014580# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014581if test "${with_libc+set}" = set; then
14582 withval="$with_libc"
Martin v. Löwis11437992002-04-12 09:54:03 +000014583
Guido van Rossum7f253911997-05-09 02:42:48 +000014584if test "$withval" = no
14585then LIBC=
Martin v. Löwis11437992002-04-12 09:54:03 +000014586 echo "$as_me:$LINENO: result: force LIBC empty" >&5
14587echo "${ECHO_T}force LIBC empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000014588elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000014589then LIBC=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000014590 echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
14591echo "${ECHO_T}set LIBC=\"$withval\"" >&6
14592else { { echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
14593echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
14594 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000014595fi
Guido van Rossum7f253911997-05-09 02:42:48 +000014596else
Martin v. Löwis11437992002-04-12 09:54:03 +000014597 echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
14598echo "${ECHO_T}default LIBC=\"$LIBC\"" >&6
14599fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000014600
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014601# check for hypot() in math library
14602LIBS_SAVE=$LIBS
14603LIBS="$LIBS $LIBM"
Martin v. Löwis11437992002-04-12 09:54:03 +000014604
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014605for ac_func in hypot
14606do
Martin v. Löwis11437992002-04-12 09:54:03 +000014607as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14608echo "$as_me:$LINENO: checking for $ac_func" >&5
14609echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14610if eval "test \"\${$as_ac_var+set}\" = set"; then
14611 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014612else
Martin v. Löwis11437992002-04-12 09:54:03 +000014613 cat >conftest.$ac_ext <<_ACEOF
14614#line $LINENO "configure"
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014615#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014616/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014617 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014618#include <assert.h>
14619/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014620#ifdef __cplusplus
14621extern "C"
14622#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014623/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014624 builtin and then its argument prototype would still apply. */
14625char $ac_func ();
14626char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014627
Martin v. Löwis11437992002-04-12 09:54:03 +000014628#ifdef F77_DUMMY_MAIN
14629# ifdef __cplusplus
14630 extern "C"
14631# endif
14632 int F77_DUMMY_MAIN() { return 1; }
14633#endif
14634int
14635main ()
14636{
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014637/* The GNU C library defines this for functions which it implements
14638 to always fail with ENOSYS. Some functions are actually named
14639 something starting with __ and the normal name is an alias. */
14640#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14641choke me
14642#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014643f = $ac_func;
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014644#endif
14645
Martin v. Löwis11437992002-04-12 09:54:03 +000014646 ;
14647 return 0;
14648}
14649_ACEOF
14650rm -f conftest.$ac_objext conftest$ac_exeext
14651if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14652 (eval $ac_link) 2>&5
14653 ac_status=$?
14654 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14655 (exit $ac_status); } &&
14656 { ac_try='test -s conftest$ac_exeext'
14657 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14658 (eval $ac_try) 2>&5
14659 ac_status=$?
14660 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14661 (exit $ac_status); }; }; then
14662 eval "$as_ac_var=yes"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000014663else
Martin v. Löwis11437992002-04-12 09:54:03 +000014664 echo "$as_me: failed program was:" >&5
14665cat conftest.$ac_ext >&5
14666eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014667fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014668rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014669fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014670echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14671echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14672if test `eval echo '${'$as_ac_var'}'` = yes; then
14673 cat >>confdefs.h <<_ACEOF
14674#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14675_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000014676
Michael W. Hudson54241132001-12-07 15:38:26 +000014677else
Martin v. Löwis11437992002-04-12 09:54:03 +000014678 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000014679fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +000014680done
14681
Michael W. Hudson54241132001-12-07 15:38:26 +000014682
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000014683LIBS=$LIBS_SAVE
14684
Guido van Rossumad713701997-07-10 22:42:38 +000014685# check whether malloc(0) returns NULL or not
Martin v. Löwis11437992002-04-12 09:54:03 +000014686echo "$as_me:$LINENO: checking what malloc(0) returns" >&5
14687echo $ECHO_N "checking what malloc(0) returns... $ECHO_C" >&6
14688if test "${ac_cv_malloc_zero+set}" = set; then
14689 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad713701997-07-10 22:42:38 +000014690else
14691 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000014692 ac_cv_malloc_zero=nonnull
Guido van Rossumad713701997-07-10 22:42:38 +000014693else
Martin v. Löwis11437992002-04-12 09:54:03 +000014694 cat >conftest.$ac_ext <<_ACEOF
14695#line $LINENO "configure"
Guido van Rossumad713701997-07-10 22:42:38 +000014696#include "confdefs.h"
14697#include <stdio.h>
14698#ifdef HAVE_STDLIB
14699#include <stdlib.h>
14700#else
14701char *malloc(), *realloc();
14702int *free();
14703#endif
14704main() {
14705 char *p;
14706 p = malloc(0);
14707 if (p == NULL) exit(1);
14708 p = realloc(p, 0);
14709 if (p == NULL) exit(1);
14710 free(p);
14711 exit(0);
14712}
Martin v. Löwis11437992002-04-12 09:54:03 +000014713_ACEOF
14714rm -f conftest$ac_exeext
14715if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14716 (eval $ac_link) 2>&5
14717 ac_status=$?
14718 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14719 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14720 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14721 (eval $ac_try) 2>&5
14722 ac_status=$?
14723 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14724 (exit $ac_status); }; }; then
Guido van Rossumad713701997-07-10 22:42:38 +000014725 ac_cv_malloc_zero=nonnull
14726else
Martin v. Löwis11437992002-04-12 09:54:03 +000014727 echo "$as_me: program exited with status $ac_status" >&5
14728echo "$as_me: failed program was:" >&5
14729cat conftest.$ac_ext >&5
14730( exit $ac_status )
14731ac_cv_malloc_zero=null
Guido van Rossumad713701997-07-10 22:42:38 +000014732fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014733rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumad713701997-07-10 22:42:38 +000014734fi
Guido van Rossumad713701997-07-10 22:42:38 +000014735fi
Guido van Rossum3065c942001-09-17 04:03:14 +000014736 # XXX arm cross-compile?
Martin v. Löwis11437992002-04-12 09:54:03 +000014737echo "$as_me:$LINENO: result: $ac_cv_malloc_zero" >&5
14738echo "${ECHO_T}$ac_cv_malloc_zero" >&6
Guido van Rossumad713701997-07-10 22:42:38 +000014739if test "$ac_cv_malloc_zero" = null
14740then
Martin v. Löwis11437992002-04-12 09:54:03 +000014741
14742cat >>confdefs.h <<\_ACEOF
Guido van Rossumad713701997-07-10 22:42:38 +000014743#define MALLOC_ZERO_RETURNS_NULL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014744_ACEOF
Guido van Rossumad713701997-07-10 22:42:38 +000014745
14746fi
14747
Guido van Rossumef2255b2000-03-10 22:30:29 +000014748# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000014749if test "${ac_cv_header_wchar_h+set}" = set; then
14750 echo "$as_me:$LINENO: checking for wchar.h" >&5
14751echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
14752if test "${ac_cv_header_wchar_h+set}" = set; then
14753 echo $ECHO_N "(cached) $ECHO_C" >&6
14754fi
14755echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
14756echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000014757else
Martin v. Löwis11437992002-04-12 09:54:03 +000014758 # Is the header compilable?
14759echo "$as_me:$LINENO: checking wchar.h usability" >&5
14760echo $ECHO_N "checking wchar.h usability... $ECHO_C" >&6
14761cat >conftest.$ac_ext <<_ACEOF
14762#line $LINENO "configure"
14763#include "confdefs.h"
14764$ac_includes_default
14765#include <wchar.h>
14766_ACEOF
14767rm -f conftest.$ac_objext
14768if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14769 (eval $ac_compile) 2>&5
14770 ac_status=$?
14771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14772 (exit $ac_status); } &&
14773 { ac_try='test -s conftest.$ac_objext'
14774 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14775 (eval $ac_try) 2>&5
14776 ac_status=$?
14777 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14778 (exit $ac_status); }; }; then
14779 ac_header_compiler=yes
14780else
14781 echo "$as_me: failed program was:" >&5
14782cat conftest.$ac_ext >&5
14783ac_header_compiler=no
14784fi
14785rm -f conftest.$ac_objext conftest.$ac_ext
14786echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14787echo "${ECHO_T}$ac_header_compiler" >&6
14788
14789# Is the header present?
14790echo "$as_me:$LINENO: checking wchar.h presence" >&5
14791echo $ECHO_N "checking wchar.h presence... $ECHO_C" >&6
14792cat >conftest.$ac_ext <<_ACEOF
14793#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000014794#include "confdefs.h"
14795#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014796_ACEOF
14797if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14798 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14799 ac_status=$?
14800 egrep -v '^ *\+' conftest.er1 >conftest.err
14801 rm -f conftest.er1
14802 cat conftest.err >&5
14803 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14804 (exit $ac_status); } >/dev/null; then
14805 if test -s conftest.err; then
14806 ac_cpp_err=$ac_c_preproc_warn_flag
14807 else
14808 ac_cpp_err=
14809 fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000014810else
Martin v. Löwis11437992002-04-12 09:54:03 +000014811 ac_cpp_err=yes
14812fi
14813if test -z "$ac_cpp_err"; then
14814 ac_header_preproc=yes
14815else
14816 echo "$as_me: failed program was:" >&5
Guido van Rossumef2255b2000-03-10 22:30:29 +000014817 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000014818 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000014819fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014820rm -f conftest.err conftest.$ac_ext
14821echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14822echo "${ECHO_T}$ac_header_preproc" >&6
14823
14824# So? What about this header?
14825case $ac_header_compiler:$ac_header_preproc in
14826 yes:no )
14827 { echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
14828echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14829 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
14830echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
14831 no:yes )
14832 { echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
14833echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
14834 { echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
14835echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
14836 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
14837echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
14838esac
14839echo "$as_me:$LINENO: checking for wchar.h" >&5
14840echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
14841if test "${ac_cv_header_wchar_h+set}" = set; then
14842 echo $ECHO_N "(cached) $ECHO_C" >&6
14843else
14844 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000014845fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014846echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
14847echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
14848
14849fi
14850if test $ac_cv_header_wchar_h = yes; then
14851
14852
14853cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000014854#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014855_ACEOF
14856
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014857 wchar_h="yes"
14858
Guido van Rossumef2255b2000-03-10 22:30:29 +000014859else
Martin v. Löwis11437992002-04-12 09:54:03 +000014860 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000014861
14862fi
14863
Michael W. Hudson54241132001-12-07 15:38:26 +000014864
Martin v. Löwis11437992002-04-12 09:54:03 +000014865
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000014866# determine wchar_t size
14867if test "$wchar_h" = yes
14868then
Martin v. Löwis11437992002-04-12 09:54:03 +000014869 echo "$as_me:$LINENO: checking for wchar_t" >&5
14870echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
14871if test "${ac_cv_type_wchar_t+set}" = set; then
14872 echo $ECHO_N "(cached) $ECHO_C" >&6
14873else
14874 cat >conftest.$ac_ext <<_ACEOF
14875#line $LINENO "configure"
14876#include "confdefs.h"
14877#include <wchar.h>
14878
14879#ifdef F77_DUMMY_MAIN
14880# ifdef __cplusplus
14881 extern "C"
14882# endif
14883 int F77_DUMMY_MAIN() { return 1; }
14884#endif
14885int
14886main ()
14887{
14888if ((wchar_t *) 0)
14889 return 0;
14890if (sizeof (wchar_t))
14891 return 0;
14892 ;
14893 return 0;
14894}
14895_ACEOF
14896rm -f conftest.$ac_objext
14897if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14898 (eval $ac_compile) 2>&5
14899 ac_status=$?
14900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14901 (exit $ac_status); } &&
14902 { ac_try='test -s conftest.$ac_objext'
14903 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14904 (eval $ac_try) 2>&5
14905 ac_status=$?
14906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14907 (exit $ac_status); }; }; then
14908 ac_cv_type_wchar_t=yes
14909else
14910 echo "$as_me: failed program was:" >&5
14911cat conftest.$ac_ext >&5
14912ac_cv_type_wchar_t=no
14913fi
14914rm -f conftest.$ac_objext conftest.$ac_ext
14915fi
14916echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
14917echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
14918
14919echo "$as_me:$LINENO: checking size of wchar_t" >&5
14920echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
14921if test "${ac_cv_sizeof_wchar_t+set}" = set; then
14922 echo $ECHO_N "(cached) $ECHO_C" >&6
14923else
14924 if test "$ac_cv_type_wchar_t" = yes; then
14925 # The cast to unsigned long works around a bug in the HP C Compiler
14926 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14927 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14928 # This bug is HP SR number 8606223364.
14929 if test "$cross_compiling" = yes; then
14930 # Depending upon the size, compute the lo and hi bounds.
14931cat >conftest.$ac_ext <<_ACEOF
14932#line $LINENO "configure"
14933#include "confdefs.h"
14934#include <wchar.h>
14935
14936#ifdef F77_DUMMY_MAIN
14937# ifdef __cplusplus
14938 extern "C"
14939# endif
14940 int F77_DUMMY_MAIN() { return 1; }
14941#endif
14942int
14943main ()
14944{
14945static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
14946test_array [0] = 0
14947
14948 ;
14949 return 0;
14950}
14951_ACEOF
14952rm -f conftest.$ac_objext
14953if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14954 (eval $ac_compile) 2>&5
14955 ac_status=$?
14956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14957 (exit $ac_status); } &&
14958 { ac_try='test -s conftest.$ac_objext'
14959 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14960 (eval $ac_try) 2>&5
14961 ac_status=$?
14962 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14963 (exit $ac_status); }; }; then
14964 ac_lo=0 ac_mid=0
14965 while :; do
14966 cat >conftest.$ac_ext <<_ACEOF
14967#line $LINENO "configure"
14968#include "confdefs.h"
14969#include <wchar.h>
14970
14971#ifdef F77_DUMMY_MAIN
14972# ifdef __cplusplus
14973 extern "C"
14974# endif
14975 int F77_DUMMY_MAIN() { return 1; }
14976#endif
14977int
14978main ()
14979{
14980static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
14981test_array [0] = 0
14982
14983 ;
14984 return 0;
14985}
14986_ACEOF
14987rm -f conftest.$ac_objext
14988if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14989 (eval $ac_compile) 2>&5
14990 ac_status=$?
14991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14992 (exit $ac_status); } &&
14993 { ac_try='test -s conftest.$ac_objext'
14994 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14995 (eval $ac_try) 2>&5
14996 ac_status=$?
14997 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14998 (exit $ac_status); }; }; then
14999 ac_hi=$ac_mid; break
15000else
15001 echo "$as_me: failed program was:" >&5
15002cat conftest.$ac_ext >&5
15003ac_lo=`expr $ac_mid + 1`
15004 if test $ac_lo -le $ac_mid; then
15005 ac_lo= ac_hi=
15006 break
15007 fi
15008 ac_mid=`expr 2 '*' $ac_mid + 1`
15009fi
15010rm -f conftest.$ac_objext conftest.$ac_ext
15011 done
15012else
15013 echo "$as_me: failed program was:" >&5
15014cat conftest.$ac_ext >&5
15015cat >conftest.$ac_ext <<_ACEOF
15016#line $LINENO "configure"
15017#include "confdefs.h"
15018#include <wchar.h>
15019
15020#ifdef F77_DUMMY_MAIN
15021# ifdef __cplusplus
15022 extern "C"
15023# endif
15024 int F77_DUMMY_MAIN() { return 1; }
15025#endif
15026int
15027main ()
15028{
15029static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
15030test_array [0] = 0
15031
15032 ;
15033 return 0;
15034}
15035_ACEOF
15036rm -f conftest.$ac_objext
15037if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15038 (eval $ac_compile) 2>&5
15039 ac_status=$?
15040 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15041 (exit $ac_status); } &&
15042 { ac_try='test -s conftest.$ac_objext'
15043 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15044 (eval $ac_try) 2>&5
15045 ac_status=$?
15046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15047 (exit $ac_status); }; }; then
15048 ac_hi=-1 ac_mid=-1
15049 while :; do
15050 cat >conftest.$ac_ext <<_ACEOF
15051#line $LINENO "configure"
15052#include "confdefs.h"
15053#include <wchar.h>
15054
15055#ifdef F77_DUMMY_MAIN
15056# ifdef __cplusplus
15057 extern "C"
15058# endif
15059 int F77_DUMMY_MAIN() { return 1; }
15060#endif
15061int
15062main ()
15063{
15064static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
15065test_array [0] = 0
15066
15067 ;
15068 return 0;
15069}
15070_ACEOF
15071rm -f conftest.$ac_objext
15072if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15073 (eval $ac_compile) 2>&5
15074 ac_status=$?
15075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15076 (exit $ac_status); } &&
15077 { ac_try='test -s conftest.$ac_objext'
15078 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15079 (eval $ac_try) 2>&5
15080 ac_status=$?
15081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15082 (exit $ac_status); }; }; then
15083 ac_lo=$ac_mid; break
15084else
15085 echo "$as_me: failed program was:" >&5
15086cat conftest.$ac_ext >&5
15087ac_hi=`expr '(' $ac_mid ')' - 1`
15088 if test $ac_mid -le $ac_hi; then
15089 ac_lo= ac_hi=
15090 break
15091 fi
15092 ac_mid=`expr 2 '*' $ac_mid`
15093fi
15094rm -f conftest.$ac_objext conftest.$ac_ext
15095 done
15096else
15097 echo "$as_me: failed program was:" >&5
15098cat conftest.$ac_ext >&5
15099ac_lo= ac_hi=
15100fi
15101rm -f conftest.$ac_objext conftest.$ac_ext
15102fi
15103rm -f conftest.$ac_objext conftest.$ac_ext
15104# Binary search between lo and hi bounds.
15105while test "x$ac_lo" != "x$ac_hi"; do
15106 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15107 cat >conftest.$ac_ext <<_ACEOF
15108#line $LINENO "configure"
15109#include "confdefs.h"
15110#include <wchar.h>
15111
15112#ifdef F77_DUMMY_MAIN
15113# ifdef __cplusplus
15114 extern "C"
15115# endif
15116 int F77_DUMMY_MAIN() { return 1; }
15117#endif
15118int
15119main ()
15120{
15121static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15122test_array [0] = 0
15123
15124 ;
15125 return 0;
15126}
15127_ACEOF
15128rm -f conftest.$ac_objext
15129if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15130 (eval $ac_compile) 2>&5
15131 ac_status=$?
15132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15133 (exit $ac_status); } &&
15134 { ac_try='test -s conftest.$ac_objext'
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_hi=$ac_mid
15141else
15142 echo "$as_me: failed program was:" >&5
15143cat conftest.$ac_ext >&5
15144ac_lo=`expr '(' $ac_mid ')' + 1`
15145fi
15146rm -f conftest.$ac_objext conftest.$ac_ext
15147done
15148case $ac_lo in
15149?*) ac_cv_sizeof_wchar_t=$ac_lo;;
15150'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15151echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15152 { (exit 1); exit 1; }; } ;;
15153esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015154else
15155 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015156 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15157echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15158 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000015159else
Martin v. Löwis11437992002-04-12 09:54:03 +000015160 cat >conftest.$ac_ext <<_ACEOF
15161#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015162#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015163#include <wchar.h>
15164
15165long longval () { return (long) (sizeof (wchar_t)); }
15166unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000015167#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015168#include <stdlib.h>
15169#ifdef F77_DUMMY_MAIN
15170# ifdef __cplusplus
15171 extern "C"
15172# endif
15173 int F77_DUMMY_MAIN() { return 1; }
15174#endif
15175int
15176main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015177{
Martin v. Löwis11437992002-04-12 09:54:03 +000015178
15179 FILE *f = fopen ("conftest.val", "w");
15180 if (! f)
15181 exit (1);
15182 if (((long) (sizeof (wchar_t))) < 0)
15183 {
15184 long i = longval ();
15185 if (i != ((long) (sizeof (wchar_t))))
15186 exit (1);
15187 fprintf (f, "%ld\n", i);
15188 }
15189 else
15190 {
15191 unsigned long i = ulongval ();
15192 if (i != ((long) (sizeof (wchar_t))))
15193 exit (1);
15194 fprintf (f, "%lu\n", i);
15195 }
15196 exit (ferror (f) || fclose (f) != 0);
15197
15198 ;
15199 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000015200}
Martin v. Löwis11437992002-04-12 09:54:03 +000015201_ACEOF
15202rm -f conftest$ac_exeext
15203if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15204 (eval $ac_link) 2>&5
15205 ac_status=$?
15206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15207 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15208 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15209 (eval $ac_try) 2>&5
15210 ac_status=$?
15211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15212 (exit $ac_status); }; }; then
15213 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000015214else
Martin v. Löwis11437992002-04-12 09:54:03 +000015215 echo "$as_me: program exited with status $ac_status" >&5
15216echo "$as_me: failed program was:" >&5
15217cat conftest.$ac_ext >&5
15218( exit $ac_status )
15219{ { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15220echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15221 { (exit 1); exit 1; }; }
15222fi
15223rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15224fi
15225fi
15226rm -f conftest.val
15227else
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015228 ac_cv_sizeof_wchar_t=0
Guido van Rossumef2255b2000-03-10 22:30:29 +000015229fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015230fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015231echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
15232echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
15233cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015234#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015235_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015236
Michael W. Hudson54241132001-12-07 15:38:26 +000015237
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015238fi
15239
Martin v. Löwis11437992002-04-12 09:54:03 +000015240echo "$as_me:$LINENO: checking what type to use for unicode" >&5
15241echo $ECHO_N "checking what type to use for unicode... $ECHO_C" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015242# Check whether --enable-unicode or --disable-unicode was given.
15243if test "${enable_unicode+set}" = set; then
15244 enableval="$enable_unicode"
Martin v. Löwis11437992002-04-12 09:54:03 +000015245
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015246else
15247 enable_unicode=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000015248fi;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015249
15250if test $enable_unicode = yes
15251then
Martin v. Löwisfd917792001-06-27 20:22:04 +000015252 # Without any arguments, Py_UNICODE defaults to two-byte mode
15253 enable_unicode="ucs2"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015254fi
15255
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015256
15257
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015258case "$enable_unicode" in
15259ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000015260 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015261#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000015262_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015263
15264 ;;
15265ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000015266 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015267#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000015268_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015269
15270 ;;
15271esac
15272
Michael W. Hudson54241132001-12-07 15:38:26 +000015273
Martin v. Löwis11437992002-04-12 09:54:03 +000015274
15275
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015276
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015277if test "$enable_unicode" = "no"
15278then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015279 UNICODE_OBJS=""
Martin v. Löwis11437992002-04-12 09:54:03 +000015280 echo "$as_me:$LINENO: result: not used" >&5
15281echo "${ECHO_T}not used" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015282else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015283 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000015284
15285cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015286#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015287_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015288
15289 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t"
15290 then
15291 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015292
Martin v. Löwis11437992002-04-12 09:54:03 +000015293cat >>confdefs.h <<\_ACEOF
15294#define HAVE_USABLE_WCHAR_T 1
15295_ACEOF
15296
15297 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015298#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015299_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015300
15301 elif test "$ac_cv_sizeof_short" = "$unicode_size"
15302 then
15303 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000015304 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015305#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000015306_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015307
15308 elif test "$ac_cv_sizeof_long" = "$unicode_size"
15309 then
15310 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000015311 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015312#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000015313_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015314
15315 else
15316 PY_UNICODE_TYPE="no type found"
15317 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015318 echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
15319echo "${ECHO_T}$PY_UNICODE_TYPE" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015320fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015321
15322# check for endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000015323echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
15324echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
15325if test "${ac_cv_c_bigendian+set}" = set; then
15326 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015327else
Martin v. Löwis11437992002-04-12 09:54:03 +000015328 # See if sys/param.h defines the BYTE_ORDER macro.
15329cat >conftest.$ac_ext <<_ACEOF
15330#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015331#include "confdefs.h"
15332#include <sys/types.h>
15333#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015334
Martin v. Löwis11437992002-04-12 09:54:03 +000015335#ifdef F77_DUMMY_MAIN
15336# ifdef __cplusplus
15337 extern "C"
15338# endif
15339 int F77_DUMMY_MAIN() { return 1; }
15340#endif
15341int
15342main ()
15343{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015344#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
15345 bogus endian macros
15346#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015347
15348 ;
15349 return 0;
15350}
15351_ACEOF
15352rm -f conftest.$ac_objext
15353if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15354 (eval $ac_compile) 2>&5
15355 ac_status=$?
15356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15357 (exit $ac_status); } &&
15358 { ac_try='test -s conftest.$ac_objext'
15359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15360 (eval $ac_try) 2>&5
15361 ac_status=$?
15362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15363 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015364 # It does; now see whether it defined to BIG_ENDIAN or not.
Martin v. Löwis11437992002-04-12 09:54:03 +000015365cat >conftest.$ac_ext <<_ACEOF
15366#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015367#include "confdefs.h"
15368#include <sys/types.h>
15369#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015370
Martin v. Löwis11437992002-04-12 09:54:03 +000015371#ifdef F77_DUMMY_MAIN
15372# ifdef __cplusplus
15373 extern "C"
15374# endif
15375 int F77_DUMMY_MAIN() { return 1; }
15376#endif
15377int
15378main ()
15379{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015380#if BYTE_ORDER != BIG_ENDIAN
15381 not big endian
15382#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015383
15384 ;
15385 return 0;
15386}
15387_ACEOF
15388rm -f conftest.$ac_objext
15389if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15390 (eval $ac_compile) 2>&5
15391 ac_status=$?
15392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15393 (exit $ac_status); } &&
15394 { ac_try='test -s conftest.$ac_objext'
15395 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15396 (eval $ac_try) 2>&5
15397 ac_status=$?
15398 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15399 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015400 ac_cv_c_bigendian=yes
15401else
Martin v. Löwis11437992002-04-12 09:54:03 +000015402 echo "$as_me: failed program was:" >&5
15403cat conftest.$ac_ext >&5
15404ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015405fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015406rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000015407else
Martin v. Löwis11437992002-04-12 09:54:03 +000015408 echo "$as_me: failed program was:" >&5
15409cat conftest.$ac_ext >&5
15410# It does not; compile a test program.
Guido van Rossumef2255b2000-03-10 22:30:29 +000015411if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015412 # try to guess the endianess by grep'ing values into an object file
15413 ac_cv_c_bigendian=unknown
15414 cat >conftest.$ac_ext <<_ACEOF
15415#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015416#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015417short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
15418short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
15419void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
15420short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
15421short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
15422void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
15423#ifdef F77_DUMMY_MAIN
15424# ifdef __cplusplus
15425 extern "C"
15426# endif
15427 int F77_DUMMY_MAIN() { return 1; }
15428#endif
15429int
15430main ()
15431{
15432 _ascii (); _ebcdic ();
15433 ;
15434 return 0;
15435}
15436_ACEOF
15437rm -f conftest.$ac_objext
15438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15439 (eval $ac_compile) 2>&5
15440 ac_status=$?
15441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15442 (exit $ac_status); } &&
15443 { ac_try='test -s conftest.$ac_objext'
15444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15445 (eval $ac_try) 2>&5
15446 ac_status=$?
15447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15448 (exit $ac_status); }; }; then
15449 if fgrep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
15450 ac_cv_c_bigendian=yes
15451fi
15452if fgrep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
15453 if test "$ac_cv_c_bigendian" = unknown; then
15454 ac_cv_c_bigendian=no
15455 else
15456 # finding both strings is unlikely to happen, but who knows?
15457 ac_cv_c_bigendian=unknown
15458 fi
15459fi
15460else
15461 echo "$as_me: failed program was:" >&5
15462cat conftest.$ac_ext >&5
15463fi
15464rm -f conftest.$ac_objext conftest.$ac_ext
15465else
15466 cat >conftest.$ac_ext <<_ACEOF
15467#line $LINENO "configure"
15468#include "confdefs.h"
15469int
15470main ()
15471{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015472 /* Are we little or big endian? From Harbison&Steele. */
15473 union
15474 {
15475 long l;
15476 char c[sizeof (long)];
15477 } u;
15478 u.l = 1;
15479 exit (u.c[sizeof (long) - 1] == 1);
15480}
Martin v. Löwis11437992002-04-12 09:54:03 +000015481_ACEOF
15482rm -f conftest$ac_exeext
15483if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15484 (eval $ac_link) 2>&5
15485 ac_status=$?
15486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15487 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15488 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15489 (eval $ac_try) 2>&5
15490 ac_status=$?
15491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15492 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015493 ac_cv_c_bigendian=no
15494else
Martin v. Löwis11437992002-04-12 09:54:03 +000015495 echo "$as_me: program exited with status $ac_status" >&5
15496echo "$as_me: failed program was:" >&5
15497cat conftest.$ac_ext >&5
15498( exit $ac_status )
15499ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000015500fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015501rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000015502fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015503fi
15504rm -f conftest.$ac_objext conftest.$ac_ext
15505fi
15506echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
15507echo "${ECHO_T}$ac_cv_c_bigendian" >&6
15508case $ac_cv_c_bigendian in
15509 yes)
Jack Jansendd19cf82001-12-06 22:36:17 +000015510
Martin v. Löwis11437992002-04-12 09:54:03 +000015511cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000015512#define WORDS_BIGENDIAN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015513_ACEOF
15514 ;;
15515 no)
15516 ;;
15517 *)
15518 { { echo "$as_me:$LINENO: error: unknown endianess
15519presetting ac_cv_c_bigendian=no (or yes) will help" >&5
15520echo "$as_me: error: unknown endianess
15521presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
15522 { (exit 1); exit 1; }; } ;;
15523esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000015524
Michael W. Hudson54241132001-12-07 15:38:26 +000015525
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015526# Check whether right shifting a negative integer extends the sign bit
15527# or fills with zeros (like the Cray J90, according to Tim Peters).
Martin v. Löwis11437992002-04-12 09:54:03 +000015528echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
15529echo $ECHO_N "checking whether right shift extends the sign bit... $ECHO_C" >&6
15530if test "${ac_cv_rshift_extends_sign+set}" = set; then
15531 echo $ECHO_N "(cached) $ECHO_C" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000015532else
Martin v. Löwis11437992002-04-12 09:54:03 +000015533
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015534if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000015535 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015536else
Martin v. Löwis11437992002-04-12 09:54:03 +000015537 cat >conftest.$ac_ext <<_ACEOF
15538#line $LINENO "configure"
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015539#include "confdefs.h"
15540
15541int main()
15542{
Vladimir Marangozova6180282000-07-12 05:05:06 +000015543 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015544}
15545
Martin v. Löwis11437992002-04-12 09:54:03 +000015546_ACEOF
15547rm -f conftest$ac_exeext
15548if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15549 (eval $ac_link) 2>&5
15550 ac_status=$?
15551 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15552 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15553 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15554 (eval $ac_try) 2>&5
15555 ac_status=$?
15556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15557 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000015558 ac_cv_rshift_extends_sign=yes
15559else
Martin v. Löwis11437992002-04-12 09:54:03 +000015560 echo "$as_me: program exited with status $ac_status" >&5
15561echo "$as_me: failed program was:" >&5
15562cat conftest.$ac_ext >&5
15563( exit $ac_status )
15564ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000015565fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015566rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15567fi
Vladimir Marangozova6180282000-07-12 05:05:06 +000015568fi
15569
Martin v. Löwis11437992002-04-12 09:54:03 +000015570echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
15571echo "${ECHO_T}$ac_cv_rshift_extends_sign" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000015572if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015573then
Martin v. Löwis11437992002-04-12 09:54:03 +000015574
15575cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015576#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015577_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015578
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015579fi
15580
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015581# check for getc_unlocked and related locking functions
Martin v. Löwis11437992002-04-12 09:54:03 +000015582echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
15583echo $ECHO_N "checking for getc_unlocked() and friends... $ECHO_C" >&6
15584if test "${ac_cv_have_getc_unlocked+set}" = set; then
15585 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015586else
Martin v. Löwis11437992002-04-12 09:54:03 +000015587
15588cat >conftest.$ac_ext <<_ACEOF
15589#line $LINENO "configure"
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015590#include "confdefs.h"
15591#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015592#ifdef F77_DUMMY_MAIN
15593# ifdef __cplusplus
15594 extern "C"
15595# endif
15596 int F77_DUMMY_MAIN() { return 1; }
15597#endif
15598int
15599main ()
15600{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015601
15602 FILE *f = fopen("/dev/null", "r");
15603 flockfile(f);
15604 getc_unlocked(f);
15605 funlockfile(f);
15606
Martin v. Löwis11437992002-04-12 09:54:03 +000015607 ;
15608 return 0;
15609}
15610_ACEOF
15611rm -f conftest.$ac_objext conftest$ac_exeext
15612if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15613 (eval $ac_link) 2>&5
15614 ac_status=$?
15615 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15616 (exit $ac_status); } &&
15617 { ac_try='test -s conftest$ac_exeext'
15618 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15619 (eval $ac_try) 2>&5
15620 ac_status=$?
15621 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15622 (exit $ac_status); }; }; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015623 ac_cv_have_getc_unlocked=yes
15624else
Martin v. Löwis11437992002-04-12 09:54:03 +000015625 echo "$as_me: failed program was:" >&5
15626cat conftest.$ac_ext >&5
15627ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015628fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015629rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015630fi
15631
Martin v. Löwis11437992002-04-12 09:54:03 +000015632echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
15633echo "${ECHO_T}$ac_cv_have_getc_unlocked" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015634if test "$ac_cv_have_getc_unlocked" = yes
15635then
Martin v. Löwis11437992002-04-12 09:54:03 +000015636
15637cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015638#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015639_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000015640
15641fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000015642
Martin v. Löwis0daad592001-09-30 21:09:59 +000015643# check for readline 4.0
Martin v. Löwis11437992002-04-12 09:54:03 +000015644echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
15645echo $ECHO_N "checking for rl_pre_input_hook in -lreadline... $ECHO_C" >&6
15646if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
15647 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000015648else
Martin v. Löwis11437992002-04-12 09:54:03 +000015649 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum353ae582001-07-10 16:45:32 +000015650LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015651cat >conftest.$ac_ext <<_ACEOF
15652#line $LINENO "configure"
Guido van Rossum353ae582001-07-10 16:45:32 +000015653#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015654
Guido van Rossum353ae582001-07-10 16:45:32 +000015655/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015656#ifdef __cplusplus
15657extern "C"
15658#endif
Guido van Rossum353ae582001-07-10 16:45:32 +000015659/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015660 builtin and then its argument prototype would still apply. */
15661char rl_pre_input_hook ();
15662#ifdef F77_DUMMY_MAIN
15663# ifdef __cplusplus
15664 extern "C"
15665# endif
15666 int F77_DUMMY_MAIN() { return 1; }
15667#endif
15668int
15669main ()
15670{
15671rl_pre_input_hook ();
15672 ;
15673 return 0;
15674}
15675_ACEOF
15676rm -f conftest.$ac_objext conftest$ac_exeext
15677if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15678 (eval $ac_link) 2>&5
15679 ac_status=$?
15680 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15681 (exit $ac_status); } &&
15682 { ac_try='test -s conftest$ac_exeext'
15683 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15684 (eval $ac_try) 2>&5
15685 ac_status=$?
15686 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15687 (exit $ac_status); }; }; then
15688 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000015689else
Martin v. Löwis11437992002-04-12 09:54:03 +000015690 echo "$as_me: failed program was:" >&5
15691cat conftest.$ac_ext >&5
15692ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000015693fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015694rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15695LIBS=$ac_check_lib_save_LIBS
15696fi
15697echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
15698echo "${ECHO_T}$ac_cv_lib_readline_rl_pre_input_hook" >&6
15699if test $ac_cv_lib_readline_rl_pre_input_hook = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000015700
Martin v. Löwis11437992002-04-12 09:54:03 +000015701cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000015702#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015703_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000015704
Martin v. Löwis0daad592001-09-30 21:09:59 +000015705fi
15706
Michael W. Hudson54241132001-12-07 15:38:26 +000015707
Martin v. Löwis0daad592001-09-30 21:09:59 +000015708# check for readline 4.2
Martin v. Löwis11437992002-04-12 09:54:03 +000015709echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
15710echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6
15711if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
15712 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000015713else
Martin v. Löwis11437992002-04-12 09:54:03 +000015714 ac_check_lib_save_LIBS=$LIBS
Martin v. Löwis0daad592001-09-30 21:09:59 +000015715LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015716cat >conftest.$ac_ext <<_ACEOF
15717#line $LINENO "configure"
Martin v. Löwis0daad592001-09-30 21:09:59 +000015718#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015719
Martin v. Löwis0daad592001-09-30 21:09:59 +000015720/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015721#ifdef __cplusplus
15722extern "C"
15723#endif
Martin v. Löwis0daad592001-09-30 21:09:59 +000015724/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015725 builtin and then its argument prototype would still apply. */
15726char rl_completion_matches ();
15727#ifdef F77_DUMMY_MAIN
15728# ifdef __cplusplus
15729 extern "C"
15730# endif
15731 int F77_DUMMY_MAIN() { return 1; }
15732#endif
15733int
15734main ()
15735{
15736rl_completion_matches ();
15737 ;
15738 return 0;
15739}
15740_ACEOF
15741rm -f conftest.$ac_objext conftest$ac_exeext
15742if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15743 (eval $ac_link) 2>&5
15744 ac_status=$?
15745 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15746 (exit $ac_status); } &&
15747 { ac_try='test -s conftest$ac_exeext'
15748 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15749 (eval $ac_try) 2>&5
15750 ac_status=$?
15751 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15752 (exit $ac_status); }; }; then
15753 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000015754else
Martin v. Löwis11437992002-04-12 09:54:03 +000015755 echo "$as_me: failed program was:" >&5
15756cat conftest.$ac_ext >&5
15757ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000015758fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015759rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
15760LIBS=$ac_check_lib_save_LIBS
15761fi
15762echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
15763echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6
15764if test $ac_cv_lib_readline_rl_completion_matches = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000015765
Martin v. Löwis11437992002-04-12 09:54:03 +000015766cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000015767#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015768_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000015769
Guido van Rossum353ae582001-07-10 16:45:32 +000015770fi
15771
Jack Jansendd19cf82001-12-06 22:36:17 +000015772
Martin v. Löwis11437992002-04-12 09:54:03 +000015773echo "$as_me:$LINENO: checking for broken nice()" >&5
15774echo $ECHO_N "checking for broken nice()... $ECHO_C" >&6
15775if test "${ac_cv_broken_nice+set}" = set; then
15776 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000015777else
Martin v. Löwis11437992002-04-12 09:54:03 +000015778
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015779if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000015780 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015781else
Martin v. Löwis11437992002-04-12 09:54:03 +000015782 cat >conftest.$ac_ext <<_ACEOF
15783#line $LINENO "configure"
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015784#include "confdefs.h"
15785
15786int main()
15787{
15788 int val1 = nice(1);
15789 if (val1 != -1 && val1 == nice(2))
15790 exit(0);
15791 exit(1);
15792}
15793
Martin v. Löwis11437992002-04-12 09:54:03 +000015794_ACEOF
15795rm -f conftest$ac_exeext
15796if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15797 (eval $ac_link) 2>&5
15798 ac_status=$?
15799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15800 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15801 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15802 (eval $ac_try) 2>&5
15803 ac_status=$?
15804 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15805 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015806 ac_cv_broken_nice=yes
15807else
Martin v. Löwis11437992002-04-12 09:54:03 +000015808 echo "$as_me: program exited with status $ac_status" >&5
15809echo "$as_me: failed program was:" >&5
15810cat conftest.$ac_ext >&5
15811( exit $ac_status )
15812ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015813fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015814rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15815fi
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015816fi
15817
Martin v. Löwis11437992002-04-12 09:54:03 +000015818echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
15819echo "${ECHO_T}$ac_cv_broken_nice" >&6
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015820if test "$ac_cv_broken_nice" = yes
15821then
Martin v. Löwis11437992002-04-12 09:54:03 +000015822
15823cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015824#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015825_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000015826
15827fi
15828
Martin v. Löwis94717ed2002-09-09 14:24:16 +000015829# Look for subsecond timestamps in struct stat
15830echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
15831echo $ECHO_N "checking for tv_nsec in struct stat... $ECHO_C" >&6
15832if test "${ac_cv_stat_tv_nsec+set}" = set; then
15833 echo $ECHO_N "(cached) $ECHO_C" >&6
15834else
15835 cat >conftest.$ac_ext <<_ACEOF
15836#line $LINENO "configure"
15837#include "confdefs.h"
15838#include <sys/stat.h>
15839#ifdef F77_DUMMY_MAIN
15840# ifdef __cplusplus
15841 extern "C"
15842# endif
15843 int F77_DUMMY_MAIN() { return 1; }
15844#endif
15845int
15846main ()
15847{
15848
15849struct stat st;
15850st.st_mtim.tv_nsec = 1;
15851
15852 ;
15853 return 0;
15854}
15855_ACEOF
15856rm -f conftest.$ac_objext
15857if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15858 (eval $ac_compile) 2>&5
15859 ac_status=$?
15860 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15861 (exit $ac_status); } &&
15862 { ac_try='test -s conftest.$ac_objext'
15863 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15864 (eval $ac_try) 2>&5
15865 ac_status=$?
15866 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15867 (exit $ac_status); }; }; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000015868 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000015869else
15870 echo "$as_me: failed program was:" >&5
15871cat conftest.$ac_ext >&5
15872ac_cv_stat_tv_nsec=no
15873fi
15874rm -f conftest.$ac_objext conftest.$ac_ext
15875fi
15876
15877echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
15878echo "${ECHO_T}$ac_cv_stat_tv_nsec" >&6
15879if test "$ac_cv_stat_tv_nsec" = yes
15880then
15881
15882cat >>confdefs.h <<\_ACEOF
15883#define HAVE_STAT_TV_NSEC 1
15884_ACEOF
15885
15886fi
15887
Jack Jansen666b1e72001-10-31 12:11:48 +000015888# On HP/UX 11.0, mvwdelch is a block with a return statement
Martin v. Löwis11437992002-04-12 09:54:03 +000015889echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
15890echo $ECHO_N "checking whether mvwdelch is an expression... $ECHO_C" >&6
15891if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
15892 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000015893else
Martin v. Löwis11437992002-04-12 09:54:03 +000015894 cat >conftest.$ac_ext <<_ACEOF
15895#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000015896#include "confdefs.h"
15897#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015898#ifdef F77_DUMMY_MAIN
15899# ifdef __cplusplus
15900 extern "C"
15901# endif
15902 int F77_DUMMY_MAIN() { return 1; }
15903#endif
15904int
15905main ()
15906{
Jack Jansen666b1e72001-10-31 12:11:48 +000015907
15908 int rtn;
15909 rtn = mvwdelch(0,0,0);
15910
Martin v. Löwis11437992002-04-12 09:54:03 +000015911 ;
15912 return 0;
15913}
15914_ACEOF
15915rm -f conftest.$ac_objext
15916if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15917 (eval $ac_compile) 2>&5
15918 ac_status=$?
15919 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15920 (exit $ac_status); } &&
15921 { ac_try='test -s conftest.$ac_objext'
15922 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15923 (eval $ac_try) 2>&5
15924 ac_status=$?
15925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15926 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000015927 ac_cv_mvwdelch_is_expression=yes
15928else
Martin v. Löwis11437992002-04-12 09:54:03 +000015929 echo "$as_me: failed program was:" >&5
15930cat conftest.$ac_ext >&5
15931ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000015932fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015933rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000015934fi
15935
Martin v. Löwis11437992002-04-12 09:54:03 +000015936echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
15937echo "${ECHO_T}$ac_cv_mvwdelch_is_expression" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000015938
15939if test "$ac_cv_mvwdelch_is_expression" = yes
15940then
Martin v. Löwis11437992002-04-12 09:54:03 +000015941
15942cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000015943#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015944_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000015945
15946fi
15947
Martin v. Löwis11437992002-04-12 09:54:03 +000015948echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
15949echo $ECHO_N "checking whether WINDOW has _flags... $ECHO_C" >&6
15950if test "${ac_cv_window_has_flags+set}" = set; then
15951 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000015952else
Martin v. Löwis11437992002-04-12 09:54:03 +000015953 cat >conftest.$ac_ext <<_ACEOF
15954#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000015955#include "confdefs.h"
15956#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015957#ifdef F77_DUMMY_MAIN
15958# ifdef __cplusplus
15959 extern "C"
15960# endif
15961 int F77_DUMMY_MAIN() { return 1; }
15962#endif
15963int
15964main ()
15965{
Jack Jansen666b1e72001-10-31 12:11:48 +000015966
15967 WINDOW *w;
15968 w->_flags = 0;
15969
Martin v. Löwis11437992002-04-12 09:54:03 +000015970 ;
15971 return 0;
15972}
15973_ACEOF
15974rm -f conftest.$ac_objext
15975if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15976 (eval $ac_compile) 2>&5
15977 ac_status=$?
15978 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15979 (exit $ac_status); } &&
15980 { ac_try='test -s conftest.$ac_objext'
15981 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15982 (eval $ac_try) 2>&5
15983 ac_status=$?
15984 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15985 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000015986 ac_cv_window_has_flags=yes
15987else
Martin v. Löwis11437992002-04-12 09:54:03 +000015988 echo "$as_me: failed program was:" >&5
15989cat conftest.$ac_ext >&5
15990ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000015991fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015992rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000015993fi
15994
Martin v. Löwis11437992002-04-12 09:54:03 +000015995echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
15996echo "${ECHO_T}$ac_cv_window_has_flags" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000015997
Jack Jansen666b1e72001-10-31 12:11:48 +000015998
15999if test "$ac_cv_window_has_flags" = yes
16000then
Martin v. Löwis11437992002-04-12 09:54:03 +000016001
16002cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016003#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016004_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016005
16006fi
16007
Guido van Rossum95713eb2000-05-18 20:53:31 +000016008# THIS MUST BE LAST, IT CAN BREAK OTHER TESTS!
16009# Add sys/socket.h to confdefs.h
16010cat >> confdefs.h <<\EOF
16011#ifdef HAVE_SYS_SOCKET_H
16012#include <sys/socket.h>
16013#endif
16014EOF
Martin v. Löwis11437992002-04-12 09:54:03 +000016015echo "$as_me:$LINENO: checking for socklen_t" >&5
16016echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
16017if test "${ac_cv_type_socklen_t+set}" = set; then
16018 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000016019else
Martin v. Löwis11437992002-04-12 09:54:03 +000016020 cat >conftest.$ac_ext <<_ACEOF
16021#line $LINENO "configure"
Guido van Rossum95713eb2000-05-18 20:53:31 +000016022#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016023$ac_includes_default
16024#ifdef F77_DUMMY_MAIN
16025# ifdef __cplusplus
16026 extern "C"
16027# endif
16028 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016029#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016030int
16031main ()
16032{
16033if ((socklen_t *) 0)
16034 return 0;
16035if (sizeof (socklen_t))
16036 return 0;
16037 ;
16038 return 0;
16039}
16040_ACEOF
16041rm -f conftest.$ac_objext
16042if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16043 (eval $ac_compile) 2>&5
16044 ac_status=$?
16045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16046 (exit $ac_status); } &&
16047 { ac_try='test -s conftest.$ac_objext'
16048 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16049 (eval $ac_try) 2>&5
16050 ac_status=$?
16051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16052 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000016053 ac_cv_type_socklen_t=yes
Guido van Rossum95713eb2000-05-18 20:53:31 +000016054else
Martin v. Löwis11437992002-04-12 09:54:03 +000016055 echo "$as_me: failed program was:" >&5
16056cat conftest.$ac_ext >&5
16057ac_cv_type_socklen_t=no
Guido van Rossum95713eb2000-05-18 20:53:31 +000016058fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016059rm -f conftest.$ac_objext conftest.$ac_ext
16060fi
16061echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
16062echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
16063if test $ac_cv_type_socklen_t = yes; then
16064 :
16065else
Guido van Rossum95713eb2000-05-18 20:53:31 +000016066
Martin v. Löwis11437992002-04-12 09:54:03 +000016067cat >>confdefs.h <<_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016068#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000016069_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016070
16071fi
16072
Michael W. Hudson54241132001-12-07 15:38:26 +000016073
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016074#AC_MSG_CHECKING(for Modules/Setup)
16075#if test ! -f Modules/Setup ; then
16076# if test ! -d Modules ; then
16077# mkdir Modules
16078# fi
16079# cp "$srcdir/Modules/Setup.dist" Modules/Setup
16080# AC_MSG_RESULT(creating)
16081#else
16082# AC_MSG_RESULT(already exists)
16083#fi
16084
Michael W. Hudson54241132001-12-07 15:38:26 +000016085
16086
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000016087for h in `(cd $srcdir;echo Python/thread_*.h)`
16088do
16089 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
16090done
16091
Michael W. Hudson54241132001-12-07 15:38:26 +000016092
Jack Jansen0b06be72002-06-21 14:48:38 +000016093SRCDIRS="Parser Grammar Objects Python Modules Mac Mac/Python"
Martin v. Löwis11437992002-04-12 09:54:03 +000016094echo "$as_me:$LINENO: checking for build directories" >&5
16095echo $ECHO_N "checking for build directories... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016096for dir in $SRCDIRS; do
16097 if test ! -d $dir; then
16098 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000016099 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016100done
Martin v. Löwis11437992002-04-12 09:54:03 +000016101echo "$as_me:$LINENO: result: done" >&5
16102echo "${ECHO_T}done" >&6
Fred Drake036144d2000-10-26 17:09:35 +000016103
Guido van Rossum627b2d71993-12-24 10:39:16 +000016104# generate output files
Martin v. Löwis11437992002-04-12 09:54:03 +000016105ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config"
16106cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016107# This file is a shell script that caches the results of configure
16108# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000016109# scripts and configure runs, see configure's option --config-cache.
16110# It is not useful on other systems. If it contains results you don't
16111# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016112#
Martin v. Löwis11437992002-04-12 09:54:03 +000016113# config.status only pays attention to the cache file if you give it
16114# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016115#
Martin v. Löwis11437992002-04-12 09:54:03 +000016116# `ac_cv_env_foo' variables (set or unset) will be overriden when
16117# loading this file, other *unset* `ac_cv_foo' will be assigned the
16118# following values.
16119
16120_ACEOF
16121
Guido van Rossumf78abae1997-01-21 22:02:36 +000016122# The following way of writing the cache mishandles newlines in values,
16123# but we know of no workaround that is simple, portable, and efficient.
16124# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016125# Ultrix sh set writes to stderr and can't be redirected directly,
16126# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwis11437992002-04-12 09:54:03 +000016127{
16128 (set) 2>&1 |
16129 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16130 *ac_space=\ *)
16131 # `set' does not quote correctly, so add quotes (double-quote
16132 # substitution turns \\\\ into \\, and sed turns \\ into \).
16133 sed -n \
16134 "s/'/'\\\\''/g;
16135 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16136 ;;
16137 *)
16138 # `set' quotes correctly as required by POSIX, so do not add quotes.
16139 sed -n \
16140 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16141 ;;
16142 esac;
16143} |
16144 sed '
16145 t clear
16146 : clear
16147 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16148 t end
16149 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16150 : end' >>confcache
16151if cmp -s $cache_file confcache; then :; else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016152 if test -w $cache_file; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016153 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16154 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016155 else
16156 echo "not updating unwritable cache $cache_file"
16157 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016158fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016159rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000016160
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016161test "x$prefix" = xNONE && prefix=$ac_default_prefix
16162# Let make expand exec_prefix.
16163test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000016164
Martin v. Löwis11437992002-04-12 09:54:03 +000016165# VPATH may cause trouble with some makes, so we remove $(srcdir),
16166# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16167# trailing colons and then remove the whole line if VPATH becomes empty
16168# (actually we leave an empty line to preserve line numbers).
Guido van Rossum7f43da71994-08-01 12:15:30 +000016169if test "x$srcdir" = x.; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016170 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16171s/:*\$(srcdir):*/:/;
16172s/:*\${srcdir}:*/:/;
16173s/:*@srcdir@:*/:/;
16174s/^\([^=]*=[ ]*\):*/\1/;
16175s/:*$//;
16176s/^[^=]*=[ ]*$//;
16177}'
Guido van Rossum7f43da71994-08-01 12:15:30 +000016178fi
16179
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016180DEFS=-DHAVE_CONFIG_H
16181
Martin v. Löwis11437992002-04-12 09:54:03 +000016182
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016183: ${CONFIG_STATUS=./config.status}
Martin v. Löwis11437992002-04-12 09:54:03 +000016184ac_clean_files_save=$ac_clean_files
16185ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16186{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
16187echo "$as_me: creating $CONFIG_STATUS" >&6;}
16188cat >$CONFIG_STATUS <<_ACEOF
16189#! $SHELL
16190# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016191# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016192# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000016193# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016194
Martin v. Löwis11437992002-04-12 09:54:03 +000016195debug=false
16196SHELL=\${CONFIG_SHELL-$SHELL}
16197_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016198
Martin v. Löwis11437992002-04-12 09:54:03 +000016199cat >>$CONFIG_STATUS <<\_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016200
Martin v. Löwis11437992002-04-12 09:54:03 +000016201## --------------------- ##
16202## M4sh Initialization. ##
16203## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000016204
Martin v. Löwis11437992002-04-12 09:54:03 +000016205# Be Bourne compatible
16206if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16207 emulate sh
16208 NULLCMD=:
16209elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16210 set -o posix
Michael W. Hudson54241132001-12-07 15:38:26 +000016211fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016212
Martin v. Löwis11437992002-04-12 09:54:03 +000016213# NLS nuisances.
16214# Support unset when possible.
16215if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16216 as_unset=unset
16217else
16218 as_unset=false
16219fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016220
Martin v. Löwis11437992002-04-12 09:54:03 +000016221(set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
16222 { $as_unset LANG || test "${LANG+set}" != set; } ||
16223 { LANG=C; export LANG; }
16224(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
16225 { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
16226 { LC_ALL=C; export LC_ALL; }
16227(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
16228 { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
16229 { LC_TIME=C; export LC_TIME; }
16230(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
16231 { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
16232 { LC_CTYPE=C; export LC_CTYPE; }
16233(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
16234 { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
16235 { LANGUAGE=C; export LANGUAGE; }
16236(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
16237 { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
16238 { LC_COLLATE=C; export LC_COLLATE; }
16239(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
16240 { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
16241 { LC_NUMERIC=C; export LC_NUMERIC; }
16242(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
16243 { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
16244 { LC_MESSAGES=C; export LC_MESSAGES; }
16245
16246
16247# Name of the executable.
16248as_me=`(basename "$0") 2>/dev/null ||
16249$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16250 X"$0" : 'X\(//\)$' \| \
16251 X"$0" : 'X\(/\)$' \| \
16252 . : '\(.\)' 2>/dev/null ||
16253echo X/"$0" |
16254 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
16255 /^X\/\(\/\/\)$/{ s//\1/; q; }
16256 /^X\/\(\/\).*/{ s//\1/; q; }
16257 s/.*/./; q'`
16258
16259# PATH needs CR, and LINENO needs CR and PATH.
16260# Avoid depending upon Character Ranges.
16261as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16262as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16263as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16264as_cr_digits='0123456789'
16265as_cr_alnum=$as_cr_Letters$as_cr_digits
16266
16267# The user is always right.
16268if test "${PATH_SEPARATOR+set}" != set; then
16269 echo "#! /bin/sh" >conftest.sh
16270 echo "exit 0" >>conftest.sh
16271 chmod +x conftest.sh
16272 if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
16273 PATH_SEPARATOR=';'
16274 else
16275 PATH_SEPARATOR=:
16276 fi
16277 rm -f conftest.sh
16278fi
16279
16280
16281 as_lineno_1=$LINENO
16282 as_lineno_2=$LINENO
16283 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16284 test "x$as_lineno_1" != "x$as_lineno_2" &&
16285 test "x$as_lineno_3" = "x$as_lineno_2" || {
16286 # Find who we are. Look in the path if we contain no path at all
16287 # relative or not.
16288 case $0 in
16289 *[\\/]* ) as_myself=$0 ;;
16290 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16291for as_dir in $PATH
16292do
16293 IFS=$as_save_IFS
16294 test -z "$as_dir" && as_dir=.
16295 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16296done
16297
16298 ;;
16299 esac
16300 # We did not find ourselves, most probably we were run as `sh COMMAND'
16301 # in which case we are not to be found in the path.
16302 if test "x$as_myself" = x; then
16303 as_myself=$0
16304 fi
16305 if test ! -f "$as_myself"; then
16306 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
16307echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
16308 { (exit 1); exit 1; }; }
16309 fi
16310 case $CONFIG_SHELL in
16311 '')
16312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16313for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
16314do
16315 IFS=$as_save_IFS
16316 test -z "$as_dir" && as_dir=.
16317 for as_base in sh bash ksh sh5; do
16318 case $as_dir in
16319 /*)
16320 if ("$as_dir/$as_base" -c '
16321 as_lineno_1=$LINENO
16322 as_lineno_2=$LINENO
16323 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16324 test "x$as_lineno_1" != "x$as_lineno_2" &&
16325 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
16326 CONFIG_SHELL=$as_dir/$as_base
16327 export CONFIG_SHELL
16328 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
16329 fi;;
16330 esac
16331 done
16332done
16333;;
Jack Jansendd19cf82001-12-06 22:36:17 +000016334 esac
16335
Martin v. Löwis11437992002-04-12 09:54:03 +000016336 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
16337 # uniformly replaced by the line number. The first 'sed' inserts a
16338 # line-number line before each line; the second 'sed' does the real
16339 # work. The second script uses 'N' to pair each line-number line
16340 # with the numbered line, and appends trailing '-' during
16341 # substitution so that $LINENO is not a special case at line end.
16342 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
16343 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
16344 sed '=' <$as_myself |
16345 sed '
16346 N
16347 s,$,-,
16348 : loop
16349 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
16350 t loop
16351 s,-$,,
16352 s,^['$as_cr_digits']*\n,,
16353 ' >$as_me.lineno &&
16354 chmod +x $as_me.lineno ||
16355 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
16356echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
16357 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016358
Martin v. Löwis11437992002-04-12 09:54:03 +000016359 # Don't try to exec as it changes $[0], causing all sort of problems
16360 # (the dirname of $[0] is not the place where we might find the
16361 # original and so on. Autoconf is especially sensible to this).
16362 . ./$as_me.lineno
16363 # Exit status is that of the last command.
16364 exit
16365}
16366
16367
16368case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
16369 *c*,-n*) ECHO_N= ECHO_C='
16370' ECHO_T=' ' ;;
16371 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
16372 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
16373esac
16374
16375if expr a : '\(a\)' >/dev/null 2>&1; then
16376 as_expr=expr
16377else
16378 as_expr=false
16379fi
16380
16381rm -f conf$$ conf$$.exe conf$$.file
16382echo >conf$$.file
16383if ln -s conf$$.file conf$$ 2>/dev/null; then
16384 # We could just check for DJGPP; but this test a) works b) is more generic
16385 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16386 if test -f conf$$.exe; then
16387 # Don't use ln at all; we don't have any links
16388 as_ln_s='cp -p'
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016389 else
Martin v. Löwis11437992002-04-12 09:54:03 +000016390 as_ln_s='ln -s'
16391 fi
16392elif ln conf$$.file conf$$ 2>/dev/null; then
16393 as_ln_s=ln
16394else
16395 as_ln_s='cp -p'
16396fi
16397rm -f conf$$ conf$$.exe conf$$.file
16398
16399as_executable_p="test -f"
16400
16401# Sed expression to map a string onto a valid CPP name.
16402as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
16403
16404# Sed expression to map a string onto a valid variable name.
16405as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
16406
16407
16408# IFS
16409# We need space, tab and new line, in precisely that order.
16410as_nl='
16411'
16412IFS=" $as_nl"
16413
16414# CDPATH.
16415$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
16416
16417exec 6>&1
16418
16419# Open the log real soon, to keep \$[0] and so on meaningful, and to
16420# report actual input values of CONFIG_FILES etc. instead of their
16421# values after options handling. Logging --version etc. is OK.
16422exec 5>>config.log
16423{
16424 echo
16425 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16426## Running $as_me. ##
16427_ASBOX
16428} >&5
16429cat >&5 <<_CSEOF
16430
16431This file was extended by $as_me, which was
16432generated by GNU Autoconf 2.53. Invocation command line was
16433
16434 CONFIG_FILES = $CONFIG_FILES
16435 CONFIG_HEADERS = $CONFIG_HEADERS
16436 CONFIG_LINKS = $CONFIG_LINKS
16437 CONFIG_COMMANDS = $CONFIG_COMMANDS
16438 $ $0 $@
16439
16440_CSEOF
16441echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
16442echo >&5
16443_ACEOF
16444
16445# Files that config.status was made for.
16446if test -n "$ac_config_files"; then
16447 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
16448fi
16449
16450if test -n "$ac_config_headers"; then
16451 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
16452fi
16453
16454if test -n "$ac_config_links"; then
16455 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
16456fi
16457
16458if test -n "$ac_config_commands"; then
16459 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
16460fi
16461
16462cat >>$CONFIG_STATUS <<\_ACEOF
16463
16464ac_cs_usage="\
16465\`$as_me' instantiates files from templates according to the
16466current configuration.
16467
16468Usage: $0 [OPTIONS] [FILE]...
16469
16470 -h, --help print this help, then exit
16471 -V, --version print version number, then exit
16472 -d, --debug don't remove temporary files
16473 --recheck update $as_me by reconfiguring in the same conditions
16474 --file=FILE[:TEMPLATE]
16475 instantiate the configuration file FILE
16476 --header=FILE[:TEMPLATE]
16477 instantiate the configuration header FILE
16478
16479Configuration files:
16480$config_files
16481
16482Configuration headers:
16483$config_headers
16484
16485Report bugs to <bug-autoconf@gnu.org>."
16486_ACEOF
16487
16488cat >>$CONFIG_STATUS <<_ACEOF
16489ac_cs_version="\\
16490config.status
16491configured by $0, generated by GNU Autoconf 2.53,
16492 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
16493
16494Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
16495Free Software Foundation, Inc.
16496This config.status script is free software; the Free Software Foundation
16497gives unlimited permission to copy, distribute and modify it."
16498srcdir=$srcdir
16499INSTALL="$INSTALL"
16500_ACEOF
16501
16502cat >>$CONFIG_STATUS <<\_ACEOF
16503# If no file are specified by the user, then we need to provide default
16504# value. By we need to know if files were specified by the user.
16505ac_need_defaults=:
16506while test $# != 0
16507do
16508 case $1 in
16509 --*=*)
16510 ac_option=`expr "x$1" : 'x\([^=]*\)='`
16511 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
16512 shift
16513 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
16514 shift
16515 ;;
16516 -*);;
16517 *) # This is not an option, so the user has probably given explicit
16518 # arguments.
16519 ac_need_defaults=false;;
16520 esac
16521
16522 case $1 in
16523 # Handling of the options.
16524_ACEOF
16525cat >>$CONFIG_STATUS <<_ACEOF
16526 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16527 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
16528 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
16529_ACEOF
16530cat >>$CONFIG_STATUS <<\_ACEOF
16531 --version | --vers* | -V )
16532 echo "$ac_cs_version"; exit 0 ;;
16533 --he | --h)
16534 # Conflict between --help and --header
16535 { { echo "$as_me:$LINENO: error: ambiguous option: $1
16536Try \`$0 --help' for more information." >&5
16537echo "$as_me: error: ambiguous option: $1
16538Try \`$0 --help' for more information." >&2;}
16539 { (exit 1); exit 1; }; };;
16540 --help | --hel | -h )
16541 echo "$ac_cs_usage"; exit 0 ;;
16542 --debug | --d* | -d )
16543 debug=: ;;
16544 --file | --fil | --fi | --f )
16545 shift
16546 CONFIG_FILES="$CONFIG_FILES $1"
16547 ac_need_defaults=false;;
16548 --header | --heade | --head | --hea )
16549 shift
16550 CONFIG_HEADERS="$CONFIG_HEADERS $1"
16551 ac_need_defaults=false;;
16552
16553 # This is an error.
16554 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
16555Try \`$0 --help' for more information." >&5
16556echo "$as_me: error: unrecognized option: $1
16557Try \`$0 --help' for more information." >&2;}
16558 { (exit 1); exit 1; }; } ;;
16559
16560 *) ac_config_targets="$ac_config_targets $1" ;;
16561
16562 esac
16563 shift
16564done
16565
16566_ACEOF
16567
16568
16569
16570
16571
16572cat >>$CONFIG_STATUS <<\_ACEOF
16573for ac_config_target in $ac_config_targets
16574do
16575 case "$ac_config_target" in
16576 # Handling of arguments.
16577 "Makefile.pre" ) CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
16578 "Modules/Setup.config" ) CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
16579 "pyconfig.h" ) CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
16580 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
16581echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
16582 { (exit 1); exit 1; }; };;
16583 esac
16584done
16585
16586# If the user did not use the arguments to specify the items to instantiate,
16587# then the envvar interface is used. Set only those that are not.
16588# We use the long form for the default assignment because of an extremely
16589# bizarre bug on SunOS 4.1.3.
16590if $ac_need_defaults; then
16591 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16592 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16593fi
16594
16595# Create a temporary directory, and hook for its removal unless debugging.
16596$debug ||
16597{
16598 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
16599 trap '{ (exit 1); exit 1; }' 1 2 13 15
16600}
16601
16602# Create a (secure) tmp directory for tmp files.
16603: ${TMPDIR=/tmp}
16604{
16605 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
16606 test -n "$tmp" && test -d "$tmp"
16607} ||
16608{
16609 tmp=$TMPDIR/cs$$-$RANDOM
16610 (umask 077 && mkdir $tmp)
16611} ||
16612{
16613 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
16614 { (exit 1); exit 1; }
16615}
16616
16617_ACEOF
16618
16619cat >>$CONFIG_STATUS <<_ACEOF
16620
16621#
16622# CONFIG_FILES section.
16623#
16624
16625# No need to generate the scripts if there are no CONFIG_FILES.
16626# This happens for instance when ./config.status config.h
16627if test -n "\$CONFIG_FILES"; then
16628 # Protect against being on the right side of a sed subst in config.status.
16629 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
16630 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
16631s,@SHELL@,$SHELL,;t t
16632s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
16633s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
16634s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
16635s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
16636s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
16637s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
16638s,@exec_prefix@,$exec_prefix,;t t
16639s,@prefix@,$prefix,;t t
16640s,@program_transform_name@,$program_transform_name,;t t
16641s,@bindir@,$bindir,;t t
16642s,@sbindir@,$sbindir,;t t
16643s,@libexecdir@,$libexecdir,;t t
16644s,@datadir@,$datadir,;t t
16645s,@sysconfdir@,$sysconfdir,;t t
16646s,@sharedstatedir@,$sharedstatedir,;t t
16647s,@localstatedir@,$localstatedir,;t t
16648s,@libdir@,$libdir,;t t
16649s,@includedir@,$includedir,;t t
16650s,@oldincludedir@,$oldincludedir,;t t
16651s,@infodir@,$infodir,;t t
16652s,@mandir@,$mandir,;t t
16653s,@build_alias@,$build_alias,;t t
16654s,@host_alias@,$host_alias,;t t
16655s,@target_alias@,$target_alias,;t t
16656s,@DEFS@,$DEFS,;t t
16657s,@ECHO_C@,$ECHO_C,;t t
16658s,@ECHO_N@,$ECHO_N,;t t
16659s,@ECHO_T@,$ECHO_T,;t t
16660s,@LIBS@,$LIBS,;t t
16661s,@VERSION@,$VERSION,;t t
16662s,@SOVERSION@,$SOVERSION,;t t
16663s,@CONFIG_ARGS@,$CONFIG_ARGS,;t t
16664s,@PYTHONFRAMEWORK@,$PYTHONFRAMEWORK,;t t
16665s,@PYTHONFRAMEWORKDIR@,$PYTHONFRAMEWORKDIR,;t t
16666s,@PYTHONFRAMEWORKPREFIX@,$PYTHONFRAMEWORKPREFIX,;t t
16667s,@PYTHONFRAMEWORKINSTALLDIR@,$PYTHONFRAMEWORKINSTALLDIR,;t t
16668s,@MACHDEP@,$MACHDEP,;t t
16669s,@SGI_ABI@,$SGI_ABI,;t t
16670s,@CXX@,$CXX,;t t
16671s,@MAINOBJ@,$MAINOBJ,;t t
16672s,@EXEEXT@,$EXEEXT,;t t
16673s,@CC@,$CC,;t t
16674s,@CFLAGS@,$CFLAGS,;t t
16675s,@LDFLAGS@,$LDFLAGS,;t t
16676s,@CPPFLAGS@,$CPPFLAGS,;t t
16677s,@ac_ct_CC@,$ac_ct_CC,;t t
16678s,@OBJEXT@,$OBJEXT,;t t
16679s,@CPP@,$CPP,;t t
16680s,@BUILDEXEEXT@,$BUILDEXEEXT,;t t
16681s,@LIBRARY@,$LIBRARY,;t t
16682s,@LDLIBRARY@,$LDLIBRARY,;t t
16683s,@DLLLIBRARY@,$DLLLIBRARY,;t t
16684s,@BLDLIBRARY@,$BLDLIBRARY,;t t
16685s,@LDLIBRARYDIR@,$LDLIBRARYDIR,;t t
16686s,@INSTSONAME@,$INSTSONAME,;t t
16687s,@RUNSHARED@,$RUNSHARED,;t t
16688s,@LINKCC@,$LINKCC,;t t
16689s,@RANLIB@,$RANLIB,;t t
16690s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
16691s,@AR@,$AR,;t t
16692s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
16693s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
16694s,@INSTALL_DATA@,$INSTALL_DATA,;t t
16695s,@LN@,$LN,;t t
16696s,@OPT@,$OPT,;t t
16697s,@LIBTOOL_CRUFT@,$LIBTOOL_CRUFT,;t t
16698s,@SO@,$SO,;t t
16699s,@LDSHARED@,$LDSHARED,;t t
16700s,@BLDSHARED@,$BLDSHARED,;t t
16701s,@CCSHARED@,$CCSHARED,;t t
16702s,@LINKFORSHARED@,$LINKFORSHARED,;t t
16703s,@CFLAGSFORSHARED@,$CFLAGSFORSHARED,;t t
Martin v. Löwisf90ae202002-06-11 06:22:31 +000016704s,@SHLIBS@,$SHLIBS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000016705s,@USE_SIGNAL_MODULE@,$USE_SIGNAL_MODULE,;t t
16706s,@SIGNAL_OBJS@,$SIGNAL_OBJS,;t t
16707s,@USE_THREAD_MODULE@,$USE_THREAD_MODULE,;t t
16708s,@LDLAST@,$LDLAST,;t t
16709s,@THREADOBJ@,$THREADOBJ,;t t
16710s,@DLINCLDIR@,$DLINCLDIR,;t t
16711s,@DYNLOADFILE@,$DYNLOADFILE,;t t
16712s,@MACHDEP_OBJS@,$MACHDEP_OBJS,;t t
16713s,@LIBOBJS@,$LIBOBJS,;t t
16714s,@HAVE_GETHOSTBYNAME_R_6_ARG@,$HAVE_GETHOSTBYNAME_R_6_ARG,;t t
16715s,@HAVE_GETHOSTBYNAME_R_5_ARG@,$HAVE_GETHOSTBYNAME_R_5_ARG,;t t
16716s,@HAVE_GETHOSTBYNAME_R_3_ARG@,$HAVE_GETHOSTBYNAME_R_3_ARG,;t t
16717s,@HAVE_GETHOSTBYNAME_R@,$HAVE_GETHOSTBYNAME_R,;t t
16718s,@HAVE_GETHOSTBYNAME@,$HAVE_GETHOSTBYNAME,;t t
16719s,@LIBM@,$LIBM,;t t
16720s,@LIBC@,$LIBC,;t t
16721s,@UNICODE_OBJS@,$UNICODE_OBJS,;t t
16722s,@THREADHEADERS@,$THREADHEADERS,;t t
16723s,@SRCDIRS@,$SRCDIRS,;t t
16724CEOF
16725
16726_ACEOF
16727
16728 cat >>$CONFIG_STATUS <<\_ACEOF
16729 # Split the substitutions into bite-sized pieces for seds with
16730 # small command number limits, like on Digital OSF/1 and HP-UX.
16731 ac_max_sed_lines=48
16732 ac_sed_frag=1 # Number of current file.
16733 ac_beg=1 # First line for current file.
16734 ac_end=$ac_max_sed_lines # Line after last line for current file.
16735 ac_more_lines=:
16736 ac_sed_cmds=
16737 while $ac_more_lines; do
16738 if test $ac_beg -gt 1; then
16739 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16740 else
16741 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
16742 fi
16743 if test ! -s $tmp/subs.frag; then
16744 ac_more_lines=false
16745 else
16746 # The purpose of the label and of the branching condition is to
16747 # speed up the sed processing (if there are no `@' at all, there
16748 # is no need to browse any of the substitutions).
16749 # These are the two extra sed commands mentioned above.
16750 (echo ':t
16751 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
16752 if test -z "$ac_sed_cmds"; then
16753 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
16754 else
16755 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
16756 fi
16757 ac_sed_frag=`expr $ac_sed_frag + 1`
16758 ac_beg=$ac_end
16759 ac_end=`expr $ac_end + $ac_max_sed_lines`
16760 fi
16761 done
16762 if test -z "$ac_sed_cmds"; then
16763 ac_sed_cmds=cat
16764 fi
16765fi # test -n "$CONFIG_FILES"
16766
16767_ACEOF
16768cat >>$CONFIG_STATUS <<\_ACEOF
16769for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
16770 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
16771 case $ac_file in
16772 - | *:- | *:-:* ) # input from stdin
16773 cat >$tmp/stdin
16774 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16775 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16776 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16777 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16778 * ) ac_file_in=$ac_file.in ;;
16779 esac
16780
16781 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
16782 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
16783$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16784 X"$ac_file" : 'X\(//\)[^/]' \| \
16785 X"$ac_file" : 'X\(//\)$' \| \
16786 X"$ac_file" : 'X\(/\)' \| \
16787 . : '\(.\)' 2>/dev/null ||
16788echo X"$ac_file" |
16789 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
16790 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
16791 /^X\(\/\/\)$/{ s//\1/; q; }
16792 /^X\(\/\).*/{ s//\1/; q; }
16793 s/.*/./; q'`
16794 { case "$ac_dir" in
16795 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
16796 *) as_incr_dir=.;;
16797esac
16798as_dummy="$ac_dir"
16799for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
16800 case $as_mkdir_dir in
16801 # Skip DOS drivespec
16802 ?:) as_incr_dir=$as_mkdir_dir ;;
16803 *)
16804 as_incr_dir=$as_incr_dir/$as_mkdir_dir
16805 test -d "$as_incr_dir" ||
16806 mkdir "$as_incr_dir" ||
16807 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
16808echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
16809 { (exit 1); exit 1; }; }
16810 ;;
16811 esac
16812done; }
16813
16814 ac_builddir=.
16815
16816if test "$ac_dir" != .; then
16817 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
16818 # A "../" for each directory in $ac_dir_suffix.
16819 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
16820else
16821 ac_dir_suffix= ac_top_builddir=
16822fi
16823
16824case $srcdir in
16825 .) # No --srcdir option. We are building in place.
16826 ac_srcdir=.
16827 if test -z "$ac_top_builddir"; then
16828 ac_top_srcdir=.
16829 else
16830 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
16831 fi ;;
16832 [\\/]* | ?:[\\/]* ) # Absolute path.
16833 ac_srcdir=$srcdir$ac_dir_suffix;
16834 ac_top_srcdir=$srcdir ;;
16835 *) # Relative path.
16836 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
16837 ac_top_srcdir=$ac_top_builddir$srcdir ;;
16838esac
16839# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
16840# absolute.
16841ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
16842ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
16843ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
16844ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
16845
16846
16847 case $INSTALL in
16848 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
16849 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
16850 esac
16851
16852 if test x"$ac_file" != x-; then
16853 { echo "$as_me:$LINENO: creating $ac_file" >&5
16854echo "$as_me: creating $ac_file" >&6;}
16855 rm -f "$ac_file"
16856 fi
16857 # Let's still pretend it is `configure' which instantiates (i.e., don't
16858 # use $as_me), people would be surprised to read:
16859 # /* config.h. Generated by config.status. */
16860 if test x"$ac_file" = x-; then
16861 configure_input=
16862 else
16863 configure_input="$ac_file. "
16864 fi
16865 configure_input=$configure_input"Generated from `echo $ac_file_in |
16866 sed 's,.*/,,'` by configure."
16867
16868 # First look for the input files in the build tree, otherwise in the
16869 # src tree.
16870 ac_file_inputs=`IFS=:
16871 for f in $ac_file_in; do
16872 case $f in
16873 -) echo $tmp/stdin ;;
16874 [\\/$]*)
16875 # Absolute (can't be DOS-style, as IFS=:)
16876 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
16877echo "$as_me: error: cannot find input file: $f" >&2;}
16878 { (exit 1); exit 1; }; }
16879 echo $f;;
16880 *) # Relative
16881 if test -f "$f"; then
16882 # Build tree
16883 echo $f
16884 elif test -f "$srcdir/$f"; then
16885 # Source tree
16886 echo $srcdir/$f
16887 else
16888 # /dev/null tree
16889 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
16890echo "$as_me: error: cannot find input file: $f" >&2;}
16891 { (exit 1); exit 1; }; }
16892 fi;;
16893 esac
16894 done` || { (exit 1); exit 1; }
16895_ACEOF
16896cat >>$CONFIG_STATUS <<_ACEOF
16897 sed "$ac_vpsub
16898$extrasub
16899_ACEOF
16900cat >>$CONFIG_STATUS <<\_ACEOF
16901:t
16902/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
16903s,@configure_input@,$configure_input,;t t
16904s,@srcdir@,$ac_srcdir,;t t
16905s,@abs_srcdir@,$ac_abs_srcdir,;t t
16906s,@top_srcdir@,$ac_top_srcdir,;t t
16907s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
16908s,@builddir@,$ac_builddir,;t t
16909s,@abs_builddir@,$ac_abs_builddir,;t t
16910s,@top_builddir@,$ac_top_builddir,;t t
16911s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
16912s,@INSTALL@,$ac_INSTALL,;t t
16913" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
16914 rm -f $tmp/stdin
16915 if test x"$ac_file" != x-; then
16916 mv $tmp/out $ac_file
16917 else
16918 cat $tmp/out
16919 rm -f $tmp/out
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016920 fi
16921
Martin v. Löwis11437992002-04-12 09:54:03 +000016922done
16923_ACEOF
16924cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016925
Martin v. Löwis11437992002-04-12 09:54:03 +000016926#
16927# CONFIG_HEADER section.
16928#
Guido van Rossum627b2d71993-12-24 10:39:16 +000016929
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016930# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
16931# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +000016932#
16933# ac_d sets the value in "#define NAME VALUE" lines.
Martin v. Löwis11437992002-04-12 09:54:03 +000016934ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
16935ac_dB='[ ].*$,\1#\2'
16936ac_dC=' '
16937ac_dD=',;t'
16938# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
16939ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
16940ac_uB='$,\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +000016941ac_uC=' '
Martin v. Löwis11437992002-04-12 09:54:03 +000016942ac_uD=',;t'
Guido van Rossum7f43da71994-08-01 12:15:30 +000016943
Martin v. Löwis11437992002-04-12 09:54:03 +000016944for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
Guido van Rossumf78abae1997-01-21 22:02:36 +000016945 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Martin v. Löwis11437992002-04-12 09:54:03 +000016946 case $ac_file in
16947 - | *:- | *:-:* ) # input from stdin
16948 cat >$tmp/stdin
16949 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16950 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16951 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
16952 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
16953 * ) ac_file_in=$ac_file.in ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016954 esac
16955
Martin v. Löwis11437992002-04-12 09:54:03 +000016956 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
16957echo "$as_me: creating $ac_file" >&6;}
Guido van Rossum7f43da71994-08-01 12:15:30 +000016958
Martin v. Löwis11437992002-04-12 09:54:03 +000016959 # First look for the input files in the build tree, otherwise in the
16960 # src tree.
16961 ac_file_inputs=`IFS=:
16962 for f in $ac_file_in; do
16963 case $f in
16964 -) echo $tmp/stdin ;;
16965 [\\/$]*)
16966 # Absolute (can't be DOS-style, as IFS=:)
16967 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
16968echo "$as_me: error: cannot find input file: $f" >&2;}
16969 { (exit 1); exit 1; }; }
16970 echo $f;;
16971 *) # Relative
16972 if test -f "$f"; then
16973 # Build tree
16974 echo $f
16975 elif test -f "$srcdir/$f"; then
16976 # Source tree
16977 echo $srcdir/$f
16978 else
16979 # /dev/null tree
16980 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
16981echo "$as_me: error: cannot find input file: $f" >&2;}
16982 { (exit 1); exit 1; }; }
16983 fi;;
16984 esac
16985 done` || { (exit 1); exit 1; }
16986 # Remove the trailing spaces.
16987 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016988
Martin v. Löwis11437992002-04-12 09:54:03 +000016989_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016990
Martin v. Löwis11437992002-04-12 09:54:03 +000016991# Transform confdefs.h into two sed scripts, `conftest.defines' and
16992# `conftest.undefs', that substitutes the proper values into
16993# config.h.in to produce config.h. The first handles `#define'
16994# templates, and the second `#undef' templates.
16995# And first: Protect against being on the right side of a sed subst in
16996# config.status. Protect against being in an unquoted here document
16997# in config.status.
16998rm -f conftest.defines conftest.undefs
16999# Using a here document instead of a string reduces the quoting nightmare.
17000# Putting comments in sed scripts is not portable.
17001#
17002# `end' is used to avoid that the second main sed command (meant for
17003# 0-ary CPP macros) applies to n-ary macro definitions.
17004# See the Autoconf documentation for `clear'.
17005cat >confdef2sed.sed <<\_ACEOF
17006s/[\\&,]/\\&/g
17007s,[\\$`],\\&,g
17008t clear
17009: clear
17010s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
17011t end
17012s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
17013: end
17014_ACEOF
17015# If some macros were called several times there might be several times
17016# the same #defines, which is useless. Nevertheless, we may not want to
17017# sort them, since we want the *last* AC-DEFINE to be honored.
17018uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
17019sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
17020rm -f confdef2sed.sed
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017021
17022# This sed command replaces #undef with comments. This is necessary, for
17023# example, in the case of _POSIX_SOURCE, which is predefined and required
17024# on some systems where configure will not decide to define it.
Martin v. Löwis11437992002-04-12 09:54:03 +000017025cat >>conftest.undefs <<\_ACEOF
17026s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
17027_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017028
Martin v. Löwis11437992002-04-12 09:54:03 +000017029# Break up conftest.defines because some shells have a limit on the size
17030# of here documents, and old seds have small limits too (100 cmds).
17031echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
17032echo ' if egrep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
17033echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
17034echo ' :' >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017035rm -f conftest.tail
Martin v. Löwis11437992002-04-12 09:54:03 +000017036while grep . conftest.defines >/dev/null
Jack Jansendd19cf82001-12-06 22:36:17 +000017037do
Martin v. Löwis11437992002-04-12 09:54:03 +000017038 # Write a limited-size here document to $tmp/defines.sed.
17039 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
17040 # Speed up: don't consider the non `#define' lines.
17041 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
17042 # Work around the forget-to-reset-the-flag bug.
17043 echo 't clr' >>$CONFIG_STATUS
17044 echo ': clr' >>$CONFIG_STATUS
17045 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017046 echo 'CEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000017047 sed -f $tmp/defines.sed $tmp/in >$tmp/out
17048 rm -f $tmp/in
17049 mv $tmp/out $tmp/in
17050' >>$CONFIG_STATUS
17051 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
17052 rm -f conftest.defines
17053 mv conftest.tail conftest.defines
Jack Jansendd19cf82001-12-06 22:36:17 +000017054done
Martin v. Löwis11437992002-04-12 09:54:03 +000017055rm -f conftest.defines
17056echo ' fi # egrep' >>$CONFIG_STATUS
17057echo >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017058
Martin v. Löwis11437992002-04-12 09:54:03 +000017059# Break up conftest.undefs because some shells have a limit on the size
17060# of here documents, and old seds have small limits too (100 cmds).
17061echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
17062rm -f conftest.tail
17063while grep . conftest.undefs >/dev/null
17064do
17065 # Write a limited-size here document to $tmp/undefs.sed.
17066 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
17067 # Speed up: don't consider the non `#undef'
17068 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
17069 # Work around the forget-to-reset-the-flag bug.
17070 echo 't clr' >>$CONFIG_STATUS
17071 echo ': clr' >>$CONFIG_STATUS
17072 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
17073 echo 'CEOF
17074 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
17075 rm -f $tmp/in
17076 mv $tmp/out $tmp/in
17077' >>$CONFIG_STATUS
17078 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
17079 rm -f conftest.undefs
17080 mv conftest.tail conftest.undefs
17081done
17082rm -f conftest.undefs
17083
17084cat >>$CONFIG_STATUS <<\_ACEOF
17085 # Let's still pretend it is `configure' which instantiates (i.e., don't
17086 # use $as_me), people would be surprised to read:
17087 # /* config.h. Generated by config.status. */
17088 if test x"$ac_file" = x-; then
17089 echo "/* Generated by configure. */" >$tmp/config.h
Guido van Rossum7f43da71994-08-01 12:15:30 +000017090 else
Martin v. Löwis11437992002-04-12 09:54:03 +000017091 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
Jack Jansendd19cf82001-12-06 22:36:17 +000017092 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017093 cat $tmp/in >>$tmp/config.h
17094 rm -f $tmp/in
17095 if test x"$ac_file" != x-; then
17096 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17097 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
17098echo "$as_me: $ac_file is unchanged" >&6;}
17099 else
17100 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17101$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17102 X"$ac_file" : 'X\(//\)[^/]' \| \
17103 X"$ac_file" : 'X\(//\)$' \| \
17104 X"$ac_file" : 'X\(/\)' \| \
17105 . : '\(.\)' 2>/dev/null ||
17106echo X"$ac_file" |
17107 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17108 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17109 /^X\(\/\/\)$/{ s//\1/; q; }
17110 /^X\(\/\).*/{ s//\1/; q; }
17111 s/.*/./; q'`
17112 { case "$ac_dir" in
17113 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17114 *) as_incr_dir=.;;
17115esac
17116as_dummy="$ac_dir"
17117for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17118 case $as_mkdir_dir in
17119 # Skip DOS drivespec
17120 ?:) as_incr_dir=$as_mkdir_dir ;;
17121 *)
17122 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17123 test -d "$as_incr_dir" ||
17124 mkdir "$as_incr_dir" ||
17125 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17126echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17127 { (exit 1); exit 1; }; }
17128 ;;
17129 esac
17130done; }
Michael W. Hudson54241132001-12-07 15:38:26 +000017131
Martin v. Löwis11437992002-04-12 09:54:03 +000017132 rm -f $ac_file
17133 mv $tmp/config.h $ac_file
17134 fi
17135 else
17136 cat $tmp/config.h
17137 rm -f $tmp/config.h
17138 fi
17139done
17140_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000017141
Martin v. Löwis11437992002-04-12 09:54:03 +000017142cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000017143
Martin v. Löwis11437992002-04-12 09:54:03 +000017144{ (exit 0); exit 0; }
17145_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017146chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000017147ac_clean_files=$ac_clean_files_save
17148
17149
17150# configure is writing to config.log, and then calls config.status.
17151# config.status does its own redirection, appending to config.log.
17152# Unfortunately, on DOS this fails, as config.log is still kept open
17153# by configure, so config.status won't be able to write to it; its
17154# output is simply discarded. So we exec the FD to /dev/null,
17155# effectively closing config.log, so it can be properly (re)opened and
17156# appended to by config.status. When coming back to configure, we
17157# need to make the FD available again.
17158if test "$no_create" != yes; then
17159 ac_cs_success=:
17160 exec 5>/dev/null
17161 $SHELL $CONFIG_STATUS || ac_cs_success=false
17162 exec 5>>config.log
17163 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17164 # would make configure fail if this is the last instruction.
17165 $ac_cs_success || { (exit 1); exit 1; }
17166fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000017167
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000017168
17169echo "creating Setup"
17170if test ! -f Modules/Setup
17171then
17172 cp $srcdir/Modules/Setup.dist Modules/Setup
17173fi
17174
17175echo "creating Setup.local"
17176if test ! -f Modules/Setup.local
17177then
17178 echo "# Edit this file for local setup changes" >Modules/Setup.local
17179fi
17180
17181echo "creating Makefile"
17182$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
17183 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000017184 Modules/Setup.local Modules/Setup
Neil Schemenauerc761fc82001-02-19 04:50:49 +000017185mv config.c Modules