blob: 61ca57c122acd432f8f11b80d3bd2ab18fda1500 [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +00002# From configure.in Revision: 1.364 .
Guido van Rossum627b2d71993-12-24 10:39:16 +00003# Guess values for system-dependent variables and create Makefiles.
Martin v. Löwis88afe662002-10-26 13:47:44 +00004# Generated by GNU Autoconf 2.53 for python 2.3.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005#
Martin v. Löwis11437992002-04-12 09:54:03 +00006# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
7# Free Software Foundation, Inc.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00008# This configure script is free software; the Free Software Foundation
9# gives unlimited permission to copy, distribute and modify it.
Guido van Rossum627b2d71993-12-24 10:39:16 +000010
Martin v. Löwis11437992002-04-12 09:54:03 +000011if expr a : '\(a\)' >/dev/null 2>&1; then
12 as_expr=expr
13else
14 as_expr=false
15fi
16
17
18## --------------------- ##
19## M4sh Initialization. ##
20## --------------------- ##
21
22# Be Bourne compatible
23if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
24 emulate sh
25 NULLCMD=:
26elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
27 set -o posix
28fi
29
30# NLS nuisances.
31# Support unset when possible.
32if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
33 as_unset=unset
34else
35 as_unset=false
36fi
37
38(set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
39 { $as_unset LANG || test "${LANG+set}" != set; } ||
40 { LANG=C; export LANG; }
41(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
42 { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
43 { LC_ALL=C; export LC_ALL; }
44(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
45 { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
46 { LC_TIME=C; export LC_TIME; }
47(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
48 { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
49 { LC_CTYPE=C; export LC_CTYPE; }
50(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
51 { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
52 { LANGUAGE=C; export LANGUAGE; }
53(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
54 { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
55 { LC_COLLATE=C; export LC_COLLATE; }
56(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
57 { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
58 { LC_NUMERIC=C; export LC_NUMERIC; }
59(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
60 { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
61 { LC_MESSAGES=C; export LC_MESSAGES; }
62
63
64# Name of the executable.
65as_me=`(basename "$0") 2>/dev/null ||
66$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
67 X"$0" : 'X\(//\)$' \| \
68 X"$0" : 'X\(/\)$' \| \
69 . : '\(.\)' 2>/dev/null ||
70echo X/"$0" |
71 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
72 /^X\/\(\/\/\)$/{ s//\1/; q; }
73 /^X\/\(\/\).*/{ s//\1/; q; }
74 s/.*/./; q'`
75
76# PATH needs CR, and LINENO needs CR and PATH.
77# Avoid depending upon Character Ranges.
78as_cr_letters='abcdefghijklmnopqrstuvwxyz'
79as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
80as_cr_Letters=$as_cr_letters$as_cr_LETTERS
81as_cr_digits='0123456789'
82as_cr_alnum=$as_cr_Letters$as_cr_digits
83
84# The user is always right.
85if test "${PATH_SEPARATOR+set}" != set; then
86 echo "#! /bin/sh" >conftest.sh
87 echo "exit 0" >>conftest.sh
88 chmod +x conftest.sh
89 if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
90 PATH_SEPARATOR=';'
91 else
92 PATH_SEPARATOR=:
93 fi
94 rm -f conftest.sh
95fi
96
97
98 as_lineno_1=$LINENO
99 as_lineno_2=$LINENO
100 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
101 test "x$as_lineno_1" != "x$as_lineno_2" &&
102 test "x$as_lineno_3" = "x$as_lineno_2" || {
103 # Find who we are. Look in the path if we contain no path at all
104 # relative or not.
105 case $0 in
106 *[\\/]* ) as_myself=$0 ;;
107 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
108for as_dir in $PATH
109do
110 IFS=$as_save_IFS
111 test -z "$as_dir" && as_dir=.
112 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
113done
114
115 ;;
116 esac
117 # We did not find ourselves, most probably we were run as `sh COMMAND'
118 # in which case we are not to be found in the path.
119 if test "x$as_myself" = x; then
120 as_myself=$0
121 fi
122 if test ! -f "$as_myself"; then
123 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
124 { (exit 1); exit 1; }; }
125 fi
126 case $CONFIG_SHELL in
127 '')
128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
129for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
130do
131 IFS=$as_save_IFS
132 test -z "$as_dir" && as_dir=.
133 for as_base in sh bash ksh sh5; do
134 case $as_dir in
135 /*)
136 if ("$as_dir/$as_base" -c '
137 as_lineno_1=$LINENO
138 as_lineno_2=$LINENO
139 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
140 test "x$as_lineno_1" != "x$as_lineno_2" &&
141 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
142 CONFIG_SHELL=$as_dir/$as_base
143 export CONFIG_SHELL
144 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
145 fi;;
146 esac
147 done
148done
149;;
150 esac
151
152 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
153 # uniformly replaced by the line number. The first 'sed' inserts a
154 # line-number line before each line; the second 'sed' does the real
155 # work. The second script uses 'N' to pair each line-number line
156 # with the numbered line, and appends trailing '-' during
157 # substitution so that $LINENO is not a special case at line end.
158 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
159 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
160 sed '=' <$as_myself |
161 sed '
162 N
163 s,$,-,
164 : loop
165 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
166 t loop
167 s,-$,,
168 s,^['$as_cr_digits']*\n,,
169 ' >$as_me.lineno &&
170 chmod +x $as_me.lineno ||
171 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
172 { (exit 1); exit 1; }; }
173
174 # Don't try to exec as it changes $[0], causing all sort of problems
175 # (the dirname of $[0] is not the place where we might find the
176 # original and so on. Autoconf is especially sensible to this).
177 . ./$as_me.lineno
178 # Exit status is that of the last command.
179 exit
180}
181
182
183case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
184 *c*,-n*) ECHO_N= ECHO_C='
185' ECHO_T=' ' ;;
186 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
187 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
188esac
189
190if expr a : '\(a\)' >/dev/null 2>&1; then
191 as_expr=expr
192else
193 as_expr=false
194fi
195
196rm -f conf$$ conf$$.exe conf$$.file
197echo >conf$$.file
198if ln -s conf$$.file conf$$ 2>/dev/null; then
199 # We could just check for DJGPP; but this test a) works b) is more generic
200 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
201 if test -f conf$$.exe; then
202 # Don't use ln at all; we don't have any links
203 as_ln_s='cp -p'
204 else
205 as_ln_s='ln -s'
206 fi
207elif ln conf$$.file conf$$ 2>/dev/null; then
208 as_ln_s=ln
209else
210 as_ln_s='cp -p'
211fi
212rm -f conf$$ conf$$.exe conf$$.file
213
214as_executable_p="test -f"
215
216# Sed expression to map a string onto a valid CPP name.
217as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
218
219# Sed expression to map a string onto a valid variable name.
220as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
221
222
223# IFS
224# We need space, tab and new line, in precisely that order.
225as_nl='
226'
227IFS=" $as_nl"
228
229# CDPATH.
230$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
231
232
233# Name of the host.
234# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
235# so uname gets run too.
236ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
237
238exec 6>&1
239
240#
241# Initializations.
242#
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000243ac_default_prefix=/usr/local
Martin v. Löwis11437992002-04-12 09:54:03 +0000244cross_compiling=no
245subdirs=
246MFLAGS=
247MAKEFLAGS=
248SHELL=${CONFIG_SHELL-/bin/sh}
249
250# Maximum number of lines to put in a shell here document.
251# This variable seems obsolete. It should probably be removed, and
252# only ac_max_sed_lines should be used.
253: ${ac_max_here_lines=38}
254
255# Identity of this package.
Martin v. Löwis88afe662002-10-26 13:47:44 +0000256PACKAGE_NAME='python'
257PACKAGE_TARNAME='python'
258PACKAGE_VERSION='2.3'
259PACKAGE_STRING='python 2.3'
260PACKAGE_BUGREPORT=''
Martin v. Löwis11437992002-04-12 09:54:03 +0000261
262ac_unique_file="Include/object.h"
263# Factoring default headers for most tests.
264ac_includes_default="\
265#include <stdio.h>
266#if HAVE_SYS_TYPES_H
267# include <sys/types.h>
268#endif
269#if HAVE_SYS_STAT_H
270# include <sys/stat.h>
271#endif
272#if STDC_HEADERS
273# include <stdlib.h>
274# include <stddef.h>
275#else
276# if HAVE_STDLIB_H
277# include <stdlib.h>
278# endif
279#endif
280#if HAVE_STRING_H
281# if !STDC_HEADERS && HAVE_MEMORY_H
282# include <memory.h>
283# endif
284# include <string.h>
285#endif
286#if HAVE_STRINGS_H
287# include <strings.h>
288#endif
289#if HAVE_INTTYPES_H
290# include <inttypes.h>
291#else
292# if HAVE_STDINT_H
293# include <stdint.h>
294# endif
295#endif
296#if HAVE_UNISTD_H
297# include <unistd.h>
298#endif"
299
Guido van Rossum627b2d71993-12-24 10:39:16 +0000300
Guido van Rossum7f43da71994-08-01 12:15:30 +0000301# Initialize some variables set by options.
Martin v. Löwis11437992002-04-12 09:54:03 +0000302ac_init_help=
303ac_init_version=false
Guido van Rossum7f43da71994-08-01 12:15:30 +0000304# The variables have the same names as the options, with
305# dashes changed to underlines.
Martin v. Löwis11437992002-04-12 09:54:03 +0000306cache_file=/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000307exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +0000308no_create=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000309no_recursion=
310prefix=NONE
311program_prefix=NONE
312program_suffix=NONE
313program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +0000314silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000315site=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000316srcdir=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000317verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000318x_includes=NONE
319x_libraries=NONE
Martin v. Löwis11437992002-04-12 09:54:03 +0000320
321# Installation directory options.
322# These are left unexpanded so users can "make install exec_prefix=/foo"
323# and all the variables that are supposed to be based on exec_prefix
324# by default will actually change.
325# Use braces instead of parens because sh, perl, etc. also accept them.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000326bindir='${exec_prefix}/bin'
327sbindir='${exec_prefix}/sbin'
328libexecdir='${exec_prefix}/libexec'
329datadir='${prefix}/share'
330sysconfdir='${prefix}/etc'
331sharedstatedir='${prefix}/com'
332localstatedir='${prefix}/var'
333libdir='${exec_prefix}/lib'
334includedir='${prefix}/include'
335oldincludedir='/usr/include'
336infodir='${prefix}/info'
337mandir='${prefix}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000338
Guido van Rossum7f43da71994-08-01 12:15:30 +0000339ac_prev=
340for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +0000341do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000342 # If the previous option needs an argument, assign it.
343 if test -n "$ac_prev"; then
344 eval "$ac_prev=\$ac_option"
345 ac_prev=
346 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +0000347 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000348
Martin v. Löwis11437992002-04-12 09:54:03 +0000349 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000350
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000351 # Accept the important Cygnus configure options, so we can diagnose typos.
352
Martin v. Löwis11437992002-04-12 09:54:03 +0000353 case $ac_option in
Guido van Rossum7f43da71994-08-01 12:15:30 +0000354
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000355 -bindir | --bindir | --bindi | --bind | --bin | --bi)
356 ac_prev=bindir ;;
357 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000358 bindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000359
360 -build | --build | --buil | --bui | --bu)
Martin v. Löwis11437992002-04-12 09:54:03 +0000361 ac_prev=build_alias ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000362 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000363 build_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000364
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000365 -cache-file | --cache-file | --cache-fil | --cache-fi \
366 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
367 ac_prev=cache_file ;;
368 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
369 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000370 cache_file=$ac_optarg ;;
371
372 --config-cache | -C)
373 cache_file=config.cache ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000374
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000375 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
376 ac_prev=datadir ;;
377 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
378 | --da=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000379 datadir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000380
Guido van Rossum7f43da71994-08-01 12:15:30 +0000381 -disable-* | --disable-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000382 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000383 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000384 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
385 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
386 { (exit 1); exit 1; }; }
387 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
388 eval "enable_$ac_feature=no" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000389
390 -enable-* | --enable-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000391 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000392 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000393 expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
394 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
395 { (exit 1); exit 1; }; }
396 ac_feature=`echo $ac_feature | sed 's/-/_/g'`
397 case $ac_option in
398 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000399 *) ac_optarg=yes ;;
400 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000401 eval "enable_$ac_feature='$ac_optarg'" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000402
Guido van Rossum7f43da71994-08-01 12:15:30 +0000403 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
404 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
405 | --exec | --exe | --ex)
406 ac_prev=exec_prefix ;;
407 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
408 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
409 | --exec=* | --exe=* | --ex=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000410 exec_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000411
412 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000413 # Obsolete; use --with-gas.
414 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000415
Martin v. Löwis11437992002-04-12 09:54:03 +0000416 -help | --help | --hel | --he | -h)
417 ac_init_help=long ;;
418 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
419 ac_init_help=recursive ;;
420 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
421 ac_init_help=short ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000422
423 -host | --host | --hos | --ho)
Martin v. Löwis11437992002-04-12 09:54:03 +0000424 ac_prev=host_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000425 -host=* | --host=* | --hos=* | --ho=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000426 host_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000427
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000428 -includedir | --includedir | --includedi | --included | --include \
429 | --includ | --inclu | --incl | --inc)
430 ac_prev=includedir ;;
431 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
432 | --includ=* | --inclu=* | --incl=* | --inc=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000433 includedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000434
435 -infodir | --infodir | --infodi | --infod | --info | --inf)
436 ac_prev=infodir ;;
437 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000438 infodir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000439
440 -libdir | --libdir | --libdi | --libd)
441 ac_prev=libdir ;;
442 -libdir=* | --libdir=* | --libdi=* | --libd=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000443 libdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000444
445 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
446 | --libexe | --libex | --libe)
447 ac_prev=libexecdir ;;
448 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
449 | --libexe=* | --libex=* | --libe=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000450 libexecdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000451
452 -localstatedir | --localstatedir | --localstatedi | --localstated \
453 | --localstate | --localstat | --localsta | --localst \
454 | --locals | --local | --loca | --loc | --lo)
455 ac_prev=localstatedir ;;
456 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
457 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
458 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000459 localstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000460
461 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
462 ac_prev=mandir ;;
463 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000464 mandir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000465
Guido van Rossum7f43da71994-08-01 12:15:30 +0000466 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000467 # Obsolete; use --without-fp.
468 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000469
470 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
Martin v. Löwis11437992002-04-12 09:54:03 +0000471 | --no-cr | --no-c | -n)
Guido van Rossum7f43da71994-08-01 12:15:30 +0000472 no_create=yes ;;
473
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000474 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
475 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
476 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000477
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000478 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
479 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
480 | --oldin | --oldi | --old | --ol | --o)
481 ac_prev=oldincludedir ;;
482 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
483 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
484 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000485 oldincludedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000486
Guido van Rossum7f43da71994-08-01 12:15:30 +0000487 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
488 ac_prev=prefix ;;
489 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000490 prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000491
492 -program-prefix | --program-prefix | --program-prefi | --program-pref \
493 | --program-pre | --program-pr | --program-p)
494 ac_prev=program_prefix ;;
495 -program-prefix=* | --program-prefix=* | --program-prefi=* \
496 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000497 program_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000498
499 -program-suffix | --program-suffix | --program-suffi | --program-suff \
500 | --program-suf | --program-su | --program-s)
501 ac_prev=program_suffix ;;
502 -program-suffix=* | --program-suffix=* | --program-suffi=* \
503 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000504 program_suffix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000505
506 -program-transform-name | --program-transform-name \
507 | --program-transform-nam | --program-transform-na \
508 | --program-transform-n | --program-transform- \
509 | --program-transform | --program-transfor \
510 | --program-transfo | --program-transf \
511 | --program-trans | --program-tran \
512 | --progr-tra | --program-tr | --program-t)
513 ac_prev=program_transform_name ;;
514 -program-transform-name=* | --program-transform-name=* \
515 | --program-transform-nam=* | --program-transform-na=* \
516 | --program-transform-n=* | --program-transform-=* \
517 | --program-transform=* | --program-transfor=* \
518 | --program-transfo=* | --program-transf=* \
519 | --program-trans=* | --program-tran=* \
520 | --progr-tra=* | --program-tr=* | --program-t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000521 program_transform_name=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000522
523 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
524 | -silent | --silent | --silen | --sile | --sil)
525 silent=yes ;;
526
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000527 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
528 ac_prev=sbindir ;;
529 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
530 | --sbi=* | --sb=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000531 sbindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000532
533 -sharedstatedir | --sharedstatedir | --sharedstatedi \
534 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
535 | --sharedst | --shareds | --shared | --share | --shar \
536 | --sha | --sh)
537 ac_prev=sharedstatedir ;;
538 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
539 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
540 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
541 | --sha=* | --sh=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000542 sharedstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000543
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000544 -site | --site | --sit)
545 ac_prev=site ;;
546 -site=* | --site=* | --sit=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000547 site=$ac_optarg ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000548
Guido van Rossum7f43da71994-08-01 12:15:30 +0000549 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
550 ac_prev=srcdir ;;
551 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000552 srcdir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000553
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000554 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
555 | --syscon | --sysco | --sysc | --sys | --sy)
556 ac_prev=sysconfdir ;;
557 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
558 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000559 sysconfdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000560
Guido van Rossum7f43da71994-08-01 12:15:30 +0000561 -target | --target | --targe | --targ | --tar | --ta | --t)
Martin v. Löwis11437992002-04-12 09:54:03 +0000562 ac_prev=target_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000563 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000564 target_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000565
566 -v | -verbose | --verbose | --verbos | --verbo | --verb)
567 verbose=yes ;;
568
Martin v. Löwis11437992002-04-12 09:54:03 +0000569 -version | --version | --versio | --versi | --vers | -V)
570 ac_init_version=: ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000571
572 -with-* | --with-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000573 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000574 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000575 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
576 { echo "$as_me: error: invalid package name: $ac_package" >&2
577 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000578 ac_package=`echo $ac_package| sed 's/-/_/g'`
Martin v. Löwis11437992002-04-12 09:54:03 +0000579 case $ac_option in
580 *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000581 *) ac_optarg=yes ;;
582 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000583 eval "with_$ac_package='$ac_optarg'" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000584
585 -without-* | --without-*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000586 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000587 # Reject names that are not valid shell variable names.
Martin v. Löwis11437992002-04-12 09:54:03 +0000588 expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
589 { echo "$as_me: error: invalid package name: $ac_package" >&2
590 { (exit 1); exit 1; }; }
591 ac_package=`echo $ac_package | sed 's/-/_/g'`
592 eval "with_$ac_package=no" ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000593
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000594 --x)
595 # Obsolete; use --with-x.
596 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000597
598 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
599 | --x-incl | --x-inc | --x-in | --x-i)
600 ac_prev=x_includes ;;
601 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
602 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000603 x_includes=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000604
605 -x-libraries | --x-libraries | --x-librarie | --x-librari \
606 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
607 ac_prev=x_libraries ;;
608 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
609 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000610 x_libraries=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000611
Martin v. Löwis11437992002-04-12 09:54:03 +0000612 -*) { echo "$as_me: error: unrecognized option: $ac_option
613Try \`$0 --help' for more information." >&2
614 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000615 ;;
616
Martin v. Löwis11437992002-04-12 09:54:03 +0000617 *=*)
618 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
619 # Reject names that are not valid shell variable names.
620 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
621 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
622 { (exit 1); exit 1; }; }
623 ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
624 eval "$ac_envvar='$ac_optarg'"
625 export $ac_envvar ;;
626
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000627 *)
Martin v. Löwis11437992002-04-12 09:54:03 +0000628 # FIXME: should be removed in autoconf 3.0.
629 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
630 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
631 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
632 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
Guido van Rossum7f43da71994-08-01 12:15:30 +0000633 ;;
634
635 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +0000636done
637
Guido van Rossum7f43da71994-08-01 12:15:30 +0000638if test -n "$ac_prev"; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000639 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
640 { echo "$as_me: error: missing argument to $ac_option" >&2
641 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +0000642fi
643
Martin v. Löwis11437992002-04-12 09:54:03 +0000644# Be sure to have absolute paths.
645for ac_var in exec_prefix prefix
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000646do
Martin v. Löwis11437992002-04-12 09:54:03 +0000647 eval ac_val=$`echo $ac_var`
648 case $ac_val in
649 [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
650 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
651 { (exit 1); exit 1; }; };;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000652 esac
653done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000654
Martin v. Löwis11437992002-04-12 09:54:03 +0000655# Be sure to have absolute paths.
656for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
657 localstatedir libdir includedir oldincludedir infodir mandir
658do
659 eval ac_val=$`echo $ac_var`
660 case $ac_val in
661 [\\/$]* | ?:[\\/]* ) ;;
662 *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
663 { (exit 1); exit 1; }; };;
664 esac
665done
Guido van Rossum627b2d71993-12-24 10:39:16 +0000666
Martin v. Löwis11437992002-04-12 09:54:03 +0000667# There might be people who depend on the old broken behavior: `$host'
668# used to hold the argument of --host etc.
669# FIXME: To remove some day.
670build=$build_alias
671host=$host_alias
672target=$target_alias
Guido van Rossum627b2d71993-12-24 10:39:16 +0000673
Martin v. Löwis11437992002-04-12 09:54:03 +0000674# FIXME: To remove some day.
675if test "x$host_alias" != x; then
676 if test "x$build_alias" = x; then
677 cross_compiling=maybe
678 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
679 If a cross compiler is detected then cross compile mode will be used." >&2
680 elif test "x$build_alias" != "x$host_alias"; then
681 cross_compiling=yes
682 fi
683fi
684
685ac_tool_prefix=
686test -n "$host_alias" && ac_tool_prefix=$host_alias-
687
688test "$silent" = yes && exec 6>/dev/null
689
Guido van Rossum627b2d71993-12-24 10:39:16 +0000690
691# Find the source files, if location was not specified.
692if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +0000693 ac_srcdir_defaulted=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000694 # Try the directory containing this script, then its parent.
Martin v. Löwis11437992002-04-12 09:54:03 +0000695 ac_confdir=`(dirname "$0") 2>/dev/null ||
696$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
697 X"$0" : 'X\(//\)[^/]' \| \
698 X"$0" : 'X\(//\)$' \| \
699 X"$0" : 'X\(/\)' \| \
700 . : '\(.\)' 2>/dev/null ||
701echo X"$0" |
702 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
703 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
704 /^X\(\/\/\)$/{ s//\1/; q; }
705 /^X\(\/\).*/{ s//\1/; q; }
706 s/.*/./; q'`
Guido van Rossum7f43da71994-08-01 12:15:30 +0000707 srcdir=$ac_confdir
708 if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum627b2d71993-12-24 10:39:16 +0000709 srcdir=..
710 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000711else
712 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +0000713fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000714if test ! -r $srcdir/$ac_unique_file; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000715 if test "$ac_srcdir_defaulted" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000716 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
717 { (exit 1); exit 1; }; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000718 else
Martin v. Löwis11437992002-04-12 09:54:03 +0000719 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
720 { (exit 1); exit 1; }; }
Guido van Rossum627b2d71993-12-24 10:39:16 +0000721 fi
Guido van Rossum627b2d71993-12-24 10:39:16 +0000722fi
Martin v. Löwis11437992002-04-12 09:54:03 +0000723srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
724ac_env_build_alias_set=${build_alias+set}
725ac_env_build_alias_value=$build_alias
726ac_cv_env_build_alias_set=${build_alias+set}
727ac_cv_env_build_alias_value=$build_alias
728ac_env_host_alias_set=${host_alias+set}
729ac_env_host_alias_value=$host_alias
730ac_cv_env_host_alias_set=${host_alias+set}
731ac_cv_env_host_alias_value=$host_alias
732ac_env_target_alias_set=${target_alias+set}
733ac_env_target_alias_value=$target_alias
734ac_cv_env_target_alias_set=${target_alias+set}
735ac_cv_env_target_alias_value=$target_alias
736ac_env_CC_set=${CC+set}
737ac_env_CC_value=$CC
738ac_cv_env_CC_set=${CC+set}
739ac_cv_env_CC_value=$CC
740ac_env_CFLAGS_set=${CFLAGS+set}
741ac_env_CFLAGS_value=$CFLAGS
742ac_cv_env_CFLAGS_set=${CFLAGS+set}
743ac_cv_env_CFLAGS_value=$CFLAGS
744ac_env_LDFLAGS_set=${LDFLAGS+set}
745ac_env_LDFLAGS_value=$LDFLAGS
746ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
747ac_cv_env_LDFLAGS_value=$LDFLAGS
748ac_env_CPPFLAGS_set=${CPPFLAGS+set}
749ac_env_CPPFLAGS_value=$CPPFLAGS
750ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
751ac_cv_env_CPPFLAGS_value=$CPPFLAGS
752ac_env_CPP_set=${CPP+set}
753ac_env_CPP_value=$CPP
754ac_cv_env_CPP_set=${CPP+set}
755ac_cv_env_CPP_value=$CPP
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000756
Martin v. Löwis11437992002-04-12 09:54:03 +0000757#
758# Report the --help message.
759#
760if test "$ac_init_help" = "long"; then
761 # Omit some internal or obsolete options to make the list less imposing.
762 # This message is too long to be a string in the A/UX 3.1 sh.
763 cat <<_ACEOF
Martin v. Löwis88afe662002-10-26 13:47:44 +0000764\`configure' configures python 2.3 to adapt to many kinds of systems.
Martin v. Löwis11437992002-04-12 09:54:03 +0000765
766Usage: $0 [OPTION]... [VAR=VALUE]...
767
768To assign environment variables (e.g., CC, CFLAGS...), specify them as
769VAR=VALUE. See below for descriptions of some of the useful variables.
770
771Defaults for the options are specified in brackets.
772
773Configuration:
774 -h, --help display this help and exit
775 --help=short display options specific to this package
776 --help=recursive display the short help of all the included packages
777 -V, --version display version information and exit
778 -q, --quiet, --silent do not print \`checking...' messages
779 --cache-file=FILE cache test results in FILE [disabled]
780 -C, --config-cache alias for \`--cache-file=config.cache'
781 -n, --no-create do not create output files
782 --srcdir=DIR find the sources in DIR [configure dir or \`..']
783
784_ACEOF
785
786 cat <<_ACEOF
787Installation directories:
788 --prefix=PREFIX install architecture-independent files in PREFIX
789 [$ac_default_prefix]
790 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
791 [PREFIX]
792
793By default, \`make install' will install all the files in
794\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
795an installation prefix other than \`$ac_default_prefix' using \`--prefix',
796for instance \`--prefix=\$HOME'.
797
798For better control, use the options below.
799
800Fine tuning of the installation directories:
801 --bindir=DIR user executables [EPREFIX/bin]
802 --sbindir=DIR system admin executables [EPREFIX/sbin]
803 --libexecdir=DIR program executables [EPREFIX/libexec]
804 --datadir=DIR read-only architecture-independent data [PREFIX/share]
805 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
806 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
807 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
808 --libdir=DIR object code libraries [EPREFIX/lib]
809 --includedir=DIR C header files [PREFIX/include]
810 --oldincludedir=DIR C header files for non-gcc [/usr/include]
811 --infodir=DIR info documentation [PREFIX/info]
812 --mandir=DIR man documentation [PREFIX/man]
813_ACEOF
814
815 cat <<\_ACEOF
816_ACEOF
817fi
818
819if test -n "$ac_init_help"; then
Martin v. Löwis88afe662002-10-26 13:47:44 +0000820 case $ac_init_help in
821 short | recursive ) echo "Configuration of python 2.3:";;
822 esac
Martin v. Löwis11437992002-04-12 09:54:03 +0000823 cat <<\_ACEOF
824
825Optional Features:
826 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
827 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
Martin v. Löwis3e2c6322002-10-29 10:07:43 +0000828 --enable-framework[=INSTALLDIR]
829 Build (MacOSX|Darwin) framework
830 --enable-shared disable/enable building shared python library
831 --enable-toolbox-glue disable/enable MacOSX glue code for extensions
832 --enable-ipv6 Enable ipv6 (with ipv4) support
833 --disable-ipv6 Disable ipv6 support
834 --enable-unicode[=ucs[24]]
835 Enable Unicode strings (default is yes)
Martin v. Löwis11437992002-04-12 09:54:03 +0000836
837Optional Packages:
838 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
839 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Martin v. Löwis3e2c6322002-10-29 10:07:43 +0000840 --without-gcc never use gcc
841 --with-cxx=<compiler> enable C++ support
842 --with-suffix=.exe set executable suffix
843 --with-pydebug build with Py_DEBUG defined
844 --with-libs='lib1 ...' link against additional libs
845 --with-signal-module disable/enable signal module
846 --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries
847 --with(out)-threads[=DIRECTORY]
848 disable/enable thread support
849 --with(out)-thread[=DIRECTORY]
850 deprecated; use --with(out)-threads
851 --with-pth use GNU pth threading libraries
852 --with(out)-universal-newlines
853 disable/enable foreign newlines
854 --with(out)-doc-strings disable/enable documentation strings
855 --with(out)-pymalloc disable/enable specialized mallocs
856 --with-wctype-functions use wctype.h functions
857 --with-sgi-dl=DIRECTORY IRIX 4 dynamic linking
858 --with-dl-dld=DL_DIR GNU dynamic linking
859 --with-fpectl enable SIGFPE catching
860 --with-libm=STRING math library
861 --with-libc=STRING C library
Martin v. Löwis11437992002-04-12 09:54:03 +0000862
863Some influential environment variables:
864 CC C compiler command
865 CFLAGS C compiler flags
866 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
867 nonstandard directory <lib dir>
868 CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
869 headers in a nonstandard directory <include dir>
870 CPP C preprocessor
871
872Use these variables to override the choices made by `configure' or to help
873it to find libraries and programs with nonstandard names/locations.
874
875_ACEOF
876fi
877
878if test "$ac_init_help" = "recursive"; then
879 # If there are subdirs, report their specific --help.
880 ac_popdir=`pwd`
881 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
882 test -d $ac_dir || continue
883 ac_builddir=.
884
885if test "$ac_dir" != .; then
886 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
887 # A "../" for each directory in $ac_dir_suffix.
888 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
889else
890 ac_dir_suffix= ac_top_builddir=
891fi
892
893case $srcdir in
894 .) # No --srcdir option. We are building in place.
895 ac_srcdir=.
896 if test -z "$ac_top_builddir"; then
897 ac_top_srcdir=.
898 else
899 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
900 fi ;;
901 [\\/]* | ?:[\\/]* ) # Absolute path.
902 ac_srcdir=$srcdir$ac_dir_suffix;
903 ac_top_srcdir=$srcdir ;;
904 *) # Relative path.
905 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
906 ac_top_srcdir=$ac_top_builddir$srcdir ;;
907esac
908# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
909# absolute.
910ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwise3271202002-11-07 07:42:30 +0000911ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +0000912ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
913ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
914
915 cd $ac_dir
916 # Check for guested configure; otherwise get Cygnus style configure.
917 if test -f $ac_srcdir/configure.gnu; then
918 echo
919 $SHELL $ac_srcdir/configure.gnu --help=recursive
920 elif test -f $ac_srcdir/configure; then
921 echo
922 $SHELL $ac_srcdir/configure --help=recursive
923 elif test -f $ac_srcdir/configure.ac ||
924 test -f $ac_srcdir/configure.in; then
925 echo
926 $ac_configure --help
927 else
928 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
929 fi
930 cd $ac_popdir
931 done
932fi
933
934test -n "$ac_init_help" && exit 0
935if $ac_init_version; then
936 cat <<\_ACEOF
Martin v. Löwis88afe662002-10-26 13:47:44 +0000937python configure 2.3
938generated by GNU Autoconf 2.53
Martin v. Löwis11437992002-04-12 09:54:03 +0000939
940Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
941Free Software Foundation, Inc.
942This configure script is free software; the Free Software Foundation
943gives unlimited permission to copy, distribute and modify it.
944_ACEOF
945 exit 0
946fi
947exec 5>config.log
948cat >&5 <<_ACEOF
949This file contains any messages produced by compilers while
950running configure, to aid debugging if configure makes a mistake.
951
Martin v. Löwis88afe662002-10-26 13:47:44 +0000952It was created by python $as_me 2.3, which was
Martin v. Löwis11437992002-04-12 09:54:03 +0000953generated by GNU Autoconf 2.53. Invocation command line was
954
955 $ $0 $@
956
957_ACEOF
958{
959cat <<_ASUNAME
960## --------- ##
961## Platform. ##
962## --------- ##
963
964hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
965uname -m = `(uname -m) 2>/dev/null || echo unknown`
966uname -r = `(uname -r) 2>/dev/null || echo unknown`
967uname -s = `(uname -s) 2>/dev/null || echo unknown`
968uname -v = `(uname -v) 2>/dev/null || echo unknown`
969
970/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
971/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
972
973/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
974/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
975/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
976hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
977/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
978/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
979/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
980
981_ASUNAME
982
983as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
984for as_dir in $PATH
985do
986 IFS=$as_save_IFS
987 test -z "$as_dir" && as_dir=.
988 echo "PATH: $as_dir"
989done
990
991} >&5
992
993cat >&5 <<_ACEOF
994
995
996## ----------- ##
997## Core tests. ##
998## ----------- ##
999
1000_ACEOF
1001
1002
1003# Keep a trace of the command line.
1004# Strip out --no-create and --no-recursion so they do not pile up.
1005# Also quote any args containing shell meta-characters.
1006ac_configure_args=
1007ac_sep=
1008for ac_arg
1009do
1010 case $ac_arg in
1011 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1012 | --no-cr | --no-c | -n ) continue ;;
1013 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1014 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1015 continue ;;
1016 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1017 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1018 esac
1019 case " $ac_configure_args " in
1020 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1021 *) ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1022 ac_sep=" " ;;
1023 esac
1024 # Get rid of the leading space.
1025done
1026
1027# When interrupted or exit'd, cleanup temporary files, and complete
1028# config.log. We remove comments because anyway the quotes in there
1029# would cause problems or look ugly.
1030# WARNING: Be sure not to use single quotes in there, as some shells,
1031# such as our DU 5.0 friend, will then `close' the trap.
1032trap 'exit_status=$?
1033 # Save into config.log some information that might help in debugging.
1034 {
1035 echo
1036 cat <<\_ASBOX
1037## ---------------- ##
1038## Cache variables. ##
1039## ---------------- ##
1040_ASBOX
1041 echo
1042 # The following way of writing the cache mishandles newlines in values,
1043{
1044 (set) 2>&1 |
1045 case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1046 *ac_space=\ *)
1047 sed -n \
1048 "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1049 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1050 ;;
1051 *)
1052 sed -n \
1053 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1054 ;;
1055 esac;
1056}
1057 echo
1058 if test -s confdefs.h; then
1059 cat <<\_ASBOX
1060## ----------- ##
1061## confdefs.h. ##
1062## ----------- ##
1063_ASBOX
1064 echo
1065 sed "/^$/d" confdefs.h
1066 echo
1067 fi
1068 test "$ac_signal" != 0 &&
1069 echo "$as_me: caught signal $ac_signal"
1070 echo "$as_me: exit $exit_status"
1071 } >&5
1072 rm -f core core.* *.core &&
1073 rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1074 exit $exit_status
1075 ' 0
1076for ac_signal in 1 2 13 15; do
1077 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1078done
1079ac_signal=0
1080
1081# confdefs.h avoids OS command line length limits that DEFS can exceed.
1082rm -rf conftest* confdefs.h
1083# AIX cpp loses on an empty file, so make sure it contains at least a newline.
1084echo >confdefs.h
1085
1086# Predefined preprocessor variables.
1087
1088cat >>confdefs.h <<_ACEOF
1089#define PACKAGE_NAME "$PACKAGE_NAME"
1090_ACEOF
1091
1092
1093cat >>confdefs.h <<_ACEOF
1094#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1095_ACEOF
1096
1097
1098cat >>confdefs.h <<_ACEOF
1099#define PACKAGE_VERSION "$PACKAGE_VERSION"
1100_ACEOF
1101
1102
1103cat >>confdefs.h <<_ACEOF
1104#define PACKAGE_STRING "$PACKAGE_STRING"
1105_ACEOF
1106
1107
1108cat >>confdefs.h <<_ACEOF
1109#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1110_ACEOF
1111
1112
1113# Let the site file select an alternate cache file if it wants to.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001114# Prefer explicitly selected file to automatically selected ones.
1115if test -z "$CONFIG_SITE"; then
1116 if test "x$prefix" != xNONE; then
1117 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1118 else
1119 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1120 fi
1121fi
1122for ac_site_file in $CONFIG_SITE; do
1123 if test -r "$ac_site_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001124 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1125echo "$as_me: loading site script $ac_site_file" >&6;}
1126 sed 's/^/| /' "$ac_site_file" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001127 . "$ac_site_file"
1128 fi
1129done
1130
1131if test -r "$cache_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001132 # Some versions of bash will fail to source /dev/null (special
1133 # files actually), so we avoid doing that.
1134 if test -f "$cache_file"; then
1135 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1136echo "$as_me: loading cache $cache_file" >&6;}
1137 case $cache_file in
1138 [\\/]* | ?:[\\/]* ) . $cache_file;;
1139 *) . ./$cache_file;;
1140 esac
1141 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001142else
Martin v. Löwis11437992002-04-12 09:54:03 +00001143 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1144echo "$as_me: creating cache $cache_file" >&6;}
1145 >$cache_file
1146fi
1147
1148# Check that the precious variables saved in the cache have kept the same
1149# value.
1150ac_cache_corrupted=false
1151for ac_var in `(set) 2>&1 |
1152 sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1153 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1154 eval ac_new_set=\$ac_env_${ac_var}_set
1155 eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1156 eval ac_new_val="\$ac_env_${ac_var}_value"
1157 case $ac_old_set,$ac_new_set in
1158 set,)
1159 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1160echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1161 ac_cache_corrupted=: ;;
1162 ,set)
1163 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1164echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1165 ac_cache_corrupted=: ;;
1166 ,);;
1167 *)
1168 if test "x$ac_old_val" != "x$ac_new_val"; then
1169 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1170echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1171 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
1172echo "$as_me: former value: $ac_old_val" >&2;}
1173 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
1174echo "$as_me: current value: $ac_new_val" >&2;}
1175 ac_cache_corrupted=:
1176 fi;;
1177 esac
1178 # Pass precious variables to config.status.
1179 if test "$ac_new_set" = set; then
1180 case $ac_new_val in
1181 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1182 ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1183 *) ac_arg=$ac_var=$ac_new_val ;;
1184 esac
1185 case " $ac_configure_args " in
1186 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1187 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1188 esac
1189 fi
1190done
1191if $ac_cache_corrupted; then
1192 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1193echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1194 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1195echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1196 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001197fi
1198
Guido van Rossum7f43da71994-08-01 12:15:30 +00001199ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001200ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001201ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1202ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1203ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001204
Guido van Rossum627b2d71993-12-24 10:39:16 +00001205
Michael W. Hudson54241132001-12-07 15:38:26 +00001206
1207
Guido van Rossum627b2d71993-12-24 10:39:16 +00001208
Martin v. Löwis11437992002-04-12 09:54:03 +00001209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
Martin v. Löwis88afe662002-10-26 13:47:44 +00001222
1223
1224
1225
1226
1227
1228
1229
1230
Martin v. Löwis11437992002-04-12 09:54:03 +00001231ac_config_headers="$ac_config_headers pyconfig.h"
1232
1233
1234# This is for stuff that absolutely must end up in pyconfig.h.
1235# Please use pyport.h instead, if possible.
1236
1237
1238
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001239
Andrew M. Kuchlingf2f219d2002-02-11 16:31:10 +00001240VERSION=2.3
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001241
Martin v. Löwis1142de32002-03-29 16:28:31 +00001242
1243SOVERSION=1.0
1244
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001245# The later defininition of _XOPEN_SOURCE disables certain features
1246# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1247
1248cat >>confdefs.h <<\_ACEOF
1249#define _GNU_SOURCE 1
1250_ACEOF
1251
1252
1253# The definition of _GNU_SOURCE potentially causes a change of the value
1254# of _XOPEN_SOURCE. So define it only conditionally.
1255
1256
1257cat >>confdefs.h <<\_ACEOF
1258#define _XOPEN_SOURCE 500
1259_ACEOF
1260
1261
Martin v. Löwise4826582002-10-26 13:33:00 +00001262# On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires definition
1263# of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else several APIs
1264# are not declared. Since this is also needed in some cases for HP-UX,
1265# we define it globally.
1266
1267cat >>confdefs.h <<\_ACEOF
1268#define _XOPEN_SOURCE_EXTENDED 1
1269_ACEOF
1270
1271
1272cat >>confdefs.h <<\_ACEOF
1273#define _POSIX_C_SOURCE 199506L
1274_ACEOF
1275
1276
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00001277# Arguments passed to configure.
1278
1279CONFIG_ARGS="$ac_configure_args"
1280
Jack Jansene578a632001-08-15 01:27:14 +00001281# Check whether --enable-framework or --disable-framework was given.
1282if test "${enable_framework+set}" = set; then
1283 enableval="$enable_framework"
Martin v. Löwis11437992002-04-12 09:54:03 +00001284
Jack Jansene578a632001-08-15 01:27:14 +00001285 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00001286 yes)
Jack Jansene578a632001-08-15 01:27:14 +00001287 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00001288 esac
1289 case $enableval in
1290 no)
1291 PYTHONFRAMEWORK=
1292 PYTHONFRAMEWORKDIR=no-framework
1293 PYTHONFRAMEWORKPREFIX=
1294 PYTHONFRAMEWORKINSTALLDIR=
1295 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00001296 ;;
1297 *)
Jack Jansen127e56e2001-09-11 14:41:54 +00001298 PYTHONFRAMEWORK=Python
1299 PYTHONFRAMEWORKDIR=Python.framework
Jack Jansene578a632001-08-15 01:27:14 +00001300 PYTHONFRAMEWORKPREFIX=$enableval
Jack Jansen127e56e2001-09-11 14:41:54 +00001301 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
1302 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Jack Jansene578a632001-08-15 01:27:14 +00001303 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001304
Guido van Rossum563e7081996-09-10 18:20:48 +00001305else
Martin v. Löwis11437992002-04-12 09:54:03 +00001306
Jack Jansene578a632001-08-15 01:27:14 +00001307 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00001308 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00001309 PYTHONFRAMEWORKPREFIX=
1310 PYTHONFRAMEWORKINSTALLDIR=
1311 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001312
Martin v. Löwis11437992002-04-12 09:54:03 +00001313fi;
Michael W. Hudson54241132001-12-07 15:38:26 +00001314
1315
1316
1317
Jack Jansene578a632001-08-15 01:27:14 +00001318
1319##AC_ARG_WITH(dyld,
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001320## AC_HELP_STRING(--with-dyld,
1321## Use (OpenStep|Rhapsody) dynamic linker))
Jack Jansene578a632001-08-15 01:27:14 +00001322##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001323# Set name for machine-dependent library files
1324
Martin v. Löwis11437992002-04-12 09:54:03 +00001325echo "$as_me:$LINENO: checking MACHDEP" >&5
1326echo $ECHO_N "checking MACHDEP... $ECHO_C" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001327if test -z "$MACHDEP"
1328then
Guido van Rossum563e7081996-09-10 18:20:48 +00001329 ac_sys_system=`uname -s`
Martin v. Löwis21ee4092002-09-30 16:19:48 +00001330 if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64" \
1331 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00001332 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001333 else
Guido van Rossum563e7081996-09-10 18:20:48 +00001334 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001335 fi
Guido van Rossum563e7081996-09-10 18:20:48 +00001336 ac_md_system=`echo $ac_sys_system |
1337 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
1338 ac_md_release=`echo $ac_sys_release |
Guido van Rossum67b26592001-10-20 14:21:45 +00001339 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +00001340 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00001341
Guido van Rossum07397971997-04-29 21:49:50 +00001342 case $MACHDEP in
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00001343 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00001344 darwin*) MACHDEP="darwin";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00001345 atheos*) MACHDEP="atheos";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00001346 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001347 esac
1348fi
Guido van Rossum91922671997-10-09 20:24:13 +00001349
1350#
1351# SGI compilers allow the specification of the both the ABI and the
1352# ISA on the command line. Depending on the values of these switches,
1353# different and often incompatable code will be generated.
1354#
1355# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
1356# thus supply support for various ABI/ISA combinations. The MACHDEP
1357# variable is also adjusted.
1358#
1359
1360if test ! -z "$SGI_ABI"
1361then
1362 CC="cc $SGI_ABI"
1363 LDFLAGS="$SGI_ABI $LDFLAGS"
1364 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
1365fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001366echo "$as_me:$LINENO: result: $MACHDEP" >&5
1367echo "${ECHO_T}$MACHDEP" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001368
Guido van Rossum627b2d71993-12-24 10:39:16 +00001369# checks for alternative programs
Martin v. Löwis11437992002-04-12 09:54:03 +00001370echo "$as_me:$LINENO: checking for --without-gcc" >&5
1371echo $ECHO_N "checking for --without-gcc... $ECHO_C" >&6
1372
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001373# Check whether --with-gcc or --without-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001374if test "${with_gcc+set}" = set; then
1375 withval="$with_gcc"
Martin v. Löwis11437992002-04-12 09:54:03 +00001376
Guido van Rossum7f43da71994-08-01 12:15:30 +00001377 case $withval in
Guido van Rossumda88dad1995-01-26 00:46:29 +00001378 no) CC=cc
1379 without_gcc=yes;;
1380 yes) CC=gcc
1381 without_gcc=no;;
1382 *) CC=$withval
1383 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001384 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +00001385else
Martin v. Löwis11437992002-04-12 09:54:03 +00001386
Guido van Rossum7b3853f1996-07-30 18:09:35 +00001387 case $ac_sys_system in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001388 AIX*) CC=cc_r
1389 without_gcc=;;
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001390 BeOS*)
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001391 case $BE_HOST_CPU in
1392 ppc)
Fred Drake5790be12000-10-09 17:06:13 +00001393 CC=mwcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001394 without_gcc=yes
Mark Hammond8235ea12002-07-19 06:55:41 +00001395 OPT="-O -export pragma"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001396 LDFLAGS="$LDFLAGS -nodup"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001397 ;;
1398 x86)
Fred Drake5790be12000-10-09 17:06:13 +00001399 CC=gcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001400 without_gcc=no
Fred Drake5790be12000-10-09 17:06:13 +00001401 OPT=-O
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001402 ;;
1403 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001404 { { echo "$as_me:$LINENO: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&5
1405echo "$as_me: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&2;}
1406 { (exit 1); exit 1; }; }
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001407 ;;
1408 esac
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00001409 AR="\$(srcdir)/Modules/ar_beos"
1410 RANLIB=:
Guido van Rossum7a5f4201999-01-12 20:30:23 +00001411 ;;
Trent Mick635f6fb2000-08-23 21:33:05 +00001412 Monterey*)
1413 RANLIB=:
Martin v. Löwis130fb172001-07-19 11:00:41 +00001414 without_gcc=;;
1415 *) without_gcc=no;;
Guido van Rossume77438c1995-09-13 18:59:59 +00001416 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001417fi;
1418echo "$as_me:$LINENO: result: $without_gcc" >&5
1419echo "${ECHO_T}$without_gcc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001420
1421
Guido van Rossum95012191999-12-16 17:50:52 +00001422
Fred Drakea1a84e72001-03-06 05:52:16 +00001423MAINOBJ=python.o
Martin v. Löwis11437992002-04-12 09:54:03 +00001424echo "$as_me:$LINENO: checking for --with-cxx=<compiler>" >&5
1425echo $ECHO_N "checking for --with-cxx=<compiler>... $ECHO_C" >&6
1426
Guido van Rossum95012191999-12-16 17:50:52 +00001427# Check whether --with-cxx or --without-cxx was given.
1428if test "${with_cxx+set}" = set; then
1429 withval="$with_cxx"
Martin v. Löwis11437992002-04-12 09:54:03 +00001430
Martin v. Löwis22352952000-12-13 17:37:02 +00001431 check_cxx=no
Guido van Rossum95012191999-12-16 17:50:52 +00001432 case $withval in
1433 no) CXX=
1434 with_cxx=no;;
1435 *) CXX=$withval
Fred Drakea1a84e72001-03-06 05:52:16 +00001436 MAINOBJ=ccpython.o
Guido van Rossum95012191999-12-16 17:50:52 +00001437 with_cxx=$withval;;
1438 esac
1439else
Martin v. Löwis11437992002-04-12 09:54:03 +00001440
Guido van Rossum95012191999-12-16 17:50:52 +00001441 with_cxx=no
Martin v. Löwis22352952000-12-13 17:37:02 +00001442 check_cxx=yes
Guido van Rossum95012191999-12-16 17:50:52 +00001443
Martin v. Löwis11437992002-04-12 09:54:03 +00001444fi;
1445echo "$as_me:$LINENO: result: $with_cxx" >&5
1446echo "${ECHO_T}$with_cxx" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00001447
1448if test "$with_cxx" = "yes"
1449then
Martin v. Löwis11437992002-04-12 09:54:03 +00001450 { { echo "$as_me:$LINENO: error: must supply a compiler when using --with-cxx" >&5
1451echo "$as_me: error: must supply a compiler when using --with-cxx" >&2;}
1452 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001453fi
1454
1455
1456
1457
Martin v. Löwis11437992002-04-12 09:54:03 +00001458if test "$check_cxx" = "yes"
Martin v. Löwis22352952000-12-13 17:37:02 +00001459then
1460 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
1461do
Martin v. Löwis11437992002-04-12 09:54:03 +00001462 # 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 +00001463set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00001464echo "$as_me:$LINENO: checking for $ac_word" >&5
1465echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1466if test "${ac_cv_prog_CXX+set}" = set; then
1467 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001468else
1469 if test -n "$CXX"; then
1470 ac_cv_prog_CXX="$CXX" # Let the user override the test.
1471else
Martin v. Löwis11437992002-04-12 09:54:03 +00001472as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1473for as_dir in $PATH
1474do
1475 IFS=$as_save_IFS
1476 test -z "$as_dir" && as_dir=.
1477 for ac_exec_ext in '' $ac_executable_extensions; do
1478 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1479 ac_cv_prog_CXX="$ac_prog"
1480 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1481 break 2
1482 fi
1483done
1484done
1485
Martin v. Löwis22352952000-12-13 17:37:02 +00001486fi
1487fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001488CXX=$ac_cv_prog_CXX
Martin v. Löwis22352952000-12-13 17:37:02 +00001489if test -n "$CXX"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001490 echo "$as_me:$LINENO: result: $CXX" >&5
1491echo "${ECHO_T}$CXX" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001492else
Martin v. Löwis11437992002-04-12 09:54:03 +00001493 echo "$as_me:$LINENO: result: no" >&5
1494echo "${ECHO_T}no" >&6
Martin v. Löwis22352952000-12-13 17:37:02 +00001495fi
1496
Martin v. Löwis11437992002-04-12 09:54:03 +00001497 test -n "$CXX" && break
Martin v. Löwis22352952000-12-13 17:37:02 +00001498done
1499test -n "$CXX" || CXX="notfound"
1500
1501 if test "$CXX" = "notfound"
1502 then
1503 CXX=
1504 else
Martin v. Löwis11437992002-04-12 09:54:03 +00001505 ac_ext=cc
Martin v. Löwis22352952000-12-13 17:37:02 +00001506ac_cpp='$CXXCPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001507ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1508ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1509ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
1510 cat >conftest.$ac_ext <<_ACEOF
1511#line $LINENO "configure"
Martin v. Löwis22352952000-12-13 17:37:02 +00001512#include "confdefs.h"
1513
Martin v. Löwis11437992002-04-12 09:54:03 +00001514#ifdef F77_DUMMY_MAIN
1515# ifdef __cplusplus
1516 extern "C"
1517# endif
1518 int F77_DUMMY_MAIN() { return 1; }
1519#endif
1520int
1521main ()
1522{
Michael W. Hudson54241132001-12-07 15:38:26 +00001523
Martin v. Löwis11437992002-04-12 09:54:03 +00001524 ;
1525 return 0;
1526}
1527_ACEOF
1528ac_clean_files_save=$ac_clean_files
1529ac_clean_files="$ac_clean_files a.out a.exe"
1530# Try to create an executable without -o first, disregard a.out.
1531# It will help us diagnose broken compilers, and finding out an intuition
1532# of exeext.
1533echo "$as_me:$LINENO: checking for C++ compiler default output" >&5
1534echo $ECHO_N "checking for C++ compiler default output... $ECHO_C" >&6
1535ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
1536if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
1537 (eval $ac_link_default) 2>&5
1538 ac_status=$?
1539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1540 (exit $ac_status); }; then
1541 # Find the output, starting from the most likely. This scheme is
1542# not robust to junk in `.', hence go to wildcards (a.*) only as a last
1543# resort.
1544
1545# Be careful to initialize this variable, since it used to be cached.
1546# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
1547ac_cv_exeext=
1548for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
1549 ls a.out conftest 2>/dev/null;
1550 ls a.* conftest.* 2>/dev/null`; do
1551 case $ac_file in
1552 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
1553 a.out ) # We found the default executable, but exeext='' is most
1554 # certainly right.
1555 break;;
1556 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1557 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
1558 export ac_cv_exeext
1559 break;;
1560 * ) break;;
1561 esac
1562done
1563else
1564 echo "$as_me: failed program was:" >&5
1565cat conftest.$ac_ext >&5
1566{ { echo "$as_me:$LINENO: error: C++ compiler cannot create executables" >&5
1567echo "$as_me: error: C++ compiler cannot create executables" >&2;}
1568 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00001569fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001570
1571ac_exeext=$ac_cv_exeext
1572echo "$as_me:$LINENO: result: $ac_file" >&5
1573echo "${ECHO_T}$ac_file" >&6
1574
1575# Check the compiler produces executables we can run. If not, either
1576# the compiler is broken, or we cross compile.
1577echo "$as_me:$LINENO: checking whether the C++ compiler works" >&5
1578echo $ECHO_N "checking whether the C++ compiler works... $ECHO_C" >&6
1579# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
1580# If not cross compiling, check that we can run a simple program.
1581if test "$cross_compiling" != yes; then
1582 if { ac_try='./$ac_file'
1583 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
1584 (eval $ac_try) 2>&5
1585 ac_status=$?
1586 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1587 (exit $ac_status); }; }; then
1588 cross_compiling=no
1589 else
1590 if test "$cross_compiling" = maybe; then
1591 cross_compiling=yes
1592 else
1593 { { echo "$as_me:$LINENO: error: cannot run C++ compiled programs.
1594If you meant to cross compile, use \`--host'." >&5
1595echo "$as_me: error: cannot run C++ compiled programs.
1596If you meant to cross compile, use \`--host'." >&2;}
1597 { (exit 1); exit 1; }; }
1598 fi
1599 fi
1600fi
1601echo "$as_me:$LINENO: result: yes" >&5
1602echo "${ECHO_T}yes" >&6
1603
1604rm -f a.out a.exe conftest$ac_cv_exeext
1605ac_clean_files=$ac_clean_files_save
1606# Check the compiler produces executables we can run. If not, either
1607# the compiler is broken, or we cross compile.
1608echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
1609echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
1610echo "$as_me:$LINENO: result: $cross_compiling" >&5
1611echo "${ECHO_T}$cross_compiling" >&6
1612
1613echo "$as_me:$LINENO: checking for suffix of executables" >&5
1614echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
1615if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
1616 (eval $ac_link) 2>&5
1617 ac_status=$?
1618 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1619 (exit $ac_status); }; then
1620 # If both `conftest.exe' and `conftest' are `present' (well, observable)
1621# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
1622# work properly (i.e., refer to `conftest.exe'), while it won't with
1623# `rm'.
1624for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
1625 case $ac_file in
1626 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
1627 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
1628 export ac_cv_exeext
1629 break;;
1630 * ) break;;
1631 esac
1632done
1633else
1634 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
1635echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
1636 { (exit 1); exit 1; }; }
1637fi
1638
1639rm -f conftest$ac_cv_exeext
1640echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
1641echo "${ECHO_T}$ac_cv_exeext" >&6
1642
1643rm -f conftest.$ac_ext
1644EXEEXT=$ac_cv_exeext
1645ac_exeext=$EXEEXT
1646
1647 ac_ext=c
1648ac_cpp='$CPP $CPPFLAGS'
1649ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1650ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1651ac_compiler_gnu=$ac_cv_c_compiler_gnu
1652
1653
Martin v. Löwis22352952000-12-13 17:37:02 +00001654
1655 fi
1656fi
1657
Guido van Rossum8b131c51995-03-09 14:10:13 +00001658# If the user switches compilers, we can't believe the cache
1659if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
1660then
Martin v. Löwis11437992002-04-12 09:54:03 +00001661 { { echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file
1662(it is also a good idea to do 'make clean' before compiling)" >&5
1663echo "$as_me: error: cached CC is different -- throw away $cache_file
1664(it is also a good idea to do 'make clean' before compiling)" >&2;}
1665 { (exit 1); exit 1; }; }
Guido van Rossum8b131c51995-03-09 14:10:13 +00001666fi
1667
Martin v. Löwis11437992002-04-12 09:54:03 +00001668ac_ext=c
1669ac_cpp='$CPP $CPPFLAGS'
1670ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1671ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1672ac_compiler_gnu=$ac_cv_c_compiler_gnu
1673if test -n "$ac_tool_prefix"; then
1674 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1675set dummy ${ac_tool_prefix}gcc; ac_word=$2
1676echo "$as_me:$LINENO: checking for $ac_word" >&5
1677echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1678if test "${ac_cv_prog_CC+set}" = set; then
1679 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001680else
1681 if test -n "$CC"; then
1682 ac_cv_prog_CC="$CC" # Let the user override the test.
1683else
Martin v. Löwis11437992002-04-12 09:54:03 +00001684as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1685for as_dir in $PATH
1686do
1687 IFS=$as_save_IFS
1688 test -z "$as_dir" && as_dir=.
1689 for ac_exec_ext in '' $ac_executable_extensions; do
1690 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1691 ac_cv_prog_CC="${ac_tool_prefix}gcc"
1692 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1693 break 2
1694 fi
1695done
1696done
1697
Jack Jansendd19cf82001-12-06 22:36:17 +00001698fi
1699fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001700CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00001701if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001702 echo "$as_me:$LINENO: result: $CC" >&5
1703echo "${ECHO_T}$CC" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001704else
Martin v. Löwis11437992002-04-12 09:54:03 +00001705 echo "$as_me:$LINENO: result: no" >&5
1706echo "${ECHO_T}no" >&6
1707fi
1708
1709fi
1710if test -z "$ac_cv_prog_CC"; then
1711 ac_ct_CC=$CC
1712 # Extract the first word of "gcc", so it can be a program name with args.
1713set dummy gcc; ac_word=$2
1714echo "$as_me:$LINENO: checking for $ac_word" >&5
1715echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1716if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1717 echo $ECHO_N "(cached) $ECHO_C" >&6
1718else
1719 if test -n "$ac_ct_CC"; then
1720 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1721else
1722as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1723for as_dir in $PATH
1724do
1725 IFS=$as_save_IFS
1726 test -z "$as_dir" && as_dir=.
1727 for ac_exec_ext in '' $ac_executable_extensions; do
1728 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1729 ac_cv_prog_ac_ct_CC="gcc"
1730 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1731 break 2
1732 fi
1733done
1734done
1735
1736fi
1737fi
1738ac_ct_CC=$ac_cv_prog_ac_ct_CC
1739if test -n "$ac_ct_CC"; then
1740 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1741echo "${ECHO_T}$ac_ct_CC" >&6
1742else
1743 echo "$as_me:$LINENO: result: no" >&5
1744echo "${ECHO_T}no" >&6
1745fi
1746
1747 CC=$ac_ct_CC
1748else
1749 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00001750fi
1751
Jack Jansendd19cf82001-12-06 22:36:17 +00001752if test -z "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001753 if test -n "$ac_tool_prefix"; then
1754 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1755set dummy ${ac_tool_prefix}cc; ac_word=$2
1756echo "$as_me:$LINENO: checking for $ac_word" >&5
1757echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1758if test "${ac_cv_prog_CC+set}" = set; then
1759 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001760else
1761 if test -n "$CC"; then
1762 ac_cv_prog_CC="$CC" # Let the user override the test.
1763else
Martin v. Löwis11437992002-04-12 09:54:03 +00001764as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1765for as_dir in $PATH
1766do
1767 IFS=$as_save_IFS
1768 test -z "$as_dir" && as_dir=.
1769 for ac_exec_ext in '' $ac_executable_extensions; do
1770 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1771 ac_cv_prog_CC="${ac_tool_prefix}cc"
1772 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1773 break 2
1774 fi
1775done
1776done
1777
1778fi
1779fi
1780CC=$ac_cv_prog_CC
1781if test -n "$CC"; then
1782 echo "$as_me:$LINENO: result: $CC" >&5
1783echo "${ECHO_T}$CC" >&6
1784else
1785 echo "$as_me:$LINENO: result: no" >&5
1786echo "${ECHO_T}no" >&6
1787fi
1788
1789fi
1790if test -z "$ac_cv_prog_CC"; then
1791 ac_ct_CC=$CC
1792 # Extract the first word of "cc", so it can be a program name with args.
1793set dummy cc; ac_word=$2
1794echo "$as_me:$LINENO: checking for $ac_word" >&5
1795echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1796if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1797 echo $ECHO_N "(cached) $ECHO_C" >&6
1798else
1799 if test -n "$ac_ct_CC"; then
1800 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1801else
1802as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1803for as_dir in $PATH
1804do
1805 IFS=$as_save_IFS
1806 test -z "$as_dir" && as_dir=.
1807 for ac_exec_ext in '' $ac_executable_extensions; do
1808 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1809 ac_cv_prog_ac_ct_CC="cc"
1810 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1811 break 2
1812 fi
1813done
1814done
1815
1816fi
1817fi
1818ac_ct_CC=$ac_cv_prog_ac_ct_CC
1819if test -n "$ac_ct_CC"; then
1820 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1821echo "${ECHO_T}$ac_ct_CC" >&6
1822else
1823 echo "$as_me:$LINENO: result: no" >&5
1824echo "${ECHO_T}no" >&6
1825fi
1826
1827 CC=$ac_ct_CC
1828else
1829 CC="$ac_cv_prog_CC"
1830fi
1831
1832fi
1833if test -z "$CC"; then
1834 # Extract the first word of "cc", so it can be a program name with args.
1835set dummy cc; ac_word=$2
1836echo "$as_me:$LINENO: checking for $ac_word" >&5
1837echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1838if test "${ac_cv_prog_CC+set}" = set; then
1839 echo $ECHO_N "(cached) $ECHO_C" >&6
1840else
1841 if test -n "$CC"; then
1842 ac_cv_prog_CC="$CC" # Let the user override the test.
1843else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001844 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00001845as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1846for as_dir in $PATH
1847do
1848 IFS=$as_save_IFS
1849 test -z "$as_dir" && as_dir=.
1850 for ac_exec_ext in '' $ac_executable_extensions; do
1851 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1852 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1853 ac_prog_rejected=yes
1854 continue
1855 fi
1856 ac_cv_prog_CC="cc"
1857 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1858 break 2
1859 fi
1860done
1861done
1862
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001863if test $ac_prog_rejected = yes; then
1864 # We found a bogon in the path, so make sure we never use it.
1865 set dummy $ac_cv_prog_CC
1866 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00001867 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001868 # We chose a different compiler from the bogus one.
1869 # However, it has the same basename, so the bogon will be chosen
1870 # first if we set CC to just the basename; use the full file name.
1871 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00001872 set dummy "$as_dir/$ac_word" ${1+"$@"}
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001873 shift
1874 ac_cv_prog_CC="$@"
1875 fi
1876fi
1877fi
1878fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001879CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001880if test -n "$CC"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001881 echo "$as_me:$LINENO: result: $CC" >&5
1882echo "${ECHO_T}$CC" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001883else
Martin v. Löwis11437992002-04-12 09:54:03 +00001884 echo "$as_me:$LINENO: result: no" >&5
1885echo "${ECHO_T}no" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001886fi
1887
Martin v. Löwis11437992002-04-12 09:54:03 +00001888fi
1889if test -z "$CC"; then
1890 if test -n "$ac_tool_prefix"; then
1891 for ac_prog in cl
1892 do
1893 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1894set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1895echo "$as_me:$LINENO: checking for $ac_word" >&5
1896echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1897if test "${ac_cv_prog_CC+set}" = set; then
1898 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00001899else
1900 if test -n "$CC"; then
1901 ac_cv_prog_CC="$CC" # Let the user override the test.
1902else
Martin v. Löwis11437992002-04-12 09:54:03 +00001903as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1904for as_dir in $PATH
1905do
1906 IFS=$as_save_IFS
1907 test -z "$as_dir" && as_dir=.
1908 for ac_exec_ext in '' $ac_executable_extensions; do
1909 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1910 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1911 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1912 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00001913 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00001914done
1915done
1916
1917fi
1918fi
1919CC=$ac_cv_prog_CC
1920if test -n "$CC"; then
1921 echo "$as_me:$LINENO: result: $CC" >&5
1922echo "${ECHO_T}$CC" >&6
1923else
1924 echo "$as_me:$LINENO: result: no" >&5
1925echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00001926fi
1927
Martin v. Löwis11437992002-04-12 09:54:03 +00001928 test -n "$CC" && break
1929 done
1930fi
1931if test -z "$CC"; then
1932 ac_ct_CC=$CC
1933 for ac_prog in cl
1934do
1935 # Extract the first word of "$ac_prog", so it can be a program name with args.
1936set dummy $ac_prog; ac_word=$2
1937echo "$as_me:$LINENO: checking for $ac_word" >&5
1938echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1939if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1940 echo $ECHO_N "(cached) $ECHO_C" >&6
1941else
1942 if test -n "$ac_ct_CC"; then
1943 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1944else
1945as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1946for as_dir in $PATH
1947do
1948 IFS=$as_save_IFS
1949 test -z "$as_dir" && as_dir=.
1950 for ac_exec_ext in '' $ac_executable_extensions; do
1951 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1952 ac_cv_prog_ac_ct_CC="$ac_prog"
1953 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1954 break 2
1955 fi
1956done
1957done
Jack Jansendd19cf82001-12-06 22:36:17 +00001958
Martin v. Löwis11437992002-04-12 09:54:03 +00001959fi
1960fi
1961ac_ct_CC=$ac_cv_prog_ac_ct_CC
1962if test -n "$ac_ct_CC"; then
1963 echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1964echo "${ECHO_T}$ac_ct_CC" >&6
1965else
1966 echo "$as_me:$LINENO: result: no" >&5
1967echo "${ECHO_T}no" >&6
1968fi
Michael W. Hudson54241132001-12-07 15:38:26 +00001969
Martin v. Löwis11437992002-04-12 09:54:03 +00001970 test -n "$ac_ct_CC" && break
1971done
Michael W. Hudson54241132001-12-07 15:38:26 +00001972
Martin v. Löwis11437992002-04-12 09:54:03 +00001973 CC=$ac_ct_CC
1974fi
1975
1976fi
1977
1978
1979test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH" >&5
1980echo "$as_me: error: no acceptable C compiler found in \$PATH" >&2;}
1981 { (exit 1); exit 1; }; }
1982
1983# Provide some information about the compiler.
1984echo "$as_me:$LINENO:" \
1985 "checking for C compiler version" >&5
1986ac_compiler=`set X $ac_compile; echo $2`
1987{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1988 (eval $ac_compiler --version </dev/null >&5) 2>&5
1989 ac_status=$?
1990 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1991 (exit $ac_status); }
1992{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1993 (eval $ac_compiler -v </dev/null >&5) 2>&5
1994 ac_status=$?
1995 echo "$as_me:$LINENO: \$? = $ac_status" >&5
1996 (exit $ac_status); }
1997{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1998 (eval $ac_compiler -V </dev/null >&5) 2>&5
1999 ac_status=$?
2000 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2001 (exit $ac_status); }
2002
2003cat >conftest.$ac_ext <<_ACEOF
2004#line $LINENO "configure"
Jack Jansendd19cf82001-12-06 22:36:17 +00002005#include "confdefs.h"
2006
Martin v. Löwis11437992002-04-12 09:54:03 +00002007#ifdef F77_DUMMY_MAIN
2008# ifdef __cplusplus
2009 extern "C"
2010# endif
2011 int F77_DUMMY_MAIN() { return 1; }
Guido van Rossum627b2d71993-12-24 10:39:16 +00002012#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00002013int
2014main ()
2015{
2016
2017 ;
2018 return 0;
2019}
2020_ACEOF
2021ac_clean_files_save=$ac_clean_files
2022ac_clean_files="$ac_clean_files a.out a.exe"
2023# Try to create an executable without -o first, disregard a.out.
2024# It will help us diagnose broken compilers, and finding out an intuition
2025# of exeext.
2026echo "$as_me:$LINENO: checking for C compiler default output" >&5
2027echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2028ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2029if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2030 (eval $ac_link_default) 2>&5
2031 ac_status=$?
2032 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2033 (exit $ac_status); }; then
2034 # Find the output, starting from the most likely. This scheme is
2035# not robust to junk in `.', hence go to wildcards (a.*) only as a last
2036# resort.
2037
2038# Be careful to initialize this variable, since it used to be cached.
2039# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2040ac_cv_exeext=
2041for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
2042 ls a.out conftest 2>/dev/null;
2043 ls a.* conftest.* 2>/dev/null`; do
2044 case $ac_file in
2045 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
2046 a.out ) # We found the default executable, but exeext='' is most
2047 # certainly right.
2048 break;;
2049 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2050 # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
2051 export ac_cv_exeext
2052 break;;
2053 * ) break;;
2054 esac
2055done
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002056else
Martin v. Löwis11437992002-04-12 09:54:03 +00002057 echo "$as_me: failed program was:" >&5
2058cat conftest.$ac_ext >&5
2059{ { echo "$as_me:$LINENO: error: C compiler cannot create executables" >&5
2060echo "$as_me: error: C compiler cannot create executables" >&2;}
2061 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002062fi
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002063
Martin v. Löwis11437992002-04-12 09:54:03 +00002064ac_exeext=$ac_cv_exeext
2065echo "$as_me:$LINENO: result: $ac_file" >&5
2066echo "${ECHO_T}$ac_file" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002067
Martin v. Löwis11437992002-04-12 09:54:03 +00002068# Check the compiler produces executables we can run. If not, either
2069# the compiler is broken, or we cross compile.
2070echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2071echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2072# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2073# If not cross compiling, check that we can run a simple program.
2074if test "$cross_compiling" != yes; then
2075 if { ac_try='./$ac_file'
2076 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2077 (eval $ac_try) 2>&5
2078 ac_status=$?
2079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2080 (exit $ac_status); }; }; then
2081 cross_compiling=no
2082 else
2083 if test "$cross_compiling" = maybe; then
2084 cross_compiling=yes
2085 else
2086 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2087If you meant to cross compile, use \`--host'." >&5
2088echo "$as_me: error: cannot run C compiled programs.
2089If you meant to cross compile, use \`--host'." >&2;}
2090 { (exit 1); exit 1; }; }
2091 fi
2092 fi
2093fi
2094echo "$as_me:$LINENO: result: yes" >&5
2095echo "${ECHO_T}yes" >&6
2096
2097rm -f a.out a.exe conftest$ac_cv_exeext
2098ac_clean_files=$ac_clean_files_save
2099# Check the compiler produces executables we can run. If not, either
2100# the compiler is broken, or we cross compile.
2101echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2102echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2103echo "$as_me:$LINENO: result: $cross_compiling" >&5
2104echo "${ECHO_T}$cross_compiling" >&6
2105
2106echo "$as_me:$LINENO: checking for suffix of executables" >&5
2107echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2108if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2109 (eval $ac_link) 2>&5
2110 ac_status=$?
2111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2112 (exit $ac_status); }; then
2113 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2114# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2115# work properly (i.e., refer to `conftest.exe'), while it won't with
2116# `rm'.
2117for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
2118 case $ac_file in
2119 *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
2120 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2121 export ac_cv_exeext
2122 break;;
2123 * ) break;;
2124 esac
2125done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002126else
Martin v. Löwis11437992002-04-12 09:54:03 +00002127 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
2128echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
2129 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002130fi
Jack Jansendd19cf82001-12-06 22:36:17 +00002131
Martin v. Löwis11437992002-04-12 09:54:03 +00002132rm -f conftest$ac_cv_exeext
2133echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2134echo "${ECHO_T}$ac_cv_exeext" >&6
2135
2136rm -f conftest.$ac_ext
2137EXEEXT=$ac_cv_exeext
2138ac_exeext=$EXEEXT
2139echo "$as_me:$LINENO: checking for suffix of object files" >&5
2140echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2141if test "${ac_cv_objext+set}" = set; then
2142 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002143else
Martin v. Löwis11437992002-04-12 09:54:03 +00002144 cat >conftest.$ac_ext <<_ACEOF
2145#line $LINENO "configure"
2146#include "confdefs.h"
2147
2148#ifdef F77_DUMMY_MAIN
2149# ifdef __cplusplus
2150 extern "C"
2151# endif
2152 int F77_DUMMY_MAIN() { return 1; }
2153#endif
2154int
2155main ()
2156{
2157
2158 ;
2159 return 0;
2160}
2161_ACEOF
2162rm -f conftest.o conftest.obj
2163if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2164 (eval $ac_compile) 2>&5
2165 ac_status=$?
2166 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2167 (exit $ac_status); }; then
2168 for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2169 case $ac_file in
2170 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
2171 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2172 break;;
2173 esac
2174done
2175else
2176 echo "$as_me: failed program was:" >&5
2177cat conftest.$ac_ext >&5
2178{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile" >&5
2179echo "$as_me: error: cannot compute suffix of object files: cannot compile" >&2;}
2180 { (exit 1); exit 1; }; }
2181fi
2182
2183rm -f conftest.$ac_cv_objext conftest.$ac_ext
2184fi
2185echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2186echo "${ECHO_T}$ac_cv_objext" >&6
2187OBJEXT=$ac_cv_objext
2188ac_objext=$OBJEXT
2189echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2190echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2191if test "${ac_cv_c_compiler_gnu+set}" = set; then
2192 echo $ECHO_N "(cached) $ECHO_C" >&6
2193else
2194 cat >conftest.$ac_ext <<_ACEOF
2195#line $LINENO "configure"
2196#include "confdefs.h"
2197
2198#ifdef F77_DUMMY_MAIN
2199# ifdef __cplusplus
2200 extern "C"
2201# endif
2202 int F77_DUMMY_MAIN() { return 1; }
2203#endif
2204int
2205main ()
2206{
2207#ifndef __GNUC__
2208 choke me
2209#endif
2210
2211 ;
2212 return 0;
2213}
2214_ACEOF
2215rm -f conftest.$ac_objext
2216if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2217 (eval $ac_compile) 2>&5
2218 ac_status=$?
2219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2220 (exit $ac_status); } &&
2221 { ac_try='test -s conftest.$ac_objext'
2222 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2223 (eval $ac_try) 2>&5
2224 ac_status=$?
2225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2226 (exit $ac_status); }; }; then
2227 ac_compiler_gnu=yes
2228else
2229 echo "$as_me: failed program was:" >&5
2230cat conftest.$ac_ext >&5
2231ac_compiler_gnu=no
2232fi
2233rm -f conftest.$ac_objext conftest.$ac_ext
2234ac_cv_c_compiler_gnu=$ac_compiler_gnu
2235
2236fi
2237echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2238echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2239GCC=`test $ac_compiler_gnu = yes && echo yes`
2240ac_test_CFLAGS=${CFLAGS+set}
2241ac_save_CFLAGS=$CFLAGS
2242CFLAGS="-g"
2243echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2244echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2245if test "${ac_cv_prog_cc_g+set}" = set; then
2246 echo $ECHO_N "(cached) $ECHO_C" >&6
2247else
2248 cat >conftest.$ac_ext <<_ACEOF
2249#line $LINENO "configure"
2250#include "confdefs.h"
2251
2252#ifdef F77_DUMMY_MAIN
2253# ifdef __cplusplus
2254 extern "C"
2255# endif
2256 int F77_DUMMY_MAIN() { return 1; }
2257#endif
2258int
2259main ()
2260{
2261
2262 ;
2263 return 0;
2264}
2265_ACEOF
2266rm -f conftest.$ac_objext
2267if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2268 (eval $ac_compile) 2>&5
2269 ac_status=$?
2270 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2271 (exit $ac_status); } &&
2272 { ac_try='test -s conftest.$ac_objext'
2273 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2274 (eval $ac_try) 2>&5
2275 ac_status=$?
2276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2277 (exit $ac_status); }; }; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002278 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002279else
Martin v. Löwis11437992002-04-12 09:54:03 +00002280 echo "$as_me: failed program was:" >&5
2281cat conftest.$ac_ext >&5
2282ac_cv_prog_cc_g=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00002283fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002284rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002285fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002286echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2287echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002288if test "$ac_test_CFLAGS" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002289 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002290elif test $ac_cv_prog_cc_g = yes; then
2291 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00002292 CFLAGS="-g -O2"
2293 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002294 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002295 fi
2296else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002297 if test "$GCC" = yes; then
2298 CFLAGS="-O2"
2299 else
2300 CFLAGS=
2301 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002302fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002303# Some people use a C++ compiler to compile C. Since we use `exit',
2304# in C++ we need to declare it. In case someone uses the same compiler
2305# for both compiling C and C++ we need to have the C++ compiler decide
2306# the declaration of exit, since it's the most demanding environment.
2307cat >conftest.$ac_ext <<_ACEOF
2308#ifndef __cplusplus
2309 choke me
2310#endif
2311_ACEOF
2312rm -f conftest.$ac_objext
2313if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2314 (eval $ac_compile) 2>&5
2315 ac_status=$?
2316 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2317 (exit $ac_status); } &&
2318 { ac_try='test -s conftest.$ac_objext'
2319 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2320 (eval $ac_try) 2>&5
2321 ac_status=$?
2322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2323 (exit $ac_status); }; }; then
2324 for ac_declaration in \
2325 ''\
2326 '#include <stdlib.h>' \
2327 'extern "C" void std::exit (int) throw (); using std::exit;' \
2328 'extern "C" void std::exit (int); using std::exit;' \
2329 'extern "C" void exit (int) throw ();' \
2330 'extern "C" void exit (int);' \
2331 'void exit (int);'
2332do
2333 cat >conftest.$ac_ext <<_ACEOF
2334#line $LINENO "configure"
2335#include "confdefs.h"
2336#include <stdlib.h>
2337$ac_declaration
2338#ifdef F77_DUMMY_MAIN
2339# ifdef __cplusplus
2340 extern "C"
2341# endif
2342 int F77_DUMMY_MAIN() { return 1; }
2343#endif
2344int
2345main ()
2346{
2347exit (42);
2348 ;
2349 return 0;
2350}
2351_ACEOF
2352rm -f conftest.$ac_objext
2353if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2354 (eval $ac_compile) 2>&5
2355 ac_status=$?
2356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2357 (exit $ac_status); } &&
2358 { ac_try='test -s conftest.$ac_objext'
2359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2360 (eval $ac_try) 2>&5
2361 ac_status=$?
2362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2363 (exit $ac_status); }; }; then
2364 :
2365else
2366 echo "$as_me: failed program was:" >&5
2367cat conftest.$ac_ext >&5
2368continue
2369fi
2370rm -f conftest.$ac_objext conftest.$ac_ext
2371 cat >conftest.$ac_ext <<_ACEOF
2372#line $LINENO "configure"
2373#include "confdefs.h"
2374$ac_declaration
2375#ifdef F77_DUMMY_MAIN
2376# ifdef __cplusplus
2377 extern "C"
2378# endif
2379 int F77_DUMMY_MAIN() { return 1; }
2380#endif
2381int
2382main ()
2383{
2384exit (42);
2385 ;
2386 return 0;
2387}
2388_ACEOF
2389rm -f conftest.$ac_objext
2390if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2391 (eval $ac_compile) 2>&5
2392 ac_status=$?
2393 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2394 (exit $ac_status); } &&
2395 { ac_try='test -s conftest.$ac_objext'
2396 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2397 (eval $ac_try) 2>&5
2398 ac_status=$?
2399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2400 (exit $ac_status); }; }; then
2401 break
2402else
2403 echo "$as_me: failed program was:" >&5
2404cat conftest.$ac_ext >&5
2405fi
2406rm -f conftest.$ac_objext conftest.$ac_ext
2407done
2408rm -f conftest*
2409if test -n "$ac_declaration"; then
2410 echo '#ifdef __cplusplus' >>confdefs.h
2411 echo $ac_declaration >>confdefs.h
2412 echo '#endif' >>confdefs.h
2413fi
2414
2415else
2416 echo "$as_me: failed program was:" >&5
2417cat conftest.$ac_ext >&5
2418fi
2419rm -f conftest.$ac_objext conftest.$ac_ext
2420ac_ext=c
2421ac_cpp='$CPP $CPPFLAGS'
2422ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2423ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2424ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002425
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002426
2427# checks for UNIX variants that set C preprocessor variables
Martin v. Löwis11437992002-04-12 09:54:03 +00002428
2429ac_ext=c
2430ac_cpp='$CPP $CPPFLAGS'
2431ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2432ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2433ac_compiler_gnu=$ac_cv_c_compiler_gnu
2434echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2435echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002436# On Suns, sometimes $CPP names a directory.
2437if test -n "$CPP" && test -d "$CPP"; then
2438 CPP=
2439fi
2440if test -z "$CPP"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002441 if test "${ac_cv_prog_CPP+set}" = set; then
2442 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002443else
Martin v. Löwis11437992002-04-12 09:54:03 +00002444 # Double quotes because CPP needs to be expanded
2445 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2446 do
2447 ac_preproc_ok=false
2448for ac_c_preproc_warn_flag in '' yes
2449do
2450 # Use a header file that comes with gcc, so configuring glibc
2451 # with a fresh cross-compiler works.
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002452 # On the NeXT, cc -E runs the code through the compiler's parser,
Martin v. Löwis11437992002-04-12 09:54:03 +00002453 # not just through cpp. "Syntax error" is here to catch this case.
2454 cat >conftest.$ac_ext <<_ACEOF
2455#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002456#include "confdefs.h"
2457#include <assert.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00002458 Syntax error
2459_ACEOF
2460if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2461 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2462 ac_status=$?
2463 egrep -v '^ *\+' conftest.er1 >conftest.err
2464 rm -f conftest.er1
2465 cat conftest.err >&5
2466 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2467 (exit $ac_status); } >/dev/null; then
2468 if test -s conftest.err; then
2469 ac_cpp_err=$ac_c_preproc_warn_flag
2470 else
2471 ac_cpp_err=
2472 fi
2473else
2474 ac_cpp_err=yes
2475fi
2476if test -z "$ac_cpp_err"; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002477 :
2478else
Martin v. Löwis11437992002-04-12 09:54:03 +00002479 echo "$as_me: failed program was:" >&5
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002480 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002481 # Broken: fails on valid input.
2482continue
Jack Jansendd19cf82001-12-06 22:36:17 +00002483fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002484rm -f conftest.err conftest.$ac_ext
Jack Jansendd19cf82001-12-06 22:36:17 +00002485
Martin v. Löwis11437992002-04-12 09:54:03 +00002486 # OK, works on sane cases. Now check whether non-existent headers
2487 # can be detected and how.
2488 cat >conftest.$ac_ext <<_ACEOF
2489#line $LINENO "configure"
2490#include "confdefs.h"
2491#include <ac_nonexistent.h>
2492_ACEOF
2493if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2494 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2495 ac_status=$?
2496 egrep -v '^ *\+' conftest.er1 >conftest.err
2497 rm -f conftest.er1
2498 cat conftest.err >&5
2499 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2500 (exit $ac_status); } >/dev/null; then
2501 if test -s conftest.err; then
2502 ac_cpp_err=$ac_c_preproc_warn_flag
2503 else
2504 ac_cpp_err=
2505 fi
2506else
2507 ac_cpp_err=yes
2508fi
2509if test -z "$ac_cpp_err"; then
2510 # Broken: success on invalid input.
2511continue
2512else
2513 echo "$as_me: failed program was:" >&5
2514 cat conftest.$ac_ext >&5
2515 # Passes both tests.
2516ac_preproc_ok=:
2517break
2518fi
2519rm -f conftest.err conftest.$ac_ext
2520
2521done
2522# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2523rm -f conftest.err conftest.$ac_ext
2524if $ac_preproc_ok; then
2525 break
2526fi
2527
2528 done
2529 ac_cv_prog_CPP=$CPP
2530
2531fi
2532 CPP=$ac_cv_prog_CPP
2533else
2534 ac_cv_prog_CPP=$CPP
2535fi
2536echo "$as_me:$LINENO: result: $CPP" >&5
2537echo "${ECHO_T}$CPP" >&6
2538ac_preproc_ok=false
2539for ac_c_preproc_warn_flag in '' yes
2540do
2541 # Use a header file that comes with gcc, so configuring glibc
2542 # with a fresh cross-compiler works.
2543 # On the NeXT, cc -E runs the code through the compiler's parser,
2544 # not just through cpp. "Syntax error" is here to catch this case.
2545 cat >conftest.$ac_ext <<_ACEOF
2546#line $LINENO "configure"
2547#include "confdefs.h"
2548#include <assert.h>
2549 Syntax error
2550_ACEOF
2551if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2552 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2553 ac_status=$?
2554 egrep -v '^ *\+' conftest.er1 >conftest.err
2555 rm -f conftest.er1
2556 cat conftest.err >&5
2557 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2558 (exit $ac_status); } >/dev/null; then
2559 if test -s conftest.err; then
2560 ac_cpp_err=$ac_c_preproc_warn_flag
2561 else
2562 ac_cpp_err=
2563 fi
2564else
2565 ac_cpp_err=yes
2566fi
2567if test -z "$ac_cpp_err"; then
2568 :
2569else
2570 echo "$as_me: failed program was:" >&5
2571 cat conftest.$ac_ext >&5
2572 # Broken: fails on valid input.
2573continue
2574fi
2575rm -f conftest.err conftest.$ac_ext
2576
2577 # OK, works on sane cases. Now check whether non-existent headers
2578 # can be detected and how.
2579 cat >conftest.$ac_ext <<_ACEOF
2580#line $LINENO "configure"
2581#include "confdefs.h"
2582#include <ac_nonexistent.h>
2583_ACEOF
2584if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2585 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2586 ac_status=$?
2587 egrep -v '^ *\+' conftest.er1 >conftest.err
2588 rm -f conftest.er1
2589 cat conftest.err >&5
2590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2591 (exit $ac_status); } >/dev/null; then
2592 if test -s conftest.err; then
2593 ac_cpp_err=$ac_c_preproc_warn_flag
2594 else
2595 ac_cpp_err=
2596 fi
2597else
2598 ac_cpp_err=yes
2599fi
2600if test -z "$ac_cpp_err"; then
2601 # Broken: success on invalid input.
2602continue
2603else
2604 echo "$as_me: failed program was:" >&5
2605 cat conftest.$ac_ext >&5
2606 # Passes both tests.
2607ac_preproc_ok=:
2608break
2609fi
2610rm -f conftest.err conftest.$ac_ext
2611
2612done
2613# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2614rm -f conftest.err conftest.$ac_ext
2615if $ac_preproc_ok; then
2616 :
2617else
2618 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check" >&5
2619echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2620 { (exit 1); exit 1; }; }
2621fi
2622
2623ac_ext=c
2624ac_cpp='$CPP $CPPFLAGS'
2625ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2626ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2627ac_compiler_gnu=$ac_cv_c_compiler_gnu
2628
2629
2630
2631echo "$as_me:$LINENO: checking for AIX" >&5
2632echo $ECHO_N "checking for AIX... $ECHO_C" >&6
2633cat >conftest.$ac_ext <<_ACEOF
2634#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002635#include "confdefs.h"
2636#ifdef _AIX
2637 yes
2638#endif
2639
Martin v. Löwis11437992002-04-12 09:54:03 +00002640_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002641if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2642 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002643 echo "$as_me:$LINENO: result: yes" >&5
2644echo "${ECHO_T}yes" >&6
2645cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002646#define _ALL_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002647_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002648
2649else
Martin v. Löwis11437992002-04-12 09:54:03 +00002650 echo "$as_me:$LINENO: result: no" >&5
2651echo "${ECHO_T}no" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002652fi
2653rm -f conftest*
2654
Michael W. Hudson54241132001-12-07 15:38:26 +00002655
Martin v. Löwis11437992002-04-12 09:54:03 +00002656echo "$as_me:$LINENO: checking for ANSI C header files" >&5
2657echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
2658if test "${ac_cv_header_stdc+set}" = set; then
2659 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002660else
Martin v. Löwis11437992002-04-12 09:54:03 +00002661 cat >conftest.$ac_ext <<_ACEOF
2662#line $LINENO "configure"
2663#include "confdefs.h"
2664#include <stdlib.h>
2665#include <stdarg.h>
2666#include <string.h>
2667#include <float.h>
2668
2669_ACEOF
2670if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2671 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2672 ac_status=$?
2673 egrep -v '^ *\+' conftest.er1 >conftest.err
2674 rm -f conftest.er1
2675 cat conftest.err >&5
2676 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2677 (exit $ac_status); } >/dev/null; then
2678 if test -s conftest.err; then
2679 ac_cpp_err=$ac_c_preproc_warn_flag
2680 else
2681 ac_cpp_err=
2682 fi
2683else
2684 ac_cpp_err=yes
2685fi
2686if test -z "$ac_cpp_err"; then
2687 ac_cv_header_stdc=yes
2688else
2689 echo "$as_me: failed program was:" >&5
2690 cat conftest.$ac_ext >&5
2691 ac_cv_header_stdc=no
2692fi
2693rm -f conftest.err conftest.$ac_ext
2694
2695if test $ac_cv_header_stdc = yes; then
2696 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2697 cat >conftest.$ac_ext <<_ACEOF
2698#line $LINENO "configure"
2699#include "confdefs.h"
2700#include <string.h>
2701
2702_ACEOF
2703if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2704 egrep "memchr" >/dev/null 2>&1; then
2705 :
2706else
2707 ac_cv_header_stdc=no
2708fi
2709rm -f conftest*
2710
2711fi
2712
2713if test $ac_cv_header_stdc = yes; then
2714 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2715 cat >conftest.$ac_ext <<_ACEOF
2716#line $LINENO "configure"
2717#include "confdefs.h"
2718#include <stdlib.h>
2719
2720_ACEOF
2721if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2722 egrep "free" >/dev/null 2>&1; then
2723 :
2724else
2725 ac_cv_header_stdc=no
2726fi
2727rm -f conftest*
2728
2729fi
2730
2731if test $ac_cv_header_stdc = yes; then
2732 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2733 if test "$cross_compiling" = yes; then
2734 :
2735else
2736 cat >conftest.$ac_ext <<_ACEOF
2737#line $LINENO "configure"
2738#include "confdefs.h"
2739#include <ctype.h>
2740#if ((' ' & 0x0FF) == 0x020)
2741# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2742# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2743#else
2744# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
2745 || ('j' <= (c) && (c) <= 'r') \
2746 || ('s' <= (c) && (c) <= 'z'))
2747# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
2748#endif
2749
2750#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2751int
2752main ()
2753{
2754 int i;
2755 for (i = 0; i < 256; i++)
2756 if (XOR (islower (i), ISLOWER (i))
2757 || toupper (i) != TOUPPER (i))
2758 exit(2);
2759 exit (0);
2760}
2761_ACEOF
2762rm -f conftest$ac_exeext
2763if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2764 (eval $ac_link) 2>&5
2765 ac_status=$?
2766 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2767 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
2768 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2769 (eval $ac_try) 2>&5
2770 ac_status=$?
2771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2772 (exit $ac_status); }; }; then
2773 :
2774else
2775 echo "$as_me: program exited with status $ac_status" >&5
2776echo "$as_me: failed program was:" >&5
2777cat conftest.$ac_ext >&5
2778( exit $ac_status )
2779ac_cv_header_stdc=no
2780fi
2781rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
2782fi
2783fi
2784fi
2785echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
2786echo "${ECHO_T}$ac_cv_header_stdc" >&6
2787if test $ac_cv_header_stdc = yes; then
2788
2789cat >>confdefs.h <<\_ACEOF
2790#define STDC_HEADERS 1
2791_ACEOF
2792
2793fi
2794
2795# On IRIX 5.3, sys/types and inttypes.h are conflicting.
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
2806 inttypes.h stdint.h unistd.h
2807do
2808as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
2809echo "$as_me:$LINENO: checking for $ac_header" >&5
2810echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
2811if eval "test \"\${$as_ac_Header+set}\" = set"; then
2812 echo $ECHO_N "(cached) $ECHO_C" >&6
2813else
2814 cat >conftest.$ac_ext <<_ACEOF
2815#line $LINENO "configure"
2816#include "confdefs.h"
2817$ac_includes_default
2818
2819#include <$ac_header>
2820_ACEOF
2821rm -f conftest.$ac_objext
2822if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2823 (eval $ac_compile) 2>&5
2824 ac_status=$?
2825 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2826 (exit $ac_status); } &&
2827 { ac_try='test -s conftest.$ac_objext'
2828 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2829 (eval $ac_try) 2>&5
2830 ac_status=$?
2831 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2832 (exit $ac_status); }; }; then
2833 eval "$as_ac_Header=yes"
2834else
2835 echo "$as_me: failed program was:" >&5
2836cat conftest.$ac_ext >&5
2837eval "$as_ac_Header=no"
2838fi
2839rm -f conftest.$ac_objext conftest.$ac_ext
2840fi
2841echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
2842echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
2843if test `eval echo '${'$as_ac_Header'}'` = yes; then
2844 cat >>confdefs.h <<_ACEOF
2845#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
2846_ACEOF
2847
2848fi
2849
2850done
2851
2852
2853if test "${ac_cv_header_minix_config_h+set}" = set; then
2854 echo "$as_me:$LINENO: checking for minix/config.h" >&5
2855echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2856if test "${ac_cv_header_minix_config_h+set}" = set; then
2857 echo $ECHO_N "(cached) $ECHO_C" >&6
2858fi
2859echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
2860echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2861else
2862 # Is the header compilable?
2863echo "$as_me:$LINENO: checking minix/config.h usability" >&5
2864echo $ECHO_N "checking minix/config.h usability... $ECHO_C" >&6
2865cat >conftest.$ac_ext <<_ACEOF
2866#line $LINENO "configure"
2867#include "confdefs.h"
2868$ac_includes_default
2869#include <minix/config.h>
2870_ACEOF
2871rm -f conftest.$ac_objext
2872if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2873 (eval $ac_compile) 2>&5
2874 ac_status=$?
2875 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2876 (exit $ac_status); } &&
2877 { ac_try='test -s conftest.$ac_objext'
2878 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2879 (eval $ac_try) 2>&5
2880 ac_status=$?
2881 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2882 (exit $ac_status); }; }; then
2883 ac_header_compiler=yes
2884else
2885 echo "$as_me: failed program was:" >&5
2886cat conftest.$ac_ext >&5
2887ac_header_compiler=no
2888fi
2889rm -f conftest.$ac_objext conftest.$ac_ext
2890echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
2891echo "${ECHO_T}$ac_header_compiler" >&6
2892
2893# Is the header present?
2894echo "$as_me:$LINENO: checking minix/config.h presence" >&5
2895echo $ECHO_N "checking minix/config.h presence... $ECHO_C" >&6
2896cat >conftest.$ac_ext <<_ACEOF
2897#line $LINENO "configure"
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002898#include "confdefs.h"
2899#include <minix/config.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00002900_ACEOF
2901if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2902 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2903 ac_status=$?
2904 egrep -v '^ *\+' conftest.er1 >conftest.err
2905 rm -f conftest.er1
2906 cat conftest.err >&5
2907 echo "$as_me:$LINENO: \$? = $ac_status" >&5
2908 (exit $ac_status); } >/dev/null; then
2909 if test -s conftest.err; then
2910 ac_cpp_err=$ac_c_preproc_warn_flag
2911 else
2912 ac_cpp_err=
2913 fi
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002914else
Martin v. Löwis11437992002-04-12 09:54:03 +00002915 ac_cpp_err=yes
2916fi
2917if test -z "$ac_cpp_err"; then
2918 ac_header_preproc=yes
2919else
2920 echo "$as_me: failed program was:" >&5
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002921 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002922 ac_header_preproc=no
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002923fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002924rm -f conftest.err conftest.$ac_ext
2925echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
2926echo "${ECHO_T}$ac_header_preproc" >&6
2927
2928# So? What about this header?
2929case $ac_header_compiler:$ac_header_preproc in
2930 yes:no )
2931 { echo "$as_me:$LINENO: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5
2932echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
2933 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
2934echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;};;
2935 no:yes )
2936 { echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5
2937echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;}
2938 { echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5
2939echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;}
2940 { echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5
2941echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;};;
2942esac
2943echo "$as_me:$LINENO: checking for minix/config.h" >&5
2944echo $ECHO_N "checking for minix/config.h... $ECHO_C" >&6
2945if test "${ac_cv_header_minix_config_h+set}" = set; then
2946 echo $ECHO_N "(cached) $ECHO_C" >&6
2947else
2948 ac_cv_header_minix_config_h=$ac_header_preproc
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002949fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002950echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5
2951echo "${ECHO_T}$ac_cv_header_minix_config_h" >&6
2952
2953fi
2954if test $ac_cv_header_minix_config_h = yes; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002955 MINIX=yes
2956else
Martin v. Löwis11437992002-04-12 09:54:03 +00002957 MINIX=
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002958fi
2959
Martin v. Löwis11437992002-04-12 09:54:03 +00002960
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002961if test "$MINIX" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002962
2963cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002964#define _POSIX_SOURCE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002965_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002966
Martin v. Löwis11437992002-04-12 09:54:03 +00002967
2968cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002969#define _POSIX_1_SOURCE 2
Martin v. Löwis11437992002-04-12 09:54:03 +00002970_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002971
Martin v. Löwis11437992002-04-12 09:54:03 +00002972
2973cat >>confdefs.h <<\_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002974#define _MINIX 1
Martin v. Löwis11437992002-04-12 09:54:03 +00002975_ACEOF
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00002976
2977fi
2978
2979
Michael W. Hudson54241132001-12-07 15:38:26 +00002980
Martin v. Löwis11437992002-04-12 09:54:03 +00002981echo "$as_me:$LINENO: checking for --with-suffix" >&5
2982echo $ECHO_N "checking for --with-suffix... $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002983
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00002984# Check whether --with-suffix or --without-suffix was given.
2985if test "${with_suffix+set}" = set; then
2986 withval="$with_suffix"
Martin v. Löwis11437992002-04-12 09:54:03 +00002987
Neil Schemenauerdfb38e42001-01-27 06:57:08 +00002988 case $withval in
2989 no) EXEEXT=;;
2990 yes) EXEEXT=.exe;;
2991 *) EXEEXT=$withval;;
2992 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00002993fi;
2994echo "$as_me:$LINENO: result: $EXEEXT" >&5
2995echo "${ECHO_T}$EXEEXT" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00002996
Jack Jansen9a66b6d2001-08-08 13:56:14 +00002997# Test whether we're running on a non-case-sensitive system, in which
2998# case we give a warning if no ext is given
Jack Jansen1999ef42001-12-06 21:47:20 +00002999
Martin v. Löwis11437992002-04-12 09:54:03 +00003000echo "$as_me:$LINENO: checking for case-insensitive build directory" >&5
3001echo $ECHO_N "checking for case-insensitive build directory... $ECHO_C" >&6
Jack Jansen3c2c4332002-11-06 13:33:32 +00003002if test ! -d CaseSensitiveTestDir; then
3003mkdir CaseSensitiveTestDir
3004fi
3005
3006if test -d casesensitivetestdir
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003007then
Martin v. Löwis11437992002-04-12 09:54:03 +00003008 echo "$as_me:$LINENO: result: yes" >&5
3009echo "${ECHO_T}yes" >&6
Jack Jansen1999ef42001-12-06 21:47:20 +00003010 BUILDEXEEXT=.exe
3011else
Martin v. Löwis11437992002-04-12 09:54:03 +00003012 echo "$as_me:$LINENO: result: no" >&5
3013echo "${ECHO_T}no" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00003014 BUILDEXEEXT=$EXEEXT
Jack Jansen9a66b6d2001-08-08 13:56:14 +00003015fi
Jack Jansen3c2c4332002-11-06 13:33:32 +00003016rmdir CaseSensitiveTestDir
Guido van Rossumff555e32000-09-22 15:38:21 +00003017
Guido van Rossumdd997f71998-10-07 19:58:26 +00003018case $MACHDEP in
3019bsdos*)
3020 case $CC in
3021 gcc) CC="$CC -D_HAVE_BSDI";;
3022 esac;;
3023esac
3024
Guido van Rossum24b1e751997-08-21 02:29:16 +00003025case $ac_sys_system in
3026hp*|HP*)
3027 case $CC in
Guido van Rossumcd5ff9f2000-09-22 16:15:54 +00003028 cc|*/cc) CC="$CC -Ae";;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003029 esac;;
Trent Mick635f6fb2000-08-23 21:33:05 +00003030Monterey*)
3031 case $CC in
3032 cc) CC="$CC -Wl,-Bexport";;
3033 esac;;
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003034SunOS*)
3035 # Some functions have a prototype only with that define, e.g. confstr
Martin v. Löwis11437992002-04-12 09:54:03 +00003036
3037cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003038#define __EXTENSIONS__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003039_ACEOF
Martin v. Löwisa30c1002001-03-06 12:10:20 +00003040
3041 ;;
Guido van Rossum24b1e751997-08-21 02:29:16 +00003042esac
3043
Michael W. Hudson54241132001-12-07 15:38:26 +00003044
3045
Martin v. Löwis11437992002-04-12 09:54:03 +00003046echo "$as_me:$LINENO: checking LIBRARY" >&5
3047echo $ECHO_N "checking LIBRARY... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003048if test -z "$LIBRARY"
3049then
3050 LIBRARY='libpython$(VERSION).a'
3051fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003052echo "$as_me:$LINENO: result: $LIBRARY" >&5
3053echo "${ECHO_T}$LIBRARY" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003054
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003055# LDLIBRARY is the name of the library to link against (as opposed to the
Jack Jansene578a632001-08-15 01:27:14 +00003056# name of the library into which to insert object files). BLDLIBRARY is also
3057# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
3058# is blank as the main program is not linked directly against LDLIBRARY.
3059# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
3060# systems without shared libraries, LDLIBRARY is the same as LIBRARY
3061# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
3062# DLLLIBRARY is the shared (i.e., DLL) library.
Martin v. Löwis11437992002-04-12 09:54:03 +00003063#
Martin v. Löwis1142de32002-03-29 16:28:31 +00003064# RUNSHARED is used to run shared python without installed libraries
3065#
3066# INSTSONAME is the name of the shared library that will be use to install
3067# on the system - some systems like version suffix, others don't
3068
3069
Michael W. Hudson54241132001-12-07 15:38:26 +00003070
3071
3072
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003073
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00003074LDLIBRARY="$LIBRARY"
Jack Jansene578a632001-08-15 01:27:14 +00003075BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis09bdf722002-05-08 08:51:29 +00003076INSTSONAME='$(LDLIBRARY)'
Guido van Rossumca563f22001-01-23 01:52:44 +00003077DLLLIBRARY=''
Jack Jansene578a632001-08-15 01:27:14 +00003078LDLIBRARYDIR=''
Martin v. Löwis1142de32002-03-29 16:28:31 +00003079RUNSHARED=''
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003080
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003081# LINKCC is the command that links the python executable -- default is $(CC).
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003082# If CXX is set, and if it is needed to link a main function that was
3083# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
3084# python might then depend on the C++ runtime
Martin v. Löwis11437992002-04-12 09:54:03 +00003085# This is altered for AIX in order to build the export list before
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003086# linking.
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003087
Martin v. Löwis11437992002-04-12 09:54:03 +00003088echo "$as_me:$LINENO: checking LINKCC" >&5
3089echo $ECHO_N "checking LINKCC... $ECHO_C" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003090if test -z "$LINKCC"
3091then
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003092 if test -z "$CXX"; then
3093 LINKCC="\$(PURIFY) \$(CC)"
3094 else
Martin v. Löwis1931ca72002-06-01 21:39:58 +00003095 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
Martin v. Löwisb7da67a2001-10-18 15:35:38 +00003096 $CXX -c conftest.$ac_ext 2>&5
3097 if $CC -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
3098 && test -s conftest$ac_exeext && ./conftest$ac_exeext
3099 then
3100 LINKCC="\$(PURIFY) \$(CC)"
3101 else
3102 LINKCC="\$(PURIFY) \$(CXX)"
3103 fi
3104 rm -fr conftest*
3105 fi
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003106 case $ac_sys_system in
3107 AIX*)
Jack Jansen524a0982002-03-12 15:25:52 +00003108 LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp \"\" \$(LIBRARY); $LINKCC";;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00003109 dgux*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003110 LINKCC="LD_RUN_PATH=$libdir $LINKCC";;
Trent Mick635f6fb2000-08-23 21:33:05 +00003111 Monterey64*)
Martin v. Löwis4e732dc2002-03-19 15:15:32 +00003112 LINKCC="$LINKCC -L/usr/lib/ia64l64";;
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003113 esac
3114fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003115echo "$as_me:$LINENO: result: $LINKCC" >&5
3116echo "${ECHO_T}$LINKCC" >&6
Guido van Rossum76c5fe21997-08-14 19:45:07 +00003117
Martin v. Löwis11437992002-04-12 09:54:03 +00003118echo "$as_me:$LINENO: checking for --enable-shared" >&5
3119echo $ECHO_N "checking for --enable-shared... $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003120# Check whether --enable-shared or --disable-shared was given.
3121if test "${enable_shared+set}" = set; then
3122 enableval="$enable_shared"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003123
Martin v. Löwis11437992002-04-12 09:54:03 +00003124fi;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003125
3126if test -z "$enable_shared"
Martin v. Löwis11437992002-04-12 09:54:03 +00003127then
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003128 case $ac_sys_system in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003129 CYGWIN* | atheos*)
Martin v. Löwisb51033d2002-05-03 05:53:15 +00003130 enable_shared="yes";;
3131 *)
3132 enable_shared="no";;
3133 esac
Martin v. Löwis1142de32002-03-29 16:28:31 +00003134fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003135echo "$as_me:$LINENO: result: $enable_shared" >&5
3136echo "${ECHO_T}$enable_shared" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +00003137
3138
Martin v. Löwis11437992002-04-12 09:54:03 +00003139echo "$as_me:$LINENO: checking LDLIBRARY" >&5
3140echo $ECHO_N "checking LDLIBRARY... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00003141
Guido van Rossumb8552162001-09-05 14:58:11 +00003142# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
3143# library that we build, but we do not want to link against it (we
3144# will find it with a -framework option). For this reason there is an
3145# extra variable BLDLIBRARY against which Python and the extension
3146# modules are linked, BLDLIBRARY. This is normally the same as
3147# LDLIBRARY, but empty for MacOSX framework builds.
Jack Jansene578a632001-08-15 01:27:14 +00003148if test "$enable_framework"
3149then
3150 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
3151 LDLIBRARYDIR='$(PYTHONFRAMEWORKDIR)'
3152 BLDLIBRARY=''
3153else
3154 BLDLIBRARY='$(LDLIBRARY)'
Martin v. Löwis11437992002-04-12 09:54:03 +00003155fi
Jack Jansene578a632001-08-15 01:27:14 +00003156
Martin v. Löwis1142de32002-03-29 16:28:31 +00003157# Other platforms follow
3158if test $enable_shared = "yes"; then
Mark Hammond8235ea12002-07-19 06:55:41 +00003159
3160cat >>confdefs.h <<\_ACEOF
3161#define Py_ENABLE_SHARED 1
3162_ACEOF
3163
Martin v. Löwis1142de32002-03-29 16:28:31 +00003164 case $ac_sys_system in
3165 BeOS*)
3166 LDLIBRARY='libpython$(VERSION).so'
3167 ;;
3168 CYGWIN*)
3169 LDLIBRARY='libpython$(VERSION).dll.a'
3170 DLLLIBRARY='libpython$(VERSION).dll'
3171 ;;
3172 SunOS*)
3173 LDLIBRARY='libpython$(VERSION).so'
3174 BLDLIBRARY='-Wl,-rpath,$(LIBDIR) -L. -lpython$(VERSION)'
3175 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3176 ;;
Martin v. Löwis1bc894b2002-07-30 20:19:58 +00003177 Linux*|GNU*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00003178 LDLIBRARY='libpython$(VERSION).so'
3179 BLDLIBRARY='-L. -lpython$(VERSION)'
3180 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3181 INSTSONAME="$LDLIBRARY".$SOVERSION
3182 ;;
3183 hp*|HP*)
3184 LDLIBRARY='libpython$(VERSION).sl'
3185 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
3186 RUNSHARED=SHLIB_PATH=`pwd`:$SHLIB_PATH
3187 ;;
3188 OSF*)
3189 LDLIBRARY='libpython$(VERSION).so'
3190 BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
3191 RUNSHARED=LD_LIBRARY_PATH=`pwd`:$LD_LIBRARY_PATH
3192 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003193 atheos*)
3194 LDLIBRARY='libpython$(VERSION).so'
3195 BLDLIBRARY='-L. -lpython$(VERSION)'
3196 RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
3197 ;;
Martin v. Löwis1142de32002-03-29 16:28:31 +00003198 esac
3199 # DG/UX requires some fancy ld contortions to produce a .so from an .a
3200 case $MACHDEP in
3201 dguxR4)
3202 LDLIBRARY='libpython$(VERSION).so'
3203 OPT="$OPT -pic"
3204 ;;
3205 esac
3206fi
3207
Martin v. Löwis11437992002-04-12 09:54:03 +00003208echo "$as_me:$LINENO: result: $LDLIBRARY" >&5
3209echo "${ECHO_T}$LDLIBRARY" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00003210
Martin v. Löwis11437992002-04-12 09:54:03 +00003211if test -n "$ac_tool_prefix"; then
3212 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3213set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3214echo "$as_me:$LINENO: checking for $ac_word" >&5
3215echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3216if test "${ac_cv_prog_RANLIB+set}" = set; then
3217 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003218else
3219 if test -n "$RANLIB"; then
3220 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3221else
Martin v. Löwis11437992002-04-12 09:54:03 +00003222as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3223for as_dir in $PATH
3224do
3225 IFS=$as_save_IFS
3226 test -z "$as_dir" && as_dir=.
3227 for ac_exec_ext in '' $ac_executable_extensions; do
3228 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3229 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3230 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3231 break 2
3232 fi
3233done
3234done
3235
Guido van Rossum627b2d71993-12-24 10:39:16 +00003236fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003237fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003238RANLIB=$ac_cv_prog_RANLIB
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003239if test -n "$RANLIB"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003240 echo "$as_me:$LINENO: result: $RANLIB" >&5
3241echo "${ECHO_T}$RANLIB" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003242else
Martin v. Löwis11437992002-04-12 09:54:03 +00003243 echo "$as_me:$LINENO: result: no" >&5
3244echo "${ECHO_T}no" >&6
3245fi
3246
3247fi
3248if test -z "$ac_cv_prog_RANLIB"; then
3249 ac_ct_RANLIB=$RANLIB
3250 # Extract the first word of "ranlib", so it can be a program name with args.
3251set dummy ranlib; ac_word=$2
3252echo "$as_me:$LINENO: checking for $ac_word" >&5
3253echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3254if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
3255 echo $ECHO_N "(cached) $ECHO_C" >&6
3256else
3257 if test -n "$ac_ct_RANLIB"; then
3258 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
3259else
3260as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3261for as_dir in $PATH
3262do
3263 IFS=$as_save_IFS
3264 test -z "$as_dir" && as_dir=.
3265 for ac_exec_ext in '' $ac_executable_extensions; do
3266 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3267 ac_cv_prog_ac_ct_RANLIB="ranlib"
3268 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3269 break 2
3270 fi
3271done
3272done
3273
3274 test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
3275fi
3276fi
3277ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
3278if test -n "$ac_ct_RANLIB"; then
3279 echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
3280echo "${ECHO_T}$ac_ct_RANLIB" >&6
3281else
3282 echo "$as_me:$LINENO: result: no" >&5
3283echo "${ECHO_T}no" >&6
3284fi
3285
3286 RANLIB=$ac_ct_RANLIB
3287else
3288 RANLIB="$ac_cv_prog_RANLIB"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003289fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003290
3291
Guido van Rossum7f43da71994-08-01 12:15:30 +00003292for ac_prog in ar aal
3293do
Martin v. Löwis11437992002-04-12 09:54:03 +00003294 # Extract the first word of "$ac_prog", so it can be a program name with args.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003295set dummy $ac_prog; ac_word=$2
Martin v. Löwis11437992002-04-12 09:54:03 +00003296echo "$as_me:$LINENO: checking for $ac_word" >&5
3297echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3298if test "${ac_cv_prog_AR+set}" = set; then
3299 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003300else
3301 if test -n "$AR"; then
3302 ac_cv_prog_AR="$AR" # Let the user override the test.
3303else
Martin v. Löwis11437992002-04-12 09:54:03 +00003304as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3305for as_dir in $PATH
3306do
3307 IFS=$as_save_IFS
3308 test -z "$as_dir" && as_dir=.
3309 for ac_exec_ext in '' $ac_executable_extensions; do
3310 if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3311 ac_cv_prog_AR="$ac_prog"
3312 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3313 break 2
3314 fi
3315done
3316done
3317
Guido van Rossum7f43da71994-08-01 12:15:30 +00003318fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003319fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003320AR=$ac_cv_prog_AR
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003321if test -n "$AR"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003322 echo "$as_me:$LINENO: result: $AR" >&5
3323echo "${ECHO_T}$AR" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003324else
Martin v. Löwis11437992002-04-12 09:54:03 +00003325 echo "$as_me:$LINENO: result: no" >&5
3326echo "${ECHO_T}no" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003327fi
Guido van Rossum7f43da71994-08-01 12:15:30 +00003328
Martin v. Löwis11437992002-04-12 09:54:03 +00003329 test -n "$AR" && break
Guido van Rossum7f43da71994-08-01 12:15:30 +00003330done
3331test -n "$AR" || AR="ar"
3332
Michael W. Hudson54241132001-12-07 15:38:26 +00003333
Neil Schemenauera42c8272001-03-31 00:01:55 +00003334case $MACHDEP in
Neil Schemenaueraf5567f2001-10-21 22:32:04 +00003335bsdos*|hp*|HP*)
3336 # install -d does not work on BSDI or HP-UX
Neil Schemenauera42c8272001-03-31 00:01:55 +00003337 if test -z "$INSTALL"
3338 then
3339 INSTALL="${srcdir}/install-sh -c"
3340 fi
3341esac
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003342ac_aux_dir=
3343for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
3344 if test -f $ac_dir/install-sh; then
3345 ac_aux_dir=$ac_dir
3346 ac_install_sh="$ac_aux_dir/install-sh -c"
3347 break
3348 elif test -f $ac_dir/install.sh; then
3349 ac_aux_dir=$ac_dir
3350 ac_install_sh="$ac_aux_dir/install.sh -c"
3351 break
Martin v. Löwis11437992002-04-12 09:54:03 +00003352 elif test -f $ac_dir/shtool; then
3353 ac_aux_dir=$ac_dir
3354 ac_install_sh="$ac_aux_dir/shtool install -c"
3355 break
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003356 fi
3357done
3358if test -z "$ac_aux_dir"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003359 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
3360echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
3361 { (exit 1); exit 1; }; }
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003362fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003363ac_config_guess="$SHELL $ac_aux_dir/config.guess"
3364ac_config_sub="$SHELL $ac_aux_dir/config.sub"
3365ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003366
3367# Find a good install program. We prefer a C program (faster),
3368# so one script is as good as another. But avoid the broken or
3369# incompatible versions:
3370# SysV /etc/install, /usr/sbin/install
3371# SunOS /usr/etc/install
3372# IRIX /sbin/install
3373# AIX /bin/install
Martin v. Löwis11437992002-04-12 09:54:03 +00003374# AmigaOS /C/install, which installs bootblocks on floppy discs
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003375# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3376# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3377# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3378# ./install, which can be erroneously created by make from ./install.sh.
Martin v. Löwis11437992002-04-12 09:54:03 +00003379echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3380echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003381if test -z "$INSTALL"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003382if test "${ac_cv_path_install+set}" = set; then
3383 echo $ECHO_N "(cached) $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003384else
Martin v. Löwis11437992002-04-12 09:54:03 +00003385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3386for as_dir in $PATH
3387do
3388 IFS=$as_save_IFS
3389 test -z "$as_dir" && as_dir=.
3390 # Account for people who put trailing slashes in PATH elements.
3391case $as_dir/ in
3392 ./ | .// | /cC/* | \
3393 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3394 /usr/ucb/* ) ;;
3395 *)
3396 # OSF1 and SCO ODT 3.0 have their own names for install.
3397 # Don't use installbsd from OSF since it installs stuff as root
3398 # by default.
3399 for ac_prog in ginstall scoinst install; do
3400 for ac_exec_ext in '' $ac_executable_extensions; do
3401 if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3402 if test $ac_prog = install &&
3403 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3404 # AIX install. It has an incompatible calling convention.
3405 :
3406 elif test $ac_prog = install &&
3407 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3408 # program-specific install script used by HP pwplus--don't use.
3409 :
3410 else
3411 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3412 break 3
3413 fi
3414 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003415 done
Martin v. Löwis11437992002-04-12 09:54:03 +00003416 done
3417 ;;
3418esac
3419done
3420
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003421
3422fi
3423 if test "${ac_cv_path_install+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003424 INSTALL=$ac_cv_path_install
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003425 else
3426 # As a last resort, use the slow shell script. We don't cache a
3427 # path for INSTALL within a source directory, because that will
3428 # break other packages using the cache if that directory is
3429 # removed, or if the path is relative.
Martin v. Löwis11437992002-04-12 09:54:03 +00003430 INSTALL=$ac_install_sh
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003431 fi
3432fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003433echo "$as_me:$LINENO: result: $INSTALL" >&5
3434echo "${ECHO_T}$INSTALL" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003435
3436# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3437# It thinks the first close brace ends the variable substitution.
3438test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3439
Martin v. Löwis11437992002-04-12 09:54:03 +00003440test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003441
3442test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3443
Michael W. Hudson54241132001-12-07 15:38:26 +00003444
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003445# Not every filesystem supports hard links
3446
3447if test -z "$LN" ; then
3448 case $ac_sys_system in
3449 BeOS*) LN="ln -s";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00003450 CYGWIN*) LN="ln -s";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00003451 atheos*) LN="ln -s";;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00003452 *) LN=ln;;
3453 esac
3454fi
3455
Fred Drake109d9862001-07-11 06:27:56 +00003456# Check for --with-pydebug
Martin v. Löwis11437992002-04-12 09:54:03 +00003457echo "$as_me:$LINENO: checking for --with-pydebug" >&5
3458echo $ECHO_N "checking for --with-pydebug... $ECHO_C" >&6
3459
Fred Drake109d9862001-07-11 06:27:56 +00003460# Check whether --with-pydebug or --without-pydebug was given.
3461if test "${with_pydebug+set}" = set; then
3462 withval="$with_pydebug"
Martin v. Löwis11437992002-04-12 09:54:03 +00003463
Fred Drake109d9862001-07-11 06:27:56 +00003464if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +00003465then
3466
3467cat >>confdefs.h <<\_ACEOF
Fred Drake109d9862001-07-11 06:27:56 +00003468#define Py_DEBUG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003469_ACEOF
3470
3471 echo "$as_me:$LINENO: result: yes" >&5
3472echo "${ECHO_T}yes" >&6;
Martin v. Löwisc45929e2002-04-06 10:10:49 +00003473 Py_DEBUG='true'
Martin v. Löwis11437992002-04-12 09:54:03 +00003474else echo "$as_me:$LINENO: result: no" >&5
3475echo "${ECHO_T}no" >&6; Py_DEBUG='false'
Fred Drake109d9862001-07-11 06:27:56 +00003476fi
3477else
Martin v. Löwis11437992002-04-12 09:54:03 +00003478 echo "$as_me:$LINENO: result: no" >&5
3479echo "${ECHO_T}no" >&6
3480fi;
Fred Drake109d9862001-07-11 06:27:56 +00003481
Neil Schemenauerd32c2492001-01-24 17:25:28 +00003482# Optimizer/debugger flags
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003483
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003484if test -z "$OPT"
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003485then
Neal Norwitzd957f392002-09-25 21:26:19 +00003486 case $GCC in
Guido van Rossumedca74a1997-07-18 23:29:40 +00003487 yes)
3488 case $ac_cv_prog_cc_g in
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003489 yes)
Fred Drake109d9862001-07-11 06:27:56 +00003490 if test "$Py_DEBUG" = 'true' ; then
3491 # Optimization messes up debuggers, so turn it off for
3492 # debug builds.
3493 OPT="-g -Wall -Wstrict-prototypes"
3494 else
3495 OPT="-g -O3 -Wall -Wstrict-prototypes"
3496 fi;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003497 *)
Fred Drake109d9862001-07-11 06:27:56 +00003498 OPT="-O3 -Wall -Wstrict-prototypes";;
3499 esac
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003500 case $ac_sys_system in
3501 SCO_SV*) OPT="$OPT -m486 -DSCO5";;
3502 esac
Fred Drake109d9862001-07-11 06:27:56 +00003503 ;;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003504 *)
3505 case $ac_sys_system in
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00003506 OpenUNIX*|UnixWare*)
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003507 OPT="-O -K pentium,host,inline,loop_unroll,alloca ";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00003508 SCO_SV*)
3509 CFLAGS="$CFLAGS -belf"
3510 OPT="-belf -O -Ki486 -DSCO5";;
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003511 *)
3512 OPT="-O";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00003513 esac
Guido van Rossum2242f2f2001-04-11 20:58:20 +00003514 esac
Jack Jansenca06bc62001-08-03 15:32:23 +00003515 case $ac_sys_system in
3516 Darwin*)
Jack Jansen524a0982002-03-12 15:25:52 +00003517 OPT="$OPT -Wno-long-double -no-cpp-precomp";;
Jack Jansenca06bc62001-08-03 15:32:23 +00003518 esac
Guido van Rossumb1ba03f1994-08-19 15:34:50 +00003519fi
3520
Fred Drakee1ceaa02001-12-04 20:55:47 +00003521if test "$Py_DEBUG" = 'true'; then
3522 :
3523else
3524 OPT="-DNDEBUG $OPT"
3525fi
3526
Trent Mick635f6fb2000-08-23 21:33:05 +00003527# The current (beta) Monterey compiler dies with optimizations
3528case $ac_sys_system in
3529Monterey*) OPT="";;
3530esac
3531
Guido van Rossum563e7081996-09-10 18:20:48 +00003532if test "$ac_arch_flags"
Guido van Rossuma68acba1996-07-31 17:36:39 +00003533then
3534 OPT="$OPT $ac_arch_flags"
3535fi
Guido van Rossumda88dad1995-01-26 00:46:29 +00003536
Martin v. Löwis11437992002-04-12 09:54:03 +00003537echo "$as_me:$LINENO: checking whether $CC accepts -OPT:Olimit=0" >&5
3538echo $ECHO_N "checking whether $CC accepts -OPT:Olimit=0... $ECHO_C" >&6
3539if test "${ac_cv_opt_olimit_ok+set}" = set; then
3540 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum91922671997-10-09 20:24:13 +00003541else
3542 ac_save_cc="$CC"
3543CC="$CC -OPT:Olimit=0"
3544if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00003545 ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00003546else
Martin v. Löwis11437992002-04-12 09:54:03 +00003547 cat >conftest.$ac_ext <<_ACEOF
3548#line $LINENO "configure"
Guido van Rossum91922671997-10-09 20:24:13 +00003549#include "confdefs.h"
3550int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003551_ACEOF
3552rm -f conftest$ac_exeext
3553if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3554 (eval $ac_link) 2>&5
3555 ac_status=$?
3556 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3557 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3558 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3559 (eval $ac_try) 2>&5
3560 ac_status=$?
3561 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3562 (exit $ac_status); }; }; then
Guido van Rossum91922671997-10-09 20:24:13 +00003563 ac_cv_opt_olimit_ok=yes
3564else
Martin v. Löwis11437992002-04-12 09:54:03 +00003565 echo "$as_me: program exited with status $ac_status" >&5
3566echo "$as_me: failed program was:" >&5
3567cat conftest.$ac_ext >&5
3568( exit $ac_status )
3569ac_cv_opt_olimit_ok=no
Guido van Rossum91922671997-10-09 20:24:13 +00003570fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003571rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum91922671997-10-09 20:24:13 +00003572fi
Guido van Rossum91922671997-10-09 20:24:13 +00003573CC="$ac_save_cc"
3574fi
3575
Martin v. Löwis11437992002-04-12 09:54:03 +00003576echo "$as_me:$LINENO: result: $ac_cv_opt_olimit_ok" >&5
3577echo "${ECHO_T}$ac_cv_opt_olimit_ok" >&6
Guido van Rossum2efa34b1997-10-23 17:43:11 +00003578if test $ac_cv_opt_olimit_ok = yes; then
Guido van Rossum5839e582000-10-09 19:52:35 +00003579 case $ac_sys_system in
3580 Darwin*) OPT="$OPT" ;;
3581 *) OPT="$OPT -OPT:Olimit=0";;
3582 esac
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003583else
Martin v. Löwis11437992002-04-12 09:54:03 +00003584 echo "$as_me:$LINENO: checking whether $CC accepts -Olimit 1500" >&5
3585echo $ECHO_N "checking whether $CC accepts -Olimit 1500... $ECHO_C" >&6
3586 if test "${ac_cv_olimit_ok+set}" = set; then
3587 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003588else
3589 ac_save_cc="$CC"
3590 CC="$CC -Olimit 1500"
3591 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00003592 ac_cv_olimit_ok=no
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003593else
Martin v. Löwis11437992002-04-12 09:54:03 +00003594 cat >conftest.$ac_ext <<_ACEOF
3595#line $LINENO "configure"
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003596#include "confdefs.h"
3597int main() { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003598_ACEOF
3599rm -f conftest$ac_exeext
3600if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3601 (eval $ac_link) 2>&5
3602 ac_status=$?
3603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3604 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3605 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3606 (eval $ac_try) 2>&5
3607 ac_status=$?
3608 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3609 (exit $ac_status); }; }; then
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003610 ac_cv_olimit_ok=yes
3611else
Martin v. Löwis11437992002-04-12 09:54:03 +00003612 echo "$as_me: program exited with status $ac_status" >&5
3613echo "$as_me: failed program was:" >&5
3614cat conftest.$ac_ext >&5
3615( exit $ac_status )
3616ac_cv_olimit_ok=no
Guido van Rossum201afe51997-05-14 21:14:44 +00003617fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003618rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003619fi
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003620 CC="$ac_save_cc"
3621fi
3622
Martin v. Löwis11437992002-04-12 09:54:03 +00003623 echo "$as_me:$LINENO: result: $ac_cv_olimit_ok" >&5
3624echo "${ECHO_T}$ac_cv_olimit_ok" >&6
Guido van Rossum6b3d77e1998-07-07 21:11:02 +00003625 if test $ac_cv_olimit_ok = yes; then
3626 OPT="$OPT -Olimit 1500"
3627 fi
3628fi
3629
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003630# On some compilers, pthreads are available without further options
3631# (e.g. MacOS X). On some of these systems, the compiler will not
3632# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
3633# So we have to see first whether pthreads are available without
3634# options before we can check whether -Kpthread improves anything.
Martin v. Löwis11437992002-04-12 09:54:03 +00003635echo "$as_me:$LINENO: checking whether pthreads are available without options" >&5
3636echo $ECHO_N "checking whether pthreads are available without options... $ECHO_C" >&6
3637if test "${ac_cv_pthread_is_default+set}" = set; then
3638 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis130fb172001-07-19 11:00:41 +00003639else
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003640 if test "$cross_compiling" = yes; then
3641 ac_cv_pthread_is_default=no
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003642else
Martin v. Löwis11437992002-04-12 09:54:03 +00003643 cat >conftest.$ac_ext <<_ACEOF
3644#line $LINENO "configure"
Martin v. Löwis130fb172001-07-19 11:00:41 +00003645#include "confdefs.h"
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003646
Martin v. Löwis130fb172001-07-19 11:00:41 +00003647#include <pthread.h>
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003648
3649void* routine(void* p){return NULL;}
3650
3651int main(){
3652 pthread_t p;
3653 if(pthread_create(&p,NULL,routine,NULL)!=0)
3654 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00003655 (void)pthread_detach(p);
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003656 return 0;
3657}
3658
Martin v. Löwis11437992002-04-12 09:54:03 +00003659_ACEOF
3660rm -f conftest$ac_exeext
3661if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3662 (eval $ac_link) 2>&5
3663 ac_status=$?
3664 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3665 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3666 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3667 (eval $ac_try) 2>&5
3668 ac_status=$?
3669 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3670 (exit $ac_status); }; }; then
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003671 ac_cv_pthread_is_default=yes
3672else
Martin v. Löwis11437992002-04-12 09:54:03 +00003673 echo "$as_me: program exited with status $ac_status" >&5
3674echo "$as_me: failed program was:" >&5
3675cat conftest.$ac_ext >&5
3676( exit $ac_status )
3677ac_cv_pthread_is_default=no
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003678fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003679rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003680fi
3681
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003682fi
3683
Martin v. Löwis11437992002-04-12 09:54:03 +00003684echo "$as_me:$LINENO: result: $ac_cv_pthread_is_default" >&5
3685echo "${ECHO_T}$ac_cv_pthread_is_default" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003686
Michael W. Hudson54241132001-12-07 15:38:26 +00003687
Martin v. Löwis11437992002-04-12 09:54:03 +00003688if test $ac_cv_pthread_is_default = yes
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003689then
3690 ac_cv_kpthread=no
3691else
3692# -Kpthread, if available, provides the right #defines
3693# and linker options to make pthread_create available
3694# Some compilers won't report that they do not support -Kpthread,
3695# so we need to run a program to see whether it really made the
3696# function available.
Martin v. Löwis11437992002-04-12 09:54:03 +00003697echo "$as_me:$LINENO: checking whether $CC accepts -Kpthread" >&5
3698echo $ECHO_N "checking whether $CC accepts -Kpthread... $ECHO_C" >&6
3699if test "${ac_cv_kpthread+set}" = set; then
3700 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003701else
3702 ac_save_cc="$CC"
3703CC="$CC -Kpthread"
3704if test "$cross_compiling" = yes; then
3705 ac_cv_kpthread=no
3706else
Martin v. Löwis11437992002-04-12 09:54:03 +00003707 cat >conftest.$ac_ext <<_ACEOF
3708#line $LINENO "configure"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003709#include "confdefs.h"
3710
3711#include <pthread.h>
3712
3713void* routine(void* p){return NULL;}
3714
3715int main(){
3716 pthread_t p;
3717 if(pthread_create(&p,NULL,routine,NULL)!=0)
3718 return 1;
Jack Jansen4f8d0542002-03-08 13:43:01 +00003719 (void)pthread_detach(p);
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003720 return 0;
3721}
3722
Martin v. Löwis11437992002-04-12 09:54:03 +00003723_ACEOF
3724rm -f conftest$ac_exeext
3725if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3726 (eval $ac_link) 2>&5
3727 ac_status=$?
3728 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3729 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3730 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3731 (eval $ac_try) 2>&5
3732 ac_status=$?
3733 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3734 (exit $ac_status); }; }; then
Martin v. Löwis130fb172001-07-19 11:00:41 +00003735 ac_cv_kpthread=yes
3736else
Martin v. Löwis11437992002-04-12 09:54:03 +00003737 echo "$as_me: program exited with status $ac_status" >&5
3738echo "$as_me: failed program was:" >&5
3739cat conftest.$ac_ext >&5
3740( exit $ac_status )
3741ac_cv_kpthread=no
Martin v. Löwis130fb172001-07-19 11:00:41 +00003742fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003743rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis260aecc2001-10-07 08:14:41 +00003744fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00003745CC="$ac_save_cc"
3746fi
3747
Martin v. Löwis11437992002-04-12 09:54:03 +00003748echo "$as_me:$LINENO: result: $ac_cv_kpthread" >&5
3749echo "${ECHO_T}$ac_cv_kpthread" >&6
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00003750fi
Martin v. Löwis130fb172001-07-19 11:00:41 +00003751
Michael W. Hudson54241132001-12-07 15:38:26 +00003752
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00003753# checks for header files
Martin v. Löwis11437992002-04-12 09:54:03 +00003754echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3755echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
3756if test "${ac_cv_header_stdc+set}" = set; then
3757 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003758else
Martin v. Löwis11437992002-04-12 09:54:03 +00003759 cat >conftest.$ac_ext <<_ACEOF
3760#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003761#include "confdefs.h"
3762#include <stdlib.h>
3763#include <stdarg.h>
3764#include <string.h>
3765#include <float.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003766
3767_ACEOF
3768if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3769 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3770 ac_status=$?
3771 egrep -v '^ *\+' conftest.er1 >conftest.err
3772 rm -f conftest.er1
3773 cat conftest.err >&5
3774 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3775 (exit $ac_status); } >/dev/null; then
3776 if test -s conftest.err; then
3777 ac_cpp_err=$ac_c_preproc_warn_flag
3778 else
3779 ac_cpp_err=
3780 fi
3781else
3782 ac_cpp_err=yes
3783fi
3784if test -z "$ac_cpp_err"; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003785 ac_cv_header_stdc=yes
3786else
Martin v. Löwis11437992002-04-12 09:54:03 +00003787 echo "$as_me: failed program was:" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +00003788 cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003789 ac_cv_header_stdc=no
3790fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003791rm -f conftest.err conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003792
3793if test $ac_cv_header_stdc = yes; then
3794 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00003795 cat >conftest.$ac_ext <<_ACEOF
3796#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003797#include "confdefs.h"
3798#include <string.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003799
3800_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003801if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3802 egrep "memchr" >/dev/null 2>&1; then
3803 :
3804else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003805 ac_cv_header_stdc=no
3806fi
3807rm -f conftest*
3808
3809fi
3810
3811if test $ac_cv_header_stdc = yes; then
3812 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
Martin v. Löwis11437992002-04-12 09:54:03 +00003813 cat >conftest.$ac_ext <<_ACEOF
3814#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003815#include "confdefs.h"
3816#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003817
3818_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003819if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3820 egrep "free" >/dev/null 2>&1; then
3821 :
3822else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003823 ac_cv_header_stdc=no
3824fi
3825rm -f conftest*
3826
3827fi
3828
3829if test $ac_cv_header_stdc = yes; then
3830 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
Martin v. Löwis11437992002-04-12 09:54:03 +00003831 if test "$cross_compiling" = yes; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00003832 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003833else
Martin v. Löwis11437992002-04-12 09:54:03 +00003834 cat >conftest.$ac_ext <<_ACEOF
3835#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003836#include "confdefs.h"
3837#include <ctype.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00003838#if ((' ' & 0x0FF) == 0x020)
3839# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3840# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3841#else
3842# define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
3843 || ('j' <= (c) && (c) <= 'r') \
3844 || ('s' <= (c) && (c) <= 'z'))
3845# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3846#endif
Michael W. Hudson54241132001-12-07 15:38:26 +00003847
Martin v. Löwis11437992002-04-12 09:54:03 +00003848#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3849int
3850main ()
3851{
3852 int i;
3853 for (i = 0; i < 256; i++)
3854 if (XOR (islower (i), ISLOWER (i))
3855 || toupper (i) != TOUPPER (i))
3856 exit(2);
3857 exit (0);
3858}
3859_ACEOF
3860rm -f conftest$ac_exeext
3861if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3862 (eval $ac_link) 2>&5
3863 ac_status=$?
3864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3865 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3866 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3867 (eval $ac_try) 2>&5
3868 ac_status=$?
3869 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3870 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003871 :
3872else
Martin v. Löwis11437992002-04-12 09:54:03 +00003873 echo "$as_me: program exited with status $ac_status" >&5
3874echo "$as_me: failed program was:" >&5
3875cat conftest.$ac_ext >&5
3876( exit $ac_status )
3877ac_cv_header_stdc=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00003878fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003879rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00003880fi
3881fi
Martin v. Löwis11437992002-04-12 09:54:03 +00003882fi
3883echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3884echo "${ECHO_T}$ac_cv_header_stdc" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00003885if test $ac_cv_header_stdc = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003886
3887cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003888#define STDC_HEADERS 1
Martin v. Löwis11437992002-04-12 09:54:03 +00003889_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00003890
3891fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00003892
Martin v. Löwis11437992002-04-12 09:54:03 +00003893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
Martin v. Löwis11437992002-04-12 09:54:03 +00003930for ac_header in dlfcn.h fcntl.h grp.h limits.h langinfo.h \
Martin v. Löwis2e64c342002-03-27 18:49:02 +00003931libintl.h locale.h ncurses.h poll.h pthread.h \
Eric S. Raymondd2d75d32001-01-16 15:26:34 +00003932signal.h stdarg.h stddef.h stdlib.h thread.h unistd.h utime.h termios.h \
Skip Montanaro57454e52002-06-14 20:30:31 +00003933sys/audioio.h sys/file.h sys/lock.h sys/mkdev.h sys/modem.h \
Andrew M. Kuchling881fd902001-07-14 20:55:52 +00003934sys/param.h sys/poll.h sys/select.h sys/socket.h sys/time.h sys/times.h \
Martin v. Löwisa5f09072002-10-11 05:37:59 +00003935sys/un.h sys/utsname.h sys/wait.h pty.h term.h libutil.h \
Skip Montanaro8345f712002-06-25 05:53:48 +00003936sys/resource.h netpacket/packet.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00003937do
Martin v. Löwis11437992002-04-12 09:54:03 +00003938as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3939if eval "test \"\${$as_ac_Header+set}\" = set"; then
3940 echo "$as_me:$LINENO: checking for $ac_header" >&5
3941echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
3942if eval "test \"\${$as_ac_Header+set}\" = set"; then
3943 echo $ECHO_N "(cached) $ECHO_C" >&6
3944fi
3945echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
3946echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003947else
Martin v. Löwis11437992002-04-12 09:54:03 +00003948 # Is the header compilable?
3949echo "$as_me:$LINENO: checking $ac_header usability" >&5
3950echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
3951cat >conftest.$ac_ext <<_ACEOF
3952#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00003953#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00003954$ac_includes_default
3955#include <$ac_header>
3956_ACEOF
3957rm -f conftest.$ac_objext
3958if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3959 (eval $ac_compile) 2>&5
3960 ac_status=$?
3961 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3962 (exit $ac_status); } &&
3963 { ac_try='test -s conftest.$ac_objext'
3964 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3965 (eval $ac_try) 2>&5
3966 ac_status=$?
3967 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3968 (exit $ac_status); }; }; then
3969 ac_header_compiler=yes
Michael W. Hudson54241132001-12-07 15:38:26 +00003970else
Martin v. Löwis11437992002-04-12 09:54:03 +00003971 echo "$as_me: failed program was:" >&5
3972cat conftest.$ac_ext >&5
3973ac_header_compiler=no
3974fi
3975rm -f conftest.$ac_objext conftest.$ac_ext
3976echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
3977echo "${ECHO_T}$ac_header_compiler" >&6
3978
3979# Is the header present?
3980echo "$as_me:$LINENO: checking $ac_header presence" >&5
3981echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
3982cat >conftest.$ac_ext <<_ACEOF
3983#line $LINENO "configure"
3984#include "confdefs.h"
3985#include <$ac_header>
3986_ACEOF
3987if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3988 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3989 ac_status=$?
3990 egrep -v '^ *\+' conftest.er1 >conftest.err
3991 rm -f conftest.er1
3992 cat conftest.err >&5
3993 echo "$as_me:$LINENO: \$? = $ac_status" >&5
3994 (exit $ac_status); } >/dev/null; then
3995 if test -s conftest.err; then
3996 ac_cpp_err=$ac_c_preproc_warn_flag
3997 else
3998 ac_cpp_err=
3999 fi
4000else
4001 ac_cpp_err=yes
4002fi
4003if test -z "$ac_cpp_err"; then
4004 ac_header_preproc=yes
4005else
4006 echo "$as_me: failed program was:" >&5
Michael W. Hudson54241132001-12-07 15:38:26 +00004007 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00004008 ac_header_preproc=no
Michael W. Hudson54241132001-12-07 15:38:26 +00004009fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004010rm -f conftest.err conftest.$ac_ext
4011echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4012echo "${ECHO_T}$ac_header_preproc" >&6
4013
4014# So? What about this header?
4015case $ac_header_compiler:$ac_header_preproc in
4016 yes:no )
4017 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
4018echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
4019 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4020echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
4021 no:yes )
4022 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
4023echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
4024 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
4025echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
4026 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
4027echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
4028esac
4029echo "$as_me:$LINENO: checking for $ac_header" >&5
4030echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
4031if eval "test \"\${$as_ac_Header+set}\" = set"; then
4032 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00004033else
Martin v. Löwis11437992002-04-12 09:54:03 +00004034 eval "$as_ac_Header=$ac_header_preproc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004035fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004036echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4037echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4038
4039fi
4040if test `eval echo '${'$as_ac_Header'}'` = yes; then
4041 cat >>confdefs.h <<_ACEOF
4042#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
4043_ACEOF
4044
4045fi
4046
Guido van Rossum627b2d71993-12-24 10:39:16 +00004047done
4048
Martin v. Löwis11437992002-04-12 09:54:03 +00004049
4050
4051
4052
4053
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004054ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004055for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
4056 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
4057echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
4058echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
4059if eval "test \"\${$as_ac_Header+set}\" = set"; then
4060 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00004061else
Martin v. Löwis11437992002-04-12 09:54:03 +00004062 cat >conftest.$ac_ext <<_ACEOF
4063#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004064#include "confdefs.h"
4065#include <sys/types.h>
4066#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00004067
4068#ifdef F77_DUMMY_MAIN
4069# ifdef __cplusplus
4070 extern "C"
4071# endif
4072 int F77_DUMMY_MAIN() { return 1; }
4073#endif
4074int
4075main ()
4076{
4077if ((DIR *) 0)
4078return 0;
4079 ;
4080 return 0;
4081}
4082_ACEOF
4083rm -f conftest.$ac_objext
4084if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4085 (eval $ac_compile) 2>&5
4086 ac_status=$?
4087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4088 (exit $ac_status); } &&
4089 { ac_try='test -s conftest.$ac_objext'
4090 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4091 (eval $ac_try) 2>&5
4092 ac_status=$?
4093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4094 (exit $ac_status); }; }; then
4095 eval "$as_ac_Header=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +00004096else
Martin v. Löwis11437992002-04-12 09:54:03 +00004097 echo "$as_me: failed program was:" >&5
4098cat conftest.$ac_ext >&5
4099eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004100fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004101rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004102fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004103echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
4104echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
4105if test `eval echo '${'$as_ac_Header'}'` = yes; then
4106 cat >>confdefs.h <<_ACEOF
4107#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
4108_ACEOF
4109
4110ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00004111fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004112
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004113done
4114# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4115if test $ac_header_dirent = dirent.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +00004116 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4117echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4118if test "${ac_cv_search_opendir+set}" = set; then
4119 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004120else
Martin v. Löwis11437992002-04-12 09:54:03 +00004121 ac_func_search_save_LIBS=$LIBS
4122ac_cv_search_opendir=no
4123cat >conftest.$ac_ext <<_ACEOF
4124#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004125#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004126
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004127/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004128#ifdef __cplusplus
4129extern "C"
4130#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004131/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004132 builtin and then its argument prototype would still apply. */
4133char opendir ();
4134#ifdef F77_DUMMY_MAIN
4135# ifdef __cplusplus
4136 extern "C"
4137# endif
4138 int F77_DUMMY_MAIN() { return 1; }
4139#endif
4140int
4141main ()
4142{
4143opendir ();
4144 ;
4145 return 0;
4146}
4147_ACEOF
4148rm -f conftest.$ac_objext conftest$ac_exeext
4149if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4150 (eval $ac_link) 2>&5
4151 ac_status=$?
4152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4153 (exit $ac_status); } &&
4154 { ac_try='test -s conftest$ac_exeext'
4155 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4156 (eval $ac_try) 2>&5
4157 ac_status=$?
4158 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4159 (exit $ac_status); }; }; then
4160 ac_cv_search_opendir="none required"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004161else
Martin v. Löwis11437992002-04-12 09:54:03 +00004162 echo "$as_me: failed program was:" >&5
4163cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004164fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004165rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4166if test "$ac_cv_search_opendir" = no; then
4167 for ac_lib in dir; do
4168 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4169 cat >conftest.$ac_ext <<_ACEOF
4170#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004171#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004172
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004173/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00004174#ifdef __cplusplus
4175extern "C"
4176#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00004177/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00004178 builtin and then its argument prototype would still apply. */
4179char opendir ();
4180#ifdef F77_DUMMY_MAIN
4181# ifdef __cplusplus
4182 extern "C"
4183# endif
4184 int F77_DUMMY_MAIN() { return 1; }
4185#endif
4186int
4187main ()
4188{
4189opendir ();
4190 ;
4191 return 0;
4192}
4193_ACEOF
4194rm -f conftest.$ac_objext conftest$ac_exeext
4195if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4196 (eval $ac_link) 2>&5
4197 ac_status=$?
4198 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4199 (exit $ac_status); } &&
4200 { ac_try='test -s conftest$ac_exeext'
4201 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4202 (eval $ac_try) 2>&5
4203 ac_status=$?
4204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4205 (exit $ac_status); }; }; then
4206 ac_cv_search_opendir="-l$ac_lib"
4207break
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004208else
Martin v. Löwis11437992002-04-12 09:54:03 +00004209 echo "$as_me: failed program was:" >&5
4210cat conftest.$ac_ext >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004211fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004212rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4213 done
4214fi
4215LIBS=$ac_func_search_save_LIBS
4216fi
4217echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4218echo "${ECHO_T}$ac_cv_search_opendir" >&6
4219if test "$ac_cv_search_opendir" != no; then
4220 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00004221
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004222fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004223
Michael W. Hudson54241132001-12-07 15:38:26 +00004224else
Martin v. Löwis11437992002-04-12 09:54:03 +00004225 echo "$as_me:$LINENO: checking for library containing opendir" >&5
4226echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6
4227if test "${ac_cv_search_opendir+set}" = set; then
4228 echo $ECHO_N "(cached) $ECHO_C" >&6
4229else
4230 ac_func_search_save_LIBS=$LIBS
4231ac_cv_search_opendir=no
4232cat >conftest.$ac_ext <<_ACEOF
4233#line $LINENO "configure"
4234#include "confdefs.h"
4235
4236/* Override any gcc2 internal prototype to avoid an error. */
4237#ifdef __cplusplus
4238extern "C"
4239#endif
4240/* We use char because int might match the return type of a gcc2
4241 builtin and then its argument prototype would still apply. */
4242char opendir ();
4243#ifdef F77_DUMMY_MAIN
4244# ifdef __cplusplus
4245 extern "C"
4246# endif
4247 int F77_DUMMY_MAIN() { return 1; }
4248#endif
4249int
4250main ()
4251{
4252opendir ();
4253 ;
4254 return 0;
4255}
4256_ACEOF
4257rm -f conftest.$ac_objext conftest$ac_exeext
4258if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4259 (eval $ac_link) 2>&5
4260 ac_status=$?
4261 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4262 (exit $ac_status); } &&
4263 { ac_try='test -s conftest$ac_exeext'
4264 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4265 (eval $ac_try) 2>&5
4266 ac_status=$?
4267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4268 (exit $ac_status); }; }; then
4269 ac_cv_search_opendir="none required"
4270else
4271 echo "$as_me: failed program was:" >&5
4272cat conftest.$ac_ext >&5
4273fi
4274rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4275if test "$ac_cv_search_opendir" = no; then
4276 for ac_lib in x; do
4277 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
4278 cat >conftest.$ac_ext <<_ACEOF
4279#line $LINENO "configure"
4280#include "confdefs.h"
4281
4282/* Override any gcc2 internal prototype to avoid an error. */
4283#ifdef __cplusplus
4284extern "C"
4285#endif
4286/* We use char because int might match the return type of a gcc2
4287 builtin and then its argument prototype would still apply. */
4288char opendir ();
4289#ifdef F77_DUMMY_MAIN
4290# ifdef __cplusplus
4291 extern "C"
4292# endif
4293 int F77_DUMMY_MAIN() { return 1; }
4294#endif
4295int
4296main ()
4297{
4298opendir ();
4299 ;
4300 return 0;
4301}
4302_ACEOF
4303rm -f conftest.$ac_objext conftest$ac_exeext
4304if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4305 (eval $ac_link) 2>&5
4306 ac_status=$?
4307 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4308 (exit $ac_status); } &&
4309 { ac_try='test -s conftest$ac_exeext'
4310 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4311 (eval $ac_try) 2>&5
4312 ac_status=$?
4313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4314 (exit $ac_status); }; }; then
4315 ac_cv_search_opendir="-l$ac_lib"
4316break
4317else
4318 echo "$as_me: failed program was:" >&5
4319cat conftest.$ac_ext >&5
4320fi
4321rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4322 done
4323fi
4324LIBS=$ac_func_search_save_LIBS
4325fi
4326echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
4327echo "${ECHO_T}$ac_cv_search_opendir" >&6
4328if test "$ac_cv_search_opendir" != no; then
4329 test "$ac_cv_search_opendir" = "none required" || LIBS="$ac_cv_search_opendir $LIBS"
4330
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004331fi
4332
4333fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00004334
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00004335echo "$as_me:$LINENO: checking whether sys/types.h defines makedev" >&5
4336echo $ECHO_N "checking whether sys/types.h defines makedev... $ECHO_C" >&6
4337if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then
4338 echo $ECHO_N "(cached) $ECHO_C" >&6
4339else
4340 cat >conftest.$ac_ext <<_ACEOF
4341#line $LINENO "configure"
4342#include "confdefs.h"
4343#include <sys/types.h>
4344#ifdef F77_DUMMY_MAIN
4345# ifdef __cplusplus
4346 extern "C"
4347# endif
4348 int F77_DUMMY_MAIN() { return 1; }
4349#endif
4350int
4351main ()
4352{
4353return makedev(0, 0);
4354 ;
4355 return 0;
4356}
4357_ACEOF
4358rm -f conftest.$ac_objext conftest$ac_exeext
4359if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4360 (eval $ac_link) 2>&5
4361 ac_status=$?
4362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4363 (exit $ac_status); } &&
4364 { ac_try='test -s conftest$ac_exeext'
4365 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4366 (eval $ac_try) 2>&5
4367 ac_status=$?
4368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4369 (exit $ac_status); }; }; then
4370 ac_cv_header_sys_types_h_makedev=yes
4371else
4372 echo "$as_me: failed program was:" >&5
4373cat conftest.$ac_ext >&5
4374ac_cv_header_sys_types_h_makedev=no
4375fi
4376rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4377
4378fi
4379echo "$as_me:$LINENO: result: $ac_cv_header_sys_types_h_makedev" >&5
4380echo "${ECHO_T}$ac_cv_header_sys_types_h_makedev" >&6
4381
4382if test $ac_cv_header_sys_types_h_makedev = no; then
4383if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
4384 echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
4385echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6
4386if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
4387 echo $ECHO_N "(cached) $ECHO_C" >&6
4388fi
4389echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
4390echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6
4391else
4392 # Is the header compilable?
4393echo "$as_me:$LINENO: checking sys/mkdev.h usability" >&5
4394echo $ECHO_N "checking sys/mkdev.h usability... $ECHO_C" >&6
4395cat >conftest.$ac_ext <<_ACEOF
4396#line $LINENO "configure"
4397#include "confdefs.h"
4398$ac_includes_default
4399#include <sys/mkdev.h>
4400_ACEOF
4401rm -f conftest.$ac_objext
4402if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4403 (eval $ac_compile) 2>&5
4404 ac_status=$?
4405 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4406 (exit $ac_status); } &&
4407 { ac_try='test -s conftest.$ac_objext'
4408 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4409 (eval $ac_try) 2>&5
4410 ac_status=$?
4411 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4412 (exit $ac_status); }; }; then
4413 ac_header_compiler=yes
4414else
4415 echo "$as_me: failed program was:" >&5
4416cat conftest.$ac_ext >&5
4417ac_header_compiler=no
4418fi
4419rm -f conftest.$ac_objext conftest.$ac_ext
4420echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4421echo "${ECHO_T}$ac_header_compiler" >&6
4422
4423# Is the header present?
4424echo "$as_me:$LINENO: checking sys/mkdev.h presence" >&5
4425echo $ECHO_N "checking sys/mkdev.h presence... $ECHO_C" >&6
4426cat >conftest.$ac_ext <<_ACEOF
4427#line $LINENO "configure"
4428#include "confdefs.h"
4429#include <sys/mkdev.h>
4430_ACEOF
4431if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4432 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4433 ac_status=$?
4434 egrep -v '^ *\+' conftest.er1 >conftest.err
4435 rm -f conftest.er1
4436 cat conftest.err >&5
4437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4438 (exit $ac_status); } >/dev/null; then
4439 if test -s conftest.err; then
4440 ac_cpp_err=$ac_c_preproc_warn_flag
4441 else
4442 ac_cpp_err=
4443 fi
4444else
4445 ac_cpp_err=yes
4446fi
4447if test -z "$ac_cpp_err"; then
4448 ac_header_preproc=yes
4449else
4450 echo "$as_me: failed program was:" >&5
4451 cat conftest.$ac_ext >&5
4452 ac_header_preproc=no
4453fi
4454rm -f conftest.err conftest.$ac_ext
4455echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4456echo "${ECHO_T}$ac_header_preproc" >&6
4457
4458# So? What about this header?
4459case $ac_header_compiler:$ac_header_preproc in
4460 yes:no )
4461 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&5
4462echo "$as_me: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
4463 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
4464echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;};;
4465 no:yes )
4466 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: present but cannot be compiled" >&5
4467echo "$as_me: WARNING: sys/mkdev.h: present but cannot be compiled" >&2;}
4468 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&5
4469echo "$as_me: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&2;}
4470 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
4471echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;};;
4472esac
4473echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
4474echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6
4475if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
4476 echo $ECHO_N "(cached) $ECHO_C" >&6
4477else
4478 ac_cv_header_sys_mkdev_h=$ac_header_preproc
4479fi
4480echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
4481echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6
4482
4483fi
4484if test $ac_cv_header_sys_mkdev_h = yes; then
4485
4486cat >>confdefs.h <<\_ACEOF
4487#define MAJOR_IN_MKDEV 1
4488_ACEOF
4489
4490fi
4491
4492
4493
4494 if test $ac_cv_header_sys_mkdev_h = no; then
4495 if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
4496 echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
4497echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6
4498if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
4499 echo $ECHO_N "(cached) $ECHO_C" >&6
4500fi
4501echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
4502echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6
4503else
4504 # Is the header compilable?
4505echo "$as_me:$LINENO: checking sys/sysmacros.h usability" >&5
4506echo $ECHO_N "checking sys/sysmacros.h usability... $ECHO_C" >&6
4507cat >conftest.$ac_ext <<_ACEOF
4508#line $LINENO "configure"
4509#include "confdefs.h"
4510$ac_includes_default
4511#include <sys/sysmacros.h>
4512_ACEOF
4513rm -f conftest.$ac_objext
4514if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4515 (eval $ac_compile) 2>&5
4516 ac_status=$?
4517 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4518 (exit $ac_status); } &&
4519 { ac_try='test -s conftest.$ac_objext'
4520 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4521 (eval $ac_try) 2>&5
4522 ac_status=$?
4523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4524 (exit $ac_status); }; }; then
4525 ac_header_compiler=yes
4526else
4527 echo "$as_me: failed program was:" >&5
4528cat conftest.$ac_ext >&5
4529ac_header_compiler=no
4530fi
4531rm -f conftest.$ac_objext conftest.$ac_ext
4532echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
4533echo "${ECHO_T}$ac_header_compiler" >&6
4534
4535# Is the header present?
4536echo "$as_me:$LINENO: checking sys/sysmacros.h presence" >&5
4537echo $ECHO_N "checking sys/sysmacros.h presence... $ECHO_C" >&6
4538cat >conftest.$ac_ext <<_ACEOF
4539#line $LINENO "configure"
4540#include "confdefs.h"
4541#include <sys/sysmacros.h>
4542_ACEOF
4543if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
4544 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
4545 ac_status=$?
4546 egrep -v '^ *\+' conftest.er1 >conftest.err
4547 rm -f conftest.er1
4548 cat conftest.err >&5
4549 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4550 (exit $ac_status); } >/dev/null; then
4551 if test -s conftest.err; then
4552 ac_cpp_err=$ac_c_preproc_warn_flag
4553 else
4554 ac_cpp_err=
4555 fi
4556else
4557 ac_cpp_err=yes
4558fi
4559if test -z "$ac_cpp_err"; then
4560 ac_header_preproc=yes
4561else
4562 echo "$as_me: failed program was:" >&5
4563 cat conftest.$ac_ext >&5
4564 ac_header_preproc=no
4565fi
4566rm -f conftest.err conftest.$ac_ext
4567echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
4568echo "${ECHO_T}$ac_header_preproc" >&6
4569
4570# So? What about this header?
4571case $ac_header_compiler:$ac_header_preproc in
4572 yes:no )
4573 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&5
4574echo "$as_me: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
4575 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
4576echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;};;
4577 no:yes )
4578 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: present but cannot be compiled" >&5
4579echo "$as_me: WARNING: sys/sysmacros.h: present but cannot be compiled" >&2;}
4580 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&5
4581echo "$as_me: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&2;}
4582 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
4583echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;};;
4584esac
4585echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
4586echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6
4587if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
4588 echo $ECHO_N "(cached) $ECHO_C" >&6
4589else
4590 ac_cv_header_sys_sysmacros_h=$ac_header_preproc
4591fi
4592echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
4593echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6
4594
4595fi
4596if test $ac_cv_header_sys_sysmacros_h = yes; then
4597
4598cat >>confdefs.h <<\_ACEOF
4599#define MAJOR_IN_SYSMACROS 1
4600_ACEOF
4601
4602fi
4603
4604
4605 fi
4606fi
4607
Michael W. Hudson54241132001-12-07 15:38:26 +00004608
Guido van Rossum627b2d71993-12-24 10:39:16 +00004609# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00004610was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +00004611echo "$as_me:$LINENO: checking for clock_t in time.h" >&5
4612echo $ECHO_N "checking for clock_t in time.h... $ECHO_C" >&6
4613cat >conftest.$ac_ext <<_ACEOF
4614#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004615#include "confdefs.h"
4616#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00004617
4618_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004619if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4620 egrep "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00004621 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004622else
Martin v. Löwis11437992002-04-12 09:54:03 +00004623
4624
4625cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004626#define clock_t long
Martin v. Löwis11437992002-04-12 09:54:03 +00004627_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00004628
Martin v. Löwisc45929e2002-04-06 10:10:49 +00004629
Guido van Rossum627b2d71993-12-24 10:39:16 +00004630fi
4631rm -f conftest*
4632
Martin v. Löwis11437992002-04-12 09:54:03 +00004633echo "$as_me:$LINENO: result: $was_it_defined" >&5
4634echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossumda88dad1995-01-26 00:46:29 +00004635
Neal Norwitz11690112002-07-30 01:08:28 +00004636# Check whether using makedev requires defining _OSF_SOURCE
4637echo "$as_me:$LINENO: checking for makedev" >&5
4638echo $ECHO_N "checking for makedev... $ECHO_C" >&6
4639cat >conftest.$ac_ext <<_ACEOF
4640#line $LINENO "configure"
4641#include "confdefs.h"
4642 #include <sys/types.h>
4643#ifdef F77_DUMMY_MAIN
4644# ifdef __cplusplus
4645 extern "C"
4646# endif
4647 int F77_DUMMY_MAIN() { return 1; }
4648#endif
4649int
4650main ()
4651{
4652 makedev(0, 0)
4653 ;
4654 return 0;
4655}
4656_ACEOF
4657rm -f conftest.$ac_objext conftest$ac_exeext
4658if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4659 (eval $ac_link) 2>&5
4660 ac_status=$?
4661 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4662 (exit $ac_status); } &&
4663 { ac_try='test -s conftest$ac_exeext'
4664 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4665 (eval $ac_try) 2>&5
4666 ac_status=$?
4667 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4668 (exit $ac_status); }; }; then
4669 ac_cv_has_makedev=yes
4670else
4671 echo "$as_me: failed program was:" >&5
4672cat conftest.$ac_ext >&5
4673ac_cv_has_makedev=no
4674fi
4675rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4676if test "$ac_cv_has_makedev" = "no"; then
4677 # we didn't link, try if _OSF_SOURCE will allow us to link
4678 cat >conftest.$ac_ext <<_ACEOF
4679#line $LINENO "configure"
4680#include "confdefs.h"
4681
4682 #define _OSF_SOURCE 1
4683 #include <sys/types.h>
4684
4685#ifdef F77_DUMMY_MAIN
4686# ifdef __cplusplus
4687 extern "C"
4688# endif
4689 int F77_DUMMY_MAIN() { return 1; }
4690#endif
4691int
4692main ()
4693{
4694 makedev(0, 0)
4695 ;
4696 return 0;
4697}
4698_ACEOF
4699rm -f conftest.$ac_objext conftest$ac_exeext
4700if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4701 (eval $ac_link) 2>&5
4702 ac_status=$?
4703 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4704 (exit $ac_status); } &&
4705 { ac_try='test -s conftest$ac_exeext'
4706 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4707 (eval $ac_try) 2>&5
4708 ac_status=$?
4709 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4710 (exit $ac_status); }; }; then
4711 ac_cv_has_makedev=yes
4712else
4713 echo "$as_me: failed program was:" >&5
4714cat conftest.$ac_ext >&5
4715ac_cv_has_makedev=no
4716fi
4717rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4718 if test "$ac_cv_has_makedev" = "yes"; then
4719
4720cat >>confdefs.h <<\_ACEOF
4721#define _OSF_SOURCE 1
4722_ACEOF
4723
4724 fi
4725fi
4726echo "$as_me:$LINENO: result: $ac_cv_has_makedev" >&5
4727echo "${ECHO_T}$ac_cv_has_makedev" >&6
4728if test "$ac_cv_has_makedev" = "yes"; then
4729
4730cat >>confdefs.h <<\_ACEOF
4731#define HAVE_MAKEDEV 1
4732_ACEOF
4733
4734fi
4735
Martin v. Löwis399a6892002-10-04 10:22:02 +00004736# Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in
4737# the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are
4738# defined, but the compiler does not support pragma redefine_extname,
4739# and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit
4740# structures (such as rlimit64) without declaring them. As a
4741# work-around, disable LFS on such configurations
4742
4743use_lfs=yes
4744echo "$as_me:$LINENO: checking Solaris LFS bug" >&5
4745echo $ECHO_N "checking Solaris LFS bug... $ECHO_C" >&6
4746cat >conftest.$ac_ext <<_ACEOF
4747#line $LINENO "configure"
4748#include "confdefs.h"
4749
4750#define _LARGEFILE_SOURCE 1
4751#define _FILE_OFFSET_BITS 64
4752#include <sys/resource.h>
4753
4754#ifdef F77_DUMMY_MAIN
4755# ifdef __cplusplus
4756 extern "C"
4757# endif
4758 int F77_DUMMY_MAIN() { return 1; }
4759#endif
4760int
4761main ()
4762{
4763struct rlimit foo;
4764 ;
4765 return 0;
4766}
4767_ACEOF
4768rm -f conftest.$ac_objext
4769if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4770 (eval $ac_compile) 2>&5
4771 ac_status=$?
4772 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4773 (exit $ac_status); } &&
4774 { ac_try='test -s conftest.$ac_objext'
4775 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4776 (eval $ac_try) 2>&5
4777 ac_status=$?
4778 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4779 (exit $ac_status); }; }; then
4780 sol_lfs_bug=no
4781else
4782 echo "$as_me: failed program was:" >&5
4783cat conftest.$ac_ext >&5
4784sol_lfs_bug=yes
4785fi
4786rm -f conftest.$ac_objext conftest.$ac_ext
4787echo "$as_me:$LINENO: result: $sol_lfs_bug" >&5
4788echo "${ECHO_T}$sol_lfs_bug" >&6
4789if test "$sol_lfs_bug" = "yes"; then
4790 use_lfs=no
4791fi
4792
4793if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00004794# Two defines needed to enable largefile support on various platforms
4795# These may affect some typedefs
Guido van Rossum810cc512001-09-09 23:51:39 +00004796
Martin v. Löwis11437992002-04-12 09:54:03 +00004797cat >>confdefs.h <<\_ACEOF
4798#define _LARGEFILE_SOURCE 1
4799_ACEOF
4800
4801
4802cat >>confdefs.h <<\_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00004803#define _FILE_OFFSET_BITS 64
Martin v. Löwis11437992002-04-12 09:54:03 +00004804_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00004805
Martin v. Löwis399a6892002-10-04 10:22:02 +00004806fi
Michael W. Hudson54241132001-12-07 15:38:26 +00004807
Guido van Rossum84e7b241996-08-19 21:59:00 +00004808# Add some code to confdefs.h so that the test for off_t works on SCO
4809cat >> confdefs.h <<\EOF
4810#if defined(SCO_DS)
4811#undef _OFF_T
4812#endif
4813EOF
4814
Guido van Rossumef2255b2000-03-10 22:30:29 +00004815# Type availability checks
Martin v. Löwis11437992002-04-12 09:54:03 +00004816echo "$as_me:$LINENO: checking for mode_t" >&5
4817echo $ECHO_N "checking for mode_t... $ECHO_C" >&6
4818if test "${ac_cv_type_mode_t+set}" = set; then
4819 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004820else
Martin v. Löwis11437992002-04-12 09:54:03 +00004821 cat >conftest.$ac_ext <<_ACEOF
4822#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004823#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004824$ac_includes_default
4825#ifdef F77_DUMMY_MAIN
4826# ifdef __cplusplus
4827 extern "C"
4828# endif
4829 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004830#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004831int
4832main ()
4833{
4834if ((mode_t *) 0)
4835 return 0;
4836if (sizeof (mode_t))
4837 return 0;
4838 ;
4839 return 0;
4840}
4841_ACEOF
4842rm -f conftest.$ac_objext
4843if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4844 (eval $ac_compile) 2>&5
4845 ac_status=$?
4846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4847 (exit $ac_status); } &&
4848 { ac_try='test -s conftest.$ac_objext'
4849 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4850 (eval $ac_try) 2>&5
4851 ac_status=$?
4852 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4853 (exit $ac_status); }; }; then
Jack Jansendd19cf82001-12-06 22:36:17 +00004854 ac_cv_type_mode_t=yes
4855else
Martin v. Löwis11437992002-04-12 09:54:03 +00004856 echo "$as_me: failed program was:" >&5
4857cat conftest.$ac_ext >&5
4858ac_cv_type_mode_t=no
Jack Jansendd19cf82001-12-06 22:36:17 +00004859fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004860rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004861fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004862echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
4863echo "${ECHO_T}$ac_cv_type_mode_t" >&6
4864if test $ac_cv_type_mode_t = yes; then
4865 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004866else
Martin v. Löwis11437992002-04-12 09:54:03 +00004867
4868cat >>confdefs.h <<_ACEOF
4869#define mode_t int
4870_ACEOF
4871
4872fi
4873
4874echo "$as_me:$LINENO: checking for off_t" >&5
4875echo $ECHO_N "checking for off_t... $ECHO_C" >&6
4876if test "${ac_cv_type_off_t+set}" = set; then
4877 echo $ECHO_N "(cached) $ECHO_C" >&6
4878else
4879 cat >conftest.$ac_ext <<_ACEOF
4880#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004881#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004882$ac_includes_default
4883#ifdef F77_DUMMY_MAIN
4884# ifdef __cplusplus
4885 extern "C"
4886# endif
4887 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004888#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004889int
4890main ()
4891{
4892if ((off_t *) 0)
4893 return 0;
4894if (sizeof (off_t))
4895 return 0;
4896 ;
4897 return 0;
4898}
4899_ACEOF
4900rm -f conftest.$ac_objext
4901if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4902 (eval $ac_compile) 2>&5
4903 ac_status=$?
4904 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4905 (exit $ac_status); } &&
4906 { ac_try='test -s conftest.$ac_objext'
4907 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4908 (eval $ac_try) 2>&5
4909 ac_status=$?
4910 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4911 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00004912 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004913else
Martin v. Löwis11437992002-04-12 09:54:03 +00004914 echo "$as_me: failed program was:" >&5
4915cat conftest.$ac_ext >&5
4916ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004917fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004918rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004919fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004920echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
4921echo "${ECHO_T}$ac_cv_type_off_t" >&6
4922if test $ac_cv_type_off_t = yes; then
4923 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004924else
Martin v. Löwis11437992002-04-12 09:54:03 +00004925
4926cat >>confdefs.h <<_ACEOF
4927#define off_t long
4928_ACEOF
4929
4930fi
4931
4932echo "$as_me:$LINENO: checking for pid_t" >&5
4933echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
4934if test "${ac_cv_type_pid_t+set}" = set; then
4935 echo $ECHO_N "(cached) $ECHO_C" >&6
4936else
4937 cat >conftest.$ac_ext <<_ACEOF
4938#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004939#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00004940$ac_includes_default
4941#ifdef F77_DUMMY_MAIN
4942# ifdef __cplusplus
4943 extern "C"
4944# endif
4945 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00004946#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00004947int
4948main ()
4949{
4950if ((pid_t *) 0)
4951 return 0;
4952if (sizeof (pid_t))
4953 return 0;
4954 ;
4955 return 0;
4956}
4957_ACEOF
4958rm -f conftest.$ac_objext
4959if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
4960 (eval $ac_compile) 2>&5
4961 ac_status=$?
4962 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4963 (exit $ac_status); } &&
4964 { ac_try='test -s conftest.$ac_objext'
4965 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4966 (eval $ac_try) 2>&5
4967 ac_status=$?
4968 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4969 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00004970 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00004971else
Martin v. Löwis11437992002-04-12 09:54:03 +00004972 echo "$as_me: failed program was:" >&5
4973cat conftest.$ac_ext >&5
4974ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00004975fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004976rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00004977fi
Martin v. Löwis11437992002-04-12 09:54:03 +00004978echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
4979echo "${ECHO_T}$ac_cv_type_pid_t" >&6
4980if test $ac_cv_type_pid_t = yes; then
4981 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00004982else
Martin v. Löwis11437992002-04-12 09:54:03 +00004983
4984cat >>confdefs.h <<_ACEOF
4985#define pid_t int
4986_ACEOF
4987
4988fi
4989
4990echo "$as_me:$LINENO: checking return type of signal handlers" >&5
4991echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
4992if test "${ac_cv_type_signal+set}" = set; then
4993 echo $ECHO_N "(cached) $ECHO_C" >&6
4994else
4995 cat >conftest.$ac_ext <<_ACEOF
4996#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00004997#include "confdefs.h"
4998#include <sys/types.h>
4999#include <signal.h>
5000#ifdef signal
Martin v. Löwis11437992002-04-12 09:54:03 +00005001# undef signal
Guido van Rossum627b2d71993-12-24 10:39:16 +00005002#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00005003#ifdef __cplusplus
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005004extern "C" void (*signal (int, void (*)(int)))(int);
5005#else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00005006void (*signal ()) ();
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005007#endif
5008
Martin v. Löwis11437992002-04-12 09:54:03 +00005009#ifdef F77_DUMMY_MAIN
5010# ifdef __cplusplus
5011 extern "C"
5012# endif
5013 int F77_DUMMY_MAIN() { return 1; }
5014#endif
5015int
5016main ()
5017{
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005018int i;
Martin v. Löwis11437992002-04-12 09:54:03 +00005019 ;
5020 return 0;
5021}
5022_ACEOF
5023rm -f conftest.$ac_objext
5024if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5025 (eval $ac_compile) 2>&5
5026 ac_status=$?
5027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5028 (exit $ac_status); } &&
5029 { ac_try='test -s conftest.$ac_objext'
5030 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5031 (eval $ac_try) 2>&5
5032 ac_status=$?
5033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5034 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005035 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00005036else
Martin v. Löwis11437992002-04-12 09:54:03 +00005037 echo "$as_me: failed program was:" >&5
5038cat conftest.$ac_ext >&5
5039ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00005040fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005041rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005042fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005043echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
5044echo "${ECHO_T}$ac_cv_type_signal" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00005045
Martin v. Löwis11437992002-04-12 09:54:03 +00005046cat >>confdefs.h <<_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005047#define RETSIGTYPE $ac_cv_type_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00005048_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00005049
Michael W. Hudson54241132001-12-07 15:38:26 +00005050
Martin v. Löwis11437992002-04-12 09:54:03 +00005051echo "$as_me:$LINENO: checking for size_t" >&5
5052echo $ECHO_N "checking for size_t... $ECHO_C" >&6
5053if test "${ac_cv_type_size_t+set}" = set; then
5054 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005055else
Martin v. Löwis11437992002-04-12 09:54:03 +00005056 cat >conftest.$ac_ext <<_ACEOF
5057#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005058#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005059$ac_includes_default
5060#ifdef F77_DUMMY_MAIN
5061# ifdef __cplusplus
5062 extern "C"
5063# endif
5064 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +00005065#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00005066int
5067main ()
5068{
5069if ((size_t *) 0)
5070 return 0;
5071if (sizeof (size_t))
5072 return 0;
5073 ;
5074 return 0;
5075}
5076_ACEOF
5077rm -f conftest.$ac_objext
5078if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5079 (eval $ac_compile) 2>&5
5080 ac_status=$?
5081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5082 (exit $ac_status); } &&
5083 { ac_try='test -s conftest.$ac_objext'
5084 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5085 (eval $ac_try) 2>&5
5086 ac_status=$?
5087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5088 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +00005089 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00005090else
Martin v. Löwis11437992002-04-12 09:54:03 +00005091 echo "$as_me: failed program was:" >&5
5092cat conftest.$ac_ext >&5
5093ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00005094fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005095rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005096fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005097echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
5098echo "${ECHO_T}$ac_cv_type_size_t" >&6
5099if test $ac_cv_type_size_t = yes; then
5100 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005101else
Martin v. Löwis11437992002-04-12 09:54:03 +00005102
5103cat >>confdefs.h <<_ACEOF
5104#define size_t unsigned
5105_ACEOF
5106
5107fi
5108
5109echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
5110echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6
5111if test "${ac_cv_type_uid_t+set}" = set; then
5112 echo $ECHO_N "(cached) $ECHO_C" >&6
5113else
5114 cat >conftest.$ac_ext <<_ACEOF
5115#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005116#include "confdefs.h"
5117#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005118
5119_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005120if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5121 egrep "uid_t" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005122 ac_cv_type_uid_t=yes
5123else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005124 ac_cv_type_uid_t=no
5125fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00005126rm -f conftest*
5127
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005128fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005129echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
5130echo "${ECHO_T}$ac_cv_type_uid_t" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00005131if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005132
Martin v. Löwis11437992002-04-12 09:54:03 +00005133cat >>confdefs.h <<\_ACEOF
5134#define uid_t int
5135_ACEOF
5136
5137
5138cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005139#define gid_t int
Martin v. Löwis11437992002-04-12 09:54:03 +00005140_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005141
5142fi
5143
Jack Jansendd19cf82001-12-06 22:36:17 +00005144
Michael W. Hudson54241132001-12-07 15:38:26 +00005145# Sizes of various common basic types
Martin v. Löwis11437992002-04-12 09:54:03 +00005146echo "$as_me:$LINENO: checking for int" >&5
5147echo $ECHO_N "checking for int... $ECHO_C" >&6
5148if test "${ac_cv_type_int+set}" = set; then
5149 echo $ECHO_N "(cached) $ECHO_C" >&6
5150else
5151 cat >conftest.$ac_ext <<_ACEOF
5152#line $LINENO "configure"
5153#include "confdefs.h"
5154$ac_includes_default
5155#ifdef F77_DUMMY_MAIN
5156# ifdef __cplusplus
5157 extern "C"
5158# endif
5159 int F77_DUMMY_MAIN() { return 1; }
5160#endif
5161int
5162main ()
5163{
5164if ((int *) 0)
5165 return 0;
5166if (sizeof (int))
5167 return 0;
5168 ;
5169 return 0;
5170}
5171_ACEOF
5172rm -f conftest.$ac_objext
5173if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5174 (eval $ac_compile) 2>&5
5175 ac_status=$?
5176 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5177 (exit $ac_status); } &&
5178 { ac_try='test -s conftest.$ac_objext'
5179 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5180 (eval $ac_try) 2>&5
5181 ac_status=$?
5182 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5183 (exit $ac_status); }; }; then
5184 ac_cv_type_int=yes
5185else
5186 echo "$as_me: failed program was:" >&5
5187cat conftest.$ac_ext >&5
5188ac_cv_type_int=no
5189fi
5190rm -f conftest.$ac_objext conftest.$ac_ext
5191fi
5192echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
5193echo "${ECHO_T}$ac_cv_type_int" >&6
5194
5195echo "$as_me:$LINENO: checking size of int" >&5
5196echo $ECHO_N "checking size of int... $ECHO_C" >&6
5197if test "${ac_cv_sizeof_int+set}" = set; then
5198 echo $ECHO_N "(cached) $ECHO_C" >&6
5199else
5200 if test "$ac_cv_type_int" = yes; then
5201 # The cast to unsigned long works around a bug in the HP C Compiler
5202 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5203 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5204 # This bug is HP SR number 8606223364.
5205 if test "$cross_compiling" = yes; then
5206 # Depending upon the size, compute the lo and hi bounds.
5207cat >conftest.$ac_ext <<_ACEOF
5208#line $LINENO "configure"
5209#include "confdefs.h"
5210$ac_includes_default
5211#ifdef F77_DUMMY_MAIN
5212# ifdef __cplusplus
5213 extern "C"
5214# endif
5215 int F77_DUMMY_MAIN() { return 1; }
5216#endif
5217int
5218main ()
5219{
5220static int test_array [1 - 2 * !(((long) (sizeof (int))) >= 0)];
5221test_array [0] = 0
5222
5223 ;
5224 return 0;
5225}
5226_ACEOF
5227rm -f conftest.$ac_objext
5228if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5229 (eval $ac_compile) 2>&5
5230 ac_status=$?
5231 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5232 (exit $ac_status); } &&
5233 { ac_try='test -s conftest.$ac_objext'
5234 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5235 (eval $ac_try) 2>&5
5236 ac_status=$?
5237 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5238 (exit $ac_status); }; }; then
5239 ac_lo=0 ac_mid=0
5240 while :; do
5241 cat >conftest.$ac_ext <<_ACEOF
5242#line $LINENO "configure"
5243#include "confdefs.h"
5244$ac_includes_default
5245#ifdef F77_DUMMY_MAIN
5246# ifdef __cplusplus
5247 extern "C"
5248# endif
5249 int F77_DUMMY_MAIN() { return 1; }
5250#endif
5251int
5252main ()
5253{
5254static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
5255test_array [0] = 0
5256
5257 ;
5258 return 0;
5259}
5260_ACEOF
5261rm -f conftest.$ac_objext
5262if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5263 (eval $ac_compile) 2>&5
5264 ac_status=$?
5265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5266 (exit $ac_status); } &&
5267 { ac_try='test -s conftest.$ac_objext'
5268 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5269 (eval $ac_try) 2>&5
5270 ac_status=$?
5271 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5272 (exit $ac_status); }; }; then
5273 ac_hi=$ac_mid; break
5274else
5275 echo "$as_me: failed program was:" >&5
5276cat conftest.$ac_ext >&5
5277ac_lo=`expr $ac_mid + 1`
5278 if test $ac_lo -le $ac_mid; then
5279 ac_lo= ac_hi=
5280 break
5281 fi
5282 ac_mid=`expr 2 '*' $ac_mid + 1`
5283fi
5284rm -f conftest.$ac_objext conftest.$ac_ext
5285 done
5286else
5287 echo "$as_me: failed program was:" >&5
5288cat conftest.$ac_ext >&5
5289cat >conftest.$ac_ext <<_ACEOF
5290#line $LINENO "configure"
5291#include "confdefs.h"
5292$ac_includes_default
5293#ifdef F77_DUMMY_MAIN
5294# ifdef __cplusplus
5295 extern "C"
5296# endif
5297 int F77_DUMMY_MAIN() { return 1; }
5298#endif
5299int
5300main ()
5301{
5302static int test_array [1 - 2 * !(((long) (sizeof (int))) < 0)];
5303test_array [0] = 0
5304
5305 ;
5306 return 0;
5307}
5308_ACEOF
5309rm -f conftest.$ac_objext
5310if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5311 (eval $ac_compile) 2>&5
5312 ac_status=$?
5313 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5314 (exit $ac_status); } &&
5315 { ac_try='test -s conftest.$ac_objext'
5316 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5317 (eval $ac_try) 2>&5
5318 ac_status=$?
5319 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5320 (exit $ac_status); }; }; then
5321 ac_hi=-1 ac_mid=-1
5322 while :; do
5323 cat >conftest.$ac_ext <<_ACEOF
5324#line $LINENO "configure"
5325#include "confdefs.h"
5326$ac_includes_default
5327#ifdef F77_DUMMY_MAIN
5328# ifdef __cplusplus
5329 extern "C"
5330# endif
5331 int F77_DUMMY_MAIN() { return 1; }
5332#endif
5333int
5334main ()
5335{
5336static int test_array [1 - 2 * !(((long) (sizeof (int))) >= $ac_mid)];
5337test_array [0] = 0
5338
5339 ;
5340 return 0;
5341}
5342_ACEOF
5343rm -f conftest.$ac_objext
5344if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5345 (eval $ac_compile) 2>&5
5346 ac_status=$?
5347 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5348 (exit $ac_status); } &&
5349 { ac_try='test -s conftest.$ac_objext'
5350 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5351 (eval $ac_try) 2>&5
5352 ac_status=$?
5353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5354 (exit $ac_status); }; }; then
5355 ac_lo=$ac_mid; break
5356else
5357 echo "$as_me: failed program was:" >&5
5358cat conftest.$ac_ext >&5
5359ac_hi=`expr '(' $ac_mid ')' - 1`
5360 if test $ac_mid -le $ac_hi; then
5361 ac_lo= ac_hi=
5362 break
5363 fi
5364 ac_mid=`expr 2 '*' $ac_mid`
5365fi
5366rm -f conftest.$ac_objext conftest.$ac_ext
5367 done
5368else
5369 echo "$as_me: failed program was:" >&5
5370cat conftest.$ac_ext >&5
5371ac_lo= ac_hi=
5372fi
5373rm -f conftest.$ac_objext conftest.$ac_ext
5374fi
5375rm -f conftest.$ac_objext conftest.$ac_ext
5376# Binary search between lo and hi bounds.
5377while test "x$ac_lo" != "x$ac_hi"; do
5378 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5379 cat >conftest.$ac_ext <<_ACEOF
5380#line $LINENO "configure"
5381#include "confdefs.h"
5382$ac_includes_default
5383#ifdef F77_DUMMY_MAIN
5384# ifdef __cplusplus
5385 extern "C"
5386# endif
5387 int F77_DUMMY_MAIN() { return 1; }
5388#endif
5389int
5390main ()
5391{
5392static int test_array [1 - 2 * !(((long) (sizeof (int))) <= $ac_mid)];
5393test_array [0] = 0
5394
5395 ;
5396 return 0;
5397}
5398_ACEOF
5399rm -f conftest.$ac_objext
5400if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5401 (eval $ac_compile) 2>&5
5402 ac_status=$?
5403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5404 (exit $ac_status); } &&
5405 { ac_try='test -s conftest.$ac_objext'
5406 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5407 (eval $ac_try) 2>&5
5408 ac_status=$?
5409 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5410 (exit $ac_status); }; }; then
5411 ac_hi=$ac_mid
5412else
5413 echo "$as_me: failed program was:" >&5
5414cat conftest.$ac_ext >&5
5415ac_lo=`expr '(' $ac_mid ')' + 1`
5416fi
5417rm -f conftest.$ac_objext conftest.$ac_ext
5418done
5419case $ac_lo in
5420?*) ac_cv_sizeof_int=$ac_lo;;
5421'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77" >&5
5422echo "$as_me: error: cannot compute sizeof (int), 77" >&2;}
5423 { (exit 1); exit 1; }; } ;;
5424esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005425else
5426 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005427 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5428echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5429 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005430else
Martin v. Löwis11437992002-04-12 09:54:03 +00005431 cat >conftest.$ac_ext <<_ACEOF
5432#line $LINENO "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005433#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005434$ac_includes_default
5435long longval () { return (long) (sizeof (int)); }
5436unsigned long ulongval () { return (long) (sizeof (int)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005437#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005438#include <stdlib.h>
5439#ifdef F77_DUMMY_MAIN
5440# ifdef __cplusplus
5441 extern "C"
5442# endif
5443 int F77_DUMMY_MAIN() { return 1; }
5444#endif
5445int
5446main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005447{
Martin v. Löwis11437992002-04-12 09:54:03 +00005448
5449 FILE *f = fopen ("conftest.val", "w");
5450 if (! f)
5451 exit (1);
5452 if (((long) (sizeof (int))) < 0)
5453 {
5454 long i = longval ();
5455 if (i != ((long) (sizeof (int))))
5456 exit (1);
5457 fprintf (f, "%ld\n", i);
5458 }
5459 else
5460 {
5461 unsigned long i = ulongval ();
5462 if (i != ((long) (sizeof (int))))
5463 exit (1);
5464 fprintf (f, "%lu\n", i);
5465 }
5466 exit (ferror (f) || fclose (f) != 0);
5467
5468 ;
5469 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005470}
Martin v. Löwis11437992002-04-12 09:54:03 +00005471_ACEOF
5472rm -f conftest$ac_exeext
5473if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5474 (eval $ac_link) 2>&5
5475 ac_status=$?
5476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5477 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5478 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5479 (eval $ac_try) 2>&5
5480 ac_status=$?
5481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5482 (exit $ac_status); }; }; then
5483 ac_cv_sizeof_int=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005484else
Martin v. Löwis11437992002-04-12 09:54:03 +00005485 echo "$as_me: program exited with status $ac_status" >&5
5486echo "$as_me: failed program was:" >&5
5487cat conftest.$ac_ext >&5
5488( exit $ac_status )
5489{ { echo "$as_me:$LINENO: error: cannot compute sizeof (int), 77" >&5
5490echo "$as_me: error: cannot compute sizeof (int), 77" >&2;}
5491 { (exit 1); exit 1; }; }
5492fi
5493rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5494fi
5495fi
5496rm -f conftest.val
5497else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005498 ac_cv_sizeof_int=0
5499fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005500fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005501echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
5502echo "${ECHO_T}$ac_cv_sizeof_int" >&6
5503cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005504#define SIZEOF_INT $ac_cv_sizeof_int
Martin v. Löwis11437992002-04-12 09:54:03 +00005505_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005506
5507
Martin v. Löwis11437992002-04-12 09:54:03 +00005508echo "$as_me:$LINENO: checking for long" >&5
5509echo $ECHO_N "checking for long... $ECHO_C" >&6
5510if test "${ac_cv_type_long+set}" = set; then
5511 echo $ECHO_N "(cached) $ECHO_C" >&6
5512else
5513 cat >conftest.$ac_ext <<_ACEOF
5514#line $LINENO "configure"
5515#include "confdefs.h"
5516$ac_includes_default
5517#ifdef F77_DUMMY_MAIN
5518# ifdef __cplusplus
5519 extern "C"
5520# endif
5521 int F77_DUMMY_MAIN() { return 1; }
5522#endif
5523int
5524main ()
5525{
5526if ((long *) 0)
5527 return 0;
5528if (sizeof (long))
5529 return 0;
5530 ;
5531 return 0;
5532}
5533_ACEOF
5534rm -f conftest.$ac_objext
5535if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5536 (eval $ac_compile) 2>&5
5537 ac_status=$?
5538 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5539 (exit $ac_status); } &&
5540 { ac_try='test -s conftest.$ac_objext'
5541 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5542 (eval $ac_try) 2>&5
5543 ac_status=$?
5544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5545 (exit $ac_status); }; }; then
5546 ac_cv_type_long=yes
5547else
5548 echo "$as_me: failed program was:" >&5
5549cat conftest.$ac_ext >&5
5550ac_cv_type_long=no
5551fi
5552rm -f conftest.$ac_objext conftest.$ac_ext
5553fi
5554echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
5555echo "${ECHO_T}$ac_cv_type_long" >&6
5556
5557echo "$as_me:$LINENO: checking size of long" >&5
5558echo $ECHO_N "checking size of long... $ECHO_C" >&6
5559if test "${ac_cv_sizeof_long+set}" = set; then
5560 echo $ECHO_N "(cached) $ECHO_C" >&6
5561else
5562 if test "$ac_cv_type_long" = yes; then
5563 # The cast to unsigned long works around a bug in the HP C Compiler
5564 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5565 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5566 # This bug is HP SR number 8606223364.
5567 if test "$cross_compiling" = yes; then
5568 # Depending upon the size, compute the lo and hi bounds.
5569cat >conftest.$ac_ext <<_ACEOF
5570#line $LINENO "configure"
5571#include "confdefs.h"
5572$ac_includes_default
5573#ifdef F77_DUMMY_MAIN
5574# ifdef __cplusplus
5575 extern "C"
5576# endif
5577 int F77_DUMMY_MAIN() { return 1; }
5578#endif
5579int
5580main ()
5581{
5582static int test_array [1 - 2 * !(((long) (sizeof (long))) >= 0)];
5583test_array [0] = 0
5584
5585 ;
5586 return 0;
5587}
5588_ACEOF
5589rm -f conftest.$ac_objext
5590if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5591 (eval $ac_compile) 2>&5
5592 ac_status=$?
5593 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5594 (exit $ac_status); } &&
5595 { ac_try='test -s conftest.$ac_objext'
5596 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5597 (eval $ac_try) 2>&5
5598 ac_status=$?
5599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5600 (exit $ac_status); }; }; then
5601 ac_lo=0 ac_mid=0
5602 while :; do
5603 cat >conftest.$ac_ext <<_ACEOF
5604#line $LINENO "configure"
5605#include "confdefs.h"
5606$ac_includes_default
5607#ifdef F77_DUMMY_MAIN
5608# ifdef __cplusplus
5609 extern "C"
5610# endif
5611 int F77_DUMMY_MAIN() { return 1; }
5612#endif
5613int
5614main ()
5615{
5616static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5617test_array [0] = 0
5618
5619 ;
5620 return 0;
5621}
5622_ACEOF
5623rm -f conftest.$ac_objext
5624if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5625 (eval $ac_compile) 2>&5
5626 ac_status=$?
5627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5628 (exit $ac_status); } &&
5629 { ac_try='test -s conftest.$ac_objext'
5630 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5631 (eval $ac_try) 2>&5
5632 ac_status=$?
5633 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5634 (exit $ac_status); }; }; then
5635 ac_hi=$ac_mid; break
5636else
5637 echo "$as_me: failed program was:" >&5
5638cat conftest.$ac_ext >&5
5639ac_lo=`expr $ac_mid + 1`
5640 if test $ac_lo -le $ac_mid; then
5641 ac_lo= ac_hi=
5642 break
5643 fi
5644 ac_mid=`expr 2 '*' $ac_mid + 1`
5645fi
5646rm -f conftest.$ac_objext conftest.$ac_ext
5647 done
5648else
5649 echo "$as_me: failed program was:" >&5
5650cat conftest.$ac_ext >&5
5651cat >conftest.$ac_ext <<_ACEOF
5652#line $LINENO "configure"
5653#include "confdefs.h"
5654$ac_includes_default
5655#ifdef F77_DUMMY_MAIN
5656# ifdef __cplusplus
5657 extern "C"
5658# endif
5659 int F77_DUMMY_MAIN() { return 1; }
5660#endif
5661int
5662main ()
5663{
5664static int test_array [1 - 2 * !(((long) (sizeof (long))) < 0)];
5665test_array [0] = 0
5666
5667 ;
5668 return 0;
5669}
5670_ACEOF
5671rm -f conftest.$ac_objext
5672if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5673 (eval $ac_compile) 2>&5
5674 ac_status=$?
5675 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5676 (exit $ac_status); } &&
5677 { ac_try='test -s conftest.$ac_objext'
5678 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5679 (eval $ac_try) 2>&5
5680 ac_status=$?
5681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5682 (exit $ac_status); }; }; then
5683 ac_hi=-1 ac_mid=-1
5684 while :; do
5685 cat >conftest.$ac_ext <<_ACEOF
5686#line $LINENO "configure"
5687#include "confdefs.h"
5688$ac_includes_default
5689#ifdef F77_DUMMY_MAIN
5690# ifdef __cplusplus
5691 extern "C"
5692# endif
5693 int F77_DUMMY_MAIN() { return 1; }
5694#endif
5695int
5696main ()
5697{
5698static int test_array [1 - 2 * !(((long) (sizeof (long))) >= $ac_mid)];
5699test_array [0] = 0
5700
5701 ;
5702 return 0;
5703}
5704_ACEOF
5705rm -f conftest.$ac_objext
5706if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5707 (eval $ac_compile) 2>&5
5708 ac_status=$?
5709 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5710 (exit $ac_status); } &&
5711 { ac_try='test -s conftest.$ac_objext'
5712 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5713 (eval $ac_try) 2>&5
5714 ac_status=$?
5715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5716 (exit $ac_status); }; }; then
5717 ac_lo=$ac_mid; break
5718else
5719 echo "$as_me: failed program was:" >&5
5720cat conftest.$ac_ext >&5
5721ac_hi=`expr '(' $ac_mid ')' - 1`
5722 if test $ac_mid -le $ac_hi; then
5723 ac_lo= ac_hi=
5724 break
5725 fi
5726 ac_mid=`expr 2 '*' $ac_mid`
5727fi
5728rm -f conftest.$ac_objext conftest.$ac_ext
5729 done
5730else
5731 echo "$as_me: failed program was:" >&5
5732cat conftest.$ac_ext >&5
5733ac_lo= ac_hi=
5734fi
5735rm -f conftest.$ac_objext conftest.$ac_ext
5736fi
5737rm -f conftest.$ac_objext conftest.$ac_ext
5738# Binary search between lo and hi bounds.
5739while test "x$ac_lo" != "x$ac_hi"; do
5740 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
5741 cat >conftest.$ac_ext <<_ACEOF
5742#line $LINENO "configure"
5743#include "confdefs.h"
5744$ac_includes_default
5745#ifdef F77_DUMMY_MAIN
5746# ifdef __cplusplus
5747 extern "C"
5748# endif
5749 int F77_DUMMY_MAIN() { return 1; }
5750#endif
5751int
5752main ()
5753{
5754static int test_array [1 - 2 * !(((long) (sizeof (long))) <= $ac_mid)];
5755test_array [0] = 0
5756
5757 ;
5758 return 0;
5759}
5760_ACEOF
5761rm -f conftest.$ac_objext
5762if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5763 (eval $ac_compile) 2>&5
5764 ac_status=$?
5765 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5766 (exit $ac_status); } &&
5767 { ac_try='test -s conftest.$ac_objext'
5768 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5769 (eval $ac_try) 2>&5
5770 ac_status=$?
5771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5772 (exit $ac_status); }; }; then
5773 ac_hi=$ac_mid
5774else
5775 echo "$as_me: failed program was:" >&5
5776cat conftest.$ac_ext >&5
5777ac_lo=`expr '(' $ac_mid ')' + 1`
5778fi
5779rm -f conftest.$ac_objext conftest.$ac_ext
5780done
5781case $ac_lo in
5782?*) ac_cv_sizeof_long=$ac_lo;;
5783'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77" >&5
5784echo "$as_me: error: cannot compute sizeof (long), 77" >&2;}
5785 { (exit 1); exit 1; }; } ;;
5786esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005787else
5788 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005789 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
5790echo "$as_me: error: cannot run test program while cross compiling" >&2;}
5791 { (exit 1); exit 1; }; }
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005792else
Martin v. Löwis11437992002-04-12 09:54:03 +00005793 cat >conftest.$ac_ext <<_ACEOF
5794#line $LINENO "configure"
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005795#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00005796$ac_includes_default
5797long longval () { return (long) (sizeof (long)); }
5798unsigned long ulongval () { return (long) (sizeof (long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00005799#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00005800#include <stdlib.h>
5801#ifdef F77_DUMMY_MAIN
5802# ifdef __cplusplus
5803 extern "C"
5804# endif
5805 int F77_DUMMY_MAIN() { return 1; }
5806#endif
5807int
5808main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005809{
Martin v. Löwis11437992002-04-12 09:54:03 +00005810
5811 FILE *f = fopen ("conftest.val", "w");
5812 if (! f)
5813 exit (1);
5814 if (((long) (sizeof (long))) < 0)
5815 {
5816 long i = longval ();
5817 if (i != ((long) (sizeof (long))))
5818 exit (1);
5819 fprintf (f, "%ld\n", i);
5820 }
5821 else
5822 {
5823 unsigned long i = ulongval ();
5824 if (i != ((long) (sizeof (long))))
5825 exit (1);
5826 fprintf (f, "%lu\n", i);
5827 }
5828 exit (ferror (f) || fclose (f) != 0);
5829
5830 ;
5831 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005832}
Martin v. Löwis11437992002-04-12 09:54:03 +00005833_ACEOF
5834rm -f conftest$ac_exeext
5835if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5836 (eval $ac_link) 2>&5
5837 ac_status=$?
5838 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5839 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5840 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5841 (eval $ac_try) 2>&5
5842 ac_status=$?
5843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5844 (exit $ac_status); }; }; then
5845 ac_cv_sizeof_long=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005846else
Martin v. Löwis11437992002-04-12 09:54:03 +00005847 echo "$as_me: program exited with status $ac_status" >&5
5848echo "$as_me: failed program was:" >&5
5849cat conftest.$ac_ext >&5
5850( exit $ac_status )
5851{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long), 77" >&5
5852echo "$as_me: error: cannot compute sizeof (long), 77" >&2;}
5853 { (exit 1); exit 1; }; }
5854fi
5855rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5856fi
5857fi
5858rm -f conftest.val
5859else
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005860 ac_cv_sizeof_long=0
5861fi
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005862fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005863echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
5864echo "${ECHO_T}$ac_cv_sizeof_long" >&6
5865cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005866#define SIZEOF_LONG $ac_cv_sizeof_long
Martin v. Löwis11437992002-04-12 09:54:03 +00005867_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00005868
5869
Martin v. Löwis11437992002-04-12 09:54:03 +00005870echo "$as_me:$LINENO: checking for void *" >&5
5871echo $ECHO_N "checking for void *... $ECHO_C" >&6
5872if test "${ac_cv_type_void_p+set}" = set; then
5873 echo $ECHO_N "(cached) $ECHO_C" >&6
5874else
5875 cat >conftest.$ac_ext <<_ACEOF
5876#line $LINENO "configure"
5877#include "confdefs.h"
5878$ac_includes_default
5879#ifdef F77_DUMMY_MAIN
5880# ifdef __cplusplus
5881 extern "C"
5882# endif
5883 int F77_DUMMY_MAIN() { return 1; }
5884#endif
5885int
5886main ()
5887{
5888if ((void * *) 0)
5889 return 0;
5890if (sizeof (void *))
5891 return 0;
5892 ;
5893 return 0;
5894}
5895_ACEOF
5896rm -f conftest.$ac_objext
5897if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5898 (eval $ac_compile) 2>&5
5899 ac_status=$?
5900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5901 (exit $ac_status); } &&
5902 { ac_try='test -s conftest.$ac_objext'
5903 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5904 (eval $ac_try) 2>&5
5905 ac_status=$?
5906 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5907 (exit $ac_status); }; }; then
5908 ac_cv_type_void_p=yes
5909else
5910 echo "$as_me: failed program was:" >&5
5911cat conftest.$ac_ext >&5
5912ac_cv_type_void_p=no
5913fi
5914rm -f conftest.$ac_objext conftest.$ac_ext
5915fi
5916echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
5917echo "${ECHO_T}$ac_cv_type_void_p" >&6
5918
5919echo "$as_me:$LINENO: checking size of void *" >&5
5920echo $ECHO_N "checking size of void *... $ECHO_C" >&6
5921if test "${ac_cv_sizeof_void_p+set}" = set; then
5922 echo $ECHO_N "(cached) $ECHO_C" >&6
5923else
5924 if test "$ac_cv_type_void_p" = yes; then
5925 # The cast to unsigned long works around a bug in the HP C Compiler
5926 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
5927 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
5928 # This bug is HP SR number 8606223364.
5929 if test "$cross_compiling" = yes; then
5930 # Depending upon the size, compute the lo and hi bounds.
5931cat >conftest.$ac_ext <<_ACEOF
5932#line $LINENO "configure"
5933#include "confdefs.h"
5934$ac_includes_default
5935#ifdef F77_DUMMY_MAIN
5936# ifdef __cplusplus
5937 extern "C"
5938# endif
5939 int F77_DUMMY_MAIN() { return 1; }
5940#endif
5941int
5942main ()
5943{
5944static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= 0)];
5945test_array [0] = 0
5946
5947 ;
5948 return 0;
5949}
5950_ACEOF
5951rm -f conftest.$ac_objext
5952if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5953 (eval $ac_compile) 2>&5
5954 ac_status=$?
5955 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5956 (exit $ac_status); } &&
5957 { ac_try='test -s conftest.$ac_objext'
5958 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5959 (eval $ac_try) 2>&5
5960 ac_status=$?
5961 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5962 (exit $ac_status); }; }; then
5963 ac_lo=0 ac_mid=0
5964 while :; do
5965 cat >conftest.$ac_ext <<_ACEOF
5966#line $LINENO "configure"
5967#include "confdefs.h"
5968$ac_includes_default
5969#ifdef F77_DUMMY_MAIN
5970# ifdef __cplusplus
5971 extern "C"
5972# endif
5973 int F77_DUMMY_MAIN() { return 1; }
5974#endif
5975int
5976main ()
5977{
5978static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
5979test_array [0] = 0
5980
5981 ;
5982 return 0;
5983}
5984_ACEOF
5985rm -f conftest.$ac_objext
5986if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5987 (eval $ac_compile) 2>&5
5988 ac_status=$?
5989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5990 (exit $ac_status); } &&
5991 { ac_try='test -s conftest.$ac_objext'
5992 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5993 (eval $ac_try) 2>&5
5994 ac_status=$?
5995 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5996 (exit $ac_status); }; }; then
5997 ac_hi=$ac_mid; break
5998else
5999 echo "$as_me: failed program was:" >&5
6000cat conftest.$ac_ext >&5
6001ac_lo=`expr $ac_mid + 1`
6002 if test $ac_lo -le $ac_mid; then
6003 ac_lo= ac_hi=
6004 break
6005 fi
6006 ac_mid=`expr 2 '*' $ac_mid + 1`
6007fi
6008rm -f conftest.$ac_objext conftest.$ac_ext
6009 done
6010else
6011 echo "$as_me: failed program was:" >&5
6012cat conftest.$ac_ext >&5
6013cat >conftest.$ac_ext <<_ACEOF
6014#line $LINENO "configure"
6015#include "confdefs.h"
6016$ac_includes_default
6017#ifdef F77_DUMMY_MAIN
6018# ifdef __cplusplus
6019 extern "C"
6020# endif
6021 int F77_DUMMY_MAIN() { return 1; }
6022#endif
6023int
6024main ()
6025{
6026static int test_array [1 - 2 * !(((long) (sizeof (void *))) < 0)];
6027test_array [0] = 0
6028
6029 ;
6030 return 0;
6031}
6032_ACEOF
6033rm -f conftest.$ac_objext
6034if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6035 (eval $ac_compile) 2>&5
6036 ac_status=$?
6037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6038 (exit $ac_status); } &&
6039 { ac_try='test -s conftest.$ac_objext'
6040 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6041 (eval $ac_try) 2>&5
6042 ac_status=$?
6043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6044 (exit $ac_status); }; }; then
6045 ac_hi=-1 ac_mid=-1
6046 while :; do
6047 cat >conftest.$ac_ext <<_ACEOF
6048#line $LINENO "configure"
6049#include "confdefs.h"
6050$ac_includes_default
6051#ifdef F77_DUMMY_MAIN
6052# ifdef __cplusplus
6053 extern "C"
6054# endif
6055 int F77_DUMMY_MAIN() { return 1; }
6056#endif
6057int
6058main ()
6059{
6060static int test_array [1 - 2 * !(((long) (sizeof (void *))) >= $ac_mid)];
6061test_array [0] = 0
6062
6063 ;
6064 return 0;
6065}
6066_ACEOF
6067rm -f conftest.$ac_objext
6068if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6069 (eval $ac_compile) 2>&5
6070 ac_status=$?
6071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6072 (exit $ac_status); } &&
6073 { ac_try='test -s conftest.$ac_objext'
6074 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6075 (eval $ac_try) 2>&5
6076 ac_status=$?
6077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6078 (exit $ac_status); }; }; then
6079 ac_lo=$ac_mid; break
6080else
6081 echo "$as_me: failed program was:" >&5
6082cat conftest.$ac_ext >&5
6083ac_hi=`expr '(' $ac_mid ')' - 1`
6084 if test $ac_mid -le $ac_hi; then
6085 ac_lo= ac_hi=
6086 break
6087 fi
6088 ac_mid=`expr 2 '*' $ac_mid`
6089fi
6090rm -f conftest.$ac_objext conftest.$ac_ext
6091 done
6092else
6093 echo "$as_me: failed program was:" >&5
6094cat conftest.$ac_ext >&5
6095ac_lo= ac_hi=
6096fi
6097rm -f conftest.$ac_objext conftest.$ac_ext
6098fi
6099rm -f conftest.$ac_objext conftest.$ac_ext
6100# Binary search between lo and hi bounds.
6101while test "x$ac_lo" != "x$ac_hi"; do
6102 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6103 cat >conftest.$ac_ext <<_ACEOF
6104#line $LINENO "configure"
6105#include "confdefs.h"
6106$ac_includes_default
6107#ifdef F77_DUMMY_MAIN
6108# ifdef __cplusplus
6109 extern "C"
6110# endif
6111 int F77_DUMMY_MAIN() { return 1; }
6112#endif
6113int
6114main ()
6115{
6116static int test_array [1 - 2 * !(((long) (sizeof (void *))) <= $ac_mid)];
6117test_array [0] = 0
6118
6119 ;
6120 return 0;
6121}
6122_ACEOF
6123rm -f conftest.$ac_objext
6124if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6125 (eval $ac_compile) 2>&5
6126 ac_status=$?
6127 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6128 (exit $ac_status); } &&
6129 { ac_try='test -s conftest.$ac_objext'
6130 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6131 (eval $ac_try) 2>&5
6132 ac_status=$?
6133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6134 (exit $ac_status); }; }; then
6135 ac_hi=$ac_mid
6136else
6137 echo "$as_me: failed program was:" >&5
6138cat conftest.$ac_ext >&5
6139ac_lo=`expr '(' $ac_mid ')' + 1`
6140fi
6141rm -f conftest.$ac_objext conftest.$ac_ext
6142done
6143case $ac_lo in
6144?*) ac_cv_sizeof_void_p=$ac_lo;;
6145'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77" >&5
6146echo "$as_me: error: cannot compute sizeof (void *), 77" >&2;}
6147 { (exit 1); exit 1; }; } ;;
6148esac
Guido van Rossumad678af1998-10-02 14:42:15 +00006149else
6150 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006151 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6152echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6153 { (exit 1); exit 1; }; }
Guido van Rossumad678af1998-10-02 14:42:15 +00006154else
Martin v. Löwis11437992002-04-12 09:54:03 +00006155 cat >conftest.$ac_ext <<_ACEOF
6156#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +00006157#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006158$ac_includes_default
6159long longval () { return (long) (sizeof (void *)); }
6160unsigned long ulongval () { return (long) (sizeof (void *)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006161#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006162#include <stdlib.h>
6163#ifdef F77_DUMMY_MAIN
6164# ifdef __cplusplus
6165 extern "C"
6166# endif
6167 int F77_DUMMY_MAIN() { return 1; }
6168#endif
6169int
6170main ()
Guido van Rossumad678af1998-10-02 14:42:15 +00006171{
Martin v. Löwis11437992002-04-12 09:54:03 +00006172
6173 FILE *f = fopen ("conftest.val", "w");
6174 if (! f)
6175 exit (1);
6176 if (((long) (sizeof (void *))) < 0)
6177 {
6178 long i = longval ();
6179 if (i != ((long) (sizeof (void *))))
6180 exit (1);
6181 fprintf (f, "%ld\n", i);
6182 }
6183 else
6184 {
6185 unsigned long i = ulongval ();
6186 if (i != ((long) (sizeof (void *))))
6187 exit (1);
6188 fprintf (f, "%lu\n", i);
6189 }
6190 exit (ferror (f) || fclose (f) != 0);
6191
6192 ;
6193 return 0;
Guido van Rossumad678af1998-10-02 14:42:15 +00006194}
Martin v. Löwis11437992002-04-12 09:54:03 +00006195_ACEOF
6196rm -f conftest$ac_exeext
6197if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6198 (eval $ac_link) 2>&5
6199 ac_status=$?
6200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6201 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6202 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6203 (eval $ac_try) 2>&5
6204 ac_status=$?
6205 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6206 (exit $ac_status); }; }; then
6207 ac_cv_sizeof_void_p=`cat conftest.val`
Guido van Rossumad678af1998-10-02 14:42:15 +00006208else
Martin v. Löwis11437992002-04-12 09:54:03 +00006209 echo "$as_me: program exited with status $ac_status" >&5
6210echo "$as_me: failed program was:" >&5
6211cat conftest.$ac_ext >&5
6212( exit $ac_status )
6213{ { echo "$as_me:$LINENO: error: cannot compute sizeof (void *), 77" >&5
6214echo "$as_me: error: cannot compute sizeof (void *), 77" >&2;}
6215 { (exit 1); exit 1; }; }
6216fi
6217rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6218fi
6219fi
6220rm -f conftest.val
6221else
Guido van Rossumad678af1998-10-02 14:42:15 +00006222 ac_cv_sizeof_void_p=0
6223fi
Guido van Rossumad678af1998-10-02 14:42:15 +00006224fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006225echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
6226echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6
6227cat >>confdefs.h <<_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00006228#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
Martin v. Löwis11437992002-04-12 09:54:03 +00006229_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00006230
6231
Martin v. Löwis11437992002-04-12 09:54:03 +00006232echo "$as_me:$LINENO: checking for char" >&5
6233echo $ECHO_N "checking for char... $ECHO_C" >&6
6234if test "${ac_cv_type_char+set}" = set; then
6235 echo $ECHO_N "(cached) $ECHO_C" >&6
6236else
6237 cat >conftest.$ac_ext <<_ACEOF
6238#line $LINENO "configure"
6239#include "confdefs.h"
6240$ac_includes_default
6241#ifdef F77_DUMMY_MAIN
6242# ifdef __cplusplus
6243 extern "C"
6244# endif
6245 int F77_DUMMY_MAIN() { return 1; }
6246#endif
6247int
6248main ()
6249{
6250if ((char *) 0)
6251 return 0;
6252if (sizeof (char))
6253 return 0;
6254 ;
6255 return 0;
6256}
6257_ACEOF
6258rm -f conftest.$ac_objext
6259if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6260 (eval $ac_compile) 2>&5
6261 ac_status=$?
6262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6263 (exit $ac_status); } &&
6264 { ac_try='test -s conftest.$ac_objext'
6265 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6266 (eval $ac_try) 2>&5
6267 ac_status=$?
6268 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6269 (exit $ac_status); }; }; then
6270 ac_cv_type_char=yes
6271else
6272 echo "$as_me: failed program was:" >&5
6273cat conftest.$ac_ext >&5
6274ac_cv_type_char=no
6275fi
6276rm -f conftest.$ac_objext conftest.$ac_ext
6277fi
6278echo "$as_me:$LINENO: result: $ac_cv_type_char" >&5
6279echo "${ECHO_T}$ac_cv_type_char" >&6
6280
6281echo "$as_me:$LINENO: checking size of char" >&5
6282echo $ECHO_N "checking size of char... $ECHO_C" >&6
6283if test "${ac_cv_sizeof_char+set}" = set; then
6284 echo $ECHO_N "(cached) $ECHO_C" >&6
6285else
6286 if test "$ac_cv_type_char" = yes; then
6287 # The cast to unsigned long works around a bug in the HP C Compiler
6288 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6289 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6290 # This bug is HP SR number 8606223364.
6291 if test "$cross_compiling" = yes; then
6292 # Depending upon the size, compute the lo and hi bounds.
6293cat >conftest.$ac_ext <<_ACEOF
6294#line $LINENO "configure"
6295#include "confdefs.h"
6296$ac_includes_default
6297#ifdef F77_DUMMY_MAIN
6298# ifdef __cplusplus
6299 extern "C"
6300# endif
6301 int F77_DUMMY_MAIN() { return 1; }
6302#endif
6303int
6304main ()
6305{
6306static int test_array [1 - 2 * !(((long) (sizeof (char))) >= 0)];
6307test_array [0] = 0
6308
6309 ;
6310 return 0;
6311}
6312_ACEOF
6313rm -f conftest.$ac_objext
6314if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6315 (eval $ac_compile) 2>&5
6316 ac_status=$?
6317 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6318 (exit $ac_status); } &&
6319 { ac_try='test -s conftest.$ac_objext'
6320 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6321 (eval $ac_try) 2>&5
6322 ac_status=$?
6323 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6324 (exit $ac_status); }; }; then
6325 ac_lo=0 ac_mid=0
6326 while :; do
6327 cat >conftest.$ac_ext <<_ACEOF
6328#line $LINENO "configure"
6329#include "confdefs.h"
6330$ac_includes_default
6331#ifdef F77_DUMMY_MAIN
6332# ifdef __cplusplus
6333 extern "C"
6334# endif
6335 int F77_DUMMY_MAIN() { return 1; }
6336#endif
6337int
6338main ()
6339{
6340static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
6341test_array [0] = 0
6342
6343 ;
6344 return 0;
6345}
6346_ACEOF
6347rm -f conftest.$ac_objext
6348if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6349 (eval $ac_compile) 2>&5
6350 ac_status=$?
6351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6352 (exit $ac_status); } &&
6353 { ac_try='test -s conftest.$ac_objext'
6354 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6355 (eval $ac_try) 2>&5
6356 ac_status=$?
6357 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6358 (exit $ac_status); }; }; then
6359 ac_hi=$ac_mid; break
6360else
6361 echo "$as_me: failed program was:" >&5
6362cat conftest.$ac_ext >&5
6363ac_lo=`expr $ac_mid + 1`
6364 if test $ac_lo -le $ac_mid; then
6365 ac_lo= ac_hi=
6366 break
6367 fi
6368 ac_mid=`expr 2 '*' $ac_mid + 1`
6369fi
6370rm -f conftest.$ac_objext conftest.$ac_ext
6371 done
6372else
6373 echo "$as_me: failed program was:" >&5
6374cat conftest.$ac_ext >&5
6375cat >conftest.$ac_ext <<_ACEOF
6376#line $LINENO "configure"
6377#include "confdefs.h"
6378$ac_includes_default
6379#ifdef F77_DUMMY_MAIN
6380# ifdef __cplusplus
6381 extern "C"
6382# endif
6383 int F77_DUMMY_MAIN() { return 1; }
6384#endif
6385int
6386main ()
6387{
6388static int test_array [1 - 2 * !(((long) (sizeof (char))) < 0)];
6389test_array [0] = 0
6390
6391 ;
6392 return 0;
6393}
6394_ACEOF
6395rm -f conftest.$ac_objext
6396if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6397 (eval $ac_compile) 2>&5
6398 ac_status=$?
6399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6400 (exit $ac_status); } &&
6401 { ac_try='test -s conftest.$ac_objext'
6402 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6403 (eval $ac_try) 2>&5
6404 ac_status=$?
6405 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6406 (exit $ac_status); }; }; then
6407 ac_hi=-1 ac_mid=-1
6408 while :; do
6409 cat >conftest.$ac_ext <<_ACEOF
6410#line $LINENO "configure"
6411#include "confdefs.h"
6412$ac_includes_default
6413#ifdef F77_DUMMY_MAIN
6414# ifdef __cplusplus
6415 extern "C"
6416# endif
6417 int F77_DUMMY_MAIN() { return 1; }
6418#endif
6419int
6420main ()
6421{
6422static int test_array [1 - 2 * !(((long) (sizeof (char))) >= $ac_mid)];
6423test_array [0] = 0
6424
6425 ;
6426 return 0;
6427}
6428_ACEOF
6429rm -f conftest.$ac_objext
6430if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6431 (eval $ac_compile) 2>&5
6432 ac_status=$?
6433 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6434 (exit $ac_status); } &&
6435 { ac_try='test -s conftest.$ac_objext'
6436 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6437 (eval $ac_try) 2>&5
6438 ac_status=$?
6439 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6440 (exit $ac_status); }; }; then
6441 ac_lo=$ac_mid; break
6442else
6443 echo "$as_me: failed program was:" >&5
6444cat conftest.$ac_ext >&5
6445ac_hi=`expr '(' $ac_mid ')' - 1`
6446 if test $ac_mid -le $ac_hi; then
6447 ac_lo= ac_hi=
6448 break
6449 fi
6450 ac_mid=`expr 2 '*' $ac_mid`
6451fi
6452rm -f conftest.$ac_objext conftest.$ac_ext
6453 done
6454else
6455 echo "$as_me: failed program was:" >&5
6456cat conftest.$ac_ext >&5
6457ac_lo= ac_hi=
6458fi
6459rm -f conftest.$ac_objext conftest.$ac_ext
6460fi
6461rm -f conftest.$ac_objext conftest.$ac_ext
6462# Binary search between lo and hi bounds.
6463while test "x$ac_lo" != "x$ac_hi"; do
6464 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6465 cat >conftest.$ac_ext <<_ACEOF
6466#line $LINENO "configure"
6467#include "confdefs.h"
6468$ac_includes_default
6469#ifdef F77_DUMMY_MAIN
6470# ifdef __cplusplus
6471 extern "C"
6472# endif
6473 int F77_DUMMY_MAIN() { return 1; }
6474#endif
6475int
6476main ()
6477{
6478static int test_array [1 - 2 * !(((long) (sizeof (char))) <= $ac_mid)];
6479test_array [0] = 0
6480
6481 ;
6482 return 0;
6483}
6484_ACEOF
6485rm -f conftest.$ac_objext
6486if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6487 (eval $ac_compile) 2>&5
6488 ac_status=$?
6489 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6490 (exit $ac_status); } &&
6491 { ac_try='test -s conftest.$ac_objext'
6492 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6493 (eval $ac_try) 2>&5
6494 ac_status=$?
6495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6496 (exit $ac_status); }; }; then
6497 ac_hi=$ac_mid
6498else
6499 echo "$as_me: failed program was:" >&5
6500cat conftest.$ac_ext >&5
6501ac_lo=`expr '(' $ac_mid ')' + 1`
6502fi
6503rm -f conftest.$ac_objext conftest.$ac_ext
6504done
6505case $ac_lo in
6506?*) ac_cv_sizeof_char=$ac_lo;;
6507'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77" >&5
6508echo "$as_me: error: cannot compute sizeof (char), 77" >&2;}
6509 { (exit 1); exit 1; }; } ;;
6510esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006511else
6512 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006513 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6514echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6515 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006516else
Martin v. Löwis11437992002-04-12 09:54:03 +00006517 cat >conftest.$ac_ext <<_ACEOF
6518#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006519#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006520$ac_includes_default
6521long longval () { return (long) (sizeof (char)); }
6522unsigned long ulongval () { return (long) (sizeof (char)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006523#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006524#include <stdlib.h>
6525#ifdef F77_DUMMY_MAIN
6526# ifdef __cplusplus
6527 extern "C"
6528# endif
6529 int F77_DUMMY_MAIN() { return 1; }
6530#endif
6531int
6532main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006533{
Martin v. Löwis11437992002-04-12 09:54:03 +00006534
6535 FILE *f = fopen ("conftest.val", "w");
6536 if (! f)
6537 exit (1);
6538 if (((long) (sizeof (char))) < 0)
6539 {
6540 long i = longval ();
6541 if (i != ((long) (sizeof (char))))
6542 exit (1);
6543 fprintf (f, "%ld\n", i);
6544 }
6545 else
6546 {
6547 unsigned long i = ulongval ();
6548 if (i != ((long) (sizeof (char))))
6549 exit (1);
6550 fprintf (f, "%lu\n", i);
6551 }
6552 exit (ferror (f) || fclose (f) != 0);
6553
6554 ;
6555 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006556}
Martin v. Löwis11437992002-04-12 09:54:03 +00006557_ACEOF
6558rm -f conftest$ac_exeext
6559if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6560 (eval $ac_link) 2>&5
6561 ac_status=$?
6562 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6563 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6564 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6565 (eval $ac_try) 2>&5
6566 ac_status=$?
6567 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6568 (exit $ac_status); }; }; then
6569 ac_cv_sizeof_char=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006570else
Martin v. Löwis11437992002-04-12 09:54:03 +00006571 echo "$as_me: program exited with status $ac_status" >&5
6572echo "$as_me: failed program was:" >&5
6573cat conftest.$ac_ext >&5
6574( exit $ac_status )
6575{ { echo "$as_me:$LINENO: error: cannot compute sizeof (char), 77" >&5
6576echo "$as_me: error: cannot compute sizeof (char), 77" >&2;}
6577 { (exit 1); exit 1; }; }
6578fi
6579rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6580fi
6581fi
6582rm -f conftest.val
6583else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006584 ac_cv_sizeof_char=0
6585fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00006586fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006587echo "$as_me:$LINENO: result: $ac_cv_sizeof_char" >&5
6588echo "${ECHO_T}$ac_cv_sizeof_char" >&6
6589cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006590#define SIZEOF_CHAR $ac_cv_sizeof_char
Martin v. Löwis11437992002-04-12 09:54:03 +00006591_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006592
6593
Martin v. Löwis11437992002-04-12 09:54:03 +00006594echo "$as_me:$LINENO: checking for short" >&5
6595echo $ECHO_N "checking for short... $ECHO_C" >&6
6596if test "${ac_cv_type_short+set}" = set; then
6597 echo $ECHO_N "(cached) $ECHO_C" >&6
6598else
6599 cat >conftest.$ac_ext <<_ACEOF
6600#line $LINENO "configure"
6601#include "confdefs.h"
6602$ac_includes_default
6603#ifdef F77_DUMMY_MAIN
6604# ifdef __cplusplus
6605 extern "C"
6606# endif
6607 int F77_DUMMY_MAIN() { return 1; }
6608#endif
6609int
6610main ()
6611{
6612if ((short *) 0)
6613 return 0;
6614if (sizeof (short))
6615 return 0;
6616 ;
6617 return 0;
6618}
6619_ACEOF
6620rm -f conftest.$ac_objext
6621if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6622 (eval $ac_compile) 2>&5
6623 ac_status=$?
6624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6625 (exit $ac_status); } &&
6626 { ac_try='test -s conftest.$ac_objext'
6627 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6628 (eval $ac_try) 2>&5
6629 ac_status=$?
6630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6631 (exit $ac_status); }; }; then
6632 ac_cv_type_short=yes
6633else
6634 echo "$as_me: failed program was:" >&5
6635cat conftest.$ac_ext >&5
6636ac_cv_type_short=no
6637fi
6638rm -f conftest.$ac_objext conftest.$ac_ext
6639fi
6640echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
6641echo "${ECHO_T}$ac_cv_type_short" >&6
6642
6643echo "$as_me:$LINENO: checking size of short" >&5
6644echo $ECHO_N "checking size of short... $ECHO_C" >&6
6645if test "${ac_cv_sizeof_short+set}" = set; then
6646 echo $ECHO_N "(cached) $ECHO_C" >&6
6647else
6648 if test "$ac_cv_type_short" = yes; then
6649 # The cast to unsigned long works around a bug in the HP C Compiler
6650 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
6651 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
6652 # This bug is HP SR number 8606223364.
6653 if test "$cross_compiling" = yes; then
6654 # Depending upon the size, compute the lo and hi bounds.
6655cat >conftest.$ac_ext <<_ACEOF
6656#line $LINENO "configure"
6657#include "confdefs.h"
6658$ac_includes_default
6659#ifdef F77_DUMMY_MAIN
6660# ifdef __cplusplus
6661 extern "C"
6662# endif
6663 int F77_DUMMY_MAIN() { return 1; }
6664#endif
6665int
6666main ()
6667{
6668static int test_array [1 - 2 * !(((long) (sizeof (short))) >= 0)];
6669test_array [0] = 0
6670
6671 ;
6672 return 0;
6673}
6674_ACEOF
6675rm -f conftest.$ac_objext
6676if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6677 (eval $ac_compile) 2>&5
6678 ac_status=$?
6679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6680 (exit $ac_status); } &&
6681 { ac_try='test -s conftest.$ac_objext'
6682 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6683 (eval $ac_try) 2>&5
6684 ac_status=$?
6685 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6686 (exit $ac_status); }; }; then
6687 ac_lo=0 ac_mid=0
6688 while :; do
6689 cat >conftest.$ac_ext <<_ACEOF
6690#line $LINENO "configure"
6691#include "confdefs.h"
6692$ac_includes_default
6693#ifdef F77_DUMMY_MAIN
6694# ifdef __cplusplus
6695 extern "C"
6696# endif
6697 int F77_DUMMY_MAIN() { return 1; }
6698#endif
6699int
6700main ()
6701{
6702static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
6703test_array [0] = 0
6704
6705 ;
6706 return 0;
6707}
6708_ACEOF
6709rm -f conftest.$ac_objext
6710if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6711 (eval $ac_compile) 2>&5
6712 ac_status=$?
6713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6714 (exit $ac_status); } &&
6715 { ac_try='test -s conftest.$ac_objext'
6716 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6717 (eval $ac_try) 2>&5
6718 ac_status=$?
6719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6720 (exit $ac_status); }; }; then
6721 ac_hi=$ac_mid; break
6722else
6723 echo "$as_me: failed program was:" >&5
6724cat conftest.$ac_ext >&5
6725ac_lo=`expr $ac_mid + 1`
6726 if test $ac_lo -le $ac_mid; then
6727 ac_lo= ac_hi=
6728 break
6729 fi
6730 ac_mid=`expr 2 '*' $ac_mid + 1`
6731fi
6732rm -f conftest.$ac_objext conftest.$ac_ext
6733 done
6734else
6735 echo "$as_me: failed program was:" >&5
6736cat conftest.$ac_ext >&5
6737cat >conftest.$ac_ext <<_ACEOF
6738#line $LINENO "configure"
6739#include "confdefs.h"
6740$ac_includes_default
6741#ifdef F77_DUMMY_MAIN
6742# ifdef __cplusplus
6743 extern "C"
6744# endif
6745 int F77_DUMMY_MAIN() { return 1; }
6746#endif
6747int
6748main ()
6749{
6750static int test_array [1 - 2 * !(((long) (sizeof (short))) < 0)];
6751test_array [0] = 0
6752
6753 ;
6754 return 0;
6755}
6756_ACEOF
6757rm -f conftest.$ac_objext
6758if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6759 (eval $ac_compile) 2>&5
6760 ac_status=$?
6761 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6762 (exit $ac_status); } &&
6763 { ac_try='test -s conftest.$ac_objext'
6764 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6765 (eval $ac_try) 2>&5
6766 ac_status=$?
6767 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6768 (exit $ac_status); }; }; then
6769 ac_hi=-1 ac_mid=-1
6770 while :; do
6771 cat >conftest.$ac_ext <<_ACEOF
6772#line $LINENO "configure"
6773#include "confdefs.h"
6774$ac_includes_default
6775#ifdef F77_DUMMY_MAIN
6776# ifdef __cplusplus
6777 extern "C"
6778# endif
6779 int F77_DUMMY_MAIN() { return 1; }
6780#endif
6781int
6782main ()
6783{
6784static int test_array [1 - 2 * !(((long) (sizeof (short))) >= $ac_mid)];
6785test_array [0] = 0
6786
6787 ;
6788 return 0;
6789}
6790_ACEOF
6791rm -f conftest.$ac_objext
6792if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6793 (eval $ac_compile) 2>&5
6794 ac_status=$?
6795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6796 (exit $ac_status); } &&
6797 { ac_try='test -s conftest.$ac_objext'
6798 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6799 (eval $ac_try) 2>&5
6800 ac_status=$?
6801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6802 (exit $ac_status); }; }; then
6803 ac_lo=$ac_mid; break
6804else
6805 echo "$as_me: failed program was:" >&5
6806cat conftest.$ac_ext >&5
6807ac_hi=`expr '(' $ac_mid ')' - 1`
6808 if test $ac_mid -le $ac_hi; then
6809 ac_lo= ac_hi=
6810 break
6811 fi
6812 ac_mid=`expr 2 '*' $ac_mid`
6813fi
6814rm -f conftest.$ac_objext conftest.$ac_ext
6815 done
6816else
6817 echo "$as_me: failed program was:" >&5
6818cat conftest.$ac_ext >&5
6819ac_lo= ac_hi=
6820fi
6821rm -f conftest.$ac_objext conftest.$ac_ext
6822fi
6823rm -f conftest.$ac_objext conftest.$ac_ext
6824# Binary search between lo and hi bounds.
6825while test "x$ac_lo" != "x$ac_hi"; do
6826 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
6827 cat >conftest.$ac_ext <<_ACEOF
6828#line $LINENO "configure"
6829#include "confdefs.h"
6830$ac_includes_default
6831#ifdef F77_DUMMY_MAIN
6832# ifdef __cplusplus
6833 extern "C"
6834# endif
6835 int F77_DUMMY_MAIN() { return 1; }
6836#endif
6837int
6838main ()
6839{
6840static int test_array [1 - 2 * !(((long) (sizeof (short))) <= $ac_mid)];
6841test_array [0] = 0
6842
6843 ;
6844 return 0;
6845}
6846_ACEOF
6847rm -f conftest.$ac_objext
6848if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6849 (eval $ac_compile) 2>&5
6850 ac_status=$?
6851 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6852 (exit $ac_status); } &&
6853 { ac_try='test -s conftest.$ac_objext'
6854 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6855 (eval $ac_try) 2>&5
6856 ac_status=$?
6857 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6858 (exit $ac_status); }; }; then
6859 ac_hi=$ac_mid
6860else
6861 echo "$as_me: failed program was:" >&5
6862cat conftest.$ac_ext >&5
6863ac_lo=`expr '(' $ac_mid ')' + 1`
6864fi
6865rm -f conftest.$ac_objext conftest.$ac_ext
6866done
6867case $ac_lo in
6868?*) ac_cv_sizeof_short=$ac_lo;;
6869'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77" >&5
6870echo "$as_me: error: cannot compute sizeof (short), 77" >&2;}
6871 { (exit 1); exit 1; }; } ;;
6872esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00006873else
6874 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006875 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
6876echo "$as_me: error: cannot run test program while cross compiling" >&2;}
6877 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00006878else
Martin v. Löwis11437992002-04-12 09:54:03 +00006879 cat >conftest.$ac_ext <<_ACEOF
6880#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00006881#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00006882$ac_includes_default
6883long longval () { return (long) (sizeof (short)); }
6884unsigned long ulongval () { return (long) (sizeof (short)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00006885#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006886#include <stdlib.h>
6887#ifdef F77_DUMMY_MAIN
6888# ifdef __cplusplus
6889 extern "C"
6890# endif
6891 int F77_DUMMY_MAIN() { return 1; }
6892#endif
6893int
6894main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00006895{
Martin v. Löwis11437992002-04-12 09:54:03 +00006896
6897 FILE *f = fopen ("conftest.val", "w");
6898 if (! f)
6899 exit (1);
6900 if (((long) (sizeof (short))) < 0)
6901 {
6902 long i = longval ();
6903 if (i != ((long) (sizeof (short))))
6904 exit (1);
6905 fprintf (f, "%ld\n", i);
6906 }
6907 else
6908 {
6909 unsigned long i = ulongval ();
6910 if (i != ((long) (sizeof (short))))
6911 exit (1);
6912 fprintf (f, "%lu\n", i);
6913 }
6914 exit (ferror (f) || fclose (f) != 0);
6915
6916 ;
6917 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00006918}
Martin v. Löwis11437992002-04-12 09:54:03 +00006919_ACEOF
6920rm -f conftest$ac_exeext
6921if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6922 (eval $ac_link) 2>&5
6923 ac_status=$?
6924 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6925 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
6926 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6927 (eval $ac_try) 2>&5
6928 ac_status=$?
6929 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6930 (exit $ac_status); }; }; then
6931 ac_cv_sizeof_short=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00006932else
Martin v. Löwis11437992002-04-12 09:54:03 +00006933 echo "$as_me: program exited with status $ac_status" >&5
6934echo "$as_me: failed program was:" >&5
6935cat conftest.$ac_ext >&5
6936( exit $ac_status )
6937{ { echo "$as_me:$LINENO: error: cannot compute sizeof (short), 77" >&5
6938echo "$as_me: error: cannot compute sizeof (short), 77" >&2;}
6939 { (exit 1); exit 1; }; }
6940fi
6941rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
6942fi
6943fi
6944rm -f conftest.val
6945else
Guido van Rossumef2255b2000-03-10 22:30:29 +00006946 ac_cv_sizeof_short=0
6947fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00006948fi
Martin v. Löwis11437992002-04-12 09:54:03 +00006949echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
6950echo "${ECHO_T}$ac_cv_sizeof_short" >&6
6951cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006952#define SIZEOF_SHORT $ac_cv_sizeof_short
Martin v. Löwis11437992002-04-12 09:54:03 +00006953_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00006954
6955
Martin v. Löwis11437992002-04-12 09:54:03 +00006956echo "$as_me:$LINENO: checking for float" >&5
6957echo $ECHO_N "checking for float... $ECHO_C" >&6
6958if test "${ac_cv_type_float+set}" = set; then
6959 echo $ECHO_N "(cached) $ECHO_C" >&6
6960else
6961 cat >conftest.$ac_ext <<_ACEOF
6962#line $LINENO "configure"
6963#include "confdefs.h"
6964$ac_includes_default
6965#ifdef F77_DUMMY_MAIN
6966# ifdef __cplusplus
6967 extern "C"
6968# endif
6969 int F77_DUMMY_MAIN() { return 1; }
6970#endif
6971int
6972main ()
6973{
6974if ((float *) 0)
6975 return 0;
6976if (sizeof (float))
6977 return 0;
6978 ;
6979 return 0;
6980}
6981_ACEOF
6982rm -f conftest.$ac_objext
6983if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6984 (eval $ac_compile) 2>&5
6985 ac_status=$?
6986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6987 (exit $ac_status); } &&
6988 { ac_try='test -s conftest.$ac_objext'
6989 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6990 (eval $ac_try) 2>&5
6991 ac_status=$?
6992 echo "$as_me:$LINENO: \$? = $ac_status" >&5
6993 (exit $ac_status); }; }; then
6994 ac_cv_type_float=yes
6995else
6996 echo "$as_me: failed program was:" >&5
6997cat conftest.$ac_ext >&5
6998ac_cv_type_float=no
6999fi
7000rm -f conftest.$ac_objext conftest.$ac_ext
7001fi
7002echo "$as_me:$LINENO: result: $ac_cv_type_float" >&5
7003echo "${ECHO_T}$ac_cv_type_float" >&6
7004
7005echo "$as_me:$LINENO: checking size of float" >&5
7006echo $ECHO_N "checking size of float... $ECHO_C" >&6
7007if test "${ac_cv_sizeof_float+set}" = set; then
7008 echo $ECHO_N "(cached) $ECHO_C" >&6
7009else
7010 if test "$ac_cv_type_float" = yes; then
7011 # The cast to unsigned long works around a bug in the HP C Compiler
7012 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7013 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7014 # This bug is HP SR number 8606223364.
7015 if test "$cross_compiling" = yes; then
7016 # Depending upon the size, compute the lo and hi bounds.
7017cat >conftest.$ac_ext <<_ACEOF
7018#line $LINENO "configure"
7019#include "confdefs.h"
7020$ac_includes_default
7021#ifdef F77_DUMMY_MAIN
7022# ifdef __cplusplus
7023 extern "C"
7024# endif
7025 int F77_DUMMY_MAIN() { return 1; }
7026#endif
7027int
7028main ()
7029{
7030static int test_array [1 - 2 * !(((long) (sizeof (float))) >= 0)];
7031test_array [0] = 0
7032
7033 ;
7034 return 0;
7035}
7036_ACEOF
7037rm -f conftest.$ac_objext
7038if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7039 (eval $ac_compile) 2>&5
7040 ac_status=$?
7041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7042 (exit $ac_status); } &&
7043 { ac_try='test -s conftest.$ac_objext'
7044 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7045 (eval $ac_try) 2>&5
7046 ac_status=$?
7047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7048 (exit $ac_status); }; }; then
7049 ac_lo=0 ac_mid=0
7050 while :; do
7051 cat >conftest.$ac_ext <<_ACEOF
7052#line $LINENO "configure"
7053#include "confdefs.h"
7054$ac_includes_default
7055#ifdef F77_DUMMY_MAIN
7056# ifdef __cplusplus
7057 extern "C"
7058# endif
7059 int F77_DUMMY_MAIN() { return 1; }
7060#endif
7061int
7062main ()
7063{
7064static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
7065test_array [0] = 0
7066
7067 ;
7068 return 0;
7069}
7070_ACEOF
7071rm -f conftest.$ac_objext
7072if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7073 (eval $ac_compile) 2>&5
7074 ac_status=$?
7075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7076 (exit $ac_status); } &&
7077 { ac_try='test -s conftest.$ac_objext'
7078 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7079 (eval $ac_try) 2>&5
7080 ac_status=$?
7081 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7082 (exit $ac_status); }; }; then
7083 ac_hi=$ac_mid; break
7084else
7085 echo "$as_me: failed program was:" >&5
7086cat conftest.$ac_ext >&5
7087ac_lo=`expr $ac_mid + 1`
7088 if test $ac_lo -le $ac_mid; then
7089 ac_lo= ac_hi=
7090 break
7091 fi
7092 ac_mid=`expr 2 '*' $ac_mid + 1`
7093fi
7094rm -f conftest.$ac_objext conftest.$ac_ext
7095 done
7096else
7097 echo "$as_me: failed program was:" >&5
7098cat conftest.$ac_ext >&5
7099cat >conftest.$ac_ext <<_ACEOF
7100#line $LINENO "configure"
7101#include "confdefs.h"
7102$ac_includes_default
7103#ifdef F77_DUMMY_MAIN
7104# ifdef __cplusplus
7105 extern "C"
7106# endif
7107 int F77_DUMMY_MAIN() { return 1; }
7108#endif
7109int
7110main ()
7111{
7112static int test_array [1 - 2 * !(((long) (sizeof (float))) < 0)];
7113test_array [0] = 0
7114
7115 ;
7116 return 0;
7117}
7118_ACEOF
7119rm -f conftest.$ac_objext
7120if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7121 (eval $ac_compile) 2>&5
7122 ac_status=$?
7123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7124 (exit $ac_status); } &&
7125 { ac_try='test -s conftest.$ac_objext'
7126 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7127 (eval $ac_try) 2>&5
7128 ac_status=$?
7129 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7130 (exit $ac_status); }; }; then
7131 ac_hi=-1 ac_mid=-1
7132 while :; do
7133 cat >conftest.$ac_ext <<_ACEOF
7134#line $LINENO "configure"
7135#include "confdefs.h"
7136$ac_includes_default
7137#ifdef F77_DUMMY_MAIN
7138# ifdef __cplusplus
7139 extern "C"
7140# endif
7141 int F77_DUMMY_MAIN() { return 1; }
7142#endif
7143int
7144main ()
7145{
7146static int test_array [1 - 2 * !(((long) (sizeof (float))) >= $ac_mid)];
7147test_array [0] = 0
7148
7149 ;
7150 return 0;
7151}
7152_ACEOF
7153rm -f conftest.$ac_objext
7154if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7155 (eval $ac_compile) 2>&5
7156 ac_status=$?
7157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7158 (exit $ac_status); } &&
7159 { ac_try='test -s conftest.$ac_objext'
7160 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7161 (eval $ac_try) 2>&5
7162 ac_status=$?
7163 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7164 (exit $ac_status); }; }; then
7165 ac_lo=$ac_mid; break
7166else
7167 echo "$as_me: failed program was:" >&5
7168cat conftest.$ac_ext >&5
7169ac_hi=`expr '(' $ac_mid ')' - 1`
7170 if test $ac_mid -le $ac_hi; then
7171 ac_lo= ac_hi=
7172 break
7173 fi
7174 ac_mid=`expr 2 '*' $ac_mid`
7175fi
7176rm -f conftest.$ac_objext conftest.$ac_ext
7177 done
7178else
7179 echo "$as_me: failed program was:" >&5
7180cat conftest.$ac_ext >&5
7181ac_lo= ac_hi=
7182fi
7183rm -f conftest.$ac_objext conftest.$ac_ext
7184fi
7185rm -f conftest.$ac_objext conftest.$ac_ext
7186# Binary search between lo and hi bounds.
7187while test "x$ac_lo" != "x$ac_hi"; do
7188 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7189 cat >conftest.$ac_ext <<_ACEOF
7190#line $LINENO "configure"
7191#include "confdefs.h"
7192$ac_includes_default
7193#ifdef F77_DUMMY_MAIN
7194# ifdef __cplusplus
7195 extern "C"
7196# endif
7197 int F77_DUMMY_MAIN() { return 1; }
7198#endif
7199int
7200main ()
7201{
7202static int test_array [1 - 2 * !(((long) (sizeof (float))) <= $ac_mid)];
7203test_array [0] = 0
7204
7205 ;
7206 return 0;
7207}
7208_ACEOF
7209rm -f conftest.$ac_objext
7210if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7211 (eval $ac_compile) 2>&5
7212 ac_status=$?
7213 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7214 (exit $ac_status); } &&
7215 { ac_try='test -s conftest.$ac_objext'
7216 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7217 (eval $ac_try) 2>&5
7218 ac_status=$?
7219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7220 (exit $ac_status); }; }; then
7221 ac_hi=$ac_mid
7222else
7223 echo "$as_me: failed program was:" >&5
7224cat conftest.$ac_ext >&5
7225ac_lo=`expr '(' $ac_mid ')' + 1`
7226fi
7227rm -f conftest.$ac_objext conftest.$ac_ext
7228done
7229case $ac_lo in
7230?*) ac_cv_sizeof_float=$ac_lo;;
7231'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77" >&5
7232echo "$as_me: error: cannot compute sizeof (float), 77" >&2;}
7233 { (exit 1); exit 1; }; } ;;
7234esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007235else
7236 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007237 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7238echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7239 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007240else
Martin v. Löwis11437992002-04-12 09:54:03 +00007241 cat >conftest.$ac_ext <<_ACEOF
7242#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00007243#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007244$ac_includes_default
7245long longval () { return (long) (sizeof (float)); }
7246unsigned long ulongval () { return (long) (sizeof (float)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007247#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007248#include <stdlib.h>
7249#ifdef F77_DUMMY_MAIN
7250# ifdef __cplusplus
7251 extern "C"
7252# endif
7253 int F77_DUMMY_MAIN() { return 1; }
7254#endif
7255int
7256main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007257{
Martin v. Löwis11437992002-04-12 09:54:03 +00007258
7259 FILE *f = fopen ("conftest.val", "w");
7260 if (! f)
7261 exit (1);
7262 if (((long) (sizeof (float))) < 0)
7263 {
7264 long i = longval ();
7265 if (i != ((long) (sizeof (float))))
7266 exit (1);
7267 fprintf (f, "%ld\n", i);
7268 }
7269 else
7270 {
7271 unsigned long i = ulongval ();
7272 if (i != ((long) (sizeof (float))))
7273 exit (1);
7274 fprintf (f, "%lu\n", i);
7275 }
7276 exit (ferror (f) || fclose (f) != 0);
7277
7278 ;
7279 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007280}
Martin v. Löwis11437992002-04-12 09:54:03 +00007281_ACEOF
7282rm -f conftest$ac_exeext
7283if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7284 (eval $ac_link) 2>&5
7285 ac_status=$?
7286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7287 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7288 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7289 (eval $ac_try) 2>&5
7290 ac_status=$?
7291 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7292 (exit $ac_status); }; }; then
7293 ac_cv_sizeof_float=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007294else
Martin v. Löwis11437992002-04-12 09:54:03 +00007295 echo "$as_me: program exited with status $ac_status" >&5
7296echo "$as_me: failed program was:" >&5
7297cat conftest.$ac_ext >&5
7298( exit $ac_status )
7299{ { echo "$as_me:$LINENO: error: cannot compute sizeof (float), 77" >&5
7300echo "$as_me: error: cannot compute sizeof (float), 77" >&2;}
7301 { (exit 1); exit 1; }; }
7302fi
7303rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7304fi
7305fi
7306rm -f conftest.val
7307else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007308 ac_cv_sizeof_float=0
7309fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007310fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007311echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5
7312echo "${ECHO_T}$ac_cv_sizeof_float" >&6
7313cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007314#define SIZEOF_FLOAT $ac_cv_sizeof_float
Martin v. Löwis11437992002-04-12 09:54:03 +00007315_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007316
7317
Martin v. Löwis11437992002-04-12 09:54:03 +00007318echo "$as_me:$LINENO: checking for double" >&5
7319echo $ECHO_N "checking for double... $ECHO_C" >&6
7320if test "${ac_cv_type_double+set}" = set; then
7321 echo $ECHO_N "(cached) $ECHO_C" >&6
7322else
7323 cat >conftest.$ac_ext <<_ACEOF
7324#line $LINENO "configure"
7325#include "confdefs.h"
7326$ac_includes_default
7327#ifdef F77_DUMMY_MAIN
7328# ifdef __cplusplus
7329 extern "C"
7330# endif
7331 int F77_DUMMY_MAIN() { return 1; }
7332#endif
7333int
7334main ()
7335{
7336if ((double *) 0)
7337 return 0;
7338if (sizeof (double))
7339 return 0;
7340 ;
7341 return 0;
7342}
7343_ACEOF
7344rm -f conftest.$ac_objext
7345if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7346 (eval $ac_compile) 2>&5
7347 ac_status=$?
7348 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7349 (exit $ac_status); } &&
7350 { ac_try='test -s conftest.$ac_objext'
7351 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7352 (eval $ac_try) 2>&5
7353 ac_status=$?
7354 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7355 (exit $ac_status); }; }; then
7356 ac_cv_type_double=yes
7357else
7358 echo "$as_me: failed program was:" >&5
7359cat conftest.$ac_ext >&5
7360ac_cv_type_double=no
7361fi
7362rm -f conftest.$ac_objext conftest.$ac_ext
7363fi
7364echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
7365echo "${ECHO_T}$ac_cv_type_double" >&6
7366
7367echo "$as_me:$LINENO: checking size of double" >&5
7368echo $ECHO_N "checking size of double... $ECHO_C" >&6
7369if test "${ac_cv_sizeof_double+set}" = set; then
7370 echo $ECHO_N "(cached) $ECHO_C" >&6
7371else
7372 if test "$ac_cv_type_double" = yes; then
7373 # The cast to unsigned long works around a bug in the HP C Compiler
7374 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7375 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7376 # This bug is HP SR number 8606223364.
7377 if test "$cross_compiling" = yes; then
7378 # Depending upon the size, compute the lo and hi bounds.
7379cat >conftest.$ac_ext <<_ACEOF
7380#line $LINENO "configure"
7381#include "confdefs.h"
7382$ac_includes_default
7383#ifdef F77_DUMMY_MAIN
7384# ifdef __cplusplus
7385 extern "C"
7386# endif
7387 int F77_DUMMY_MAIN() { return 1; }
7388#endif
7389int
7390main ()
7391{
7392static int test_array [1 - 2 * !(((long) (sizeof (double))) >= 0)];
7393test_array [0] = 0
7394
7395 ;
7396 return 0;
7397}
7398_ACEOF
7399rm -f conftest.$ac_objext
7400if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7401 (eval $ac_compile) 2>&5
7402 ac_status=$?
7403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7404 (exit $ac_status); } &&
7405 { ac_try='test -s conftest.$ac_objext'
7406 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7407 (eval $ac_try) 2>&5
7408 ac_status=$?
7409 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7410 (exit $ac_status); }; }; then
7411 ac_lo=0 ac_mid=0
7412 while :; do
7413 cat >conftest.$ac_ext <<_ACEOF
7414#line $LINENO "configure"
7415#include "confdefs.h"
7416$ac_includes_default
7417#ifdef F77_DUMMY_MAIN
7418# ifdef __cplusplus
7419 extern "C"
7420# endif
7421 int F77_DUMMY_MAIN() { return 1; }
7422#endif
7423int
7424main ()
7425{
7426static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
7427test_array [0] = 0
7428
7429 ;
7430 return 0;
7431}
7432_ACEOF
7433rm -f conftest.$ac_objext
7434if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7435 (eval $ac_compile) 2>&5
7436 ac_status=$?
7437 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7438 (exit $ac_status); } &&
7439 { ac_try='test -s conftest.$ac_objext'
7440 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7441 (eval $ac_try) 2>&5
7442 ac_status=$?
7443 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7444 (exit $ac_status); }; }; then
7445 ac_hi=$ac_mid; break
7446else
7447 echo "$as_me: failed program was:" >&5
7448cat conftest.$ac_ext >&5
7449ac_lo=`expr $ac_mid + 1`
7450 if test $ac_lo -le $ac_mid; then
7451 ac_lo= ac_hi=
7452 break
7453 fi
7454 ac_mid=`expr 2 '*' $ac_mid + 1`
7455fi
7456rm -f conftest.$ac_objext conftest.$ac_ext
7457 done
7458else
7459 echo "$as_me: failed program was:" >&5
7460cat conftest.$ac_ext >&5
7461cat >conftest.$ac_ext <<_ACEOF
7462#line $LINENO "configure"
7463#include "confdefs.h"
7464$ac_includes_default
7465#ifdef F77_DUMMY_MAIN
7466# ifdef __cplusplus
7467 extern "C"
7468# endif
7469 int F77_DUMMY_MAIN() { return 1; }
7470#endif
7471int
7472main ()
7473{
7474static int test_array [1 - 2 * !(((long) (sizeof (double))) < 0)];
7475test_array [0] = 0
7476
7477 ;
7478 return 0;
7479}
7480_ACEOF
7481rm -f conftest.$ac_objext
7482if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7483 (eval $ac_compile) 2>&5
7484 ac_status=$?
7485 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7486 (exit $ac_status); } &&
7487 { ac_try='test -s conftest.$ac_objext'
7488 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7489 (eval $ac_try) 2>&5
7490 ac_status=$?
7491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7492 (exit $ac_status); }; }; then
7493 ac_hi=-1 ac_mid=-1
7494 while :; do
7495 cat >conftest.$ac_ext <<_ACEOF
7496#line $LINENO "configure"
7497#include "confdefs.h"
7498$ac_includes_default
7499#ifdef F77_DUMMY_MAIN
7500# ifdef __cplusplus
7501 extern "C"
7502# endif
7503 int F77_DUMMY_MAIN() { return 1; }
7504#endif
7505int
7506main ()
7507{
7508static int test_array [1 - 2 * !(((long) (sizeof (double))) >= $ac_mid)];
7509test_array [0] = 0
7510
7511 ;
7512 return 0;
7513}
7514_ACEOF
7515rm -f conftest.$ac_objext
7516if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7517 (eval $ac_compile) 2>&5
7518 ac_status=$?
7519 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7520 (exit $ac_status); } &&
7521 { ac_try='test -s conftest.$ac_objext'
7522 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7523 (eval $ac_try) 2>&5
7524 ac_status=$?
7525 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7526 (exit $ac_status); }; }; then
7527 ac_lo=$ac_mid; break
7528else
7529 echo "$as_me: failed program was:" >&5
7530cat conftest.$ac_ext >&5
7531ac_hi=`expr '(' $ac_mid ')' - 1`
7532 if test $ac_mid -le $ac_hi; then
7533 ac_lo= ac_hi=
7534 break
7535 fi
7536 ac_mid=`expr 2 '*' $ac_mid`
7537fi
7538rm -f conftest.$ac_objext conftest.$ac_ext
7539 done
7540else
7541 echo "$as_me: failed program was:" >&5
7542cat conftest.$ac_ext >&5
7543ac_lo= ac_hi=
7544fi
7545rm -f conftest.$ac_objext conftest.$ac_ext
7546fi
7547rm -f conftest.$ac_objext conftest.$ac_ext
7548# Binary search between lo and hi bounds.
7549while test "x$ac_lo" != "x$ac_hi"; do
7550 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7551 cat >conftest.$ac_ext <<_ACEOF
7552#line $LINENO "configure"
7553#include "confdefs.h"
7554$ac_includes_default
7555#ifdef F77_DUMMY_MAIN
7556# ifdef __cplusplus
7557 extern "C"
7558# endif
7559 int F77_DUMMY_MAIN() { return 1; }
7560#endif
7561int
7562main ()
7563{
7564static int test_array [1 - 2 * !(((long) (sizeof (double))) <= $ac_mid)];
7565test_array [0] = 0
7566
7567 ;
7568 return 0;
7569}
7570_ACEOF
7571rm -f conftest.$ac_objext
7572if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7573 (eval $ac_compile) 2>&5
7574 ac_status=$?
7575 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7576 (exit $ac_status); } &&
7577 { ac_try='test -s conftest.$ac_objext'
7578 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7579 (eval $ac_try) 2>&5
7580 ac_status=$?
7581 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7582 (exit $ac_status); }; }; then
7583 ac_hi=$ac_mid
7584else
7585 echo "$as_me: failed program was:" >&5
7586cat conftest.$ac_ext >&5
7587ac_lo=`expr '(' $ac_mid ')' + 1`
7588fi
7589rm -f conftest.$ac_objext conftest.$ac_ext
7590done
7591case $ac_lo in
7592?*) ac_cv_sizeof_double=$ac_lo;;
7593'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77" >&5
7594echo "$as_me: error: cannot compute sizeof (double), 77" >&2;}
7595 { (exit 1); exit 1; }; } ;;
7596esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00007597else
7598 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007599 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7600echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7601 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +00007602else
Martin v. Löwis11437992002-04-12 09:54:03 +00007603 cat >conftest.$ac_ext <<_ACEOF
7604#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +00007605#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007606$ac_includes_default
7607long longval () { return (long) (sizeof (double)); }
7608unsigned long ulongval () { return (long) (sizeof (double)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007609#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007610#include <stdlib.h>
7611#ifdef F77_DUMMY_MAIN
7612# ifdef __cplusplus
7613 extern "C"
7614# endif
7615 int F77_DUMMY_MAIN() { return 1; }
7616#endif
7617int
7618main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00007619{
Martin v. Löwis11437992002-04-12 09:54:03 +00007620
7621 FILE *f = fopen ("conftest.val", "w");
7622 if (! f)
7623 exit (1);
7624 if (((long) (sizeof (double))) < 0)
7625 {
7626 long i = longval ();
7627 if (i != ((long) (sizeof (double))))
7628 exit (1);
7629 fprintf (f, "%ld\n", i);
7630 }
7631 else
7632 {
7633 unsigned long i = ulongval ();
7634 if (i != ((long) (sizeof (double))))
7635 exit (1);
7636 fprintf (f, "%lu\n", i);
7637 }
7638 exit (ferror (f) || fclose (f) != 0);
7639
7640 ;
7641 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00007642}
Martin v. Löwis11437992002-04-12 09:54:03 +00007643_ACEOF
7644rm -f conftest$ac_exeext
7645if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7646 (eval $ac_link) 2>&5
7647 ac_status=$?
7648 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7649 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7650 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7651 (eval $ac_try) 2>&5
7652 ac_status=$?
7653 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7654 (exit $ac_status); }; }; then
7655 ac_cv_sizeof_double=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00007656else
Martin v. Löwis11437992002-04-12 09:54:03 +00007657 echo "$as_me: program exited with status $ac_status" >&5
7658echo "$as_me: failed program was:" >&5
7659cat conftest.$ac_ext >&5
7660( exit $ac_status )
7661{ { echo "$as_me:$LINENO: error: cannot compute sizeof (double), 77" >&5
7662echo "$as_me: error: cannot compute sizeof (double), 77" >&2;}
7663 { (exit 1); exit 1; }; }
7664fi
7665rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7666fi
7667fi
7668rm -f conftest.val
7669else
Guido van Rossumef2255b2000-03-10 22:30:29 +00007670 ac_cv_sizeof_double=0
7671fi
Guido van Rossumef2255b2000-03-10 22:30:29 +00007672fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007673echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5
7674echo "${ECHO_T}$ac_cv_sizeof_double" >&6
7675cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007676#define SIZEOF_DOUBLE $ac_cv_sizeof_double
Martin v. Löwis11437992002-04-12 09:54:03 +00007677_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00007678
7679
Martin v. Löwis11437992002-04-12 09:54:03 +00007680echo "$as_me:$LINENO: checking for fpos_t" >&5
7681echo $ECHO_N "checking for fpos_t... $ECHO_C" >&6
7682if test "${ac_cv_type_fpos_t+set}" = set; then
7683 echo $ECHO_N "(cached) $ECHO_C" >&6
7684else
7685 cat >conftest.$ac_ext <<_ACEOF
7686#line $LINENO "configure"
7687#include "confdefs.h"
7688$ac_includes_default
7689#ifdef F77_DUMMY_MAIN
7690# ifdef __cplusplus
7691 extern "C"
7692# endif
7693 int F77_DUMMY_MAIN() { return 1; }
7694#endif
7695int
7696main ()
7697{
7698if ((fpos_t *) 0)
7699 return 0;
7700if (sizeof (fpos_t))
7701 return 0;
7702 ;
7703 return 0;
7704}
7705_ACEOF
7706rm -f conftest.$ac_objext
7707if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7708 (eval $ac_compile) 2>&5
7709 ac_status=$?
7710 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7711 (exit $ac_status); } &&
7712 { ac_try='test -s conftest.$ac_objext'
7713 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7714 (eval $ac_try) 2>&5
7715 ac_status=$?
7716 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7717 (exit $ac_status); }; }; then
7718 ac_cv_type_fpos_t=yes
7719else
7720 echo "$as_me: failed program was:" >&5
7721cat conftest.$ac_ext >&5
7722ac_cv_type_fpos_t=no
7723fi
7724rm -f conftest.$ac_objext conftest.$ac_ext
7725fi
7726echo "$as_me:$LINENO: result: $ac_cv_type_fpos_t" >&5
7727echo "${ECHO_T}$ac_cv_type_fpos_t" >&6
7728
7729echo "$as_me:$LINENO: checking size of fpos_t" >&5
7730echo $ECHO_N "checking size of fpos_t... $ECHO_C" >&6
7731if test "${ac_cv_sizeof_fpos_t+set}" = set; then
7732 echo $ECHO_N "(cached) $ECHO_C" >&6
7733else
7734 if test "$ac_cv_type_fpos_t" = yes; then
7735 # The cast to unsigned long works around a bug in the HP C Compiler
7736 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7737 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7738 # This bug is HP SR number 8606223364.
7739 if test "$cross_compiling" = yes; then
7740 # Depending upon the size, compute the lo and hi bounds.
7741cat >conftest.$ac_ext <<_ACEOF
7742#line $LINENO "configure"
7743#include "confdefs.h"
7744$ac_includes_default
7745#ifdef F77_DUMMY_MAIN
7746# ifdef __cplusplus
7747 extern "C"
7748# endif
7749 int F77_DUMMY_MAIN() { return 1; }
7750#endif
7751int
7752main ()
7753{
7754static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= 0)];
7755test_array [0] = 0
7756
7757 ;
7758 return 0;
7759}
7760_ACEOF
7761rm -f conftest.$ac_objext
7762if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7763 (eval $ac_compile) 2>&5
7764 ac_status=$?
7765 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7766 (exit $ac_status); } &&
7767 { ac_try='test -s conftest.$ac_objext'
7768 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7769 (eval $ac_try) 2>&5
7770 ac_status=$?
7771 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7772 (exit $ac_status); }; }; then
7773 ac_lo=0 ac_mid=0
7774 while :; do
7775 cat >conftest.$ac_ext <<_ACEOF
7776#line $LINENO "configure"
7777#include "confdefs.h"
7778$ac_includes_default
7779#ifdef F77_DUMMY_MAIN
7780# ifdef __cplusplus
7781 extern "C"
7782# endif
7783 int F77_DUMMY_MAIN() { return 1; }
7784#endif
7785int
7786main ()
7787{
7788static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
7789test_array [0] = 0
7790
7791 ;
7792 return 0;
7793}
7794_ACEOF
7795rm -f conftest.$ac_objext
7796if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7797 (eval $ac_compile) 2>&5
7798 ac_status=$?
7799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7800 (exit $ac_status); } &&
7801 { ac_try='test -s conftest.$ac_objext'
7802 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7803 (eval $ac_try) 2>&5
7804 ac_status=$?
7805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7806 (exit $ac_status); }; }; then
7807 ac_hi=$ac_mid; break
7808else
7809 echo "$as_me: failed program was:" >&5
7810cat conftest.$ac_ext >&5
7811ac_lo=`expr $ac_mid + 1`
7812 if test $ac_lo -le $ac_mid; then
7813 ac_lo= ac_hi=
7814 break
7815 fi
7816 ac_mid=`expr 2 '*' $ac_mid + 1`
7817fi
7818rm -f conftest.$ac_objext conftest.$ac_ext
7819 done
7820else
7821 echo "$as_me: failed program was:" >&5
7822cat conftest.$ac_ext >&5
7823cat >conftest.$ac_ext <<_ACEOF
7824#line $LINENO "configure"
7825#include "confdefs.h"
7826$ac_includes_default
7827#ifdef F77_DUMMY_MAIN
7828# ifdef __cplusplus
7829 extern "C"
7830# endif
7831 int F77_DUMMY_MAIN() { return 1; }
7832#endif
7833int
7834main ()
7835{
7836static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) < 0)];
7837test_array [0] = 0
7838
7839 ;
7840 return 0;
7841}
7842_ACEOF
7843rm -f conftest.$ac_objext
7844if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7845 (eval $ac_compile) 2>&5
7846 ac_status=$?
7847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7848 (exit $ac_status); } &&
7849 { ac_try='test -s conftest.$ac_objext'
7850 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7851 (eval $ac_try) 2>&5
7852 ac_status=$?
7853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7854 (exit $ac_status); }; }; then
7855 ac_hi=-1 ac_mid=-1
7856 while :; do
7857 cat >conftest.$ac_ext <<_ACEOF
7858#line $LINENO "configure"
7859#include "confdefs.h"
7860$ac_includes_default
7861#ifdef F77_DUMMY_MAIN
7862# ifdef __cplusplus
7863 extern "C"
7864# endif
7865 int F77_DUMMY_MAIN() { return 1; }
7866#endif
7867int
7868main ()
7869{
7870static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) >= $ac_mid)];
7871test_array [0] = 0
7872
7873 ;
7874 return 0;
7875}
7876_ACEOF
7877rm -f conftest.$ac_objext
7878if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7879 (eval $ac_compile) 2>&5
7880 ac_status=$?
7881 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7882 (exit $ac_status); } &&
7883 { ac_try='test -s conftest.$ac_objext'
7884 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7885 (eval $ac_try) 2>&5
7886 ac_status=$?
7887 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7888 (exit $ac_status); }; }; then
7889 ac_lo=$ac_mid; break
7890else
7891 echo "$as_me: failed program was:" >&5
7892cat conftest.$ac_ext >&5
7893ac_hi=`expr '(' $ac_mid ')' - 1`
7894 if test $ac_mid -le $ac_hi; then
7895 ac_lo= ac_hi=
7896 break
7897 fi
7898 ac_mid=`expr 2 '*' $ac_mid`
7899fi
7900rm -f conftest.$ac_objext conftest.$ac_ext
7901 done
7902else
7903 echo "$as_me: failed program was:" >&5
7904cat conftest.$ac_ext >&5
7905ac_lo= ac_hi=
7906fi
7907rm -f conftest.$ac_objext conftest.$ac_ext
7908fi
7909rm -f conftest.$ac_objext conftest.$ac_ext
7910# Binary search between lo and hi bounds.
7911while test "x$ac_lo" != "x$ac_hi"; do
7912 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7913 cat >conftest.$ac_ext <<_ACEOF
7914#line $LINENO "configure"
7915#include "confdefs.h"
7916$ac_includes_default
7917#ifdef F77_DUMMY_MAIN
7918# ifdef __cplusplus
7919 extern "C"
7920# endif
7921 int F77_DUMMY_MAIN() { return 1; }
7922#endif
7923int
7924main ()
7925{
7926static int test_array [1 - 2 * !(((long) (sizeof (fpos_t))) <= $ac_mid)];
7927test_array [0] = 0
7928
7929 ;
7930 return 0;
7931}
7932_ACEOF
7933rm -f conftest.$ac_objext
7934if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7935 (eval $ac_compile) 2>&5
7936 ac_status=$?
7937 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7938 (exit $ac_status); } &&
7939 { ac_try='test -s conftest.$ac_objext'
7940 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7941 (eval $ac_try) 2>&5
7942 ac_status=$?
7943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7944 (exit $ac_status); }; }; then
7945 ac_hi=$ac_mid
7946else
7947 echo "$as_me: failed program was:" >&5
7948cat conftest.$ac_ext >&5
7949ac_lo=`expr '(' $ac_mid ')' + 1`
7950fi
7951rm -f conftest.$ac_objext conftest.$ac_ext
7952done
7953case $ac_lo in
7954?*) ac_cv_sizeof_fpos_t=$ac_lo;;
7955'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77" >&5
7956echo "$as_me: error: cannot compute sizeof (fpos_t), 77" >&2;}
7957 { (exit 1); exit 1; }; } ;;
7958esac
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007959else
7960 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007961 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
7962echo "$as_me: error: cannot run test program while cross compiling" >&2;}
7963 { (exit 1); exit 1; }; }
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007964else
Martin v. Löwis11437992002-04-12 09:54:03 +00007965 cat >conftest.$ac_ext <<_ACEOF
7966#line $LINENO "configure"
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007967#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00007968$ac_includes_default
7969long longval () { return (long) (sizeof (fpos_t)); }
7970unsigned long ulongval () { return (long) (sizeof (fpos_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007971#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007972#include <stdlib.h>
7973#ifdef F77_DUMMY_MAIN
7974# ifdef __cplusplus
7975 extern "C"
7976# endif
7977 int F77_DUMMY_MAIN() { return 1; }
7978#endif
7979int
7980main ()
Guido van Rossumb9a22a12000-06-30 02:48:53 +00007981{
Martin v. Löwis11437992002-04-12 09:54:03 +00007982
7983 FILE *f = fopen ("conftest.val", "w");
7984 if (! f)
7985 exit (1);
7986 if (((long) (sizeof (fpos_t))) < 0)
7987 {
7988 long i = longval ();
7989 if (i != ((long) (sizeof (fpos_t))))
7990 exit (1);
7991 fprintf (f, "%ld\n", i);
7992 }
7993 else
7994 {
7995 unsigned long i = ulongval ();
7996 if (i != ((long) (sizeof (fpos_t))))
7997 exit (1);
7998 fprintf (f, "%lu\n", i);
7999 }
8000 exit (ferror (f) || fclose (f) != 0);
8001
8002 ;
8003 return 0;
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008004}
Martin v. Löwis11437992002-04-12 09:54:03 +00008005_ACEOF
8006rm -f conftest$ac_exeext
8007if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8008 (eval $ac_link) 2>&5
8009 ac_status=$?
8010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8011 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8012 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8013 (eval $ac_try) 2>&5
8014 ac_status=$?
8015 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8016 (exit $ac_status); }; }; then
8017 ac_cv_sizeof_fpos_t=`cat conftest.val`
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008018else
Martin v. Löwis11437992002-04-12 09:54:03 +00008019 echo "$as_me: program exited with status $ac_status" >&5
8020echo "$as_me: failed program was:" >&5
8021cat conftest.$ac_ext >&5
8022( exit $ac_status )
8023{ { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t), 77" >&5
8024echo "$as_me: error: cannot compute sizeof (fpos_t), 77" >&2;}
8025 { (exit 1); exit 1; }; }
8026fi
8027rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8028fi
8029fi
8030rm -f conftest.val
8031else
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008032 ac_cv_sizeof_fpos_t=0
8033fi
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008034fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008035echo "$as_me:$LINENO: result: $ac_cv_sizeof_fpos_t" >&5
8036echo "${ECHO_T}$ac_cv_sizeof_fpos_t" >&6
8037cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008038#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008039_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008040
Michael W. Hudson54241132001-12-07 15:38:26 +00008041
8042
Martin v. Löwis11437992002-04-12 09:54:03 +00008043echo "$as_me:$LINENO: checking for long long support" >&5
8044echo $ECHO_N "checking for long long support... $ECHO_C" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008045have_long_long=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008046cat >conftest.$ac_ext <<_ACEOF
8047#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008048#include "confdefs.h"
8049
Martin v. Löwis11437992002-04-12 09:54:03 +00008050#ifdef F77_DUMMY_MAIN
8051# ifdef __cplusplus
8052 extern "C"
8053# endif
8054 int F77_DUMMY_MAIN() { return 1; }
8055#endif
8056int
8057main ()
8058{
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008059long long x; x = (long long)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008060 ;
8061 return 0;
8062}
8063_ACEOF
8064rm -f conftest.$ac_objext
8065if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8066 (eval $ac_compile) 2>&5
8067 ac_status=$?
8068 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8069 (exit $ac_status); } &&
8070 { ac_try='test -s conftest.$ac_objext'
8071 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8072 (eval $ac_try) 2>&5
8073 ac_status=$?
8074 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8075 (exit $ac_status); }; }; then
8076
8077
8078cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008079#define HAVE_LONG_LONG 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008080_ACEOF
8081
Martin v. Löwisc45929e2002-04-06 10:10:49 +00008082 have_long_long=yes
8083
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008084else
Martin v. Löwis11437992002-04-12 09:54:03 +00008085 echo "$as_me: failed program was:" >&5
8086cat conftest.$ac_ext >&5
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008087fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008088rm -f conftest.$ac_objext conftest.$ac_ext
8089echo "$as_me:$LINENO: result: $have_long_long" >&5
8090echo "${ECHO_T}$have_long_long" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00008091if test "$have_long_long" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008092echo "$as_me:$LINENO: checking for long long" >&5
8093echo $ECHO_N "checking for long long... $ECHO_C" >&6
8094if test "${ac_cv_type_long_long+set}" = set; then
8095 echo $ECHO_N "(cached) $ECHO_C" >&6
8096else
8097 cat >conftest.$ac_ext <<_ACEOF
8098#line $LINENO "configure"
8099#include "confdefs.h"
8100$ac_includes_default
8101#ifdef F77_DUMMY_MAIN
8102# ifdef __cplusplus
8103 extern "C"
8104# endif
8105 int F77_DUMMY_MAIN() { return 1; }
8106#endif
8107int
8108main ()
8109{
8110if ((long long *) 0)
8111 return 0;
8112if (sizeof (long long))
8113 return 0;
8114 ;
8115 return 0;
8116}
8117_ACEOF
8118rm -f conftest.$ac_objext
8119if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8120 (eval $ac_compile) 2>&5
8121 ac_status=$?
8122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8123 (exit $ac_status); } &&
8124 { ac_try='test -s conftest.$ac_objext'
8125 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8126 (eval $ac_try) 2>&5
8127 ac_status=$?
8128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8129 (exit $ac_status); }; }; then
8130 ac_cv_type_long_long=yes
8131else
8132 echo "$as_me: failed program was:" >&5
8133cat conftest.$ac_ext >&5
8134ac_cv_type_long_long=no
8135fi
8136rm -f conftest.$ac_objext conftest.$ac_ext
8137fi
8138echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
8139echo "${ECHO_T}$ac_cv_type_long_long" >&6
8140
8141echo "$as_me:$LINENO: checking size of long long" >&5
8142echo $ECHO_N "checking size of long long... $ECHO_C" >&6
8143if test "${ac_cv_sizeof_long_long+set}" = set; then
8144 echo $ECHO_N "(cached) $ECHO_C" >&6
8145else
8146 if test "$ac_cv_type_long_long" = yes; then
8147 # The cast to unsigned long works around a bug in the HP C Compiler
8148 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8149 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8150 # This bug is HP SR number 8606223364.
8151 if test "$cross_compiling" = yes; then
8152 # Depending upon the size, compute the lo and hi bounds.
8153cat >conftest.$ac_ext <<_ACEOF
8154#line $LINENO "configure"
8155#include "confdefs.h"
8156$ac_includes_default
8157#ifdef F77_DUMMY_MAIN
8158# ifdef __cplusplus
8159 extern "C"
8160# endif
8161 int F77_DUMMY_MAIN() { return 1; }
8162#endif
8163int
8164main ()
8165{
8166static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= 0)];
8167test_array [0] = 0
8168
8169 ;
8170 return 0;
8171}
8172_ACEOF
8173rm -f conftest.$ac_objext
8174if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8175 (eval $ac_compile) 2>&5
8176 ac_status=$?
8177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8178 (exit $ac_status); } &&
8179 { ac_try='test -s conftest.$ac_objext'
8180 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8181 (eval $ac_try) 2>&5
8182 ac_status=$?
8183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8184 (exit $ac_status); }; }; then
8185 ac_lo=0 ac_mid=0
8186 while :; do
8187 cat >conftest.$ac_ext <<_ACEOF
8188#line $LINENO "configure"
8189#include "confdefs.h"
8190$ac_includes_default
8191#ifdef F77_DUMMY_MAIN
8192# ifdef __cplusplus
8193 extern "C"
8194# endif
8195 int F77_DUMMY_MAIN() { return 1; }
8196#endif
8197int
8198main ()
8199{
8200static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
8201test_array [0] = 0
8202
8203 ;
8204 return 0;
8205}
8206_ACEOF
8207rm -f conftest.$ac_objext
8208if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8209 (eval $ac_compile) 2>&5
8210 ac_status=$?
8211 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8212 (exit $ac_status); } &&
8213 { ac_try='test -s conftest.$ac_objext'
8214 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8215 (eval $ac_try) 2>&5
8216 ac_status=$?
8217 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8218 (exit $ac_status); }; }; then
8219 ac_hi=$ac_mid; break
8220else
8221 echo "$as_me: failed program was:" >&5
8222cat conftest.$ac_ext >&5
8223ac_lo=`expr $ac_mid + 1`
8224 if test $ac_lo -le $ac_mid; then
8225 ac_lo= ac_hi=
8226 break
8227 fi
8228 ac_mid=`expr 2 '*' $ac_mid + 1`
8229fi
8230rm -f conftest.$ac_objext conftest.$ac_ext
8231 done
8232else
8233 echo "$as_me: failed program was:" >&5
8234cat conftest.$ac_ext >&5
8235cat >conftest.$ac_ext <<_ACEOF
8236#line $LINENO "configure"
8237#include "confdefs.h"
8238$ac_includes_default
8239#ifdef F77_DUMMY_MAIN
8240# ifdef __cplusplus
8241 extern "C"
8242# endif
8243 int F77_DUMMY_MAIN() { return 1; }
8244#endif
8245int
8246main ()
8247{
8248static int test_array [1 - 2 * !(((long) (sizeof (long long))) < 0)];
8249test_array [0] = 0
8250
8251 ;
8252 return 0;
8253}
8254_ACEOF
8255rm -f conftest.$ac_objext
8256if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8257 (eval $ac_compile) 2>&5
8258 ac_status=$?
8259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8260 (exit $ac_status); } &&
8261 { ac_try='test -s conftest.$ac_objext'
8262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8263 (eval $ac_try) 2>&5
8264 ac_status=$?
8265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8266 (exit $ac_status); }; }; then
8267 ac_hi=-1 ac_mid=-1
8268 while :; do
8269 cat >conftest.$ac_ext <<_ACEOF
8270#line $LINENO "configure"
8271#include "confdefs.h"
8272$ac_includes_default
8273#ifdef F77_DUMMY_MAIN
8274# ifdef __cplusplus
8275 extern "C"
8276# endif
8277 int F77_DUMMY_MAIN() { return 1; }
8278#endif
8279int
8280main ()
8281{
8282static int test_array [1 - 2 * !(((long) (sizeof (long long))) >= $ac_mid)];
8283test_array [0] = 0
8284
8285 ;
8286 return 0;
8287}
8288_ACEOF
8289rm -f conftest.$ac_objext
8290if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8291 (eval $ac_compile) 2>&5
8292 ac_status=$?
8293 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8294 (exit $ac_status); } &&
8295 { ac_try='test -s conftest.$ac_objext'
8296 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8297 (eval $ac_try) 2>&5
8298 ac_status=$?
8299 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8300 (exit $ac_status); }; }; then
8301 ac_lo=$ac_mid; break
8302else
8303 echo "$as_me: failed program was:" >&5
8304cat conftest.$ac_ext >&5
8305ac_hi=`expr '(' $ac_mid ')' - 1`
8306 if test $ac_mid -le $ac_hi; then
8307 ac_lo= ac_hi=
8308 break
8309 fi
8310 ac_mid=`expr 2 '*' $ac_mid`
8311fi
8312rm -f conftest.$ac_objext conftest.$ac_ext
8313 done
8314else
8315 echo "$as_me: failed program was:" >&5
8316cat conftest.$ac_ext >&5
8317ac_lo= ac_hi=
8318fi
8319rm -f conftest.$ac_objext conftest.$ac_ext
8320fi
8321rm -f conftest.$ac_objext conftest.$ac_ext
8322# Binary search between lo and hi bounds.
8323while test "x$ac_lo" != "x$ac_hi"; do
8324 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8325 cat >conftest.$ac_ext <<_ACEOF
8326#line $LINENO "configure"
8327#include "confdefs.h"
8328$ac_includes_default
8329#ifdef F77_DUMMY_MAIN
8330# ifdef __cplusplus
8331 extern "C"
8332# endif
8333 int F77_DUMMY_MAIN() { return 1; }
8334#endif
8335int
8336main ()
8337{
8338static int test_array [1 - 2 * !(((long) (sizeof (long long))) <= $ac_mid)];
8339test_array [0] = 0
8340
8341 ;
8342 return 0;
8343}
8344_ACEOF
8345rm -f conftest.$ac_objext
8346if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8347 (eval $ac_compile) 2>&5
8348 ac_status=$?
8349 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8350 (exit $ac_status); } &&
8351 { ac_try='test -s conftest.$ac_objext'
8352 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8353 (eval $ac_try) 2>&5
8354 ac_status=$?
8355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8356 (exit $ac_status); }; }; then
8357 ac_hi=$ac_mid
8358else
8359 echo "$as_me: failed program was:" >&5
8360cat conftest.$ac_ext >&5
8361ac_lo=`expr '(' $ac_mid ')' + 1`
8362fi
8363rm -f conftest.$ac_objext conftest.$ac_ext
8364done
8365case $ac_lo in
8366?*) ac_cv_sizeof_long_long=$ac_lo;;
8367'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77" >&5
8368echo "$as_me: error: cannot compute sizeof (long long), 77" >&2;}
8369 { (exit 1); exit 1; }; } ;;
8370esac
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008371else
8372 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008373 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
8374echo "$as_me: error: cannot run test program while cross compiling" >&2;}
8375 { (exit 1); exit 1; }; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008376else
Martin v. Löwis11437992002-04-12 09:54:03 +00008377 cat >conftest.$ac_ext <<_ACEOF
8378#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008379#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008380$ac_includes_default
8381long longval () { return (long) (sizeof (long long)); }
8382unsigned long ulongval () { return (long) (sizeof (long long)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008383#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008384#include <stdlib.h>
8385#ifdef F77_DUMMY_MAIN
8386# ifdef __cplusplus
8387 extern "C"
8388# endif
8389 int F77_DUMMY_MAIN() { return 1; }
8390#endif
8391int
8392main ()
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008393{
Martin v. Löwis11437992002-04-12 09:54:03 +00008394
8395 FILE *f = fopen ("conftest.val", "w");
8396 if (! f)
8397 exit (1);
8398 if (((long) (sizeof (long long))) < 0)
8399 {
8400 long i = longval ();
8401 if (i != ((long) (sizeof (long long))))
8402 exit (1);
8403 fprintf (f, "%ld\n", i);
8404 }
8405 else
8406 {
8407 unsigned long i = ulongval ();
8408 if (i != ((long) (sizeof (long long))))
8409 exit (1);
8410 fprintf (f, "%lu\n", i);
8411 }
8412 exit (ferror (f) || fclose (f) != 0);
8413
8414 ;
8415 return 0;
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008416}
Martin v. Löwis11437992002-04-12 09:54:03 +00008417_ACEOF
8418rm -f conftest$ac_exeext
8419if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8420 (eval $ac_link) 2>&5
8421 ac_status=$?
8422 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8423 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8424 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8425 (eval $ac_try) 2>&5
8426 ac_status=$?
8427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8428 (exit $ac_status); }; }; then
8429 ac_cv_sizeof_long_long=`cat conftest.val`
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008430else
Martin v. Löwis11437992002-04-12 09:54:03 +00008431 echo "$as_me: program exited with status $ac_status" >&5
8432echo "$as_me: failed program was:" >&5
8433cat conftest.$ac_ext >&5
8434( exit $ac_status )
8435{ { echo "$as_me:$LINENO: error: cannot compute sizeof (long long), 77" >&5
8436echo "$as_me: error: cannot compute sizeof (long long), 77" >&2;}
8437 { (exit 1); exit 1; }; }
8438fi
8439rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8440fi
8441fi
8442rm -f conftest.val
8443else
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008444 ac_cv_sizeof_long_long=0
8445fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008446fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008447echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
8448echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6
8449cat >>confdefs.h <<_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008450#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
Martin v. Löwis11437992002-04-12 09:54:03 +00008451_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008452
Michael W. Hudson54241132001-12-07 15:38:26 +00008453
Guido van Rossumec95c7b1998-08-04 17:59:56 +00008454fi
8455
Martin v. Löwis11437992002-04-12 09:54:03 +00008456echo "$as_me:$LINENO: checking for uintptr_t support" >&5
8457echo $ECHO_N "checking for uintptr_t support... $ECHO_C" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008458have_uintptr_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00008459cat >conftest.$ac_ext <<_ACEOF
8460#line $LINENO "configure"
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008461#include "confdefs.h"
8462
Martin v. Löwis11437992002-04-12 09:54:03 +00008463#ifdef F77_DUMMY_MAIN
8464# ifdef __cplusplus
8465 extern "C"
8466# endif
8467 int F77_DUMMY_MAIN() { return 1; }
8468#endif
8469int
8470main ()
8471{
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008472uintptr_t x; x = (uintptr_t)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008473 ;
8474 return 0;
8475}
8476_ACEOF
8477rm -f conftest.$ac_objext
8478if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8479 (eval $ac_compile) 2>&5
8480 ac_status=$?
8481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8482 (exit $ac_status); } &&
8483 { ac_try='test -s conftest.$ac_objext'
8484 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8485 (eval $ac_try) 2>&5
8486 ac_status=$?
8487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8488 (exit $ac_status); }; }; then
8489
8490
8491cat >>confdefs.h <<\_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008492#define HAVE_UINTPTR_T 1
Martin v. Löwis11437992002-04-12 09:54:03 +00008493_ACEOF
8494
Martin v. Löwisc45929e2002-04-06 10:10:49 +00008495 have_uintptr_t=yes
8496
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008497else
Martin v. Löwis11437992002-04-12 09:54:03 +00008498 echo "$as_me: failed program was:" >&5
8499cat conftest.$ac_ext >&5
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008500fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008501rm -f conftest.$ac_objext conftest.$ac_ext
8502echo "$as_me:$LINENO: result: $have_uintptr_t" >&5
8503echo "${ECHO_T}$have_uintptr_t" >&6
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008504if test "$have_uintptr_t" = yes ; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008505echo "$as_me:$LINENO: checking for uintptr_t" >&5
8506echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6
8507if test "${ac_cv_type_uintptr_t+set}" = set; then
8508 echo $ECHO_N "(cached) $ECHO_C" >&6
8509else
8510 cat >conftest.$ac_ext <<_ACEOF
8511#line $LINENO "configure"
8512#include "confdefs.h"
8513$ac_includes_default
8514#ifdef F77_DUMMY_MAIN
8515# ifdef __cplusplus
8516 extern "C"
8517# endif
8518 int F77_DUMMY_MAIN() { return 1; }
8519#endif
8520int
8521main ()
8522{
8523if ((uintptr_t *) 0)
8524 return 0;
8525if (sizeof (uintptr_t))
8526 return 0;
8527 ;
8528 return 0;
8529}
8530_ACEOF
8531rm -f conftest.$ac_objext
8532if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8533 (eval $ac_compile) 2>&5
8534 ac_status=$?
8535 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8536 (exit $ac_status); } &&
8537 { ac_try='test -s conftest.$ac_objext'
8538 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8539 (eval $ac_try) 2>&5
8540 ac_status=$?
8541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8542 (exit $ac_status); }; }; then
8543 ac_cv_type_uintptr_t=yes
8544else
8545 echo "$as_me: failed program was:" >&5
8546cat conftest.$ac_ext >&5
8547ac_cv_type_uintptr_t=no
8548fi
8549rm -f conftest.$ac_objext conftest.$ac_ext
8550fi
8551echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
8552echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6
8553
8554echo "$as_me:$LINENO: checking size of uintptr_t" >&5
8555echo $ECHO_N "checking size of uintptr_t... $ECHO_C" >&6
8556if test "${ac_cv_sizeof_uintptr_t+set}" = set; then
8557 echo $ECHO_N "(cached) $ECHO_C" >&6
8558else
8559 if test "$ac_cv_type_uintptr_t" = yes; then
8560 # The cast to unsigned long works around a bug in the HP C Compiler
8561 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8562 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8563 # This bug is HP SR number 8606223364.
8564 if test "$cross_compiling" = yes; then
8565 # Depending upon the size, compute the lo and hi bounds.
8566cat >conftest.$ac_ext <<_ACEOF
8567#line $LINENO "configure"
8568#include "confdefs.h"
8569$ac_includes_default
8570#ifdef F77_DUMMY_MAIN
8571# ifdef __cplusplus
8572 extern "C"
8573# endif
8574 int F77_DUMMY_MAIN() { return 1; }
8575#endif
8576int
8577main ()
8578{
8579static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= 0)];
8580test_array [0] = 0
8581
8582 ;
8583 return 0;
8584}
8585_ACEOF
8586rm -f conftest.$ac_objext
8587if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8588 (eval $ac_compile) 2>&5
8589 ac_status=$?
8590 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8591 (exit $ac_status); } &&
8592 { ac_try='test -s conftest.$ac_objext'
8593 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8594 (eval $ac_try) 2>&5
8595 ac_status=$?
8596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8597 (exit $ac_status); }; }; then
8598 ac_lo=0 ac_mid=0
8599 while :; do
8600 cat >conftest.$ac_ext <<_ACEOF
8601#line $LINENO "configure"
8602#include "confdefs.h"
8603$ac_includes_default
8604#ifdef F77_DUMMY_MAIN
8605# ifdef __cplusplus
8606 extern "C"
8607# endif
8608 int F77_DUMMY_MAIN() { return 1; }
8609#endif
8610int
8611main ()
8612{
8613static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
8614test_array [0] = 0
8615
8616 ;
8617 return 0;
8618}
8619_ACEOF
8620rm -f conftest.$ac_objext
8621if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8622 (eval $ac_compile) 2>&5
8623 ac_status=$?
8624 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8625 (exit $ac_status); } &&
8626 { ac_try='test -s conftest.$ac_objext'
8627 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8628 (eval $ac_try) 2>&5
8629 ac_status=$?
8630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8631 (exit $ac_status); }; }; then
8632 ac_hi=$ac_mid; break
8633else
8634 echo "$as_me: failed program was:" >&5
8635cat conftest.$ac_ext >&5
8636ac_lo=`expr $ac_mid + 1`
8637 if test $ac_lo -le $ac_mid; then
8638 ac_lo= ac_hi=
8639 break
8640 fi
8641 ac_mid=`expr 2 '*' $ac_mid + 1`
8642fi
8643rm -f conftest.$ac_objext conftest.$ac_ext
8644 done
8645else
8646 echo "$as_me: failed program was:" >&5
8647cat conftest.$ac_ext >&5
8648cat >conftest.$ac_ext <<_ACEOF
8649#line $LINENO "configure"
8650#include "confdefs.h"
8651$ac_includes_default
8652#ifdef F77_DUMMY_MAIN
8653# ifdef __cplusplus
8654 extern "C"
8655# endif
8656 int F77_DUMMY_MAIN() { return 1; }
8657#endif
8658int
8659main ()
8660{
8661static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) < 0)];
8662test_array [0] = 0
8663
8664 ;
8665 return 0;
8666}
8667_ACEOF
8668rm -f conftest.$ac_objext
8669if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8670 (eval $ac_compile) 2>&5
8671 ac_status=$?
8672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8673 (exit $ac_status); } &&
8674 { ac_try='test -s conftest.$ac_objext'
8675 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8676 (eval $ac_try) 2>&5
8677 ac_status=$?
8678 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8679 (exit $ac_status); }; }; then
8680 ac_hi=-1 ac_mid=-1
8681 while :; do
8682 cat >conftest.$ac_ext <<_ACEOF
8683#line $LINENO "configure"
8684#include "confdefs.h"
8685$ac_includes_default
8686#ifdef F77_DUMMY_MAIN
8687# ifdef __cplusplus
8688 extern "C"
8689# endif
8690 int F77_DUMMY_MAIN() { return 1; }
8691#endif
8692int
8693main ()
8694{
8695static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) >= $ac_mid)];
8696test_array [0] = 0
8697
8698 ;
8699 return 0;
8700}
8701_ACEOF
8702rm -f conftest.$ac_objext
8703if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8704 (eval $ac_compile) 2>&5
8705 ac_status=$?
8706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8707 (exit $ac_status); } &&
8708 { ac_try='test -s conftest.$ac_objext'
8709 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8710 (eval $ac_try) 2>&5
8711 ac_status=$?
8712 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8713 (exit $ac_status); }; }; then
8714 ac_lo=$ac_mid; break
8715else
8716 echo "$as_me: failed program was:" >&5
8717cat conftest.$ac_ext >&5
8718ac_hi=`expr '(' $ac_mid ')' - 1`
8719 if test $ac_mid -le $ac_hi; then
8720 ac_lo= ac_hi=
8721 break
8722 fi
8723 ac_mid=`expr 2 '*' $ac_mid`
8724fi
8725rm -f conftest.$ac_objext conftest.$ac_ext
8726 done
8727else
8728 echo "$as_me: failed program was:" >&5
8729cat conftest.$ac_ext >&5
8730ac_lo= ac_hi=
8731fi
8732rm -f conftest.$ac_objext conftest.$ac_ext
8733fi
8734rm -f conftest.$ac_objext conftest.$ac_ext
8735# Binary search between lo and hi bounds.
8736while test "x$ac_lo" != "x$ac_hi"; do
8737 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8738 cat >conftest.$ac_ext <<_ACEOF
8739#line $LINENO "configure"
8740#include "confdefs.h"
8741$ac_includes_default
8742#ifdef F77_DUMMY_MAIN
8743# ifdef __cplusplus
8744 extern "C"
8745# endif
8746 int F77_DUMMY_MAIN() { return 1; }
8747#endif
8748int
8749main ()
8750{
8751static int test_array [1 - 2 * !(((long) (sizeof (uintptr_t))) <= $ac_mid)];
8752test_array [0] = 0
8753
8754 ;
8755 return 0;
8756}
8757_ACEOF
8758rm -f conftest.$ac_objext
8759if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8760 (eval $ac_compile) 2>&5
8761 ac_status=$?
8762 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8763 (exit $ac_status); } &&
8764 { ac_try='test -s conftest.$ac_objext'
8765 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8766 (eval $ac_try) 2>&5
8767 ac_status=$?
8768 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8769 (exit $ac_status); }; }; then
8770 ac_hi=$ac_mid
8771else
8772 echo "$as_me: failed program was:" >&5
8773cat conftest.$ac_ext >&5
8774ac_lo=`expr '(' $ac_mid ')' + 1`
8775fi
8776rm -f conftest.$ac_objext conftest.$ac_ext
8777done
8778case $ac_lo in
8779?*) ac_cv_sizeof_uintptr_t=$ac_lo;;
8780'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77" >&5
8781echo "$as_me: error: cannot compute sizeof (uintptr_t), 77" >&2;}
8782 { (exit 1); exit 1; }; } ;;
8783esac
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008784else
8785 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008786 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
8787echo "$as_me: error: cannot run test program while cross compiling" >&2;}
8788 { (exit 1); exit 1; }; }
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008789else
Martin v. Löwis11437992002-04-12 09:54:03 +00008790 cat >conftest.$ac_ext <<_ACEOF
8791#line $LINENO "configure"
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008792#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00008793$ac_includes_default
8794long longval () { return (long) (sizeof (uintptr_t)); }
8795unsigned long ulongval () { return (long) (sizeof (uintptr_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008796#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008797#include <stdlib.h>
8798#ifdef F77_DUMMY_MAIN
8799# ifdef __cplusplus
8800 extern "C"
8801# endif
8802 int F77_DUMMY_MAIN() { return 1; }
8803#endif
8804int
8805main ()
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008806{
Martin v. Löwis11437992002-04-12 09:54:03 +00008807
8808 FILE *f = fopen ("conftest.val", "w");
8809 if (! f)
8810 exit (1);
8811 if (((long) (sizeof (uintptr_t))) < 0)
8812 {
8813 long i = longval ();
8814 if (i != ((long) (sizeof (uintptr_t))))
8815 exit (1);
8816 fprintf (f, "%ld\n", i);
8817 }
8818 else
8819 {
8820 unsigned long i = ulongval ();
8821 if (i != ((long) (sizeof (uintptr_t))))
8822 exit (1);
8823 fprintf (f, "%lu\n", i);
8824 }
8825 exit (ferror (f) || fclose (f) != 0);
8826
8827 ;
8828 return 0;
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008829}
Martin v. Löwis11437992002-04-12 09:54:03 +00008830_ACEOF
8831rm -f conftest$ac_exeext
8832if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8833 (eval $ac_link) 2>&5
8834 ac_status=$?
8835 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8836 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8837 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8838 (eval $ac_try) 2>&5
8839 ac_status=$?
8840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8841 (exit $ac_status); }; }; then
8842 ac_cv_sizeof_uintptr_t=`cat conftest.val`
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008843else
Martin v. Löwis11437992002-04-12 09:54:03 +00008844 echo "$as_me: program exited with status $ac_status" >&5
8845echo "$as_me: failed program was:" >&5
8846cat conftest.$ac_ext >&5
8847( exit $ac_status )
8848{ { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t), 77" >&5
8849echo "$as_me: error: cannot compute sizeof (uintptr_t), 77" >&2;}
8850 { (exit 1); exit 1; }; }
8851fi
8852rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
8853fi
8854fi
8855rm -f conftest.val
8856else
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008857 ac_cv_sizeof_uintptr_t=0
8858fi
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008859fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008860echo "$as_me:$LINENO: result: $ac_cv_sizeof_uintptr_t" >&5
8861echo "${ECHO_T}$ac_cv_sizeof_uintptr_t" >&6
8862cat >>confdefs.h <<_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008863#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008864_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008865
Michael W. Hudson54241132001-12-07 15:38:26 +00008866
Barry Warsawbc7c7f92000-08-18 04:53:33 +00008867fi
8868
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008869# Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008870echo "$as_me:$LINENO: checking size of off_t" >&5
8871echo $ECHO_N "checking size of off_t... $ECHO_C" >&6
8872if test "${ac_cv_sizeof_off_t+set}" = set; then
8873 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008874else
8875 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008876 ac_cv_sizeof_off_t=4
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008877else
Martin v. Löwis11437992002-04-12 09:54:03 +00008878 cat >conftest.$ac_ext <<_ACEOF
8879#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008880#include "confdefs.h"
8881#include <stdio.h>
8882#include <sys/types.h>
8883main()
8884{
8885 FILE *f=fopen("conftestval", "w");
8886 if (!f) exit(1);
8887 fprintf(f, "%d\n", sizeof(off_t));
8888 exit(0);
8889}
Martin v. Löwis11437992002-04-12 09:54:03 +00008890_ACEOF
8891rm -f conftest$ac_exeext
8892if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8893 (eval $ac_link) 2>&5
8894 ac_status=$?
8895 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8896 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8897 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8898 (eval $ac_try) 2>&5
8899 ac_status=$?
8900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8901 (exit $ac_status); }; }; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008902 ac_cv_sizeof_off_t=`cat conftestval`
8903else
Martin v. Löwis11437992002-04-12 09:54:03 +00008904 echo "$as_me: program exited with status $ac_status" >&5
8905echo "$as_me: failed program was:" >&5
8906cat conftest.$ac_ext >&5
8907( exit $ac_status )
8908ac_cv_sizeof_off_t=0
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008909fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008910rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008911fi
8912
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008913fi
8914
Martin v. Löwis11437992002-04-12 09:54:03 +00008915echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
8916echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6
8917
8918cat >>confdefs.h <<_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008919#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008920_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008921
Michael W. Hudson54241132001-12-07 15:38:26 +00008922
Martin v. Löwis11437992002-04-12 09:54:03 +00008923echo "$as_me:$LINENO: checking whether to enable large file support" >&5
8924echo $ECHO_N "checking whether to enable large file support... $ECHO_C" >&6
Guido van Rossum96f2eb91999-04-10 16:02:18 +00008925if test "$have_long_long" = yes -a \
8926 "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
8927 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008928
Martin v. Löwis11437992002-04-12 09:54:03 +00008929cat >>confdefs.h <<\_ACEOF
8930#define HAVE_LARGEFILE_SUPPORT 1
8931_ACEOF
8932
8933 echo "$as_me:$LINENO: result: yes" >&5
8934echo "${ECHO_T}yes" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008935else
Martin v. Löwis11437992002-04-12 09:54:03 +00008936 echo "$as_me:$LINENO: result: no" >&5
8937echo "${ECHO_T}no" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +00008938fi
8939
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008940# AC_CHECK_SIZEOF() doesn't include <time.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00008941echo "$as_me:$LINENO: checking size of time_t" >&5
8942echo $ECHO_N "checking size of time_t... $ECHO_C" >&6
8943if test "${ac_cv_sizeof_time_t+set}" = set; then
8944 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008945else
8946 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00008947 ac_cv_sizeof_time_t=4
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008948else
Martin v. Löwis11437992002-04-12 09:54:03 +00008949 cat >conftest.$ac_ext <<_ACEOF
8950#line $LINENO "configure"
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008951#include "confdefs.h"
8952#include <stdio.h>
8953#include <time.h>
8954main()
8955{
8956 FILE *f=fopen("conftestval", "w");
8957 if (!f) exit(1);
8958 fprintf(f, "%d\n", sizeof(time_t));
8959 exit(0);
8960}
Martin v. Löwis11437992002-04-12 09:54:03 +00008961_ACEOF
8962rm -f conftest$ac_exeext
8963if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
8964 (eval $ac_link) 2>&5
8965 ac_status=$?
8966 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8967 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
8968 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8969 (eval $ac_try) 2>&5
8970 ac_status=$?
8971 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8972 (exit $ac_status); }; }; then
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008973 ac_cv_sizeof_time_t=`cat conftestval`
8974else
Martin v. Löwis11437992002-04-12 09:54:03 +00008975 echo "$as_me: program exited with status $ac_status" >&5
8976echo "$as_me: failed program was:" >&5
8977cat conftest.$ac_ext >&5
8978( exit $ac_status )
8979ac_cv_sizeof_time_t=0
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008980fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008981rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008982fi
8983
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008984fi
8985
Martin v. Löwis11437992002-04-12 09:54:03 +00008986echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5
8987echo "${ECHO_T}$ac_cv_sizeof_time_t" >&6
8988
8989cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008990#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
Martin v. Löwis11437992002-04-12 09:54:03 +00008991_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +00008992
Michael W. Hudson54241132001-12-07 15:38:26 +00008993
8994
Trent Mick635f6fb2000-08-23 21:33:05 +00008995# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +00008996ac_save_cc="$CC"
8997if test "$ac_cv_kpthread" = "yes"
8998then CC="$CC -Kpthread"
8999fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009000echo "$as_me:$LINENO: checking for pthread_t" >&5
9001echo $ECHO_N "checking for pthread_t... $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009002have_pthread_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009003cat >conftest.$ac_ext <<_ACEOF
9004#line $LINENO "configure"
Trent Mick635f6fb2000-08-23 21:33:05 +00009005#include "confdefs.h"
9006#include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009007#ifdef F77_DUMMY_MAIN
9008# ifdef __cplusplus
9009 extern "C"
9010# endif
9011 int F77_DUMMY_MAIN() { return 1; }
9012#endif
9013int
9014main ()
9015{
Guido van Rossum12580492000-09-24 16:47:19 +00009016pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009017 ;
9018 return 0;
9019}
9020_ACEOF
9021rm -f conftest.$ac_objext
9022if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9023 (eval $ac_compile) 2>&5
9024 ac_status=$?
9025 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9026 (exit $ac_status); } &&
9027 { ac_try='test -s conftest.$ac_objext'
9028 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9029 (eval $ac_try) 2>&5
9030 ac_status=$?
9031 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9032 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00009033 have_pthread_t=yes
9034else
Martin v. Löwis11437992002-04-12 09:54:03 +00009035 echo "$as_me: failed program was:" >&5
9036cat conftest.$ac_ext >&5
Trent Mick635f6fb2000-08-23 21:33:05 +00009037fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009038rm -f conftest.$ac_objext conftest.$ac_ext
9039echo "$as_me:$LINENO: result: $have_pthread_t" >&5
9040echo "${ECHO_T}$have_pthread_t" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009041if test "$have_pthread_t" = yes ; then
9042 # AC_CHECK_SIZEOF() doesn't include <pthread.h>.
Martin v. Löwis11437992002-04-12 09:54:03 +00009043 echo "$as_me:$LINENO: checking size of pthread_t" >&5
9044echo $ECHO_N "checking size of pthread_t... $ECHO_C" >&6
9045 if test "${ac_cv_sizeof_pthread_t+set}" = set; then
9046 echo $ECHO_N "(cached) $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +00009047else
9048 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +00009049 ac_cv_sizeof_pthread_t=4
Trent Mick635f6fb2000-08-23 21:33:05 +00009050else
Martin v. Löwis11437992002-04-12 09:54:03 +00009051 cat >conftest.$ac_ext <<_ACEOF
9052#line $LINENO "configure"
Trent Mick635f6fb2000-08-23 21:33:05 +00009053#include "confdefs.h"
9054#include <stdio.h>
9055 #include <pthread.h>
9056 main()
9057 {
9058 FILE *f=fopen("conftestval", "w");
9059 if (!f) exit(1);
9060 fprintf(f, "%d\n", sizeof(pthread_t));
9061 exit(0);
9062 }
Martin v. Löwis11437992002-04-12 09:54:03 +00009063_ACEOF
9064rm -f conftest$ac_exeext
9065if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9066 (eval $ac_link) 2>&5
9067 ac_status=$?
9068 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9069 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9070 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9071 (eval $ac_try) 2>&5
9072 ac_status=$?
9073 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9074 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +00009075 ac_cv_sizeof_pthread_t=`cat conftestval`
9076else
Martin v. Löwis11437992002-04-12 09:54:03 +00009077 echo "$as_me: program exited with status $ac_status" >&5
9078echo "$as_me: failed program was:" >&5
9079cat conftest.$ac_ext >&5
9080( exit $ac_status )
9081ac_cv_sizeof_pthread_t=0
Trent Mick635f6fb2000-08-23 21:33:05 +00009082fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009083rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Trent Mick635f6fb2000-08-23 21:33:05 +00009084fi
9085
Trent Mick635f6fb2000-08-23 21:33:05 +00009086fi
9087
Martin v. Löwis11437992002-04-12 09:54:03 +00009088 echo "$as_me:$LINENO: result: $ac_cv_sizeof_pthread_t" >&5
9089echo "${ECHO_T}$ac_cv_sizeof_pthread_t" >&6
9090
9091cat >>confdefs.h <<_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00009092#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
Martin v. Löwis11437992002-04-12 09:54:03 +00009093_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +00009094
9095fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +00009096CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +00009097
Martin v. Löwis11437992002-04-12 09:54:03 +00009098echo "$as_me:$LINENO: checking for --enable-toolbox-glue" >&5
9099echo $ECHO_N "checking for --enable-toolbox-glue... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009100# Check whether --enable-toolbox-glue or --disable-toolbox-glue was given.
9101if test "${enable_toolbox_glue+set}" = set; then
9102 enableval="$enable_toolbox_glue"
Jack Jansene578a632001-08-15 01:27:14 +00009103
Martin v. Löwis11437992002-04-12 09:54:03 +00009104fi;
Jack Jansene578a632001-08-15 01:27:14 +00009105
9106if test -z "$enable_toolbox_glue"
Martin v. Löwis11437992002-04-12 09:54:03 +00009107then
Jack Jansene578a632001-08-15 01:27:14 +00009108 case $ac_sys_system/$ac_sys_release in
9109 Darwin/*)
9110 enable_toolbox_glue="yes";;
9111 *)
9112 enable_toolbox_glue="no";;
9113 esac
9114fi
9115case "$enable_toolbox_glue" in
9116yes)
Jack Jansen666b1e72001-10-31 12:11:48 +00009117 extra_frameworks="-framework CoreServices -framework Foundation"
Jack Jansene578a632001-08-15 01:27:14 +00009118 extra_machdep_objs="Python/mactoolboxglue.o"
Jack Jansen591cbed2001-08-15 13:55:15 +00009119 extra_undefs="-u __dummy -u _PyMac_Error"
Martin v. Löwis11437992002-04-12 09:54:03 +00009120
9121cat >>confdefs.h <<\_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00009122#define USE_TOOLBOX_OBJECT_GLUE 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009123_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +00009124
9125 ;;
9126*)
9127 extra_frameworks=""
9128 extra_machdep_objs=""
Jack Jansen591cbed2001-08-15 13:55:15 +00009129 extra_undefs=""
Jack Jansene578a632001-08-15 01:27:14 +00009130 ;;
9131esac
Martin v. Löwis11437992002-04-12 09:54:03 +00009132echo "$as_me:$LINENO: result: $enable_toolbox_glue" >&5
9133echo "${ECHO_T}$enable_toolbox_glue" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00009134
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009135
9136case $ac_sys_system/$ac_sys_release in
Jack Jansen418c3b12001-11-14 10:59:57 +00009137 Darwin/1.3*)
Jack Jansenea0c3822002-08-01 21:57:49 +00009138 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00009139 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansena3891ea2001-09-07 14:25:12 +00009140 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Python'
9141 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +00009142 Darwin/*)
Jack Jansenea0c3822002-08-01 21:57:49 +00009143 LIBTOOL_CRUFT="-lcc_dynamic -arch_only ppc"
Jack Jansen418c3b12001-11-14 10:59:57 +00009144 LIBTOOL_CRUFT="$LIBTOOL_CRUFT $extra_frameworks"
Jack Jansene578a632001-08-15 01:27:14 +00009145 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Python'
9146 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009147esac
9148
Martin v. Löwis11437992002-04-12 09:54:03 +00009149echo "$as_me:$LINENO: checking for --enable-framework" >&5
9150echo $ECHO_N "checking for --enable-framework... $ECHO_C" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009151if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009152then
Jack Jansenca06bc62001-08-03 15:32:23 +00009153 OPT="$OPT -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +00009154 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +00009155 # in the build location.
Jack Jansenea0c3822002-08-01 21:57:49 +00009156 LDFLAGS="$LDFLAGS -Wl,-F."
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009157
Martin v. Löwis11437992002-04-12 09:54:03 +00009158cat >>confdefs.h <<\_ACEOF
9159#define WITH_NEXT_FRAMEWORK 1
9160_ACEOF
9161
9162 echo "$as_me:$LINENO: result: yes" >&5
9163echo "${ECHO_T}yes" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009164else
Martin v. Löwis11437992002-04-12 09:54:03 +00009165 echo "$as_me:$LINENO: result: no" >&5
9166echo "${ECHO_T}no" >&6
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009167fi
9168
Martin v. Löwis11437992002-04-12 09:54:03 +00009169echo "$as_me:$LINENO: checking for dyld" >&5
9170echo $ECHO_N "checking for dyld... $ECHO_C" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009171case $ac_sys_system/$ac_sys_release in
9172 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009173
Martin v. Löwis11437992002-04-12 09:54:03 +00009174cat >>confdefs.h <<\_ACEOF
9175#define WITH_DYLD 1
9176_ACEOF
9177
9178 echo "$as_me:$LINENO: result: always on for Darwin" >&5
9179echo "${ECHO_T}always on for Darwin" >&6
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009180 ;;
9181 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00009182 echo "$as_me:$LINENO: result: no" >&5
9183echo "${ECHO_T}no" >&6
Jack Jansene578a632001-08-15 01:27:14 +00009184 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +00009185esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009186
Guido van Rossum0a516c91994-09-12 10:58:40 +00009187# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +00009188
Michael W. Hudson54241132001-12-07 15:38:26 +00009189
9190
9191
9192
Guido van Rossum0a516c91994-09-12 10:58:40 +00009193# SO is the extension of shared libraries `(including the dot!)
Guido van Rossumaef734b2001-01-10 21:09:12 +00009194# -- usually .so, .sl on HP-UX, .dll on Cygwin
Martin v. Löwis11437992002-04-12 09:54:03 +00009195echo "$as_me:$LINENO: checking SO" >&5
9196echo $ECHO_N "checking SO... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009197if test -z "$SO"
9198then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009199 case $ac_sys_system in
Guido van Rossum563e7081996-09-10 18:20:48 +00009200 hp*|HP*) SO=.sl;;
Guido van Rossumaef734b2001-01-10 21:09:12 +00009201 CYGWIN*) SO=.dll;;
Guido van Rossum563e7081996-09-10 18:20:48 +00009202 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009203 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009204fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009205echo "$as_me:$LINENO: result: $SO" >&5
9206echo "${ECHO_T}$SO" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009207# LDSHARED is the ld *command* used to create shared library
Martin v. Löwis5b718fc2001-09-10 15:34:42 +00009208# -- "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 +00009209# (Shared libraries in this instance are shared modules to be loaded into
9210# Python, as opposed to building Python itself as a shared library.)
Martin v. Löwis11437992002-04-12 09:54:03 +00009211echo "$as_me:$LINENO: checking LDSHARED" >&5
9212echo $ECHO_N "checking LDSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009213if test -z "$LDSHARED"
9214then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009215 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009216 AIX*)
9217 BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Guido van Rossumce608b02001-09-28 15:59:38 +00009218 LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009219 ;;
9220 BeOS*)
9221 BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY"
Guido van Rossumce608b02001-09-28 15:59:38 +00009222 LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009223 ;;
Guido van Rossum07397971997-04-29 21:49:50 +00009224 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +00009225 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009226 SunOS/4*) LDSHARED="ld";;
Martin v. Löwis11437992002-04-12 09:54:03 +00009227 SunOS/5*)
Greg Ward57c9a6632000-05-26 12:22:54 +00009228 if test "$GCC" = "yes"
Neil Schemenauer8ba94452001-02-19 18:18:48 +00009229 then LDSHARED='$(CC) -shared'
Martin v. Löwisaa5afe12002-10-07 06:21:41 +00009230 else LDSHARED='$(CC) -G';
Greg Ward57c9a6632000-05-26 12:22:54 +00009231 fi ;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009232 hp*|HP*) LDSHARED="ld -b";;
Guido van Rossumda88dad1995-01-26 00:46:29 +00009233 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
9234 DYNIX/ptx*) LDSHARED="ld -G";;
Jack Jansen418c3b12001-11-14 10:59:57 +00009235 Darwin/1.3*)
Jack Jansena3891ea2001-09-07 14:25:12 +00009236 LDSHARED='$(CC) $(LDFLAGS) -bundle'
9237 if test "$enable_framework" ; then
9238 # Link against the framework. All externals should be defined.
9239 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
9240 else
9241 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +00009242 LDSHARED="$LDSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +00009243 fi ;;
Jack Jansene578a632001-08-15 01:27:14 +00009244 Darwin/*)
9245 LDSHARED='$(CC) $(LDFLAGS) -bundle'
9246 if test "$enable_framework" ; then
9247 # Link against the framework. All externals should be defined.
9248 LDSHARED="$LDSHARED "'-framework $(PYTHONFRAMEWORK)'
9249 else
Michael W. Hudson594bc802002-03-07 09:59:15 +00009250 # No framework, use the Python app as bundle-loader
9251 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
9252 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/$(PYTHON)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009253 fi ;;
Martin v. Löwis3cba5c02002-09-16 17:50:59 +00009254 Linux*|GNU*) LDSHARED='$(CC) -shared';;
Guido van Rossum3c4bb801997-12-18 23:55:32 +00009255 dgux*) LDSHARED="ld -G";;
Guido van Rossum458e7fa1999-09-17 15:40:40 +00009256 BSD/OS*/4*) LDSHARED="gcc -shared";;
Martin v. Löwisd61888b2002-09-30 11:17:27 +00009257 OpenBSD*|FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +00009258 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +00009259 then
9260 LDSHARED="cc -shared ${LDFLAGS}"
9261 else
9262 LDSHARED="ld -Bshareable ${LDFLAGS}"
9263 fi;;
Martin v. Löwisd61888b2002-09-30 11:17:27 +00009264 NetBSD*) LDSHARED="cc -shared ${LDFLAGS}";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009265 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +00009266 if test "$GCC" = "yes"
9267 then LDSHARED="$(CC) -shared"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009268 else LDSHARED="$(CC) -G"
Martin v. Löwisbec19582001-03-21 15:57:54 +00009269 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00009270 SCO_SV*) LDSHARED="$(CC) -Wl,-G,-Bexport";;
Trent Mick635f6fb2000-08-23 21:33:05 +00009271 Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
Guido van Rossumaef734b2001-01-10 21:09:12 +00009272 CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009273 atheos*) LDSHARED="gcc -shared";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009274 *) LDSHARED="ld";;
9275 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009276fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009277echo "$as_me:$LINENO: result: $LDSHARED" >&5
9278echo "${ECHO_T}$LDSHARED" >&6
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009279BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +00009280# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009281# library (module) -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +00009282echo "$as_me:$LINENO: checking CCSHARED" >&5
9283echo $ECHO_N "checking CCSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009284if test -z "$CCSHARED"
9285then
Guido van Rossum07397971997-04-29 21:49:50 +00009286 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +00009287 SunOS*) if test "$GCC" = yes;
9288 then CCSHARED="-fPIC";
9289 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +00009290 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +00009291 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +00009292 else CCSHARED="+z";
9293 fi;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009294 Linux*|GNU*) CCSHARED="-fPIC";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +00009295 BSD/OS*/4*) CCSHARED="-fpic";;
Martin v. Löwis36546db2001-09-05 14:24:43 +00009296 FreeBSD*|NetBSD*|OpenBSD*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009297 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +00009298 if test "$GCC" = "yes"
9299 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009300 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +00009301 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00009302 SCO_SV*)
9303 if test "$GCC" = "yes"
9304 then CCSHARED="-fPIC"
9305 else CCSHARED="-Kpic -belf"
9306 fi;;
Trent Mick635f6fb2000-08-23 21:33:05 +00009307 Monterey*) CCSHARED="-G";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009308 IRIX*/6*) case $CC in
9309 *gcc*) CCSHARED="-shared";;
Guido van Rossumee21f411998-04-20 18:51:54 +00009310 *) CCSHARED="";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009311 esac;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009312 atheos*) CCSHARED="-fPIC";;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009313 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009314fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009315echo "$as_me:$LINENO: result: $CCSHARED" >&5
9316echo "${ECHO_T}$CCSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009317# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009318# the python executable -- this is only needed for a few systems
Martin v. Löwis11437992002-04-12 09:54:03 +00009319echo "$as_me:$LINENO: checking LINKFORSHARED" >&5
9320echo $ECHO_N "checking LINKFORSHARED... $ECHO_C" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009321if test -z "$LINKFORSHARED"
9322then
Guido van Rossum07397971997-04-29 21:49:50 +00009323 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00009324 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00009325 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +00009326 LINKFORSHARED="-Wl,-E -Wl,+s";;
9327# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +00009328 BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +00009329 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +00009330 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +00009331 Darwin/*)
Jack Jansene578a632001-08-15 01:27:14 +00009332 # -u __dummy makes the linker aware of the objc runtime
9333 # in System.framework; otherwise, __objcInit (referenced in
9334 # crt1.o) gets erroneously defined as common, which breaks dynamic
9335 # loading of any modules which reference it in System.framework.
9336 # -u _PyMac_Error is needed to pull in the mac toolbox glue, which is
9337 # not used by the core itself but which needs to be in the core so
9338 # that dynamically loaded extension modules have access to it.
Jack Jansen591cbed2001-08-15 13:55:15 +00009339 LINKFORSHARED="$extra_undefs -framework System"
Jack Jansene578a632001-08-15 01:27:14 +00009340 if test "$enable_framework"
9341 then
9342 LINKFORSHARED="$LINKFORSHARED -framework Python"
9343 fi
9344 LINKFORSHARED="$LINKFORSHARED $extra_frameworks";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +00009345 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +00009346 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +00009347 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis11437992002-04-12 09:54:03 +00009348 FreeBSD*|NetBSD*|OpenBSD*)
Guido van Rossumdf693651999-01-07 21:50:41 +00009349 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
9350 then
9351 LINKFORSHARED="-Wl,--export-dynamic"
9352 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009353 SunOS/5*) case $CC in
9354 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +00009355 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +00009356 then
9357 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +00009358 fi;;
9359 esac;;
Guido van Rossum0a516c91994-09-12 10:58:40 +00009360 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +00009361fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009362echo "$as_me:$LINENO: result: $LINKFORSHARED" >&5
9363echo "${ECHO_T}$LINKFORSHARED" >&6
Guido van Rossum0a516c91994-09-12 10:58:40 +00009364
Michael W. Hudson54241132001-12-07 15:38:26 +00009365
Martin v. Löwis11437992002-04-12 09:54:03 +00009366echo "$as_me:$LINENO: checking CFLAGSFORSHARED" >&5
9367echo $ECHO_N "checking CFLAGSFORSHARED... $ECHO_C" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009368if test ! "$LIBRARY" = "$LDLIBRARY"
9369then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +00009370 case $ac_sys_system in
9371 CYGWIN*)
9372 # Cygwin needs CCSHARED when building extension DLLs
9373 # but not when building the interpreter DLL.
9374 CFLAGSFORSHARED='';;
9375 *)
9376 CFLAGSFORSHARED='$(CCSHARED)'
9377 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009378fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009379echo "$as_me:$LINENO: result: $CFLAGSFORSHARED" >&5
9380echo "${ECHO_T}$CFLAGSFORSHARED" >&6
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +00009381
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009382# SHLIBS are libraries (except -lc and -lm) to link to the python shared
9383# library (with --enable-shared).
9384# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +00009385# symbols, this must be set to $(LIBS) (expanded by make). We do this even
9386# if it is not required, since it creates a dependency of the shared library
9387# to LIBS. This, in turn, means that applications linking the shared libpython
9388# don't need to link LIBS explicitly. The default should be only changed
9389# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009390
9391echo "$as_me:$LINENO: checking SHLIBS" >&5
9392echo $ECHO_N "checking SHLIBS... $ECHO_C" >&6
9393case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009394 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +00009395 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00009396esac
9397echo "$as_me:$LINENO: result: $SHLIBS" >&5
9398echo "${ECHO_T}$SHLIBS" >&6
9399
9400
Guido van Rossum627b2d71993-12-24 10:39:16 +00009401# checks for libraries
Martin v. Löwis11437992002-04-12 09:54:03 +00009402
9403echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
9404echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
9405if test "${ac_cv_lib_dl_dlopen+set}" = set; then
9406 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009407else
Martin v. Löwis11437992002-04-12 09:54:03 +00009408 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009409LIBS="-ldl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009410cat >conftest.$ac_ext <<_ACEOF
9411#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00009412#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009413
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009414/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009415#ifdef __cplusplus
9416extern "C"
9417#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009418/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009419 builtin and then its argument prototype would still apply. */
9420char dlopen ();
9421#ifdef F77_DUMMY_MAIN
9422# ifdef __cplusplus
9423 extern "C"
9424# endif
9425 int F77_DUMMY_MAIN() { return 1; }
9426#endif
9427int
9428main ()
9429{
9430dlopen ();
9431 ;
9432 return 0;
9433}
9434_ACEOF
9435rm -f conftest.$ac_objext conftest$ac_exeext
9436if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9437 (eval $ac_link) 2>&5
9438 ac_status=$?
9439 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9440 (exit $ac_status); } &&
9441 { ac_try='test -s conftest$ac_exeext'
9442 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9443 (eval $ac_try) 2>&5
9444 ac_status=$?
9445 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9446 (exit $ac_status); }; }; then
9447 ac_cv_lib_dl_dlopen=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009448else
Martin v. Löwis11437992002-04-12 09:54:03 +00009449 echo "$as_me: failed program was:" >&5
9450cat conftest.$ac_ext >&5
9451ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00009452fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009453rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9454LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +00009455fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009456echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
9457echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
9458if test $ac_cv_lib_dl_dlopen = yes; then
9459 cat >>confdefs.h <<_ACEOF
9460#define HAVE_LIBDL 1
9461_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00009462
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009463 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +00009464
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009465fi
9466 # Dynamic linking for SunOS/Solaris and SYSV
Martin v. Löwis11437992002-04-12 09:54:03 +00009467
9468echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
9469echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6
9470if test "${ac_cv_lib_dld_shl_load+set}" = set; then
9471 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009472else
Martin v. Löwis11437992002-04-12 09:54:03 +00009473 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009474LIBS="-ldld $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009475cat >conftest.$ac_ext <<_ACEOF
9476#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +00009477#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009478
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009479/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009480#ifdef __cplusplus
9481extern "C"
9482#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009483/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009484 builtin and then its argument prototype would still apply. */
9485char shl_load ();
9486#ifdef F77_DUMMY_MAIN
9487# ifdef __cplusplus
9488 extern "C"
9489# endif
9490 int F77_DUMMY_MAIN() { return 1; }
9491#endif
9492int
9493main ()
9494{
9495shl_load ();
9496 ;
9497 return 0;
9498}
9499_ACEOF
9500rm -f conftest.$ac_objext conftest$ac_exeext
9501if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9502 (eval $ac_link) 2>&5
9503 ac_status=$?
9504 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9505 (exit $ac_status); } &&
9506 { ac_try='test -s conftest$ac_exeext'
9507 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9508 (eval $ac_try) 2>&5
9509 ac_status=$?
9510 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9511 (exit $ac_status); }; }; then
9512 ac_cv_lib_dld_shl_load=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009513else
Martin v. Löwis11437992002-04-12 09:54:03 +00009514 echo "$as_me: failed program was:" >&5
9515cat conftest.$ac_ext >&5
9516ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00009517fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009518rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9519LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +00009520fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009521echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
9522echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6
9523if test $ac_cv_lib_dld_shl_load = yes; then
9524 cat >>confdefs.h <<_ACEOF
9525#define HAVE_LIBDLD 1
9526_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00009527
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009528 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009529
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009530fi
9531 # Dynamic linking for HP-UX
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009532echo "$as_me:$LINENO: checking for library containing sem_init" >&5
9533echo $ECHO_N "checking for library containing sem_init... $ECHO_C" >&6
9534if test "${ac_cv_search_sem_init+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009535 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009536else
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009537 ac_func_search_save_LIBS=$LIBS
9538ac_cv_search_sem_init=no
Martin v. Löwis11437992002-04-12 09:54:03 +00009539cat >conftest.$ac_ext <<_ACEOF
9540#line $LINENO "configure"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009541#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009542
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009543/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009544#ifdef __cplusplus
9545extern "C"
9546#endif
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009547/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009548 builtin and then its argument prototype would still apply. */
9549char sem_init ();
9550#ifdef F77_DUMMY_MAIN
9551# ifdef __cplusplus
9552 extern "C"
9553# endif
9554 int F77_DUMMY_MAIN() { return 1; }
9555#endif
9556int
9557main ()
9558{
9559sem_init ();
9560 ;
9561 return 0;
9562}
9563_ACEOF
9564rm -f conftest.$ac_objext conftest$ac_exeext
9565if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9566 (eval $ac_link) 2>&5
9567 ac_status=$?
9568 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9569 (exit $ac_status); } &&
9570 { ac_try='test -s conftest$ac_exeext'
9571 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9572 (eval $ac_try) 2>&5
9573 ac_status=$?
9574 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9575 (exit $ac_status); }; }; then
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009576 ac_cv_search_sem_init="none required"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009577else
Martin v. Löwis11437992002-04-12 09:54:03 +00009578 echo "$as_me: failed program was:" >&5
9579cat conftest.$ac_ext >&5
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009580fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009581rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009582if test "$ac_cv_search_sem_init" = no; then
9583 for ac_lib in rt posix4; do
9584 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
9585 cat >conftest.$ac_ext <<_ACEOF
9586#line $LINENO "configure"
9587#include "confdefs.h"
9588
9589/* Override any gcc2 internal prototype to avoid an error. */
9590#ifdef __cplusplus
9591extern "C"
9592#endif
9593/* We use char because int might match the return type of a gcc2
9594 builtin and then its argument prototype would still apply. */
9595char sem_init ();
9596#ifdef F77_DUMMY_MAIN
9597# ifdef __cplusplus
9598 extern "C"
9599# endif
9600 int F77_DUMMY_MAIN() { return 1; }
9601#endif
9602int
9603main ()
9604{
9605sem_init ();
9606 ;
9607 return 0;
9608}
Martin v. Löwis11437992002-04-12 09:54:03 +00009609_ACEOF
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009610rm -f conftest.$ac_objext conftest$ac_exeext
9611if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9612 (eval $ac_link) 2>&5
9613 ac_status=$?
9614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9615 (exit $ac_status); } &&
9616 { ac_try='test -s conftest$ac_exeext'
9617 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9618 (eval $ac_try) 2>&5
9619 ac_status=$?
9620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9621 (exit $ac_status); }; }; then
9622 ac_cv_search_sem_init="-l$ac_lib"
9623break
9624else
9625 echo "$as_me: failed program was:" >&5
9626cat conftest.$ac_ext >&5
9627fi
9628rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9629 done
9630fi
9631LIBS=$ac_func_search_save_LIBS
9632fi
9633echo "$as_me:$LINENO: result: $ac_cv_search_sem_init" >&5
9634echo "${ECHO_T}$ac_cv_search_sem_init" >&6
9635if test "$ac_cv_search_sem_init" != no; then
9636 test "$ac_cv_search_sem_init" = "none required" || LIBS="$ac_cv_search_sem_init $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009637
Martin v. Löwis41933dd2002-03-21 15:10:58 +00009638fi
Martin v. Löwis82c19a72002-10-06 11:48:09 +00009639 # 'Real Time' functions on Solaris,
9640 # posix4 on Solaris 2.6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009641
9642# checks for system dependent C++ extensions support
9643case "$ac_sys_system" in
Martin v. Löwis11437992002-04-12 09:54:03 +00009644 AIX*) echo "$as_me:$LINENO: checking for genuine AIX C++ extensions support" >&5
9645echo $ECHO_N "checking for genuine AIX C++ extensions support... $ECHO_C" >&6
9646 cat >conftest.$ac_ext <<_ACEOF
9647#line $LINENO "configure"
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009648#include "confdefs.h"
9649#include "/usr/lpp/xlC/include/load.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009650#ifdef F77_DUMMY_MAIN
9651# ifdef __cplusplus
9652 extern "C"
9653# endif
9654 int F77_DUMMY_MAIN() { return 1; }
9655#endif
9656int
9657main ()
9658{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009659loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +00009660 ;
9661 return 0;
9662}
9663_ACEOF
9664rm -f conftest.$ac_objext conftest$ac_exeext
9665if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9666 (eval $ac_link) 2>&5
9667 ac_status=$?
9668 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9669 (exit $ac_status); } &&
9670 { ac_try='test -s conftest$ac_exeext'
9671 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9672 (eval $ac_try) 2>&5
9673 ac_status=$?
9674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9675 (exit $ac_status); }; }; then
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009676
Martin v. Löwis11437992002-04-12 09:54:03 +00009677cat >>confdefs.h <<\_ACEOF
9678#define AIX_GENUINE_CPLUSPLUS 1
9679_ACEOF
9680
9681 echo "$as_me:$LINENO: result: yes" >&5
9682echo "${ECHO_T}yes" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009683else
Martin v. Löwis11437992002-04-12 09:54:03 +00009684 echo "$as_me: failed program was:" >&5
9685cat conftest.$ac_ext >&5
9686echo "$as_me:$LINENO: result: no" >&5
9687echo "${ECHO_T}no" >&6
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009688fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009689rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +00009690 *) ;;
9691esac
9692
Guido van Rossum70c7f481998-03-26 18:44:10 +00009693# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
9694# However on SGI IRIX, these exist but are broken.
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009695# BeOS' sockets are stashed in libnet.
9696case "$ac_sys_system" in
9697IRIX*) ;;
Guido van Rossumb93a8621998-05-07 13:27:32 +00009698*)
Martin v. Löwis11437992002-04-12 09:54:03 +00009699echo "$as_me:$LINENO: checking for t_open in -lnsl" >&5
9700echo $ECHO_N "checking for t_open in -lnsl... $ECHO_C" >&6
9701if test "${ac_cv_lib_nsl_t_open+set}" = set; then
9702 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009703else
Martin v. Löwis11437992002-04-12 09:54:03 +00009704 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009705LIBS="-lnsl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009706cat >conftest.$ac_ext <<_ACEOF
9707#line $LINENO "configure"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009708#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009709
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009710/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009711#ifdef __cplusplus
9712extern "C"
9713#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009714/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009715 builtin and then its argument prototype would still apply. */
9716char t_open ();
9717#ifdef F77_DUMMY_MAIN
9718# ifdef __cplusplus
9719 extern "C"
9720# endif
9721 int F77_DUMMY_MAIN() { return 1; }
9722#endif
9723int
9724main ()
9725{
9726t_open ();
9727 ;
9728 return 0;
9729}
9730_ACEOF
9731rm -f conftest.$ac_objext conftest$ac_exeext
9732if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9733 (eval $ac_link) 2>&5
9734 ac_status=$?
9735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9736 (exit $ac_status); } &&
9737 { ac_try='test -s conftest$ac_exeext'
9738 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9739 (eval $ac_try) 2>&5
9740 ac_status=$?
9741 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9742 (exit $ac_status); }; }; then
9743 ac_cv_lib_nsl_t_open=yes
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009744else
Martin v. Löwis11437992002-04-12 09:54:03 +00009745 echo "$as_me: failed program was:" >&5
9746cat conftest.$ac_ext >&5
9747ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009748fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009749rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9750LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009751fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009752echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_t_open" >&5
9753echo "${ECHO_T}$ac_cv_lib_nsl_t_open" >&6
9754if test $ac_cv_lib_nsl_t_open = yes; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009755 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +00009756fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +00009757 # SVR4
Martin v. Löwis11437992002-04-12 09:54:03 +00009758echo "$as_me:$LINENO: checking for socket in -lsocket" >&5
9759echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6
9760if test "${ac_cv_lib_socket_socket+set}" = set; then
9761 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009762else
Martin v. Löwis11437992002-04-12 09:54:03 +00009763 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00009764LIBS="-lsocket $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009765cat >conftest.$ac_ext <<_ACEOF
9766#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009767#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009768
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009769/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009770#ifdef __cplusplus
9771extern "C"
9772#endif
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009773/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009774 builtin and then its argument prototype would still apply. */
9775char socket ();
9776#ifdef F77_DUMMY_MAIN
9777# ifdef __cplusplus
9778 extern "C"
9779# endif
9780 int F77_DUMMY_MAIN() { return 1; }
9781#endif
9782int
9783main ()
9784{
9785socket ();
9786 ;
9787 return 0;
9788}
9789_ACEOF
9790rm -f conftest.$ac_objext conftest$ac_exeext
9791if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9792 (eval $ac_link) 2>&5
9793 ac_status=$?
9794 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9795 (exit $ac_status); } &&
9796 { ac_try='test -s conftest$ac_exeext'
9797 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9798 (eval $ac_try) 2>&5
9799 ac_status=$?
9800 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9801 (exit $ac_status); }; }; then
9802 ac_cv_lib_socket_socket=yes
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009803else
Martin v. Löwis11437992002-04-12 09:54:03 +00009804 echo "$as_me: failed program was:" >&5
9805cat conftest.$ac_ext >&5
9806ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009807fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009808rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9809LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009810fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009811echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5
9812echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6
9813if test $ac_cv_lib_socket_socket = yes; then
Guido van Rossumad678af1998-10-02 14:42:15 +00009814 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +00009815fi
9816 # SVR4 sockets
Jeremy Hyltoncb25d5e2000-07-27 21:23:28 +00009817;;
9818esac
9819case "$ac_sys_system" in
9820BeOS*)
Martin v. Löwis11437992002-04-12 09:54:03 +00009821echo "$as_me:$LINENO: checking for socket in -lnet" >&5
9822echo $ECHO_N "checking for socket in -lnet... $ECHO_C" >&6
9823if test "${ac_cv_lib_net_socket+set}" = set; then
9824 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +00009825else
Martin v. Löwis11437992002-04-12 09:54:03 +00009826 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +00009827LIBS="-lnet $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00009828cat >conftest.$ac_ext <<_ACEOF
9829#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +00009830#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00009831
Guido van Rossumad678af1998-10-02 14:42:15 +00009832/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009833#ifdef __cplusplus
9834extern "C"
9835#endif
Guido van Rossumad678af1998-10-02 14:42:15 +00009836/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +00009837 builtin and then its argument prototype would still apply. */
9838char socket ();
9839#ifdef F77_DUMMY_MAIN
9840# ifdef __cplusplus
9841 extern "C"
9842# endif
9843 int F77_DUMMY_MAIN() { return 1; }
9844#endif
9845int
9846main ()
9847{
9848socket ();
9849 ;
9850 return 0;
9851}
9852_ACEOF
9853rm -f conftest.$ac_objext conftest$ac_exeext
9854if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
9855 (eval $ac_link) 2>&5
9856 ac_status=$?
9857 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9858 (exit $ac_status); } &&
9859 { ac_try='test -s conftest$ac_exeext'
9860 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9861 (eval $ac_try) 2>&5
9862 ac_status=$?
9863 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9864 (exit $ac_status); }; }; then
9865 ac_cv_lib_net_socket=yes
Guido van Rossumad678af1998-10-02 14:42:15 +00009866else
Martin v. Löwis11437992002-04-12 09:54:03 +00009867 echo "$as_me: failed program was:" >&5
9868cat conftest.$ac_ext >&5
9869ac_cv_lib_net_socket=no
Guido van Rossumad678af1998-10-02 14:42:15 +00009870fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009871rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
9872LIBS=$ac_check_lib_save_LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +00009873fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009874echo "$as_me:$LINENO: result: $ac_cv_lib_net_socket" >&5
9875echo "${ECHO_T}$ac_cv_lib_net_socket" >&6
9876if test $ac_cv_lib_net_socket = yes; then
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009877 LIBS="-lnet $LIBS"
Guido van Rossumec95c7b1998-08-04 17:59:56 +00009878fi
9879 # BeOS
9880;;
9881esac
Guido van Rossum70c7f481998-03-26 18:44:10 +00009882
Martin v. Löwis11437992002-04-12 09:54:03 +00009883echo "$as_me:$LINENO: checking for --with-libs" >&5
9884echo $ECHO_N "checking for --with-libs... $ECHO_C" >&6
9885
Guido van Rossuma68acba1996-07-31 17:36:39 +00009886# Check whether --with-libs or --without-libs was given.
9887if test "${with_libs+set}" = set; then
9888 withval="$with_libs"
Martin v. Löwis11437992002-04-12 09:54:03 +00009889
9890echo "$as_me:$LINENO: result: $withval" >&5
9891echo "${ECHO_T}$withval" >&6
Guido van Rossuma68acba1996-07-31 17:36:39 +00009892LIBS="$withval $LIBS"
9893
9894else
Martin v. Löwis11437992002-04-12 09:54:03 +00009895 echo "$as_me:$LINENO: result: no" >&5
9896echo "${ECHO_T}no" >&6
9897fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +00009898
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00009899# Determine if signalmodule should be used.
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009900
9901
Martin v. Löwis11437992002-04-12 09:54:03 +00009902echo "$as_me:$LINENO: checking for --with-signal-module" >&5
9903echo $ECHO_N "checking for --with-signal-module... $ECHO_C" >&6
9904
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009905# Check whether --with-signal-module or --without-signal-module was given.
9906if test "${with_signal_module+set}" = set; then
9907 withval="$with_signal_module"
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009908
Martin v. Löwis11437992002-04-12 09:54:03 +00009909fi;
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009910
9911if test -z "$with_signal_module"
9912then with_signal_module="yes"
9913fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009914echo "$as_me:$LINENO: result: $with_signal_module" >&5
9915echo "${ECHO_T}$with_signal_module" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +00009916
9917if test "${with_signal_module}" = "yes"; then
9918 USE_SIGNAL_MODULE=""
9919 SIGNAL_OBJS=""
9920else
9921 USE_SIGNAL_MODULE="#"
9922 SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o"
9923fi
9924
Guido van Rossum3d15bd82001-01-10 18:53:48 +00009925# This is used to generate Setup.config
Guido van Rossum009f7871997-12-04 00:51:42 +00009926
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009927USE_THREAD_MODULE=""
Guido van Rossum009f7871997-12-04 00:51:42 +00009928
Martin v. Löwis11437992002-04-12 09:54:03 +00009929echo "$as_me:$LINENO: checking for --with-dec-threads" >&5
9930echo $ECHO_N "checking for --with-dec-threads... $ECHO_C" >&6
9931
Guido van Rossumec2f0731997-01-22 20:54:01 +00009932
9933# Check whether --with-dec-threads or --without-dec-threads was given.
9934if test "${with_dec_threads+set}" = set; then
9935 withval="$with_dec_threads"
Martin v. Löwis11437992002-04-12 09:54:03 +00009936
9937echo "$as_me:$LINENO: result: $withval" >&5
9938echo "${ECHO_T}$withval" >&6
Guido van Rossumec2f0731997-01-22 20:54:01 +00009939LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +00009940if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +00009941 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +00009942fi
Guido van Rossumec2f0731997-01-22 20:54:01 +00009943else
Martin v. Löwis11437992002-04-12 09:54:03 +00009944 echo "$as_me:$LINENO: result: no" >&5
9945echo "${ECHO_T}no" >&6
9946fi;
9947
9948# Templates for things AC_DEFINEd more than once.
9949# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +00009950
9951
Martin v. Löwis11437992002-04-12 09:54:03 +00009952
9953
9954
9955
9956
9957echo "$as_me:$LINENO: checking for --with-threads" >&5
9958echo $ECHO_N "checking for --with-threads... $ECHO_C" >&6
9959
Guido van Rossumec2f0731997-01-22 20:54:01 +00009960# Check whether --with-threads or --without-threads was given.
9961if test "${with_threads+set}" = set; then
9962 withval="$with_threads"
Guido van Rossumec2f0731997-01-22 20:54:01 +00009963
Martin v. Löwis11437992002-04-12 09:54:03 +00009964fi;
Guido van Rossumec2f0731997-01-22 20:54:01 +00009965
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009966# --with-thread is deprecated, but check for it anyway
Martin v. Löwis11437992002-04-12 09:54:03 +00009967
Guido van Rossum76be6ed1995-01-02 18:33:54 +00009968# Check whether --with-thread or --without-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00009969if test "${with_thread+set}" = set; then
9970 withval="$with_thread"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00009971 with_threads=$with_thread
Martin v. Löwis11437992002-04-12 09:54:03 +00009972fi;
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009973
9974if test -z "$with_threads"
9975then with_threads="yes"
9976fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009977echo "$as_me:$LINENO: result: $with_threads" >&5
9978echo "${ECHO_T}$with_threads" >&6
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009979
Martin v. Löwis2d7e2642002-04-05 16:50:53 +00009980
Barry Warsawc0d24d8b2000-06-29 16:12:00 +00009981if test "$with_threads" = "no"
9982then
9983 USE_THREAD_MODULE="#"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009984elif test "$ac_cv_pthread_is_default" = yes
9985then
Martin v. Löwis11437992002-04-12 09:54:03 +00009986 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009987#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009988_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009989
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009990 # Defining _REENTRANT on system with POSIX threads should not hurt.
Martin v. Löwis11437992002-04-12 09:54:03 +00009991 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009992#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +00009993_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +00009994
9995 posix_threads=yes
Martin v. Löwis11437992002-04-12 09:54:03 +00009996 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +00009997elif test "$ac_cv_kpthread" = "yes"
9998then
9999 CC="$CC -Kpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000010000 cat >>confdefs.h <<\_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000010001#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010002_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000010003
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010004 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010005 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000010006else
10007 if test ! -z "$with_threads" -a -d "$with_threads"
10008 then LDFLAGS="$LDFLAGS -L$with_threads"
10009 fi
10010 if test ! -z "$withval" -a -d "$withval"
10011 then LDFLAGS="$LDFLAGS -L$withval"
10012 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010013
10014 # According to the POSIX spec, a pthreads implementation must
10015 # define _POSIX_THREADS in unistd.h. Some apparently don't (which ones?)
Martin v. Löwis11437992002-04-12 09:54:03 +000010016 echo "$as_me:$LINENO: checking for _POSIX_THREADS in unistd.h" >&5
10017echo $ECHO_N "checking for _POSIX_THREADS in unistd.h... $ECHO_C" >&6
10018 cat >conftest.$ac_ext <<_ACEOF
10019#line $LINENO "configure"
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010020#include "confdefs.h"
10021#include <unistd.h>
10022 #ifdef _POSIX_THREADS
10023 yes
10024 #endif
Martin v. Löwis11437992002-04-12 09:54:03 +000010025
10026_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010027if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10028 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010029 unistd_defines_pthreads=yes
10030else
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010031 unistd_defines_pthreads=no
10032fi
10033rm -f conftest*
10034
Martin v. Löwis11437992002-04-12 09:54:03 +000010035 echo "$as_me:$LINENO: result: $unistd_defines_pthreads" >&5
10036echo "${ECHO_T}$unistd_defines_pthreads" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010037
Martin v. Löwis11437992002-04-12 09:54:03 +000010038 cat >>confdefs.h <<\_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000010039#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010040_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000010041
Martin v. Löwis11437992002-04-12 09:54:03 +000010042 if test "${ac_cv_header_cthreads_h+set}" = set; then
10043 echo "$as_me:$LINENO: checking for cthreads.h" >&5
10044echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
10045if test "${ac_cv_header_cthreads_h+set}" = set; then
10046 echo $ECHO_N "(cached) $ECHO_C" >&6
10047fi
10048echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
10049echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010050else
Martin v. Löwis11437992002-04-12 09:54:03 +000010051 # Is the header compilable?
10052echo "$as_me:$LINENO: checking cthreads.h usability" >&5
10053echo $ECHO_N "checking cthreads.h usability... $ECHO_C" >&6
10054cat >conftest.$ac_ext <<_ACEOF
10055#line $LINENO "configure"
10056#include "confdefs.h"
10057$ac_includes_default
10058#include <cthreads.h>
10059_ACEOF
10060rm -f conftest.$ac_objext
10061if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10062 (eval $ac_compile) 2>&5
10063 ac_status=$?
10064 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10065 (exit $ac_status); } &&
10066 { ac_try='test -s conftest.$ac_objext'
10067 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10068 (eval $ac_try) 2>&5
10069 ac_status=$?
10070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10071 (exit $ac_status); }; }; then
10072 ac_header_compiler=yes
10073else
10074 echo "$as_me: failed program was:" >&5
10075cat conftest.$ac_ext >&5
10076ac_header_compiler=no
10077fi
10078rm -f conftest.$ac_objext conftest.$ac_ext
10079echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10080echo "${ECHO_T}$ac_header_compiler" >&6
10081
10082# Is the header present?
10083echo "$as_me:$LINENO: checking cthreads.h presence" >&5
10084echo $ECHO_N "checking cthreads.h presence... $ECHO_C" >&6
10085cat >conftest.$ac_ext <<_ACEOF
10086#line $LINENO "configure"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010087#include "confdefs.h"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010088#include <cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010089_ACEOF
10090if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10091 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10092 ac_status=$?
10093 egrep -v '^ *\+' conftest.er1 >conftest.err
10094 rm -f conftest.er1
10095 cat conftest.err >&5
10096 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10097 (exit $ac_status); } >/dev/null; then
10098 if test -s conftest.err; then
10099 ac_cpp_err=$ac_c_preproc_warn_flag
10100 else
10101 ac_cpp_err=
10102 fi
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010103else
Martin v. Löwis11437992002-04-12 09:54:03 +000010104 ac_cpp_err=yes
10105fi
10106if test -z "$ac_cpp_err"; then
10107 ac_header_preproc=yes
10108else
10109 echo "$as_me: failed program was:" >&5
Guido van Rossumf78abae1997-01-21 22:02:36 +000010110 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010111 ac_header_preproc=no
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010112fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010113rm -f conftest.err conftest.$ac_ext
10114echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10115echo "${ECHO_T}$ac_header_preproc" >&6
10116
10117# So? What about this header?
10118case $ac_header_compiler:$ac_header_preproc in
10119 yes:no )
10120 { echo "$as_me:$LINENO: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10121echo "$as_me: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10122 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
10123echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;};;
10124 no:yes )
10125 { echo "$as_me:$LINENO: WARNING: cthreads.h: present but cannot be compiled" >&5
10126echo "$as_me: WARNING: cthreads.h: present but cannot be compiled" >&2;}
10127 { echo "$as_me:$LINENO: WARNING: cthreads.h: check for missing prerequisite headers?" >&5
10128echo "$as_me: WARNING: cthreads.h: check for missing prerequisite headers?" >&2;}
10129 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
10130echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;};;
10131esac
10132echo "$as_me:$LINENO: checking for cthreads.h" >&5
10133echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6
10134if test "${ac_cv_header_cthreads_h+set}" = set; then
10135 echo $ECHO_N "(cached) $ECHO_C" >&6
10136else
10137 ac_cv_header_cthreads_h=$ac_header_preproc
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010138fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010139echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
10140echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6
10141
10142fi
10143if test $ac_cv_header_cthreads_h = yes; then
10144 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010145#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010146_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010147
Martin v. Löwis11437992002-04-12 09:54:03 +000010148 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010149#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010150_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010151
Martin v. Löwis11437992002-04-12 09:54:03 +000010152
10153cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010154#define HURD_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010155_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010156
10157 LIBS="$LIBS -lthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010158 THREADOBJ="Python/thread.o"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010159else
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010160
Martin v. Löwis11437992002-04-12 09:54:03 +000010161 if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
10162 echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
10163echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
10164if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
10165 echo $ECHO_N "(cached) $ECHO_C" >&6
10166fi
10167echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
10168echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010169else
Martin v. Löwis11437992002-04-12 09:54:03 +000010170 # Is the header compilable?
10171echo "$as_me:$LINENO: checking mach/cthreads.h usability" >&5
10172echo $ECHO_N "checking mach/cthreads.h usability... $ECHO_C" >&6
10173cat >conftest.$ac_ext <<_ACEOF
10174#line $LINENO "configure"
10175#include "confdefs.h"
10176$ac_includes_default
10177#include <mach/cthreads.h>
10178_ACEOF
10179rm -f conftest.$ac_objext
10180if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10181 (eval $ac_compile) 2>&5
10182 ac_status=$?
10183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10184 (exit $ac_status); } &&
10185 { ac_try='test -s conftest.$ac_objext'
10186 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10187 (eval $ac_try) 2>&5
10188 ac_status=$?
10189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10190 (exit $ac_status); }; }; then
10191 ac_header_compiler=yes
10192else
10193 echo "$as_me: failed program was:" >&5
10194cat conftest.$ac_ext >&5
10195ac_header_compiler=no
10196fi
10197rm -f conftest.$ac_objext conftest.$ac_ext
10198echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10199echo "${ECHO_T}$ac_header_compiler" >&6
10200
10201# Is the header present?
10202echo "$as_me:$LINENO: checking mach/cthreads.h presence" >&5
10203echo $ECHO_N "checking mach/cthreads.h presence... $ECHO_C" >&6
10204cat >conftest.$ac_ext <<_ACEOF
10205#line $LINENO "configure"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010206#include "confdefs.h"
10207#include <mach/cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010208_ACEOF
10209if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10210 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10211 ac_status=$?
10212 egrep -v '^ *\+' conftest.er1 >conftest.err
10213 rm -f conftest.er1
10214 cat conftest.err >&5
10215 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10216 (exit $ac_status); } >/dev/null; then
10217 if test -s conftest.err; then
10218 ac_cpp_err=$ac_c_preproc_warn_flag
10219 else
10220 ac_cpp_err=
10221 fi
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010222else
Martin v. Löwis11437992002-04-12 09:54:03 +000010223 ac_cpp_err=yes
10224fi
10225if test -z "$ac_cpp_err"; then
10226 ac_header_preproc=yes
10227else
10228 echo "$as_me: failed program was:" >&5
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010229 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010230 ac_header_preproc=no
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010231fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010232rm -f conftest.err conftest.$ac_ext
10233echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10234echo "${ECHO_T}$ac_header_preproc" >&6
10235
10236# So? What about this header?
10237case $ac_header_compiler:$ac_header_preproc in
10238 yes:no )
10239 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10240echo "$as_me: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10241 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
10242echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;};;
10243 no:yes )
10244 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: present but cannot be compiled" >&5
10245echo "$as_me: WARNING: mach/cthreads.h: present but cannot be compiled" >&2;}
10246 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&5
10247echo "$as_me: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&2;}
10248 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
10249echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;};;
10250esac
10251echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
10252echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6
10253if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
10254 echo $ECHO_N "(cached) $ECHO_C" >&6
10255else
10256 ac_cv_header_mach_cthreads_h=$ac_header_preproc
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010257fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010258echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
10259echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6
10260
10261fi
10262if test $ac_cv_header_mach_cthreads_h = yes; then
10263 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010264#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010265_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010266
Martin v. Löwis11437992002-04-12 09:54:03 +000010267 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010268#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010269_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010270
Martin v. Löwis11437992002-04-12 09:54:03 +000010271
10272cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010273#define MACH_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010274_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000010275
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010276 THREADOBJ="Python/thread.o"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010277else
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010278
Martin v. Löwis11437992002-04-12 09:54:03 +000010279 echo "$as_me:$LINENO: checking for --with-pth" >&5
10280echo $ECHO_N "checking for --with-pth... $ECHO_C" >&6
10281
10282# Check whether --with-pth or --without-pth was given.
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010283if test "${with_pth+set}" = set; then
10284 withval="$with_pth"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010285 echo "$as_me:$LINENO: result: $withval" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010286echo "${ECHO_T}$withval" >&6
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010287 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000010288#define WITH_THREAD 1
10289_ACEOF
10290
10291
10292cat >>confdefs.h <<\_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010293#define HAVE_PTH 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010294_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010295
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010296 LIBS="-lpth $LIBS"
10297 THREADOBJ="Python/thread.o"
Guido van Rossum9e8181b2000-09-19 00:46:46 +000010298else
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000010299 echo "$as_me:$LINENO: result: no" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010300echo "${ECHO_T}no" >&6
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010301
10302 # Just looking for pthread_create in libpthread is not enough:
10303 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
10304 # So we really have to include pthread.h, and then link.
10305 _libs=$LIBS
10306 LIBS="$LIBS -lpthread"
Martin v. Löwis11437992002-04-12 09:54:03 +000010307 echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
10308echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6
10309 cat >conftest.$ac_ext <<_ACEOF
10310#line $LINENO "configure"
Guido van Rossum02a1c402000-02-25 19:26:31 +000010311#include "confdefs.h"
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010312#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000010313
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010314void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000010315#ifdef F77_DUMMY_MAIN
10316# ifdef __cplusplus
10317 extern "C"
10318# endif
10319 int F77_DUMMY_MAIN() { return 1; }
10320#endif
10321int
10322main ()
10323{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010324
10325pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000010326 ;
10327 return 0;
10328}
10329_ACEOF
10330rm -f conftest.$ac_objext conftest$ac_exeext
10331if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10332 (eval $ac_link) 2>&5
10333 ac_status=$?
10334 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10335 (exit $ac_status); } &&
10336 { ac_try='test -s conftest$ac_exeext'
10337 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10338 (eval $ac_try) 2>&5
10339 ac_status=$?
10340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10341 (exit $ac_status); }; }; then
10342
10343 echo "$as_me:$LINENO: result: yes" >&5
10344echo "${ECHO_T}yes" >&6
10345 cat >>confdefs.h <<\_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000010346#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010347_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000010348
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010349 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010350 THREADOBJ="Python/thread.o"
Guido van Rossum02a1c402000-02-25 19:26:31 +000010351else
Martin v. Löwis11437992002-04-12 09:54:03 +000010352 echo "$as_me: failed program was:" >&5
10353cat conftest.$ac_ext >&5
10354
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000010355 LIBS=$_libs
Martin v. Löwis11437992002-04-12 09:54:03 +000010356 echo "$as_me:$LINENO: checking for pthread_detach" >&5
10357echo $ECHO_N "checking for pthread_detach... $ECHO_C" >&6
10358if test "${ac_cv_func_pthread_detach+set}" = set; then
10359 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000010360else
Martin v. Löwis11437992002-04-12 09:54:03 +000010361 cat >conftest.$ac_ext <<_ACEOF
10362#line $LINENO "configure"
Guido van Rossumad678af1998-10-02 14:42:15 +000010363#include "confdefs.h"
10364/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000010365 which can conflict with char pthread_detach (); below. */
Guido van Rossumad678af1998-10-02 14:42:15 +000010366#include <assert.h>
10367/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010368#ifdef __cplusplus
10369extern "C"
10370#endif
Guido van Rossumad678af1998-10-02 14:42:15 +000010371/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010372 builtin and then its argument prototype would still apply. */
10373char pthread_detach ();
10374char (*f) ();
Guido van Rossumad678af1998-10-02 14:42:15 +000010375
Martin v. Löwis11437992002-04-12 09:54:03 +000010376#ifdef F77_DUMMY_MAIN
10377# ifdef __cplusplus
10378 extern "C"
10379# endif
10380 int F77_DUMMY_MAIN() { return 1; }
10381#endif
10382int
10383main ()
10384{
Guido van Rossumad678af1998-10-02 14:42:15 +000010385/* The GNU C library defines this for functions which it implements
10386 to always fail with ENOSYS. Some functions are actually named
10387 something starting with __ and the normal name is an alias. */
Guido van Rossumea516321998-12-17 18:08:55 +000010388#if defined (__stub_pthread_detach) || defined (__stub___pthread_detach)
Guido van Rossumad678af1998-10-02 14:42:15 +000010389choke me
10390#else
Martin v. Löwis11437992002-04-12 09:54:03 +000010391f = pthread_detach;
Guido van Rossumad678af1998-10-02 14:42:15 +000010392#endif
10393
Martin v. Löwis11437992002-04-12 09:54:03 +000010394 ;
10395 return 0;
10396}
10397_ACEOF
10398rm -f conftest.$ac_objext conftest$ac_exeext
10399if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10400 (eval $ac_link) 2>&5
10401 ac_status=$?
10402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10403 (exit $ac_status); } &&
10404 { ac_try='test -s conftest$ac_exeext'
10405 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10406 (eval $ac_try) 2>&5
10407 ac_status=$?
10408 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10409 (exit $ac_status); }; }; then
10410 ac_cv_func_pthread_detach=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000010411else
Martin v. Löwis11437992002-04-12 09:54:03 +000010412 echo "$as_me: failed program was:" >&5
10413cat conftest.$ac_ext >&5
10414ac_cv_func_pthread_detach=no
Guido van Rossumad678af1998-10-02 14:42:15 +000010415fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010416rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumad678af1998-10-02 14:42:15 +000010417fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010418echo "$as_me:$LINENO: result: $ac_cv_func_pthread_detach" >&5
10419echo "${ECHO_T}$ac_cv_func_pthread_detach" >&6
10420if test $ac_cv_func_pthread_detach = yes; then
10421 cat >>confdefs.h <<\_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000010422#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010423_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000010424
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000010425 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010426 THREADOBJ="Python/thread.o"
Guido van Rossumad678af1998-10-02 14:42:15 +000010427else
Guido van Rossumad678af1998-10-02 14:42:15 +000010428
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010429 if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10430 echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
10431echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
10432if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10433 echo $ECHO_N "(cached) $ECHO_C" >&6
10434fi
10435echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
10436echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
10437else
10438 # Is the header compilable?
10439echo "$as_me:$LINENO: checking atheos/threads.h usability" >&5
10440echo $ECHO_N "checking atheos/threads.h usability... $ECHO_C" >&6
10441cat >conftest.$ac_ext <<_ACEOF
10442#line $LINENO "configure"
10443#include "confdefs.h"
10444$ac_includes_default
10445#include <atheos/threads.h>
10446_ACEOF
10447rm -f conftest.$ac_objext
10448if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10449 (eval $ac_compile) 2>&5
10450 ac_status=$?
10451 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10452 (exit $ac_status); } &&
10453 { ac_try='test -s conftest.$ac_objext'
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_header_compiler=yes
10460else
10461 echo "$as_me: failed program was:" >&5
10462cat conftest.$ac_ext >&5
10463ac_header_compiler=no
10464fi
10465rm -f conftest.$ac_objext conftest.$ac_ext
10466echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10467echo "${ECHO_T}$ac_header_compiler" >&6
10468
10469# Is the header present?
10470echo "$as_me:$LINENO: checking atheos/threads.h presence" >&5
10471echo $ECHO_N "checking atheos/threads.h presence... $ECHO_C" >&6
10472cat >conftest.$ac_ext <<_ACEOF
10473#line $LINENO "configure"
10474#include "confdefs.h"
10475#include <atheos/threads.h>
10476_ACEOF
10477if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10478 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10479 ac_status=$?
10480 egrep -v '^ *\+' conftest.er1 >conftest.err
10481 rm -f conftest.er1
10482 cat conftest.err >&5
10483 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10484 (exit $ac_status); } >/dev/null; then
10485 if test -s conftest.err; then
10486 ac_cpp_err=$ac_c_preproc_warn_flag
10487 else
10488 ac_cpp_err=
10489 fi
10490else
10491 ac_cpp_err=yes
10492fi
10493if test -z "$ac_cpp_err"; then
10494 ac_header_preproc=yes
10495else
10496 echo "$as_me: failed program was:" >&5
10497 cat conftest.$ac_ext >&5
10498 ac_header_preproc=no
10499fi
10500rm -f conftest.err conftest.$ac_ext
10501echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10502echo "${ECHO_T}$ac_header_preproc" >&6
10503
10504# So? What about this header?
10505case $ac_header_compiler:$ac_header_preproc in
10506 yes:no )
10507 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&5
10508echo "$as_me: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10509 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
10510echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;};;
10511 no:yes )
10512 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: present but cannot be compiled" >&5
10513echo "$as_me: WARNING: atheos/threads.h: present but cannot be compiled" >&2;}
10514 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&5
10515echo "$as_me: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&2;}
10516 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
10517echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;};;
10518esac
10519echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
10520echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6
10521if test "${ac_cv_header_atheos_threads_h+set}" = set; then
10522 echo $ECHO_N "(cached) $ECHO_C" >&6
10523else
10524 ac_cv_header_atheos_threads_h=$ac_header_preproc
10525fi
10526echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
10527echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6
10528
10529fi
10530if test $ac_cv_header_atheos_threads_h = yes; then
10531 cat >>confdefs.h <<\_ACEOF
10532#define WITH_THREAD 1
10533_ACEOF
10534
10535
10536cat >>confdefs.h <<\_ACEOF
10537#define ATHEOS_THREADS 1
10538_ACEOF
10539
10540 THREADOBJ="Python/thread.o"
10541else
10542
Martin v. Löwis11437992002-04-12 09:54:03 +000010543 if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10544 echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
10545echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
10546if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10547 echo $ECHO_N "(cached) $ECHO_C" >&6
10548fi
10549echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
10550echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010551else
Martin v. Löwis11437992002-04-12 09:54:03 +000010552 # Is the header compilable?
10553echo "$as_me:$LINENO: checking kernel/OS.h usability" >&5
10554echo $ECHO_N "checking kernel/OS.h usability... $ECHO_C" >&6
10555cat >conftest.$ac_ext <<_ACEOF
10556#line $LINENO "configure"
10557#include "confdefs.h"
10558$ac_includes_default
10559#include <kernel/OS.h>
10560_ACEOF
10561rm -f conftest.$ac_objext
10562if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10563 (eval $ac_compile) 2>&5
10564 ac_status=$?
10565 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10566 (exit $ac_status); } &&
10567 { ac_try='test -s conftest.$ac_objext'
10568 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10569 (eval $ac_try) 2>&5
10570 ac_status=$?
10571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10572 (exit $ac_status); }; }; then
10573 ac_header_compiler=yes
10574else
10575 echo "$as_me: failed program was:" >&5
10576cat conftest.$ac_ext >&5
10577ac_header_compiler=no
10578fi
10579rm -f conftest.$ac_objext conftest.$ac_ext
10580echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10581echo "${ECHO_T}$ac_header_compiler" >&6
10582
10583# Is the header present?
10584echo "$as_me:$LINENO: checking kernel/OS.h presence" >&5
10585echo $ECHO_N "checking kernel/OS.h presence... $ECHO_C" >&6
10586cat >conftest.$ac_ext <<_ACEOF
10587#line $LINENO "configure"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010588#include "confdefs.h"
10589#include <kernel/OS.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010590_ACEOF
10591if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10592 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10593 ac_status=$?
10594 egrep -v '^ *\+' conftest.er1 >conftest.err
10595 rm -f conftest.er1
10596 cat conftest.err >&5
10597 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10598 (exit $ac_status); } >/dev/null; then
10599 if test -s conftest.err; then
10600 ac_cpp_err=$ac_c_preproc_warn_flag
10601 else
10602 ac_cpp_err=
10603 fi
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010604else
Martin v. Löwis11437992002-04-12 09:54:03 +000010605 ac_cpp_err=yes
10606fi
10607if test -z "$ac_cpp_err"; then
10608 ac_header_preproc=yes
10609else
10610 echo "$as_me: failed program was:" >&5
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010611 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010612 ac_header_preproc=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010613fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010614rm -f conftest.err conftest.$ac_ext
10615echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10616echo "${ECHO_T}$ac_header_preproc" >&6
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010617
Martin v. Löwis11437992002-04-12 09:54:03 +000010618# So? What about this header?
10619case $ac_header_compiler:$ac_header_preproc in
10620 yes:no )
10621 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&5
10622echo "$as_me: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10623 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
10624echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;};;
10625 no:yes )
10626 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: present but cannot be compiled" >&5
10627echo "$as_me: WARNING: kernel/OS.h: present but cannot be compiled" >&2;}
10628 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&5
10629echo "$as_me: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&2;}
10630 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
10631echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;};;
10632esac
10633echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
10634echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6
10635if test "${ac_cv_header_kernel_OS_h+set}" = set; then
10636 echo $ECHO_N "(cached) $ECHO_C" >&6
10637else
10638 ac_cv_header_kernel_OS_h=$ac_header_preproc
10639fi
10640echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
10641echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6
10642
10643fi
10644if test $ac_cv_header_kernel_OS_h = yes; then
10645 cat >>confdefs.h <<\_ACEOF
10646#define WITH_THREAD 1
10647_ACEOF
10648
10649
10650cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010651#define BEOS_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010652_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010653
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010654 THREADOBJ="Python/thread.o"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010655else
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010656
Martin v. Löwis11437992002-04-12 09:54:03 +000010657 echo "$as_me:$LINENO: checking for pthread_create in -lpthreads" >&5
10658echo $ECHO_N "checking for pthread_create in -lpthreads... $ECHO_C" >&6
10659if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then
10660 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010661else
Martin v. Löwis11437992002-04-12 09:54:03 +000010662 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000010663LIBS="-lpthreads $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010664cat >conftest.$ac_ext <<_ACEOF
10665#line $LINENO "configure"
Greg Steinadf63d62000-07-05 10:38:09 +000010666#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010667
Greg Steinadf63d62000-07-05 10:38:09 +000010668/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010669#ifdef __cplusplus
10670extern "C"
10671#endif
Greg Steinadf63d62000-07-05 10:38:09 +000010672/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010673 builtin and then its argument prototype would still apply. */
10674char pthread_create ();
10675#ifdef F77_DUMMY_MAIN
10676# ifdef __cplusplus
10677 extern "C"
10678# endif
10679 int F77_DUMMY_MAIN() { return 1; }
10680#endif
10681int
10682main ()
10683{
10684pthread_create ();
10685 ;
10686 return 0;
10687}
10688_ACEOF
10689rm -f conftest.$ac_objext conftest$ac_exeext
10690if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10691 (eval $ac_link) 2>&5
10692 ac_status=$?
10693 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10694 (exit $ac_status); } &&
10695 { ac_try='test -s conftest$ac_exeext'
10696 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10697 (eval $ac_try) 2>&5
10698 ac_status=$?
10699 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10700 (exit $ac_status); }; }; then
10701 ac_cv_lib_pthreads_pthread_create=yes
Greg Steinadf63d62000-07-05 10:38:09 +000010702else
Martin v. Löwis11437992002-04-12 09:54:03 +000010703 echo "$as_me: failed program was:" >&5
10704cat conftest.$ac_ext >&5
10705ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000010706fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010707rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10708LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010709fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010710echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_create" >&5
10711echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_create" >&6
10712if test $ac_cv_lib_pthreads_pthread_create = yes; then
10713 cat >>confdefs.h <<\_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000010714#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010715_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000010716
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010717 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010718 LIBS="$LIBS -lpthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010719 THREADOBJ="Python/thread.o"
Greg Steinadf63d62000-07-05 10:38:09 +000010720else
Greg Steinadf63d62000-07-05 10:38:09 +000010721
Martin v. Löwis11437992002-04-12 09:54:03 +000010722 echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
10723echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6
10724if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
10725 echo $ECHO_N "(cached) $ECHO_C" >&6
Greg Steinadf63d62000-07-05 10:38:09 +000010726else
Martin v. Löwis11437992002-04-12 09:54:03 +000010727 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010728LIBS="-lc_r $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010729cat >conftest.$ac_ext <<_ACEOF
10730#line $LINENO "configure"
Guido van Rossum49545951997-12-02 19:28:29 +000010731#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010732
Guido van Rossum49545951997-12-02 19:28:29 +000010733/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010734#ifdef __cplusplus
10735extern "C"
10736#endif
Guido van Rossum49545951997-12-02 19:28:29 +000010737/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010738 builtin and then its argument prototype would still apply. */
10739char pthread_create ();
10740#ifdef F77_DUMMY_MAIN
10741# ifdef __cplusplus
10742 extern "C"
10743# endif
10744 int F77_DUMMY_MAIN() { return 1; }
10745#endif
10746int
10747main ()
10748{
10749pthread_create ();
10750 ;
10751 return 0;
10752}
10753_ACEOF
10754rm -f conftest.$ac_objext conftest$ac_exeext
10755if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10756 (eval $ac_link) 2>&5
10757 ac_status=$?
10758 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10759 (exit $ac_status); } &&
10760 { ac_try='test -s conftest$ac_exeext'
10761 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10762 (eval $ac_try) 2>&5
10763 ac_status=$?
10764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10765 (exit $ac_status); }; }; then
10766 ac_cv_lib_c_r_pthread_create=yes
Guido van Rossum49545951997-12-02 19:28:29 +000010767else
Martin v. Löwis11437992002-04-12 09:54:03 +000010768 echo "$as_me: failed program was:" >&5
10769cat conftest.$ac_ext >&5
10770ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000010771fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010772rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10773LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000010774fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010775echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
10776echo "${ECHO_T}$ac_cv_lib_c_r_pthread_create" >&6
10777if test $ac_cv_lib_c_r_pthread_create = yes; then
10778 cat >>confdefs.h <<\_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000010779#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010780_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000010781
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010782 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010783 LIBS="$LIBS -lc_r"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010784 THREADOBJ="Python/thread.o"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010785else
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010786
Martin v. Löwis11437992002-04-12 09:54:03 +000010787 echo "$as_me:$LINENO: checking for __d6_pthread_create in -lthread" >&5
10788echo $ECHO_N "checking for __d6_pthread_create in -lthread... $ECHO_C" >&6
10789if test "${ac_cv_lib_thread___d6_pthread_create+set}" = set; then
10790 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010791else
Martin v. Löwis11437992002-04-12 09:54:03 +000010792 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000010793LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010794cat >conftest.$ac_ext <<_ACEOF
10795#line $LINENO "configure"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010796#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010797
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010798/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010799#ifdef __cplusplus
10800extern "C"
10801#endif
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010802/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010803 builtin and then its argument prototype would still apply. */
10804char __d6_pthread_create ();
10805#ifdef F77_DUMMY_MAIN
10806# ifdef __cplusplus
10807 extern "C"
10808# endif
10809 int F77_DUMMY_MAIN() { return 1; }
10810#endif
10811int
10812main ()
10813{
10814__d6_pthread_create ();
10815 ;
10816 return 0;
10817}
10818_ACEOF
10819rm -f conftest.$ac_objext conftest$ac_exeext
10820if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10821 (eval $ac_link) 2>&5
10822 ac_status=$?
10823 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10824 (exit $ac_status); } &&
10825 { ac_try='test -s conftest$ac_exeext'
10826 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10827 (eval $ac_try) 2>&5
10828 ac_status=$?
10829 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10830 (exit $ac_status); }; }; then
10831 ac_cv_lib_thread___d6_pthread_create=yes
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010832else
Martin v. Löwis11437992002-04-12 09:54:03 +000010833 echo "$as_me: failed program was:" >&5
10834cat conftest.$ac_ext >&5
10835ac_cv_lib_thread___d6_pthread_create=no
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010836fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010837rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10838LIBS=$ac_check_lib_save_LIBS
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010839fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010840echo "$as_me:$LINENO: result: $ac_cv_lib_thread___d6_pthread_create" >&5
10841echo "${ECHO_T}$ac_cv_lib_thread___d6_pthread_create" >&6
10842if test $ac_cv_lib_thread___d6_pthread_create = yes; then
10843 cat >>confdefs.h <<\_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010844#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010845_ACEOF
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010846
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010847 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010848 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010849 THREADOBJ="Python/thread.o"
Guido van Rossum49545951997-12-02 19:28:29 +000010850else
Guido van Rossum49545951997-12-02 19:28:29 +000010851
Martin v. Löwis11437992002-04-12 09:54:03 +000010852 echo "$as_me:$LINENO: checking for __pthread_create_system in -lpthread" >&5
10853echo $ECHO_N "checking for __pthread_create_system in -lpthread... $ECHO_C" >&6
10854if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then
10855 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010856else
Martin v. Löwis11437992002-04-12 09:54:03 +000010857 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010858LIBS="-lpthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010859cat >conftest.$ac_ext <<_ACEOF
10860#line $LINENO "configure"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010861#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010862
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010863/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010864#ifdef __cplusplus
10865extern "C"
10866#endif
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010867/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010868 builtin and then its argument prototype would still apply. */
10869char __pthread_create_system ();
10870#ifdef F77_DUMMY_MAIN
10871# ifdef __cplusplus
10872 extern "C"
10873# endif
10874 int F77_DUMMY_MAIN() { return 1; }
10875#endif
10876int
10877main ()
10878{
10879__pthread_create_system ();
10880 ;
10881 return 0;
10882}
10883_ACEOF
10884rm -f conftest.$ac_objext conftest$ac_exeext
10885if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10886 (eval $ac_link) 2>&5
10887 ac_status=$?
10888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10889 (exit $ac_status); } &&
10890 { ac_try='test -s conftest$ac_exeext'
10891 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10892 (eval $ac_try) 2>&5
10893 ac_status=$?
10894 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10895 (exit $ac_status); }; }; then
10896 ac_cv_lib_pthread___pthread_create_system=yes
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010897else
Martin v. Löwis11437992002-04-12 09:54:03 +000010898 echo "$as_me: failed program was:" >&5
10899cat conftest.$ac_ext >&5
10900ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010901fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010902rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10903LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010904fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010905echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_create_system" >&5
10906echo "${ECHO_T}$ac_cv_lib_pthread___pthread_create_system" >&6
10907if test $ac_cv_lib_pthread___pthread_create_system = yes; then
10908 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010909#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010910_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010911
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010912 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010913 LIBS="$LIBS -lpthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010914 THREADOBJ="Python/thread.o"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010915else
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000010916
Martin v. Löwis11437992002-04-12 09:54:03 +000010917 echo "$as_me:$LINENO: checking for pthread_create in -lcma" >&5
10918echo $ECHO_N "checking for pthread_create in -lcma... $ECHO_C" >&6
10919if test "${ac_cv_lib_cma_pthread_create+set}" = set; then
10920 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb93a8621998-05-07 13:27:32 +000010921else
Martin v. Löwis11437992002-04-12 09:54:03 +000010922 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000010923LIBS="-lcma $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000010924cat >conftest.$ac_ext <<_ACEOF
10925#line $LINENO "configure"
Guido van Rossumb93a8621998-05-07 13:27:32 +000010926#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000010927
Guido van Rossumb93a8621998-05-07 13:27:32 +000010928/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010929#ifdef __cplusplus
10930extern "C"
10931#endif
Guido van Rossumb93a8621998-05-07 13:27:32 +000010932/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000010933 builtin and then its argument prototype would still apply. */
10934char pthread_create ();
10935#ifdef F77_DUMMY_MAIN
10936# ifdef __cplusplus
10937 extern "C"
10938# endif
10939 int F77_DUMMY_MAIN() { return 1; }
10940#endif
10941int
10942main ()
10943{
10944pthread_create ();
10945 ;
10946 return 0;
10947}
10948_ACEOF
10949rm -f conftest.$ac_objext conftest$ac_exeext
10950if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10951 (eval $ac_link) 2>&5
10952 ac_status=$?
10953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10954 (exit $ac_status); } &&
10955 { ac_try='test -s conftest$ac_exeext'
10956 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10957 (eval $ac_try) 2>&5
10958 ac_status=$?
10959 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10960 (exit $ac_status); }; }; then
10961 ac_cv_lib_cma_pthread_create=yes
Guido van Rossumb93a8621998-05-07 13:27:32 +000010962else
Martin v. Löwis11437992002-04-12 09:54:03 +000010963 echo "$as_me: failed program was:" >&5
10964cat conftest.$ac_ext >&5
10965ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000010966fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010967rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10968LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000010969fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010970echo "$as_me:$LINENO: result: $ac_cv_lib_cma_pthread_create" >&5
10971echo "${ECHO_T}$ac_cv_lib_cma_pthread_create" >&6
10972if test $ac_cv_lib_cma_pthread_create = yes; then
10973 cat >>confdefs.h <<\_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000010974#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000010975_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000010976
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000010977 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000010978 LIBS="$LIBS -lcma"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000010979 THREADOBJ="Python/thread.o"
Guido van Rossumb93a8621998-05-07 13:27:32 +000010980else
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000010981
Martin v. Löwis130fb172001-07-19 11:00:41 +000010982 USE_THREAD_MODULE="#"
Guido van Rossum2d38f911996-06-26 19:47:01 +000010983fi
10984
Guido van Rossum627b2d71993-12-24 10:39:16 +000010985
Guido van Rossum7b3853f1996-07-30 18:09:35 +000010986fi
10987
Guido van Rossum0be3e491997-05-22 20:33:33 +000010988fi
10989
Guido van Rossum49545951997-12-02 19:28:29 +000010990fi
10991
Guido van Rossumb93a8621998-05-07 13:27:32 +000010992fi
10993
Guido van Rossumec95c7b1998-08-04 17:59:56 +000010994fi
10995
Guido van Rossum07bd90e2000-05-08 13:41:38 +000010996
Michael W. Hudson54241132001-12-07 15:38:26 +000010997fi
10998
Martin v. Löwisf90ae202002-06-11 06:22:31 +000010999
11000fi
11001
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011002fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011003rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11004fi;
11005fi
11006
11007
11008fi
11009
Martin v. Löwisa6e97582002-01-01 18:41:33 +000011010
Michael W. Hudson54241132001-12-07 15:38:26 +000011011
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011012 if test "$posix_threads" = "yes"; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011013 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011014
11015cat >>confdefs.h <<\_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011016#define _POSIX_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011017_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011018
11019 fi
11020
Martin v. Löwis11437992002-04-12 09:54:03 +000011021 echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
11022echo $ECHO_N "checking if PTHREAD_SCOPE_SYSTEM is supported... $ECHO_C" >&6
11023 if test "${ac_cv_pthread_system_supported+set}" = set; then
11024 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011025else
11026 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000011027 ac_cv_pthread_system_supported=no
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011028else
Martin v. Löwis11437992002-04-12 09:54:03 +000011029 cat >conftest.$ac_ext <<_ACEOF
11030#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011031#include "confdefs.h"
11032#include <pthread.h>
11033 void *foo(void *parm) {
11034 return NULL;
11035 }
11036 main() {
11037 pthread_attr_t attr;
Martin v. Löwisa82d3472002-02-24 16:05:05 +000011038 pthread_t id;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011039 if (pthread_attr_init(&attr)) exit(-1);
11040 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1);
Martin v. Löwisa82d3472002-02-24 16:05:05 +000011041 if (pthread_create(&id, &attr, foo, NULL)) exit(-1);
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011042 exit(0);
11043 }
Martin v. Löwis11437992002-04-12 09:54:03 +000011044_ACEOF
11045rm -f conftest$ac_exeext
11046if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11047 (eval $ac_link) 2>&5
11048 ac_status=$?
11049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11050 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11051 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11052 (eval $ac_try) 2>&5
11053 ac_status=$?
11054 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11055 (exit $ac_status); }; }; then
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011056 ac_cv_pthread_system_supported=yes
11057else
Martin v. Löwis11437992002-04-12 09:54:03 +000011058 echo "$as_me: program exited with status $ac_status" >&5
11059echo "$as_me: failed program was:" >&5
11060cat conftest.$ac_ext >&5
11061( exit $ac_status )
11062ac_cv_pthread_system_supported=no
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011063fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011064rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011065fi
11066
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011067fi
11068
Martin v. Löwis11437992002-04-12 09:54:03 +000011069 echo "$as_me:$LINENO: result: $ac_cv_pthread_system_supported" >&5
11070echo "${ECHO_T}$ac_cv_pthread_system_supported" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011071 if test "$ac_cv_pthread_system_supported" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011072
11073cat >>confdefs.h <<\_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011074#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011075_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011076
11077 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011078
11079for ac_func in pthread_sigmask
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011080do
Martin v. Löwis11437992002-04-12 09:54:03 +000011081as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11082echo "$as_me:$LINENO: checking for $ac_func" >&5
11083echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11084if eval "test \"\${$as_ac_var+set}\" = set"; then
11085 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011086else
Martin v. Löwis11437992002-04-12 09:54:03 +000011087 cat >conftest.$ac_ext <<_ACEOF
11088#line $LINENO "configure"
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011089#include "confdefs.h"
11090/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011091 which can conflict with char $ac_func (); below. */
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011092#include <assert.h>
11093/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011094#ifdef __cplusplus
11095extern "C"
11096#endif
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011097/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011098 builtin and then its argument prototype would still apply. */
11099char $ac_func ();
11100char (*f) ();
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011101
Martin v. Löwis11437992002-04-12 09:54:03 +000011102#ifdef F77_DUMMY_MAIN
11103# ifdef __cplusplus
11104 extern "C"
11105# endif
11106 int F77_DUMMY_MAIN() { return 1; }
11107#endif
11108int
11109main ()
11110{
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011111/* The GNU C library defines this for functions which it implements
11112 to always fail with ENOSYS. Some functions are actually named
11113 something starting with __ and the normal name is an alias. */
11114#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11115choke me
11116#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011117f = $ac_func;
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011118#endif
11119
Martin v. Löwis11437992002-04-12 09:54:03 +000011120 ;
11121 return 0;
11122}
11123_ACEOF
11124rm -f conftest.$ac_objext conftest$ac_exeext
11125if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11126 (eval $ac_link) 2>&5
11127 ac_status=$?
11128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11129 (exit $ac_status); } &&
11130 { ac_try='test -s conftest$ac_exeext'
11131 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11132 (eval $ac_try) 2>&5
11133 ac_status=$?
11134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11135 (exit $ac_status); }; }; then
11136 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011137else
Martin v. Löwis11437992002-04-12 09:54:03 +000011138 echo "$as_me: failed program was:" >&5
11139cat conftest.$ac_ext >&5
11140eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011141fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011142rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011143fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011144echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11145echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11146if test `eval echo '${'$as_ac_var'}'` = yes; then
11147 cat >>confdefs.h <<_ACEOF
11148#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11149_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011150
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000011151fi
11152done
11153
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000011154 fi
11155
Martin v. Löwis11437992002-04-12 09:54:03 +000011156 echo "$as_me:$LINENO: checking for usconfig in -lmpc" >&5
11157echo $ECHO_N "checking for usconfig in -lmpc... $ECHO_C" >&6
11158if test "${ac_cv_lib_mpc_usconfig+set}" = set; then
11159 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011160else
Martin v. Löwis11437992002-04-12 09:54:03 +000011161 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011162LIBS="-lmpc $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011163cat >conftest.$ac_ext <<_ACEOF
11164#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000011165#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000011166
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011167/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011168#ifdef __cplusplus
11169extern "C"
11170#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011171/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011172 builtin and then its argument prototype would still apply. */
11173char usconfig ();
11174#ifdef F77_DUMMY_MAIN
11175# ifdef __cplusplus
11176 extern "C"
11177# endif
11178 int F77_DUMMY_MAIN() { return 1; }
11179#endif
11180int
11181main ()
11182{
11183usconfig ();
11184 ;
11185 return 0;
11186}
11187_ACEOF
11188rm -f conftest.$ac_objext conftest$ac_exeext
11189if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11190 (eval $ac_link) 2>&5
11191 ac_status=$?
11192 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11193 (exit $ac_status); } &&
11194 { ac_try='test -s conftest$ac_exeext'
11195 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11196 (eval $ac_try) 2>&5
11197 ac_status=$?
11198 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11199 (exit $ac_status); }; }; then
11200 ac_cv_lib_mpc_usconfig=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011201else
Martin v. Löwis11437992002-04-12 09:54:03 +000011202 echo "$as_me: failed program was:" >&5
11203cat conftest.$ac_ext >&5
11204ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000011205fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011206rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11207LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011208fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011209echo "$as_me:$LINENO: result: $ac_cv_lib_mpc_usconfig" >&5
11210echo "${ECHO_T}$ac_cv_lib_mpc_usconfig" >&6
11211if test $ac_cv_lib_mpc_usconfig = yes; then
11212 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011213#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011214_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000011215
Martin v. Löwis130fb172001-07-19 11:00:41 +000011216 LIBS="$LIBS -lmpc"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011217 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000011218 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000011219fi
11220
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011221
Neal Norwitza978ab02002-11-02 16:58:05 +000011222 if test "$posix_threads" != "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011223 echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
11224echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6
11225if test "${ac_cv_lib_thread_thr_create+set}" = set; then
11226 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011227else
Martin v. Löwis11437992002-04-12 09:54:03 +000011228 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011229LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000011230cat >conftest.$ac_ext <<_ACEOF
11231#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000011232#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000011233
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011234/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011235#ifdef __cplusplus
11236extern "C"
11237#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011238/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011239 builtin and then its argument prototype would still apply. */
11240char thr_create ();
11241#ifdef F77_DUMMY_MAIN
11242# ifdef __cplusplus
11243 extern "C"
11244# endif
11245 int F77_DUMMY_MAIN() { return 1; }
11246#endif
11247int
11248main ()
11249{
11250thr_create ();
11251 ;
11252 return 0;
11253}
11254_ACEOF
11255rm -f conftest.$ac_objext conftest$ac_exeext
11256if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11257 (eval $ac_link) 2>&5
11258 ac_status=$?
11259 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11260 (exit $ac_status); } &&
11261 { ac_try='test -s conftest$ac_exeext'
11262 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11263 (eval $ac_try) 2>&5
11264 ac_status=$?
11265 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11266 (exit $ac_status); }; }; then
11267 ac_cv_lib_thread_thr_create=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011268else
Martin v. Löwis11437992002-04-12 09:54:03 +000011269 echo "$as_me: failed program was:" >&5
11270cat conftest.$ac_ext >&5
11271ac_cv_lib_thread_thr_create=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000011272fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011273rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11274LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011275fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011276echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
11277echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6
11278if test $ac_cv_lib_thread_thr_create = yes; then
11279 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011280#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011281_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000011282
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011283 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000011284 THREADOBJ="Python/thread.o"
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011285 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000011286fi
11287
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000011288 fi
Michael W. Hudson54241132001-12-07 15:38:26 +000011289
Martin v. Löwis130fb172001-07-19 11:00:41 +000011290 if test "$USE_THREAD_MODULE" != "#"
11291 then
11292 # If the above checks didn't disable threads, (at least) OSF1
11293 # needs this '-threads' argument during linking.
11294 case $ac_sys_system in
11295 OSF1) LDLAST=-threads;;
11296 esac
Jeremy Hylton1a2ca862000-10-16 16:59:12 +000011297 fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000011298
11299 if test "$posix_threads" = yes -a \
11300 "$ac_sys_system" = "SunOS" -a \
11301 "$ac_sys_release" = "5.6"; then
11302
11303cat >>confdefs.h <<\_ACEOF
11304#define HAVE_PTHREAD_DESTRUCTOR 1
11305_ACEOF
11306
11307 fi
11308
Guido van Rossum627b2d71993-12-24 10:39:16 +000011309fi
11310
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011311# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000011312
11313
11314echo "$as_me:$LINENO: checking if --enable-ipv6 is specified" >&5
11315echo $ECHO_N "checking if --enable-ipv6 is specified... $ECHO_C" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011316# Check whether --enable-ipv6 or --disable-ipv6 was given.
11317if test "${enable_ipv6+set}" = set; then
11318 enableval="$enable_ipv6"
11319 case "$enableval" in
11320 no)
Martin v. Löwis11437992002-04-12 09:54:03 +000011321 echo "$as_me:$LINENO: result: no" >&5
11322echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011323 ipv6=no
11324 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011325 *) echo "$as_me:$LINENO: result: yes" >&5
11326echo "${ECHO_T}yes" >&6
11327 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011328#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011329_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011330
11331 ipv6=yes
11332 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011333 esac
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011334else
Martin v. Löwis11437992002-04-12 09:54:03 +000011335
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011336 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011337 echo "$as_me:$LINENO: result: no" >&5
11338echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011339 ipv6=no
11340
11341else
Martin v. Löwis11437992002-04-12 09:54:03 +000011342 cat >conftest.$ac_ext <<_ACEOF
11343#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011344#include "confdefs.h"
11345 /* AF_INET6 available check */
11346#include <sys/types.h>
11347#include <sys/socket.h>
11348main()
11349{
11350 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
11351 exit(1);
11352 else
11353 exit(0);
11354}
11355
Martin v. Löwis11437992002-04-12 09:54:03 +000011356_ACEOF
11357rm -f conftest$ac_exeext
11358if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11359 (eval $ac_link) 2>&5
11360 ac_status=$?
11361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11362 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11363 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11364 (eval $ac_try) 2>&5
11365 ac_status=$?
11366 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11367 (exit $ac_status); }; }; then
11368 echo "$as_me:$LINENO: result: yes" >&5
11369echo "${ECHO_T}yes" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011370 ipv6=yes
11371else
Martin v. Löwis11437992002-04-12 09:54:03 +000011372 echo "$as_me: program exited with status $ac_status" >&5
11373echo "$as_me: failed program was:" >&5
11374cat conftest.$ac_ext >&5
11375( exit $ac_status )
11376echo "$as_me:$LINENO: result: no" >&5
11377echo "${ECHO_T}no" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011378 ipv6=no
11379fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011380rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011381fi
11382
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011383if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011384 echo "$as_me:$LINENO: checking if RFC2553 API is available" >&5
11385echo $ECHO_N "checking if RFC2553 API is available... $ECHO_C" >&6
11386 cat >conftest.$ac_ext <<_ACEOF
11387#line $LINENO "configure"
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011388#include "confdefs.h"
11389#include <sys/types.h>
11390#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011391#ifdef F77_DUMMY_MAIN
11392# ifdef __cplusplus
11393 extern "C"
11394# endif
11395 int F77_DUMMY_MAIN() { return 1; }
11396#endif
11397int
11398main ()
11399{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011400struct sockaddr_in6 x;
11401x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000011402 ;
11403 return 0;
11404}
11405_ACEOF
11406rm -f conftest.$ac_objext
11407if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11408 (eval $ac_compile) 2>&5
11409 ac_status=$?
11410 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11411 (exit $ac_status); } &&
11412 { ac_try='test -s conftest.$ac_objext'
11413 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11414 (eval $ac_try) 2>&5
11415 ac_status=$?
11416 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11417 (exit $ac_status); }; }; then
11418 echo "$as_me:$LINENO: result: yes" >&5
11419echo "${ECHO_T}yes" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011420 ipv6=yes
11421else
Martin v. Löwis11437992002-04-12 09:54:03 +000011422 echo "$as_me: failed program was:" >&5
11423cat conftest.$ac_ext >&5
11424echo "$as_me:$LINENO: result: no" >&5
11425echo "${ECHO_T}no" >&6
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011426 ipv6=no
11427fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011428rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011429fi
11430
11431if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011432 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011433#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011434_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000011435
11436fi
11437
Martin v. Löwis11437992002-04-12 09:54:03 +000011438fi;
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011439
11440ipv6type=unknown
11441ipv6lib=none
11442ipv6trylibc=no
11443
11444if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011445 echo "$as_me:$LINENO: checking ipv6 stack type" >&5
11446echo $ECHO_N "checking ipv6 stack type... $ECHO_C" >&6
Guido van Rossumb8552162001-09-05 14:58:11 +000011447 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
11448 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011449 case $i in
11450 inria)
Martin v. Löwis11437992002-04-12 09:54:03 +000011451 cat >conftest.$ac_ext <<_ACEOF
11452#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011453#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011454
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011455#include <netinet/in.h>
11456#ifdef IPV6_INRIA_VERSION
11457yes
11458#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011459_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011460if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11461 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011462 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011463fi
11464rm -f conftest*
11465
11466 ;;
11467 kame)
Martin v. Löwis11437992002-04-12 09:54:03 +000011468 cat >conftest.$ac_ext <<_ACEOF
11469#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011470#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011471
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011472#include <netinet/in.h>
11473#ifdef __KAME__
11474yes
11475#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011476_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011477if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11478 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011479 ipv6type=$i;
11480 ipv6lib=inet6
11481 ipv6libdir=/usr/local/v6/lib
11482 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011483fi
11484rm -f conftest*
11485
11486 ;;
11487 linux-glibc)
Martin v. Löwis11437992002-04-12 09:54:03 +000011488 cat >conftest.$ac_ext <<_ACEOF
11489#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011490#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011491
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011492#include <features.h>
11493#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
11494yes
11495#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011496_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011497if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11498 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011499 ipv6type=$i;
11500 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011501fi
11502rm -f conftest*
11503
11504 ;;
11505 linux-inet6)
11506 if test -d /usr/inet6; then
11507 ipv6type=$i
11508 ipv6lib=inet6
11509 ipv6libdir=/usr/inet6/lib
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011510 OPT="-I/usr/inet6/include $OPT"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011511 fi
11512 ;;
11513 solaris)
11514 if test -f /etc/netconfig; then
11515 if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then
11516 ipv6type=$i
11517 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011518 fi
11519 fi
11520 ;;
11521 toshiba)
Martin v. Löwis11437992002-04-12 09:54:03 +000011522 cat >conftest.$ac_ext <<_ACEOF
11523#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011524#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011525
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011526#include <sys/param.h>
11527#ifdef _TOSHIBA_INET6
11528yes
11529#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011530_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011531if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11532 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011533 ipv6type=$i;
11534 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011535 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011536fi
11537rm -f conftest*
11538
11539 ;;
11540 v6d)
Martin v. Löwis11437992002-04-12 09:54:03 +000011541 cat >conftest.$ac_ext <<_ACEOF
11542#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011543#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011544
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011545#include </usr/local/v6/include/sys/v6config.h>
11546#ifdef __V6D__
11547yes
11548#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011549_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011550if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11551 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011552 ipv6type=$i;
11553 ipv6lib=v6;
11554 ipv6libdir=/usr/local/v6/lib;
11555 OPT="-I/usr/local/v6/include $OPT"
11556fi
11557rm -f conftest*
11558
11559 ;;
11560 zeta)
Martin v. Löwis11437992002-04-12 09:54:03 +000011561 cat >conftest.$ac_ext <<_ACEOF
11562#line $LINENO "configure"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011563#include "confdefs.h"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000011564
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011565#include <sys/param.h>
11566#ifdef _ZETA_MINAMI_INET6
11567yes
11568#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000011569_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011570if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11571 egrep "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011572 ipv6type=$i;
11573 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000011574 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011575fi
11576rm -f conftest*
11577
11578 ;;
11579 esac
11580 if test "$ipv6type" != "unknown"; then
11581 break
11582 fi
11583 done
Martin v. Löwis11437992002-04-12 09:54:03 +000011584 echo "$as_me:$LINENO: result: $ipv6type" >&5
11585echo "${ECHO_T}$ipv6type" >&6
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000011586fi
11587
11588if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
11589 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
11590 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
11591 echo "using lib$ipv6lib"
11592 else
11593 if test $ipv6trylibc = "yes"; then
11594 echo "using libc"
11595 else
11596 echo 'Fatal: no $ipv6lib library found. cannot continue.'
11597 echo "You need to fetch lib$ipv6lib.a from appropriate"
11598 echo 'ipv6 kit and compile beforehand.'
11599 exit 1
11600 fi
11601 fi
11602fi
11603
Jack Jansen7b8c7542002-04-14 20:12:41 +000011604# Check for universal newline support
Guido van Rossum402905e2002-08-15 13:56:35 +000011605echo "$as_me:$LINENO: checking for --with-universal-newlines" >&5
11606echo $ECHO_N "checking for --with-universal-newlines... $ECHO_C" >&6
Jack Jansen7b8c7542002-04-14 20:12:41 +000011607
11608# Check whether --with-universal-newlines or --without-universal-newlines was given.
11609if test "${with_universal_newlines+set}" = set; then
11610 withval="$with_universal_newlines"
11611
11612fi;
11613
11614if test -z "$with_universal_newlines"
11615then with_universal_newlines="yes"
11616fi
11617if test "$with_universal_newlines" != "no"
11618then
Martin v. Löwise8aea582002-04-16 05:51:02 +000011619
11620cat >>confdefs.h <<\_ACEOF
Jack Jansen7b8c7542002-04-14 20:12:41 +000011621#define WITH_UNIVERSAL_NEWLINES 1
11622_ACEOF
11623
11624fi
11625echo "$as_me:$LINENO: result: $with_universal_newlines" >&5
11626echo "${ECHO_T}$with_universal_newlines" >&6
11627
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000011628# Check for --with-doc-strings
11629echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
11630echo $ECHO_N "checking for --with-doc-strings... $ECHO_C" >&6
11631
11632# Check whether --with-doc-strings or --without-doc-strings was given.
11633if test "${with_doc_strings+set}" = set; then
11634 withval="$with_doc_strings"
11635
11636fi;
11637
11638if test -z "$with_doc_strings"
11639then with_doc_strings="yes"
11640fi
11641if test "$with_doc_strings" != "no"
11642then
11643
11644cat >>confdefs.h <<\_ACEOF
11645#define WITH_DOC_STRINGS 1
11646_ACEOF
11647
11648fi
11649echo "$as_me:$LINENO: result: $with_doc_strings" >&5
11650echo "${ECHO_T}$with_doc_strings" >&6
11651
Neil Schemenauera35c6882001-02-27 04:45:05 +000011652# Check for Python-specific malloc support
Martin v. Löwis11437992002-04-12 09:54:03 +000011653echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
11654echo $ECHO_N "checking for --with-pymalloc... $ECHO_C" >&6
11655
Neil Schemenauera35c6882001-02-27 04:45:05 +000011656# Check whether --with-pymalloc or --without-pymalloc was given.
11657if test "${with_pymalloc+set}" = set; then
11658 withval="$with_pymalloc"
Michael W. Hudson54241132001-12-07 15:38:26 +000011659
Martin v. Löwis11437992002-04-12 09:54:03 +000011660fi;
Neil Schemenauera35c6882001-02-27 04:45:05 +000011661
Neil Schemenauer16c22972002-03-22 15:34:49 +000011662if test -z "$with_pymalloc"
11663then with_pymalloc="yes"
11664fi
11665if test "$with_pymalloc" != "no"
11666then
Martin v. Löwis11437992002-04-12 09:54:03 +000011667
11668cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011669#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011670_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000011671
11672fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011673echo "$as_me:$LINENO: result: $with_pymalloc" >&5
11674echo "${ECHO_T}$with_pymalloc" >&6
Neil Schemenauer16c22972002-03-22 15:34:49 +000011675
Barry Warsawef82cd72000-06-30 16:21:01 +000011676# Check for --with-wctype-functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011677echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
11678echo $ECHO_N "checking for --with-wctype-functions... $ECHO_C" >&6
11679
Barry Warsawef82cd72000-06-30 16:21:01 +000011680# Check whether --with-wctype-functions or --without-wctype-functions was given.
11681if test "${with_wctype_functions+set}" = set; then
11682 withval="$with_wctype_functions"
Martin v. Löwis11437992002-04-12 09:54:03 +000011683
Barry Warsawef82cd72000-06-30 16:21:01 +000011684if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000011685then
11686
11687cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000011688#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011689_ACEOF
11690
11691 echo "$as_me:$LINENO: result: yes" >&5
11692echo "${ECHO_T}yes" >&6
11693else echo "$as_me:$LINENO: result: no" >&5
11694echo "${ECHO_T}no" >&6
Barry Warsawef82cd72000-06-30 16:21:01 +000011695fi
11696else
Martin v. Löwis11437992002-04-12 09:54:03 +000011697 echo "$as_me:$LINENO: result: no" >&5
11698echo "${ECHO_T}no" >&6
11699fi;
Barry Warsawef82cd72000-06-30 16:21:01 +000011700
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011701# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000011702
Guido van Rossum98935bf2001-09-05 19:13:16 +000011703DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000011704
Martin v. Löwis11437992002-04-12 09:54:03 +000011705echo "$as_me:$LINENO: checking for --with-sgi-dl" >&5
11706echo $ECHO_N "checking for --with-sgi-dl... $ECHO_C" >&6
11707
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011708# Check whether --with-sgi-dl or --without-sgi-dl was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011709if test "${with_sgi_dl+set}" = set; then
11710 withval="$with_sgi_dl"
Martin v. Löwis11437992002-04-12 09:54:03 +000011711
11712echo "$as_me:$LINENO: result: $withval" >&5
11713echo "${ECHO_T}$withval" >&6
11714
11715cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011716#define WITH_SGI_DL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011717_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011718
Guido van Rossume97ee181999-12-20 21:27:22 +000011719DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011720dldir=$withval
Guido van Rossum40951012000-10-07 16:21:27 +000011721if test ! -z "$dldir" -a -d "$dldir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011722then LDFLAGS="$LDFLAGS -L$dldir"
Martin v. Löwis11437992002-04-12 09:54:03 +000011723else { { echo "$as_me:$LINENO: error: proper usage is --with-sgi-dl=DIRECTORY" >&5
11724echo "$as_me: error: proper usage is --with-sgi-dl=DIRECTORY" >&2;}
11725 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011726fi
11727DLINCLDIR=${dldir}
11728LIBS="$LIBS -ldl -lmld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011729else
Martin v. Löwis11437992002-04-12 09:54:03 +000011730 echo "$as_me:$LINENO: result: no" >&5
11731echo "${ECHO_T}no" >&6
11732fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011733
Martin v. Löwis11437992002-04-12 09:54:03 +000011734echo "$as_me:$LINENO: checking for --with-dl-dld" >&5
11735echo $ECHO_N "checking for --with-dl-dld... $ECHO_C" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000011736
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011737# Check whether --with-dl-dld or --without-dl-dld was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011738if test "${with_dl_dld+set}" = set; then
11739 withval="$with_dl_dld"
Martin v. Löwis11437992002-04-12 09:54:03 +000011740
11741echo "$as_me:$LINENO: result: $withval" >&5
11742echo "${ECHO_T}$withval" >&6
11743
11744cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011745#define WITH_DL_DLD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011746_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000011747
Guido van Rossume97ee181999-12-20 21:27:22 +000011748DYNLOADFILE="dynload_dl.o"
Guido van Rossum7f43da71994-08-01 12:15:30 +000011749dldir=`echo "$withval" | sed 's/,.*//'`
11750dlddir=`echo "$withval" | sed 's/.*,//'`
Barry Warsaw7d1219d2000-10-05 18:45:53 +000011751if test ! -z "$dldir" -a -d "$dldir" -a ! -z "$dlddir" -a -d "$dlddir"
Guido van Rossum84e7b241996-08-19 21:59:00 +000011752then LDFLAGS="$LDFLAGS -L$dldir -L$dlddir"
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000011753else { { echo "$as_me:$LINENO: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&5
11754echo "$as_me: error: proper usage is --with-dl-dld=DL_DIRECTORY,DLD_DIRECTORY" >&2;}
11755 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000011756fi
11757DLINCLDIR=${dldir}
11758LIBS="$LIBS -ldl -ldld"
Guido van Rossumda88dad1995-01-26 00:46:29 +000011759else
Martin v. Löwis11437992002-04-12 09:54:03 +000011760 echo "$as_me:$LINENO: result: no" >&5
11761echo "${ECHO_T}no" >&6
11762fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000011763
Guido van Rossume97ee181999-12-20 21:27:22 +000011764# the dlopen() function means we might want to use dynload_shlib.o. some
11765# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000011766
Thomas Wouters3a584202000-08-05 23:28:51 +000011767for ac_func in dlopen
11768do
Martin v. Löwis11437992002-04-12 09:54:03 +000011769as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11770echo "$as_me:$LINENO: checking for $ac_func" >&5
11771echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11772if eval "test \"\${$as_ac_var+set}\" = set"; then
11773 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011774else
Martin v. Löwis11437992002-04-12 09:54:03 +000011775 cat >conftest.$ac_ext <<_ACEOF
11776#line $LINENO "configure"
Guido van Rossume97ee181999-12-20 21:27:22 +000011777#include "confdefs.h"
11778/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011779 which can conflict with char $ac_func (); below. */
Guido van Rossume97ee181999-12-20 21:27:22 +000011780#include <assert.h>
11781/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011782#ifdef __cplusplus
11783extern "C"
11784#endif
Guido van Rossume97ee181999-12-20 21:27:22 +000011785/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011786 builtin and then its argument prototype would still apply. */
11787char $ac_func ();
11788char (*f) ();
Guido van Rossume97ee181999-12-20 21:27:22 +000011789
Martin v. Löwis11437992002-04-12 09:54:03 +000011790#ifdef F77_DUMMY_MAIN
11791# ifdef __cplusplus
11792 extern "C"
11793# endif
11794 int F77_DUMMY_MAIN() { return 1; }
11795#endif
11796int
11797main ()
11798{
Guido van Rossume97ee181999-12-20 21:27:22 +000011799/* The GNU C library defines this for functions which it implements
11800 to always fail with ENOSYS. Some functions are actually named
11801 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000011802#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossume97ee181999-12-20 21:27:22 +000011803choke me
11804#else
Martin v. Löwis11437992002-04-12 09:54:03 +000011805f = $ac_func;
Guido van Rossume97ee181999-12-20 21:27:22 +000011806#endif
11807
Martin v. Löwis11437992002-04-12 09:54:03 +000011808 ;
11809 return 0;
11810}
11811_ACEOF
11812rm -f conftest.$ac_objext conftest$ac_exeext
11813if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11814 (eval $ac_link) 2>&5
11815 ac_status=$?
11816 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11817 (exit $ac_status); } &&
11818 { ac_try='test -s conftest$ac_exeext'
11819 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11820 (eval $ac_try) 2>&5
11821 ac_status=$?
11822 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11823 (exit $ac_status); }; }; then
11824 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000011825else
Martin v. Löwis11437992002-04-12 09:54:03 +000011826 echo "$as_me: failed program was:" >&5
11827cat conftest.$ac_ext >&5
11828eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000011829fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011830rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000011831fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011832echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11833echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11834if test `eval echo '${'$as_ac_var'}'` = yes; then
11835 cat >>confdefs.h <<_ACEOF
11836#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11837_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011838
Guido van Rossume97ee181999-12-20 21:27:22 +000011839fi
Thomas Wouters3a584202000-08-05 23:28:51 +000011840done
Guido van Rossume97ee181999-12-20 21:27:22 +000011841
Michael W. Hudson54241132001-12-07 15:38:26 +000011842
Guido van Rossume97ee181999-12-20 21:27:22 +000011843# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
11844# loading of modules.
11845
Martin v. Löwis11437992002-04-12 09:54:03 +000011846echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
11847echo $ECHO_N "checking DYNLOADFILE... $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011848if test -z "$DYNLOADFILE"
11849then
11850 case $ac_sys_system/$ac_sys_release in
11851 AIX*) DYNLOADFILE="dynload_aix.o";;
11852 BeOS*) DYNLOADFILE="dynload_beos.o";;
11853 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Jack Jansene578a632001-08-15 01:27:14 +000011854 Darwin/*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000011855 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000011856 *)
11857 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
11858 # out any dynamic loading
11859 if test "$ac_cv_func_dlopen" = yes
11860 then DYNLOADFILE="dynload_shlib.o"
11861 else DYNLOADFILE="dynload_stub.o"
11862 fi
11863 ;;
11864 esac
11865fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011866echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
11867echo "${ECHO_T}$DYNLOADFILE" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000011868if test "$DYNLOADFILE" != "dynload_stub.o"
11869then
Martin v. Löwis11437992002-04-12 09:54:03 +000011870
11871cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011872#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011873_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000011874
11875fi
11876
Neil Schemenauer4e425612001-06-19 15:44:15 +000011877# MACHDEP_OBJS can be set to platform-specific object files needed by Python
11878
Michael W. Hudson54241132001-12-07 15:38:26 +000011879
Martin v. Löwis11437992002-04-12 09:54:03 +000011880echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
11881echo $ECHO_N "checking MACHDEP_OBJS... $ECHO_C" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011882if test -z "$MACHDEP_OBJS"
11883then
Jack Jansene578a632001-08-15 01:27:14 +000011884 MACHDEP_OBJS=$extra_machdep_objs
11885else
11886 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000011887fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011888echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
11889echo "${ECHO_T}MACHDEP_OBJS" >&6
Neil Schemenauer4e425612001-06-19 15:44:15 +000011890
Guido van Rossum627b2d71993-12-24 10:39:16 +000011891# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000011892
11893
11894
11895
11896
11897
11898
11899
11900
11901
11902
11903
11904
11905
11906
11907
11908
11909
11910
11911
11912
11913
11914
11915
11916
11917
11918
11919
11920
11921
11922
11923
11924
11925
11926
11927
11928
11929
11930
11931
11932
11933
11934
11935
11936
11937
11938
11939
11940
11941
11942
11943
11944
11945
11946
11947
11948
11949
11950
11951
11952
11953
11954
11955
11956
11957
11958
11959
11960
11961
11962
11963
11964
Martin v. Löwis06a83e92002-04-14 10:19:44 +000011965
Fred Drake6b3cc522002-04-15 19:20:27 +000011966
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000011967for ac_func in alarm chown clock confstr ctermid ctermid_r execv \
Fred Drake6b3cc522002-04-15 19:20:27 +000011968 fchdir flock fork fsync fdatasync fpathconf ftime ftruncate \
Martin v. Löwis606edc12002-06-13 21:09:11 +000011969 gai_strerror getgroups getlogin getpeername getpgid getpid getpwent getwd \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000011970 hstrerror inet_pton kill killpg lchown lstat mkfifo mknod mktime \
Martin v. Löwisa5f09072002-10-11 05:37:59 +000011971 mremap nice pathconf pause plock poll pthread_init \
Fred Drake35a092f1999-12-13 16:23:35 +000011972 putenv readlink \
Martin v. Löwis61c5edf2001-10-18 04:06:00 +000011973 select setegid seteuid setgid setgroups \
Martin v. Löwis791bfda2001-07-24 06:33:08 +000011974 setlocale setregid setreuid setsid setpgid setuid setvbuf snprintf \
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000011975 sigaction siginterrupt sigrelse strftime strptime \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000011976 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Martin v. Löwis6aa9fdb2002-09-10 09:16:13 +000011977 truncate uname unsetenv utimes waitpid _getpty getpriority
Guido van Rossum627b2d71993-12-24 10:39:16 +000011978do
Martin v. Löwis11437992002-04-12 09:54:03 +000011979as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11980echo "$as_me:$LINENO: checking for $ac_func" >&5
11981echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11982if eval "test \"\${$as_ac_var+set}\" = set"; then
11983 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000011984else
Martin v. Löwis11437992002-04-12 09:54:03 +000011985 cat >conftest.$ac_ext <<_ACEOF
11986#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000011987#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011988/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000011989 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011990#include <assert.h>
11991/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011992#ifdef __cplusplus
11993extern "C"
11994#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000011995/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000011996 builtin and then its argument prototype would still apply. */
11997char $ac_func ();
11998char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000011999
Martin v. Löwis11437992002-04-12 09:54:03 +000012000#ifdef F77_DUMMY_MAIN
12001# ifdef __cplusplus
12002 extern "C"
12003# endif
12004 int F77_DUMMY_MAIN() { return 1; }
12005#endif
12006int
12007main ()
12008{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012009/* The GNU C library defines this for functions which it implements
12010 to always fail with ENOSYS. Some functions are actually named
12011 something starting with __ and the normal name is an alias. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012012#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012013choke me
12014#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012015f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012016#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012017
Martin v. Löwis11437992002-04-12 09:54:03 +000012018 ;
12019 return 0;
12020}
12021_ACEOF
12022rm -f conftest.$ac_objext conftest$ac_exeext
12023if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12024 (eval $ac_link) 2>&5
12025 ac_status=$?
12026 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12027 (exit $ac_status); } &&
12028 { ac_try='test -s conftest$ac_exeext'
12029 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12030 (eval $ac_try) 2>&5
12031 ac_status=$?
12032 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12033 (exit $ac_status); }; }; then
12034 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012035else
Martin v. Löwis11437992002-04-12 09:54:03 +000012036 echo "$as_me: failed program was:" >&5
12037cat conftest.$ac_ext >&5
12038eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012039fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012040rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012041fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012042echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12043echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12044if test `eval echo '${'$as_ac_var'}'` = yes; then
12045 cat >>confdefs.h <<_ACEOF
12046#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12047_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012048
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012049fi
12050done
12051
Michael W. Hudson54241132001-12-07 15:38:26 +000012052
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000012053# For some functions, having a definition is not sufficient, since
12054# we want to take their address.
12055echo "$as_me:$LINENO: checking for chroot" >&5
12056echo $ECHO_N "checking for chroot... $ECHO_C" >&6
12057cat >conftest.$ac_ext <<_ACEOF
12058#line $LINENO "configure"
12059#include "confdefs.h"
12060#include <unistd.h>
12061#ifdef F77_DUMMY_MAIN
12062# ifdef __cplusplus
12063 extern "C"
12064# endif
12065 int F77_DUMMY_MAIN() { return 1; }
12066#endif
12067int
12068main ()
12069{
12070void *x=chroot
12071 ;
12072 return 0;
12073}
12074_ACEOF
12075rm -f conftest.$ac_objext
12076if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12077 (eval $ac_compile) 2>&5
12078 ac_status=$?
12079 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12080 (exit $ac_status); } &&
12081 { ac_try='test -s conftest.$ac_objext'
12082 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12083 (eval $ac_try) 2>&5
12084 ac_status=$?
12085 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12086 (exit $ac_status); }; }; then
12087
12088cat >>confdefs.h <<\_ACEOF
12089#define HAVE_CHROOT 1
12090_ACEOF
12091
12092 echo "$as_me:$LINENO: result: yes" >&5
12093echo "${ECHO_T}yes" >&6
12094else
12095 echo "$as_me: failed program was:" >&5
12096cat conftest.$ac_ext >&5
12097echo "$as_me:$LINENO: result: no" >&5
12098echo "${ECHO_T}no" >&6
12099
12100fi
12101rm -f conftest.$ac_objext conftest.$ac_ext
12102echo "$as_me:$LINENO: checking for link" >&5
12103echo $ECHO_N "checking for link... $ECHO_C" >&6
12104cat >conftest.$ac_ext <<_ACEOF
12105#line $LINENO "configure"
12106#include "confdefs.h"
12107#include <unistd.h>
12108#ifdef F77_DUMMY_MAIN
12109# ifdef __cplusplus
12110 extern "C"
12111# endif
12112 int F77_DUMMY_MAIN() { return 1; }
12113#endif
12114int
12115main ()
12116{
12117void *x=link
12118 ;
12119 return 0;
12120}
12121_ACEOF
12122rm -f conftest.$ac_objext
12123if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12124 (eval $ac_compile) 2>&5
12125 ac_status=$?
12126 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12127 (exit $ac_status); } &&
12128 { ac_try='test -s conftest.$ac_objext'
12129 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12130 (eval $ac_try) 2>&5
12131 ac_status=$?
12132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12133 (exit $ac_status); }; }; then
12134
12135cat >>confdefs.h <<\_ACEOF
12136#define HAVE_LINK 1
12137_ACEOF
12138
12139 echo "$as_me:$LINENO: result: yes" >&5
12140echo "${ECHO_T}yes" >&6
12141else
12142 echo "$as_me: failed program was:" >&5
12143cat conftest.$ac_ext >&5
12144echo "$as_me:$LINENO: result: no" >&5
12145echo "${ECHO_T}no" >&6
12146
12147fi
12148rm -f conftest.$ac_objext conftest.$ac_ext
12149echo "$as_me:$LINENO: checking for symlink" >&5
12150echo $ECHO_N "checking for symlink... $ECHO_C" >&6
12151cat >conftest.$ac_ext <<_ACEOF
12152#line $LINENO "configure"
12153#include "confdefs.h"
12154#include <unistd.h>
12155#ifdef F77_DUMMY_MAIN
12156# ifdef __cplusplus
12157 extern "C"
12158# endif
12159 int F77_DUMMY_MAIN() { return 1; }
12160#endif
12161int
12162main ()
12163{
12164void *x=symlink
12165 ;
12166 return 0;
12167}
12168_ACEOF
12169rm -f conftest.$ac_objext
12170if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12171 (eval $ac_compile) 2>&5
12172 ac_status=$?
12173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12174 (exit $ac_status); } &&
12175 { ac_try='test -s conftest.$ac_objext'
12176 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12177 (eval $ac_try) 2>&5
12178 ac_status=$?
12179 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12180 (exit $ac_status); }; }; then
12181
12182cat >>confdefs.h <<\_ACEOF
12183#define HAVE_SYMLINK 1
12184_ACEOF
12185
12186 echo "$as_me:$LINENO: result: yes" >&5
12187echo "${ECHO_T}yes" >&6
12188else
12189 echo "$as_me: failed program was:" >&5
12190cat conftest.$ac_ext >&5
12191echo "$as_me:$LINENO: result: no" >&5
12192echo "${ECHO_T}no" >&6
12193
12194fi
12195rm -f conftest.$ac_objext conftest.$ac_ext
12196
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012197# check for openpty and forkpty
12198
Martin v. Löwis11437992002-04-12 09:54:03 +000012199
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012200for ac_func in openpty
12201do
Martin v. Löwis11437992002-04-12 09:54:03 +000012202as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12203echo "$as_me:$LINENO: checking for $ac_func" >&5
12204echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12205if eval "test \"\${$as_ac_var+set}\" = set"; then
12206 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012207else
Martin v. Löwis11437992002-04-12 09:54:03 +000012208 cat >conftest.$ac_ext <<_ACEOF
12209#line $LINENO "configure"
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012210#include "confdefs.h"
12211/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012212 which can conflict with char $ac_func (); below. */
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012213#include <assert.h>
12214/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012215#ifdef __cplusplus
12216extern "C"
12217#endif
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012218/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012219 builtin and then its argument prototype would still apply. */
12220char $ac_func ();
12221char (*f) ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012222
Martin v. Löwis11437992002-04-12 09:54:03 +000012223#ifdef F77_DUMMY_MAIN
12224# ifdef __cplusplus
12225 extern "C"
12226# endif
12227 int F77_DUMMY_MAIN() { return 1; }
12228#endif
12229int
12230main ()
12231{
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012232/* The GNU C library defines this for functions which it implements
12233 to always fail with ENOSYS. Some functions are actually named
12234 something starting with __ and the normal name is an alias. */
12235#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12236choke me
12237#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012238f = $ac_func;
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012239#endif
12240
Martin v. Löwis11437992002-04-12 09:54:03 +000012241 ;
12242 return 0;
12243}
12244_ACEOF
12245rm -f conftest.$ac_objext conftest$ac_exeext
12246if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12247 (eval $ac_link) 2>&5
12248 ac_status=$?
12249 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12250 (exit $ac_status); } &&
12251 { ac_try='test -s conftest$ac_exeext'
12252 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12253 (eval $ac_try) 2>&5
12254 ac_status=$?
12255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12256 (exit $ac_status); }; }; then
12257 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012258else
Martin v. Löwis11437992002-04-12 09:54:03 +000012259 echo "$as_me: failed program was:" >&5
12260cat conftest.$ac_ext >&5
12261eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012262fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012263rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012264fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012265echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12266echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12267if test `eval echo '${'$as_ac_var'}'` = yes; then
12268 cat >>confdefs.h <<_ACEOF
12269#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12270_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012271
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000012272else
Martin v. Löwis11437992002-04-12 09:54:03 +000012273 echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
12274echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
12275if test "${ac_cv_lib_util_openpty+set}" = set; then
12276 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012277else
Martin v. Löwis11437992002-04-12 09:54:03 +000012278 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012279LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012280cat >conftest.$ac_ext <<_ACEOF
12281#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012282#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000012283
Fred Drake8cef4cf2000-06-28 16:40:38 +000012284/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012285#ifdef __cplusplus
12286extern "C"
12287#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012288/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012289 builtin and then its argument prototype would still apply. */
12290char openpty ();
12291#ifdef F77_DUMMY_MAIN
12292# ifdef __cplusplus
12293 extern "C"
12294# endif
12295 int F77_DUMMY_MAIN() { return 1; }
12296#endif
12297int
12298main ()
12299{
12300openpty ();
12301 ;
12302 return 0;
12303}
12304_ACEOF
12305rm -f conftest.$ac_objext conftest$ac_exeext
12306if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12307 (eval $ac_link) 2>&5
12308 ac_status=$?
12309 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12310 (exit $ac_status); } &&
12311 { ac_try='test -s conftest$ac_exeext'
12312 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12313 (eval $ac_try) 2>&5
12314 ac_status=$?
12315 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12316 (exit $ac_status); }; }; then
12317 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012318else
Martin v. Löwis11437992002-04-12 09:54:03 +000012319 echo "$as_me: failed program was:" >&5
12320cat conftest.$ac_ext >&5
12321ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012322fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012323rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12324LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012325fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012326echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
12327echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
12328if test $ac_cv_lib_util_openpty = yes; then
12329 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012330#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012331_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012332 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012333fi
12334
12335fi
12336done
12337
Martin v. Löwis11437992002-04-12 09:54:03 +000012338
Fred Drake8cef4cf2000-06-28 16:40:38 +000012339for ac_func in forkpty
12340do
Martin v. Löwis11437992002-04-12 09:54:03 +000012341as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12342echo "$as_me:$LINENO: checking for $ac_func" >&5
12343echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12344if eval "test \"\${$as_ac_var+set}\" = set"; then
12345 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012346else
Martin v. Löwis11437992002-04-12 09:54:03 +000012347 cat >conftest.$ac_ext <<_ACEOF
12348#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012349#include "confdefs.h"
12350/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012351 which can conflict with char $ac_func (); below. */
Fred Drake8cef4cf2000-06-28 16:40:38 +000012352#include <assert.h>
12353/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012354#ifdef __cplusplus
12355extern "C"
12356#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012357/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012358 builtin and then its argument prototype would still apply. */
12359char $ac_func ();
12360char (*f) ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000012361
Martin v. Löwis11437992002-04-12 09:54:03 +000012362#ifdef F77_DUMMY_MAIN
12363# ifdef __cplusplus
12364 extern "C"
12365# endif
12366 int F77_DUMMY_MAIN() { return 1; }
12367#endif
12368int
12369main ()
12370{
Fred Drake8cef4cf2000-06-28 16:40:38 +000012371/* The GNU C library defines this for functions which it implements
12372 to always fail with ENOSYS. Some functions are actually named
12373 something starting with __ and the normal name is an alias. */
12374#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12375choke me
12376#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012377f = $ac_func;
Fred Drake8cef4cf2000-06-28 16:40:38 +000012378#endif
12379
Martin v. Löwis11437992002-04-12 09:54:03 +000012380 ;
12381 return 0;
12382}
12383_ACEOF
12384rm -f conftest.$ac_objext conftest$ac_exeext
12385if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12386 (eval $ac_link) 2>&5
12387 ac_status=$?
12388 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12389 (exit $ac_status); } &&
12390 { ac_try='test -s conftest$ac_exeext'
12391 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12392 (eval $ac_try) 2>&5
12393 ac_status=$?
12394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12395 (exit $ac_status); }; }; then
12396 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012397else
Martin v. Löwis11437992002-04-12 09:54:03 +000012398 echo "$as_me: failed program was:" >&5
12399cat conftest.$ac_ext >&5
12400eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012401fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012402rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012403fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012404echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12405echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12406if test `eval echo '${'$as_ac_var'}'` = yes; then
12407 cat >>confdefs.h <<_ACEOF
12408#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12409_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012410
Fred Drake8cef4cf2000-06-28 16:40:38 +000012411else
Martin v. Löwis11437992002-04-12 09:54:03 +000012412 echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
12413echo $ECHO_N "checking for forkpty in -lutil... $ECHO_C" >&6
12414if test "${ac_cv_lib_util_forkpty+set}" = set; then
12415 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000012416else
Martin v. Löwis11437992002-04-12 09:54:03 +000012417 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012418LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000012419cat >conftest.$ac_ext <<_ACEOF
12420#line $LINENO "configure"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012421#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000012422
Fred Drake8cef4cf2000-06-28 16:40:38 +000012423/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012424#ifdef __cplusplus
12425extern "C"
12426#endif
Fred Drake8cef4cf2000-06-28 16:40:38 +000012427/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012428 builtin and then its argument prototype would still apply. */
12429char forkpty ();
12430#ifdef F77_DUMMY_MAIN
12431# ifdef __cplusplus
12432 extern "C"
12433# endif
12434 int F77_DUMMY_MAIN() { return 1; }
12435#endif
12436int
12437main ()
12438{
12439forkpty ();
12440 ;
12441 return 0;
12442}
12443_ACEOF
12444rm -f conftest.$ac_objext conftest$ac_exeext
12445if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12446 (eval $ac_link) 2>&5
12447 ac_status=$?
12448 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12449 (exit $ac_status); } &&
12450 { ac_try='test -s conftest$ac_exeext'
12451 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12452 (eval $ac_try) 2>&5
12453 ac_status=$?
12454 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12455 (exit $ac_status); }; }; then
12456 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000012457else
Martin v. Löwis11437992002-04-12 09:54:03 +000012458 echo "$as_me: failed program was:" >&5
12459cat conftest.$ac_ext >&5
12460ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000012461fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012462rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12463LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000012464fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012465echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
12466echo "${ECHO_T}$ac_cv_lib_util_forkpty" >&6
12467if test $ac_cv_lib_util_forkpty = yes; then
12468 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012469#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012470_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000012471 LIBS="$LIBS -lutil"
Fred Drake8cef4cf2000-06-28 16:40:38 +000012472fi
12473
12474fi
12475done
12476
Jack Jansendd19cf82001-12-06 22:36:17 +000012477
Michael W. Hudson54241132001-12-07 15:38:26 +000012478# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000012479
12480
12481
12482
12483
12484
Fred Drake8cef4cf2000-06-28 16:40:38 +000012485for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
12486do
Martin v. Löwis11437992002-04-12 09:54:03 +000012487as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12488echo "$as_me:$LINENO: checking for $ac_func" >&5
12489echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12490if eval "test \"\${$as_ac_var+set}\" = set"; then
12491 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012492else
Martin v. Löwis11437992002-04-12 09:54:03 +000012493 cat >conftest.$ac_ext <<_ACEOF
12494#line $LINENO "configure"
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012495#include "confdefs.h"
12496/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012497 which can conflict with char $ac_func (); below. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012498#include <assert.h>
12499/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012500#ifdef __cplusplus
12501extern "C"
12502#endif
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012503/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012504 builtin and then its argument prototype would still apply. */
12505char $ac_func ();
12506char (*f) ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012507
Martin v. Löwis11437992002-04-12 09:54:03 +000012508#ifdef F77_DUMMY_MAIN
12509# ifdef __cplusplus
12510 extern "C"
12511# endif
12512 int F77_DUMMY_MAIN() { return 1; }
12513#endif
12514int
12515main ()
12516{
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012517/* The GNU C library defines this for functions which it implements
12518 to always fail with ENOSYS. Some functions are actually named
12519 something starting with __ and the normal name is an alias. */
12520#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12521choke me
12522#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012523f = $ac_func;
Guido van Rossumf98e2a71999-01-06 18:53:34 +000012524#endif
12525
Martin v. Löwis11437992002-04-12 09:54:03 +000012526 ;
12527 return 0;
12528}
12529_ACEOF
12530rm -f conftest.$ac_objext conftest$ac_exeext
12531if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12532 (eval $ac_link) 2>&5
12533 ac_status=$?
12534 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12535 (exit $ac_status); } &&
12536 { ac_try='test -s conftest$ac_exeext'
12537 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12538 (eval $ac_try) 2>&5
12539 ac_status=$?
12540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12541 (exit $ac_status); }; }; then
12542 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012543else
Martin v. Löwis11437992002-04-12 09:54:03 +000012544 echo "$as_me: failed program was:" >&5
12545cat conftest.$ac_ext >&5
12546eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012547fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012548rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012549fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012550echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12551echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12552if test `eval echo '${'$as_ac_var'}'` = yes; then
12553 cat >>confdefs.h <<_ACEOF
12554#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12555_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000012556
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012557fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000012558done
12559
Michael W. Hudson54241132001-12-07 15:38:26 +000012560
Martin v. Löwis11437992002-04-12 09:54:03 +000012561
12562
12563
12564
12565
Martin v. Löwis1142de32002-03-29 16:28:31 +000012566for ac_func in dup2 getcwd strdup strerror memmove
Thomas Wouters3a584202000-08-05 23:28:51 +000012567do
Martin v. Löwis11437992002-04-12 09:54:03 +000012568as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12569echo "$as_me:$LINENO: checking for $ac_func" >&5
12570echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12571if eval "test \"\${$as_ac_var+set}\" = set"; then
12572 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012573else
Martin v. Löwis11437992002-04-12 09:54:03 +000012574 cat >conftest.$ac_ext <<_ACEOF
12575#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012576#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012577/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012578 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012579#include <assert.h>
12580/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012581#ifdef __cplusplus
12582extern "C"
12583#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012584/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012585 builtin and then its argument prototype would still apply. */
12586char $ac_func ();
12587char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012588
Martin v. Löwis11437992002-04-12 09:54:03 +000012589#ifdef F77_DUMMY_MAIN
12590# ifdef __cplusplus
12591 extern "C"
12592# endif
12593 int F77_DUMMY_MAIN() { return 1; }
12594#endif
12595int
12596main ()
12597{
Guido van Rossum627b2d71993-12-24 10:39:16 +000012598/* The GNU C library defines this for functions which it implements
12599 to always fail with ENOSYS. Some functions are actually named
12600 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012601#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum627b2d71993-12-24 10:39:16 +000012602choke me
12603#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012604f = $ac_func;
Guido van Rossum627b2d71993-12-24 10:39:16 +000012605#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012606
Martin v. Löwis11437992002-04-12 09:54:03 +000012607 ;
12608 return 0;
12609}
12610_ACEOF
12611rm -f conftest.$ac_objext conftest$ac_exeext
12612if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12613 (eval $ac_link) 2>&5
12614 ac_status=$?
12615 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12616 (exit $ac_status); } &&
12617 { ac_try='test -s conftest$ac_exeext'
12618 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12619 (eval $ac_try) 2>&5
12620 ac_status=$?
12621 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12622 (exit $ac_status); }; }; then
12623 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012624else
Martin v. Löwis11437992002-04-12 09:54:03 +000012625 echo "$as_me: failed program was:" >&5
12626cat conftest.$ac_ext >&5
12627eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012628fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012629rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000012630fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012631echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12632echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12633if test `eval echo '${'$as_ac_var'}'` = yes; then
12634 cat >>confdefs.h <<_ACEOF
12635#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12636_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000012637
Martin v. Löwis1142de32002-03-29 16:28:31 +000012638else
Martin v. Löwis11437992002-04-12 09:54:03 +000012639 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012640fi
12641done
12642
12643
Martin v. Löwis11437992002-04-12 09:54:03 +000012644
Martin v. Löwis1142de32002-03-29 16:28:31 +000012645for ac_func in getpgrp
12646do
Martin v. Löwis11437992002-04-12 09:54:03 +000012647as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12648echo "$as_me:$LINENO: checking for $ac_func" >&5
12649echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12650if eval "test \"\${$as_ac_var+set}\" = set"; then
12651 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000012652else
Martin v. Löwis11437992002-04-12 09:54:03 +000012653 cat >conftest.$ac_ext <<_ACEOF
12654#line $LINENO "configure"
Martin v. Löwis1142de32002-03-29 16:28:31 +000012655#include "confdefs.h"
12656/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012657 which can conflict with char $ac_func (); below. */
Martin v. Löwis1142de32002-03-29 16:28:31 +000012658#include <assert.h>
12659/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012660#ifdef __cplusplus
12661extern "C"
12662#endif
Martin v. Löwis1142de32002-03-29 16:28:31 +000012663/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012664 builtin and then its argument prototype would still apply. */
12665char $ac_func ();
12666char (*f) ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000012667
Martin v. Löwis11437992002-04-12 09:54:03 +000012668#ifdef F77_DUMMY_MAIN
12669# ifdef __cplusplus
12670 extern "C"
12671# endif
12672 int F77_DUMMY_MAIN() { return 1; }
12673#endif
12674int
12675main ()
12676{
Martin v. Löwis1142de32002-03-29 16:28:31 +000012677/* The GNU C library defines this for functions which it implements
12678 to always fail with ENOSYS. Some functions are actually named
12679 something starting with __ and the normal name is an alias. */
12680#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12681choke me
12682#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012683f = $ac_func;
Martin v. Löwis1142de32002-03-29 16:28:31 +000012684#endif
12685
Martin v. Löwis11437992002-04-12 09:54:03 +000012686 ;
12687 return 0;
12688}
12689_ACEOF
12690rm -f conftest.$ac_objext conftest$ac_exeext
12691if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12692 (eval $ac_link) 2>&5
12693 ac_status=$?
12694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12695 (exit $ac_status); } &&
12696 { ac_try='test -s conftest$ac_exeext'
12697 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12698 (eval $ac_try) 2>&5
12699 ac_status=$?
12700 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12701 (exit $ac_status); }; }; then
12702 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012703else
Martin v. Löwis11437992002-04-12 09:54:03 +000012704 echo "$as_me: failed program was:" >&5
12705cat conftest.$ac_ext >&5
12706eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012707fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012708rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012709fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012710echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12711echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12712if test `eval echo '${'$as_ac_var'}'` = yes; then
12713 cat >>confdefs.h <<_ACEOF
12714#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12715_ACEOF
12716 cat >conftest.$ac_ext <<_ACEOF
12717#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012718#include "confdefs.h"
12719#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012720#ifdef F77_DUMMY_MAIN
12721# ifdef __cplusplus
12722 extern "C"
12723# endif
12724 int F77_DUMMY_MAIN() { return 1; }
12725#endif
12726int
12727main ()
12728{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012729getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000012730 ;
12731 return 0;
12732}
12733_ACEOF
12734rm -f conftest.$ac_objext
12735if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12736 (eval $ac_compile) 2>&5
12737 ac_status=$?
12738 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12739 (exit $ac_status); } &&
12740 { ac_try='test -s conftest.$ac_objext'
12741 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12742 (eval $ac_try) 2>&5
12743 ac_status=$?
12744 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12745 (exit $ac_status); }; }; then
12746
12747cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012748#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012749_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012750
Martin v. Löwis11437992002-04-12 09:54:03 +000012751
Guido van Rossumf78abae1997-01-21 22:02:36 +000012752else
Martin v. Löwis11437992002-04-12 09:54:03 +000012753 echo "$as_me: failed program was:" >&5
12754cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000012755fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012756rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000012757
Guido van Rossum627b2d71993-12-24 10:39:16 +000012758fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012759done
Guido van Rossum627b2d71993-12-24 10:39:16 +000012760
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012761echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
12762echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
12763if test "${ac_cv_func_setpgrp_void+set}" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012764 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012765else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012766 if test "$cross_compiling" = yes; then
12767 { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5
12768echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;}
12769 { (exit 1); exit 1; }; }
12770else
Martin v. Löwis11437992002-04-12 09:54:03 +000012771 cat >conftest.$ac_ext <<_ACEOF
12772#line $LINENO "configure"
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012773#include "confdefs.h"
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012774#if HAVE_UNISTD_H
12775# include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012776#endif
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012777
Martin v. Löwis11437992002-04-12 09:54:03 +000012778#ifdef F77_DUMMY_MAIN
12779# ifdef __cplusplus
12780 extern "C"
12781# endif
12782 int F77_DUMMY_MAIN() { return 1; }
12783#endif
12784int
12785main ()
12786{
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012787/* If this system has a BSD-style setpgrp which takes arguments,
12788 setpgrp(1, 1) will fail with ESRCH and return -1, in that case
12789 exit successfully. */
12790 exit (setpgrp (1,1) == -1 ? 0 : 1);
Martin v. Löwis11437992002-04-12 09:54:03 +000012791 ;
12792 return 0;
12793}
12794_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012795rm -f conftest$ac_exeext
Martin v. Löwis11437992002-04-12 09:54:03 +000012796if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12797 (eval $ac_link) 2>&5
12798 ac_status=$?
12799 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012800 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwis11437992002-04-12 09:54:03 +000012801 { (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
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012806 ac_cv_func_setpgrp_void=no
Michael W. Hudson54241132001-12-07 15:38:26 +000012807else
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012808 echo "$as_me: program exited with status $ac_status" >&5
12809echo "$as_me: failed program was:" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012810cat conftest.$ac_ext >&5
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012811( exit $ac_status )
12812ac_cv_func_setpgrp_void=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000012813fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012814rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012815fi
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012816fi
12817echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
12818echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
12819if test $ac_cv_func_setpgrp_void = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012820
12821cat >>confdefs.h <<\_ACEOF
Jeremy Hyltonaf4c12f2002-07-18 20:25:46 +000012822#define SETPGRP_VOID 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012823_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012824
12825fi
Guido van Rossum8eee56f1994-10-20 22:18:37 +000012826
Martin v. Löwis11437992002-04-12 09:54:03 +000012827
Thomas Wouters3a584202000-08-05 23:28:51 +000012828for ac_func in gettimeofday
12829do
Martin v. Löwis11437992002-04-12 09:54:03 +000012830as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12831echo "$as_me:$LINENO: checking for $ac_func" >&5
12832echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12833if eval "test \"\${$as_ac_var+set}\" = set"; then
12834 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012835else
Martin v. Löwis11437992002-04-12 09:54:03 +000012836 cat >conftest.$ac_ext <<_ACEOF
12837#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012838#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012839/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000012840 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012841#include <assert.h>
12842/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012843#ifdef __cplusplus
12844extern "C"
12845#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000012846/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000012847 builtin and then its argument prototype would still apply. */
12848char $ac_func ();
12849char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000012850
Martin v. Löwis11437992002-04-12 09:54:03 +000012851#ifdef F77_DUMMY_MAIN
12852# ifdef __cplusplus
12853 extern "C"
12854# endif
12855 int F77_DUMMY_MAIN() { return 1; }
12856#endif
12857int
12858main ()
12859{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012860/* The GNU C library defines this for functions which it implements
12861 to always fail with ENOSYS. Some functions are actually named
12862 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000012863#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012864choke me
12865#else
Martin v. Löwis11437992002-04-12 09:54:03 +000012866f = $ac_func;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012867#endif
12868
Martin v. Löwis11437992002-04-12 09:54:03 +000012869 ;
12870 return 0;
12871}
12872_ACEOF
12873rm -f conftest.$ac_objext conftest$ac_exeext
12874if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12875 (eval $ac_link) 2>&5
12876 ac_status=$?
12877 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12878 (exit $ac_status); } &&
12879 { ac_try='test -s conftest$ac_exeext'
12880 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12881 (eval $ac_try) 2>&5
12882 ac_status=$?
12883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12884 (exit $ac_status); }; }; then
12885 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000012886else
Martin v. Löwis11437992002-04-12 09:54:03 +000012887 echo "$as_me: failed program was:" >&5
12888cat conftest.$ac_ext >&5
12889eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000012890fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012891rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000012892fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012893echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12894echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12895if test `eval echo '${'$as_ac_var'}'` = yes; then
12896 cat >>confdefs.h <<_ACEOF
12897#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12898_ACEOF
12899 cat >conftest.$ac_ext <<_ACEOF
12900#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012901#include "confdefs.h"
Guido van Rossum627b2d71993-12-24 10:39:16 +000012902#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012903#ifdef F77_DUMMY_MAIN
12904# ifdef __cplusplus
12905 extern "C"
12906# endif
12907 int F77_DUMMY_MAIN() { return 1; }
12908#endif
12909int
12910main ()
12911{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012912gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000012913 ;
12914 return 0;
12915}
12916_ACEOF
12917rm -f conftest.$ac_objext
12918if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12919 (eval $ac_compile) 2>&5
12920 ac_status=$?
12921 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12922 (exit $ac_status); } &&
12923 { ac_try='test -s conftest.$ac_objext'
12924 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12925 (eval $ac_try) 2>&5
12926 ac_status=$?
12927 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12928 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000012929 :
12930else
Martin v. Löwis11437992002-04-12 09:54:03 +000012931 echo "$as_me: failed program was:" >&5
12932cat conftest.$ac_ext >&5
12933
12934cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012935#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000012936_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000012937
Martin v. Löwis11437992002-04-12 09:54:03 +000012938
Guido van Rossum627b2d71993-12-24 10:39:16 +000012939fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012940rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000012941
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012942fi
Thomas Wouters3a584202000-08-05 23:28:51 +000012943done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000012944
Michael W. Hudson54241132001-12-07 15:38:26 +000012945
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000012946echo "$as_me:$LINENO: checking for major" >&5
12947echo $ECHO_N "checking for major... $ECHO_C" >&6
12948cat >conftest.$ac_ext <<_ACEOF
12949#line $LINENO "configure"
12950#include "confdefs.h"
12951
12952 #if defined(MAJOR_IN_MKDEV)
12953 #include <sys/mkdev.h>
12954 #elif defined(MAJOR_IN_SYSMACROS)
12955 #include <sys/sysmacros.h>
12956 #else
12957 #include <sys/types.h>
12958 #endif
12959
12960#ifdef F77_DUMMY_MAIN
12961# ifdef __cplusplus
12962 extern "C"
12963# endif
12964 int F77_DUMMY_MAIN() { return 1; }
12965#endif
12966int
12967main ()
12968{
12969
12970 makedev(major(0),minor(0));
12971
12972 ;
12973 return 0;
12974}
12975_ACEOF
Martin v. Löwise3271202002-11-07 07:42:30 +000012976rm -f conftest.$ac_objext conftest$ac_exeext
12977if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12978 (eval $ac_link) 2>&5
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000012979 ac_status=$?
12980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12981 (exit $ac_status); } &&
Martin v. Löwise3271202002-11-07 07:42:30 +000012982 { ac_try='test -s conftest$ac_exeext'
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000012983 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12984 (eval $ac_try) 2>&5
12985 ac_status=$?
12986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12987 (exit $ac_status); }; }; then
12988
12989
12990cat >>confdefs.h <<\_ACEOF
12991#define HAVE_DEVICE_MACROS 1
12992_ACEOF
12993
12994 echo "$as_me:$LINENO: result: yes" >&5
12995echo "${ECHO_T}yes" >&6
12996
12997else
12998 echo "$as_me: failed program was:" >&5
12999cat conftest.$ac_ext >&5
13000
13001 echo "$as_me:$LINENO: result: no" >&5
13002echo "${ECHO_T}no" >&6
13003
13004fi
Martin v. Löwise3271202002-11-07 07:42:30 +000013005rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013006
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013007# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000013008# for [no]getaddrinfo in netdb.h.
13009echo "$as_me:$LINENO: checking for getaddrinfo" >&5
13010echo $ECHO_N "checking for getaddrinfo... $ECHO_C" >&6
13011cat >conftest.$ac_ext <<_ACEOF
13012#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013013#include "confdefs.h"
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013014
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000013015#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013016#include <sys/socket.h>
13017#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000013018#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013019
Martin v. Löwis11437992002-04-12 09:54:03 +000013020#ifdef F77_DUMMY_MAIN
13021# ifdef __cplusplus
13022 extern "C"
13023# endif
13024 int F77_DUMMY_MAIN() { return 1; }
13025#endif
13026int
13027main ()
13028{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013029
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013030getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013031
Martin v. Löwis11437992002-04-12 09:54:03 +000013032 ;
13033 return 0;
13034}
13035_ACEOF
13036rm -f conftest.$ac_objext conftest$ac_exeext
13037if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13038 (eval $ac_link) 2>&5
13039 ac_status=$?
13040 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13041 (exit $ac_status); } &&
13042 { ac_try='test -s conftest$ac_exeext'
13043 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13044 (eval $ac_try) 2>&5
13045 ac_status=$?
13046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13047 (exit $ac_status); }; }; then
13048
13049echo "$as_me:$LINENO: result: yes" >&5
13050echo "${ECHO_T}yes" >&6
13051echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
13052echo $ECHO_N "checking getaddrinfo bug... $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013053if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013054 echo "$as_me:$LINENO: result: buggy" >&5
13055echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013056buggygetaddrinfo=yes
13057else
Martin v. Löwis11437992002-04-12 09:54:03 +000013058 cat >conftest.$ac_ext <<_ACEOF
13059#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013060#include "confdefs.h"
13061
13062#include <sys/types.h>
13063#include <netdb.h>
13064#include <string.h>
13065#include <sys/socket.h>
13066#include <netinet/in.h>
13067
13068main()
13069{
13070 int passive, gaierr, inet4 = 0, inet6 = 0;
13071 struct addrinfo hints, *ai, *aitop;
13072 char straddr[INET6_ADDRSTRLEN], strport[16];
13073
13074 for (passive = 0; passive <= 1; passive++) {
13075 memset(&hints, 0, sizeof(hints));
13076 hints.ai_family = AF_UNSPEC;
13077 hints.ai_flags = passive ? AI_PASSIVE : 0;
13078 hints.ai_socktype = SOCK_STREAM;
13079 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
13080 (void)gai_strerror(gaierr);
13081 goto bad;
13082 }
13083 for (ai = aitop; ai; ai = ai->ai_next) {
13084 if (ai->ai_addr == NULL ||
13085 ai->ai_addrlen == 0 ||
13086 getnameinfo(ai->ai_addr, ai->ai_addrlen,
13087 straddr, sizeof(straddr), strport, sizeof(strport),
13088 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
13089 goto bad;
13090 }
13091 switch (ai->ai_family) {
13092 case AF_INET:
13093 if (strcmp(strport, "54321") != 0) {
13094 goto bad;
13095 }
13096 if (passive) {
13097 if (strcmp(straddr, "0.0.0.0") != 0) {
13098 goto bad;
13099 }
13100 } else {
13101 if (strcmp(straddr, "127.0.0.1") != 0) {
13102 goto bad;
13103 }
13104 }
13105 inet4++;
13106 break;
13107 case AF_INET6:
13108 if (strcmp(strport, "54321") != 0) {
13109 goto bad;
13110 }
13111 if (passive) {
13112 if (strcmp(straddr, "::") != 0) {
13113 goto bad;
13114 }
13115 } else {
13116 if (strcmp(straddr, "::1") != 0) {
13117 goto bad;
13118 }
13119 }
13120 inet6++;
13121 break;
13122 case AF_UNSPEC:
13123 goto bad;
13124 break;
13125 default:
13126 /* another family support? */
13127 break;
13128 }
13129 }
13130 }
13131
13132 if (!(inet4 == 0 || inet4 == 2))
13133 goto bad;
13134 if (!(inet6 == 0 || inet6 == 2))
13135 goto bad;
13136
13137 if (aitop)
13138 freeaddrinfo(aitop);
13139 exit(0);
13140
13141 bad:
13142 if (aitop)
13143 freeaddrinfo(aitop);
13144 exit(1);
13145}
13146
Martin v. Löwis11437992002-04-12 09:54:03 +000013147_ACEOF
13148rm -f conftest$ac_exeext
13149if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13150 (eval $ac_link) 2>&5
13151 ac_status=$?
13152 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13153 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13154 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13155 (eval $ac_try) 2>&5
13156 ac_status=$?
13157 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13158 (exit $ac_status); }; }; then
13159 echo "$as_me:$LINENO: result: good" >&5
13160echo "${ECHO_T}good" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013161buggygetaddrinfo=no
13162else
Martin v. Löwis11437992002-04-12 09:54:03 +000013163 echo "$as_me: program exited with status $ac_status" >&5
13164echo "$as_me: failed program was:" >&5
13165cat conftest.$ac_ext >&5
13166( exit $ac_status )
13167echo "$as_me:$LINENO: result: buggy" >&5
13168echo "${ECHO_T}buggy" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013169buggygetaddrinfo=yes
13170fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013171rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013172fi
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013173else
Martin v. Löwis11437992002-04-12 09:54:03 +000013174 echo "$as_me: failed program was:" >&5
13175cat conftest.$ac_ext >&5
13176
13177echo "$as_me:$LINENO: result: no" >&5
13178echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013179buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013180
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013181fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013182rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013183
13184if test "$buggygetaddrinfo" = "yes"; then
13185 if test "$ipv6" = "yes"; then
13186 echo 'Fatal: You must get working getaddrinfo() function.'
13187 echo ' or you can specify "--disable-ipv6"'.
13188 exit 1
13189 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013190else
Martin v. Löwis11437992002-04-12 09:54:03 +000013191
13192cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013193#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013194_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000013195
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013196fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013197
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013198for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013199do
Martin v. Löwis11437992002-04-12 09:54:03 +000013200as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13201echo "$as_me:$LINENO: checking for $ac_func" >&5
13202echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13203if eval "test \"\${$as_ac_var+set}\" = set"; then
13204 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013205else
Martin v. Löwis11437992002-04-12 09:54:03 +000013206 cat >conftest.$ac_ext <<_ACEOF
13207#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013208#include "confdefs.h"
13209/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000013210 which can conflict with char $ac_func (); below. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013211#include <assert.h>
13212/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013213#ifdef __cplusplus
13214extern "C"
13215#endif
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013216/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000013217 builtin and then its argument prototype would still apply. */
13218char $ac_func ();
13219char (*f) ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013220
Martin v. Löwis11437992002-04-12 09:54:03 +000013221#ifdef F77_DUMMY_MAIN
13222# ifdef __cplusplus
13223 extern "C"
13224# endif
13225 int F77_DUMMY_MAIN() { return 1; }
13226#endif
13227int
13228main ()
13229{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013230/* The GNU C library defines this for functions which it implements
13231 to always fail with ENOSYS. Some functions are actually named
13232 something starting with __ and the normal name is an alias. */
13233#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13234choke me
13235#else
Martin v. Löwis11437992002-04-12 09:54:03 +000013236f = $ac_func;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013237#endif
13238
Martin v. Löwis11437992002-04-12 09:54:03 +000013239 ;
13240 return 0;
13241}
13242_ACEOF
13243rm -f conftest.$ac_objext conftest$ac_exeext
13244if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13245 (eval $ac_link) 2>&5
13246 ac_status=$?
13247 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13248 (exit $ac_status); } &&
13249 { ac_try='test -s conftest$ac_exeext'
13250 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13251 (eval $ac_try) 2>&5
13252 ac_status=$?
13253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13254 (exit $ac_status); }; }; then
13255 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000013256else
Martin v. Löwis11437992002-04-12 09:54:03 +000013257 echo "$as_me: failed program was:" >&5
13258cat conftest.$ac_ext >&5
13259eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000013260fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013261rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013262fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013263echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13264echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13265if test `eval echo '${'$as_ac_var'}'` = yes; then
13266 cat >>confdefs.h <<_ACEOF
13267#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13268_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013269
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013270fi
13271done
13272
Michael W. Hudson54241132001-12-07 15:38:26 +000013273
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013274# checks for structures
Martin v. Löwis11437992002-04-12 09:54:03 +000013275echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
13276echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
13277if test "${ac_cv_header_time+set}" = set; then
13278 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013279else
Martin v. Löwis11437992002-04-12 09:54:03 +000013280 cat >conftest.$ac_ext <<_ACEOF
13281#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013282#include "confdefs.h"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013283#include <sys/types.h>
13284#include <sys/time.h>
13285#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013286
13287#ifdef F77_DUMMY_MAIN
13288# ifdef __cplusplus
13289 extern "C"
13290# endif
13291 int F77_DUMMY_MAIN() { return 1; }
13292#endif
13293int
13294main ()
13295{
13296if ((struct tm *) 0)
13297return 0;
13298 ;
13299 return 0;
13300}
13301_ACEOF
13302rm -f conftest.$ac_objext
13303if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13304 (eval $ac_compile) 2>&5
13305 ac_status=$?
13306 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13307 (exit $ac_status); } &&
13308 { ac_try='test -s conftest.$ac_objext'
13309 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13310 (eval $ac_try) 2>&5
13311 ac_status=$?
13312 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13313 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013314 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000013315else
Martin v. Löwis11437992002-04-12 09:54:03 +000013316 echo "$as_me: failed program was:" >&5
13317cat conftest.$ac_ext >&5
13318ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013319fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013320rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013321fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013322echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
13323echo "${ECHO_T}$ac_cv_header_time" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013324if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013325
13326cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013327#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013328_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013329
13330fi
13331
Martin v. Löwis11437992002-04-12 09:54:03 +000013332echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
13333echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
13334if test "${ac_cv_struct_tm+set}" = set; then
13335 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013336else
Martin v. Löwis11437992002-04-12 09:54:03 +000013337 cat >conftest.$ac_ext <<_ACEOF
13338#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013339#include "confdefs.h"
13340#include <sys/types.h>
13341#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013342
13343#ifdef F77_DUMMY_MAIN
13344# ifdef __cplusplus
13345 extern "C"
13346# endif
13347 int F77_DUMMY_MAIN() { return 1; }
13348#endif
13349int
13350main ()
13351{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013352struct tm *tp; tp->tm_sec;
Martin v. Löwis11437992002-04-12 09:54:03 +000013353 ;
13354 return 0;
13355}
13356_ACEOF
13357rm -f conftest.$ac_objext
13358if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13359 (eval $ac_compile) 2>&5
13360 ac_status=$?
13361 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13362 (exit $ac_status); } &&
13363 { ac_try='test -s conftest.$ac_objext'
13364 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13365 (eval $ac_try) 2>&5
13366 ac_status=$?
13367 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13368 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013369 ac_cv_struct_tm=time.h
13370else
Martin v. Löwis11437992002-04-12 09:54:03 +000013371 echo "$as_me: failed program was:" >&5
13372cat conftest.$ac_ext >&5
13373ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013374fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013375rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013376fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013377echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
13378echo "${ECHO_T}$ac_cv_struct_tm" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013379if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013380
13381cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013382#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013383_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013384
13385fi
13386
Martin v. Löwis11437992002-04-12 09:54:03 +000013387echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
13388echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
13389if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
13390 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013391else
Martin v. Löwis11437992002-04-12 09:54:03 +000013392 cat >conftest.$ac_ext <<_ACEOF
13393#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013394#include "confdefs.h"
13395#include <sys/types.h>
13396#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000013397
13398
13399#ifdef F77_DUMMY_MAIN
13400# ifdef __cplusplus
13401 extern "C"
13402# endif
13403 int F77_DUMMY_MAIN() { return 1; }
13404#endif
13405int
13406main ()
13407{
13408static struct tm ac_aggr;
13409if (ac_aggr.tm_zone)
13410return 0;
13411 ;
13412 return 0;
13413}
13414_ACEOF
13415rm -f conftest.$ac_objext
13416if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13417 (eval $ac_compile) 2>&5
13418 ac_status=$?
13419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13420 (exit $ac_status); } &&
13421 { ac_try='test -s conftest.$ac_objext'
13422 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13423 (eval $ac_try) 2>&5
13424 ac_status=$?
13425 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13426 (exit $ac_status); }; }; then
13427 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013428else
Martin v. Löwis11437992002-04-12 09:54:03 +000013429 echo "$as_me: failed program was:" >&5
13430cat conftest.$ac_ext >&5
13431ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013432fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013433rm -f conftest.$ac_objext conftest.$ac_ext
13434fi
13435echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
13436echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
13437if test $ac_cv_member_struct_tm_tm_zone = yes; then
13438
13439cat >>confdefs.h <<_ACEOF
13440#define HAVE_STRUCT_TM_TM_ZONE 1
13441_ACEOF
13442
13443
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013444fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000013445
Martin v. Löwis11437992002-04-12 09:54:03 +000013446if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
13447
13448cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013449#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013450_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013451
13452else
Martin v. Löwis11437992002-04-12 09:54:03 +000013453 echo "$as_me:$LINENO: checking for tzname" >&5
13454echo $ECHO_N "checking for tzname... $ECHO_C" >&6
13455if test "${ac_cv_var_tzname+set}" = set; then
13456 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013457else
Martin v. Löwis11437992002-04-12 09:54:03 +000013458 cat >conftest.$ac_ext <<_ACEOF
13459#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000013460#include "confdefs.h"
13461#include <time.h>
13462#ifndef tzname /* For SGI. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013463extern char *tzname[]; /* RS6000 and others reject char **tzname. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000013464#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013465
13466#ifdef F77_DUMMY_MAIN
13467# ifdef __cplusplus
13468 extern "C"
13469# endif
13470 int F77_DUMMY_MAIN() { return 1; }
13471#endif
13472int
13473main ()
13474{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013475atoi(*tzname);
Martin v. Löwis11437992002-04-12 09:54:03 +000013476 ;
13477 return 0;
13478}
13479_ACEOF
13480rm -f conftest.$ac_objext conftest$ac_exeext
13481if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13482 (eval $ac_link) 2>&5
13483 ac_status=$?
13484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13485 (exit $ac_status); } &&
13486 { ac_try='test -s conftest$ac_exeext'
13487 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13488 (eval $ac_try) 2>&5
13489 ac_status=$?
13490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13491 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013492 ac_cv_var_tzname=yes
13493else
Martin v. Löwis11437992002-04-12 09:54:03 +000013494 echo "$as_me: failed program was:" >&5
13495cat conftest.$ac_ext >&5
13496ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013497fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013498rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000013499fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013500echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
13501echo "${ECHO_T}$ac_cv_var_tzname" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000013502 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013503
13504cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013505#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013506_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013507
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013508 fi
13509fi
13510
Martin v. Löwis11437992002-04-12 09:54:03 +000013511echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
13512echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6
13513if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
13514 echo $ECHO_N "(cached) $ECHO_C" >&6
13515else
13516 cat >conftest.$ac_ext <<_ACEOF
13517#line $LINENO "configure"
13518#include "confdefs.h"
13519$ac_includes_default
13520#ifdef F77_DUMMY_MAIN
13521# ifdef __cplusplus
13522 extern "C"
13523# endif
13524 int F77_DUMMY_MAIN() { return 1; }
13525#endif
13526int
13527main ()
13528{
13529static struct stat ac_aggr;
13530if (ac_aggr.st_rdev)
13531return 0;
13532 ;
13533 return 0;
13534}
13535_ACEOF
13536rm -f conftest.$ac_objext
13537if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13538 (eval $ac_compile) 2>&5
13539 ac_status=$?
13540 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13541 (exit $ac_status); } &&
13542 { ac_try='test -s conftest.$ac_objext'
13543 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13544 (eval $ac_try) 2>&5
13545 ac_status=$?
13546 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13547 (exit $ac_status); }; }; then
13548 ac_cv_member_struct_stat_st_rdev=yes
13549else
13550 echo "$as_me: failed program was:" >&5
13551cat conftest.$ac_ext >&5
13552ac_cv_member_struct_stat_st_rdev=no
13553fi
13554rm -f conftest.$ac_objext conftest.$ac_ext
13555fi
13556echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
13557echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6
13558if test $ac_cv_member_struct_stat_st_rdev = yes; then
13559
13560cat >>confdefs.h <<_ACEOF
13561#define HAVE_STRUCT_STAT_ST_RDEV 1
13562_ACEOF
13563
13564
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013565fi
13566
Martin v. Löwis11437992002-04-12 09:54:03 +000013567echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
13568echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6
13569if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
13570 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013571else
Martin v. Löwis11437992002-04-12 09:54:03 +000013572 cat >conftest.$ac_ext <<_ACEOF
13573#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013574#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013575$ac_includes_default
13576#ifdef F77_DUMMY_MAIN
13577# ifdef __cplusplus
13578 extern "C"
13579# endif
13580 int F77_DUMMY_MAIN() { return 1; }
13581#endif
13582int
13583main ()
13584{
13585static struct stat ac_aggr;
13586if (ac_aggr.st_blksize)
13587return 0;
13588 ;
13589 return 0;
13590}
13591_ACEOF
13592rm -f conftest.$ac_objext
13593if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13594 (eval $ac_compile) 2>&5
13595 ac_status=$?
13596 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13597 (exit $ac_status); } &&
13598 { ac_try='test -s conftest.$ac_objext'
13599 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13600 (eval $ac_try) 2>&5
13601 ac_status=$?
13602 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13603 (exit $ac_status); }; }; then
13604 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013605else
Martin v. Löwis11437992002-04-12 09:54:03 +000013606 echo "$as_me: failed program was:" >&5
13607cat conftest.$ac_ext >&5
13608ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013609fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013610rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013611fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013612echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
13613echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6
13614if test $ac_cv_member_struct_stat_st_blksize = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013615
Martin v. Löwis11437992002-04-12 09:54:03 +000013616cat >>confdefs.h <<_ACEOF
13617#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13618_ACEOF
13619
13620
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013621fi
13622
Martin v. Löwis11437992002-04-12 09:54:03 +000013623echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
13624echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6
13625if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
13626 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013627else
Martin v. Löwis11437992002-04-12 09:54:03 +000013628 cat >conftest.$ac_ext <<_ACEOF
13629#line $LINENO "configure"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013630#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013631$ac_includes_default
13632#ifdef F77_DUMMY_MAIN
13633# ifdef __cplusplus
13634 extern "C"
13635# endif
13636 int F77_DUMMY_MAIN() { return 1; }
13637#endif
13638int
13639main ()
13640{
13641static struct stat ac_aggr;
13642if (ac_aggr.st_blocks)
13643return 0;
13644 ;
13645 return 0;
13646}
13647_ACEOF
13648rm -f conftest.$ac_objext
13649if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13650 (eval $ac_compile) 2>&5
13651 ac_status=$?
13652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13653 (exit $ac_status); } &&
13654 { ac_try='test -s conftest.$ac_objext'
13655 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13656 (eval $ac_try) 2>&5
13657 ac_status=$?
13658 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13659 (exit $ac_status); }; }; then
13660 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000013661else
Martin v. Löwis11437992002-04-12 09:54:03 +000013662 echo "$as_me: failed program was:" >&5
13663cat conftest.$ac_ext >&5
13664ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000013665fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013666rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013667fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013668echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
13669echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6
13670if test $ac_cv_member_struct_stat_st_blocks = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000013671
Martin v. Löwis11437992002-04-12 09:54:03 +000013672cat >>confdefs.h <<_ACEOF
13673#define HAVE_STRUCT_STAT_ST_BLOCKS 1
13674_ACEOF
13675
13676
13677cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013678#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013679_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013680
13681else
Martin v. Löwis11437992002-04-12 09:54:03 +000013682 LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
Guido van Rossum98bf58f2001-10-18 20:34:25 +000013683fi
13684
Michael W. Hudson54241132001-12-07 15:38:26 +000013685
Martin v. Löwis11437992002-04-12 09:54:03 +000013686
13687echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
13688echo $ECHO_N "checking for time.h that defines altzone... $ECHO_C" >&6
13689if test "${ac_cv_header_time_altzone+set}" = set; then
13690 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013691else
Martin v. Löwis11437992002-04-12 09:54:03 +000013692 cat >conftest.$ac_ext <<_ACEOF
13693#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013694#include "confdefs.h"
13695#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013696#ifdef F77_DUMMY_MAIN
13697# ifdef __cplusplus
13698 extern "C"
13699# endif
13700 int F77_DUMMY_MAIN() { return 1; }
13701#endif
13702int
13703main ()
13704{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013705return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000013706 ;
13707 return 0;
13708}
13709_ACEOF
13710rm -f conftest.$ac_objext
13711if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13712 (eval $ac_compile) 2>&5
13713 ac_status=$?
13714 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13715 (exit $ac_status); } &&
13716 { ac_try='test -s conftest.$ac_objext'
13717 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13718 (eval $ac_try) 2>&5
13719 ac_status=$?
13720 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13721 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013722 ac_cv_header_time_altzone=yes
13723else
Martin v. Löwis11437992002-04-12 09:54:03 +000013724 echo "$as_me: failed program was:" >&5
13725cat conftest.$ac_ext >&5
13726ac_cv_header_time_altzone=no
Guido van Rossum7f43da71994-08-01 12:15:30 +000013727fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013728rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013729fi
13730
Martin v. Löwis11437992002-04-12 09:54:03 +000013731echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
13732echo "${ECHO_T}$ac_cv_header_time_altzone" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013733if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013734
13735cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013736#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013737_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013738
13739fi
13740
Guido van Rossumda88dad1995-01-26 00:46:29 +000013741was_it_defined=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013742echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
13743echo $ECHO_N "checking whether sys/select.h and sys/time.h may both be included... $ECHO_C" >&6
13744cat >conftest.$ac_ext <<_ACEOF
13745#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013746#include "confdefs.h"
13747
13748#include <sys/types.h>
13749#include <sys/select.h>
13750#include <sys/time.h>
13751
Martin v. Löwis11437992002-04-12 09:54:03 +000013752#ifdef F77_DUMMY_MAIN
13753# ifdef __cplusplus
13754 extern "C"
13755# endif
13756 int F77_DUMMY_MAIN() { return 1; }
13757#endif
13758int
13759main ()
13760{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013761;
Martin v. Löwis11437992002-04-12 09:54:03 +000013762 ;
13763 return 0;
13764}
13765_ACEOF
13766rm -f conftest.$ac_objext
13767if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13768 (eval $ac_compile) 2>&5
13769 ac_status=$?
13770 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13771 (exit $ac_status); } &&
13772 { ac_try='test -s conftest.$ac_objext'
13773 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13774 (eval $ac_try) 2>&5
13775 ac_status=$?
13776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13777 (exit $ac_status); }; }; then
13778
13779
13780cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013781#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013782_ACEOF
13783
Martin v. Löwisc45929e2002-04-06 10:10:49 +000013784 was_it_defined=yes
13785
Guido van Rossumf78abae1997-01-21 22:02:36 +000013786else
Martin v. Löwis11437992002-04-12 09:54:03 +000013787 echo "$as_me: failed program was:" >&5
13788cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000013789fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013790rm -f conftest.$ac_objext conftest.$ac_ext
13791echo "$as_me:$LINENO: result: $was_it_defined" >&5
13792echo "${ECHO_T}$was_it_defined" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000013793
Martin v. Löwis11437992002-04-12 09:54:03 +000013794echo "$as_me:$LINENO: checking for addrinfo" >&5
13795echo $ECHO_N "checking for addrinfo... $ECHO_C" >&6
13796if test "${ac_cv_struct_addrinfo+set}" = set; then
13797 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013798else
Martin v. Löwis11437992002-04-12 09:54:03 +000013799 cat >conftest.$ac_ext <<_ACEOF
13800#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013801#include "confdefs.h"
13802
13803# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013804#ifdef F77_DUMMY_MAIN
13805# ifdef __cplusplus
13806 extern "C"
13807# endif
13808 int F77_DUMMY_MAIN() { return 1; }
13809#endif
13810int
13811main ()
13812{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013813struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000013814 ;
13815 return 0;
13816}
13817_ACEOF
13818rm -f conftest.$ac_objext
13819if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13820 (eval $ac_compile) 2>&5
13821 ac_status=$?
13822 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13823 (exit $ac_status); } &&
13824 { ac_try='test -s conftest.$ac_objext'
13825 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13826 (eval $ac_try) 2>&5
13827 ac_status=$?
13828 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13829 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013830 ac_cv_struct_addrinfo=yes
13831else
Martin v. Löwis11437992002-04-12 09:54:03 +000013832 echo "$as_me: failed program was:" >&5
13833cat conftest.$ac_ext >&5
13834ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013835fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013836rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013837fi
13838
Martin v. Löwis11437992002-04-12 09:54:03 +000013839echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
13840echo "${ECHO_T}$ac_cv_struct_addrinfo" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013841if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013842
13843cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013844#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013845_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013846
13847fi
13848
Martin v. Löwis11437992002-04-12 09:54:03 +000013849echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
13850echo $ECHO_N "checking for sockaddr_storage... $ECHO_C" >&6
13851if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
13852 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013853else
Martin v. Löwis11437992002-04-12 09:54:03 +000013854 cat >conftest.$ac_ext <<_ACEOF
13855#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013856#include "confdefs.h"
13857
13858# include <sys/types.h>
13859# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013860#ifdef F77_DUMMY_MAIN
13861# ifdef __cplusplus
13862 extern "C"
13863# endif
13864 int F77_DUMMY_MAIN() { return 1; }
13865#endif
13866int
13867main ()
13868{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013869struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000013870 ;
13871 return 0;
13872}
13873_ACEOF
13874rm -f conftest.$ac_objext
13875if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13876 (eval $ac_compile) 2>&5
13877 ac_status=$?
13878 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13879 (exit $ac_status); } &&
13880 { ac_try='test -s conftest.$ac_objext'
13881 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13882 (eval $ac_try) 2>&5
13883 ac_status=$?
13884 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13885 (exit $ac_status); }; }; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013886 ac_cv_struct_sockaddr_storage=yes
13887else
Martin v. Löwis11437992002-04-12 09:54:03 +000013888 echo "$as_me: failed program was:" >&5
13889cat conftest.$ac_ext >&5
13890ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013891fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013892rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013893fi
13894
Martin v. Löwis11437992002-04-12 09:54:03 +000013895echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
13896echo "${ECHO_T}$ac_cv_struct_sockaddr_storage" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013897if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013898
13899cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013900#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013901_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000013902
13903fi
13904
Guido van Rossum627b2d71993-12-24 10:39:16 +000013905# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000013906
Michael W. Hudson54241132001-12-07 15:38:26 +000013907
Martin v. Löwis11437992002-04-12 09:54:03 +000013908echo "$as_me:$LINENO: checking whether char is unsigned" >&5
13909echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6
13910if test "${ac_cv_c_char_unsigned+set}" = set; then
13911 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000013912else
Martin v. Löwis11437992002-04-12 09:54:03 +000013913 cat >conftest.$ac_ext <<_ACEOF
13914#line $LINENO "configure"
Michael W. Hudson54241132001-12-07 15:38:26 +000013915#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000013916$ac_includes_default
13917#ifdef F77_DUMMY_MAIN
13918# ifdef __cplusplus
13919 extern "C"
13920# endif
13921 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000013922#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013923int
13924main ()
13925{
13926static int test_array [1 - 2 * !(((char) -1) < 0)];
13927test_array [0] = 0
13928
13929 ;
13930 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000013931}
Martin v. Löwis11437992002-04-12 09:54:03 +000013932_ACEOF
13933rm -f conftest.$ac_objext
13934if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13935 (eval $ac_compile) 2>&5
13936 ac_status=$?
13937 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13938 (exit $ac_status); } &&
13939 { ac_try='test -s conftest.$ac_objext'
13940 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13941 (eval $ac_try) 2>&5
13942 ac_status=$?
13943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
13944 (exit $ac_status); }; }; then
Michael W. Hudson54241132001-12-07 15:38:26 +000013945 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013946else
13947 echo "$as_me: failed program was:" >&5
13948cat conftest.$ac_ext >&5
13949ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013950fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013951rm -f conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000013952fi
Martin v. Löwis11437992002-04-12 09:54:03 +000013953echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
13954echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013955if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013956 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013957#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013958_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013959
13960fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000013961
Martin v. Löwis11437992002-04-12 09:54:03 +000013962echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
13963echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
13964if test "${ac_cv_prog_cc_stdc+set}" = set; then
13965 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013966else
Martin v. Löwis11437992002-04-12 09:54:03 +000013967 ac_cv_prog_cc_stdc=no
13968ac_save_CC=$CC
13969cat >conftest.$ac_ext <<_ACEOF
13970#line $LINENO "configure"
13971#include "confdefs.h"
13972#include <stdarg.h>
13973#include <stdio.h>
13974#include <sys/types.h>
13975#include <sys/stat.h>
13976/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
13977struct buf { int x; };
13978FILE * (*rcsopen) (struct buf *, struct stat *, int);
13979static char *e (p, i)
13980 char **p;
13981 int i;
13982{
13983 return p[i];
13984}
13985static char *f (char * (*g) (char **, int), char **p, ...)
13986{
13987 char *s;
13988 va_list v;
13989 va_start (v,p);
13990 s = g (p, va_arg (v,int));
13991 va_end (v);
13992 return s;
13993}
13994int test (int i, double x);
13995struct s1 {int (*f) (int a);};
13996struct s2 {int (*f) (double a);};
13997int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
13998int argc;
13999char **argv;
14000#ifdef F77_DUMMY_MAIN
14001# ifdef __cplusplus
14002 extern "C"
14003# endif
14004 int F77_DUMMY_MAIN() { return 1; }
14005#endif
14006int
14007main ()
14008{
14009return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
14010 ;
14011 return 0;
14012}
14013_ACEOF
14014# Don't try gcc -ansi; that turns off useful extensions and
14015# breaks some systems' header files.
14016# AIX -qlanglvl=ansi
14017# Ultrix and OSF/1 -std1
14018# HP-UX 10.20 and later -Ae
14019# HP-UX older versions -Aa -D_HPUX_SOURCE
14020# SVR4 -Xc -D__EXTENSIONS__
14021for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
14022do
14023 CC="$ac_save_CC $ac_arg"
14024 rm -f conftest.$ac_objext
14025if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14026 (eval $ac_compile) 2>&5
14027 ac_status=$?
14028 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14029 (exit $ac_status); } &&
14030 { ac_try='test -s conftest.$ac_objext'
14031 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14032 (eval $ac_try) 2>&5
14033 ac_status=$?
14034 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14035 (exit $ac_status); }; }; then
14036 ac_cv_prog_cc_stdc=$ac_arg
14037break
14038else
14039 echo "$as_me: failed program was:" >&5
14040cat conftest.$ac_ext >&5
14041fi
14042rm -f conftest.$ac_objext
14043done
14044rm -f conftest.$ac_ext conftest.$ac_objext
14045CC=$ac_save_CC
14046
14047fi
14048
14049case "x$ac_cv_prog_cc_stdc" in
14050 x|xno)
14051 echo "$as_me:$LINENO: result: none needed" >&5
14052echo "${ECHO_T}none needed" >&6 ;;
14053 *)
14054 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
14055echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
14056 CC="$CC $ac_cv_prog_cc_stdc" ;;
14057esac
14058
14059echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14060echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
14061if test "${ac_cv_c_const+set}" = set; then
14062 echo $ECHO_N "(cached) $ECHO_C" >&6
14063else
14064 cat >conftest.$ac_ext <<_ACEOF
14065#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014066#include "confdefs.h"
14067
Martin v. Löwis11437992002-04-12 09:54:03 +000014068#ifdef F77_DUMMY_MAIN
14069# ifdef __cplusplus
14070 extern "C"
14071# endif
14072 int F77_DUMMY_MAIN() { return 1; }
14073#endif
14074int
14075main ()
14076{
14077/* FIXME: Include the comments suggested by Paul. */
14078#ifndef __cplusplus
14079 /* Ultrix mips cc rejects this. */
14080 typedef int charset[2];
14081 const charset x;
14082 /* SunOS 4.1.1 cc rejects this. */
14083 char const *const *ccp;
14084 char **p;
14085 /* NEC SVR4.0.2 mips cc rejects this. */
14086 struct point {int x, y;};
14087 static struct point const zero = {0,0};
14088 /* AIX XL C 1.02.0.0 rejects this.
14089 It does not let you subtract one const X* pointer from another in
14090 an arm of an if-expression whose if-part is not a constant
14091 expression */
14092 const char *g = "string";
14093 ccp = &g + (g ? g-g : 0);
14094 /* HPUX 7.0 cc rejects these. */
14095 ++ccp;
14096 p = (char**) ccp;
14097 ccp = (char const *const *) p;
14098 { /* SCO 3.2v4 cc rejects this. */
14099 char *t;
14100 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014101
Martin v. Löwis11437992002-04-12 09:54:03 +000014102 *t++ = 0;
14103 }
14104 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
14105 int x[] = {25, 17};
14106 const int *foo = &x[0];
14107 ++foo;
14108 }
14109 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14110 typedef const int *iptr;
14111 iptr p = 0;
14112 ++p;
14113 }
14114 { /* AIX XL C 1.02.0.0 rejects this saying
14115 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14116 struct s { int j; const int *ap[3]; };
14117 struct s *b; b->j = 5;
14118 }
14119 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14120 const int foo = 10;
14121 }
14122#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000014123
Martin v. Löwis11437992002-04-12 09:54:03 +000014124 ;
14125 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000014126}
Martin v. Löwis11437992002-04-12 09:54:03 +000014127_ACEOF
14128rm -f conftest.$ac_objext
14129if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14130 (eval $ac_compile) 2>&5
14131 ac_status=$?
14132 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14133 (exit $ac_status); } &&
14134 { ac_try='test -s conftest.$ac_objext'
14135 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14136 (eval $ac_try) 2>&5
14137 ac_status=$?
14138 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14139 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014140 ac_cv_c_const=yes
14141else
Martin v. Löwis11437992002-04-12 09:54:03 +000014142 echo "$as_me: failed program was:" >&5
14143cat conftest.$ac_ext >&5
14144ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014145fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014146rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014147fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014148echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14149echo "${ECHO_T}$ac_cv_c_const" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014150if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014151
14152cat >>confdefs.h <<\_ACEOF
14153#define const
14154_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014155
14156fi
14157
Michael W. Hudson54241132001-12-07 15:38:26 +000014158
Guido van Rossumda88dad1995-01-26 00:46:29 +000014159works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014160echo "$as_me:$LINENO: checking for working volatile" >&5
14161echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
14162cat >conftest.$ac_ext <<_ACEOF
14163#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014164#include "confdefs.h"
14165
Martin v. Löwis11437992002-04-12 09:54:03 +000014166#ifdef F77_DUMMY_MAIN
14167# ifdef __cplusplus
14168 extern "C"
14169# endif
14170 int F77_DUMMY_MAIN() { return 1; }
14171#endif
14172int
14173main ()
14174{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014175volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000014176 ;
14177 return 0;
14178}
14179_ACEOF
14180rm -f conftest.$ac_objext
14181if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14182 (eval $ac_compile) 2>&5
14183 ac_status=$?
14184 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14185 (exit $ac_status); } &&
14186 { ac_try='test -s conftest.$ac_objext'
14187 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14188 (eval $ac_try) 2>&5
14189 ac_status=$?
14190 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14191 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000014192 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000014193else
Martin v. Löwis11437992002-04-12 09:54:03 +000014194 echo "$as_me: failed program was:" >&5
14195cat conftest.$ac_ext >&5
14196
14197cat >>confdefs.h <<\_ACEOF
14198#define volatile
14199_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000014200
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014201
Guido van Rossum627b2d71993-12-24 10:39:16 +000014202fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014203rm -f conftest.$ac_objext conftest.$ac_ext
14204echo "$as_me:$LINENO: result: $works" >&5
14205echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000014206
Guido van Rossumda88dad1995-01-26 00:46:29 +000014207works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014208echo "$as_me:$LINENO: checking for working signed char" >&5
14209echo $ECHO_N "checking for working signed char... $ECHO_C" >&6
14210cat >conftest.$ac_ext <<_ACEOF
14211#line $LINENO "configure"
Guido van Rossumdabb11b1994-10-11 15:04:27 +000014212#include "confdefs.h"
14213
Martin v. Löwis11437992002-04-12 09:54:03 +000014214#ifdef F77_DUMMY_MAIN
14215# ifdef __cplusplus
14216 extern "C"
14217# endif
14218 int F77_DUMMY_MAIN() { return 1; }
14219#endif
14220int
14221main ()
14222{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014223signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000014224 ;
14225 return 0;
14226}
14227_ACEOF
14228rm -f conftest.$ac_objext
14229if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14230 (eval $ac_compile) 2>&5
14231 ac_status=$?
14232 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14233 (exit $ac_status); } &&
14234 { ac_try='test -s conftest.$ac_objext'
14235 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14236 (eval $ac_try) 2>&5
14237 ac_status=$?
14238 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14239 (exit $ac_status); }; }; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000014240 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000014241else
Martin v. Löwis11437992002-04-12 09:54:03 +000014242 echo "$as_me: failed program was:" >&5
14243cat conftest.$ac_ext >&5
14244
14245cat >>confdefs.h <<\_ACEOF
14246#define signed
14247_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000014248
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014249
Guido van Rossum7f43da71994-08-01 12:15:30 +000014250fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014251rm -f conftest.$ac_objext conftest.$ac_ext
14252echo "$as_me:$LINENO: result: $works" >&5
14253echo "${ECHO_T}$works" >&6
Guido van Rossum7f43da71994-08-01 12:15:30 +000014254
Guido van Rossumda88dad1995-01-26 00:46:29 +000014255have_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014256echo "$as_me:$LINENO: checking for prototypes" >&5
14257echo $ECHO_N "checking for prototypes... $ECHO_C" >&6
14258cat >conftest.$ac_ext <<_ACEOF
14259#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014260#include "confdefs.h"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014261int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014262#ifdef F77_DUMMY_MAIN
14263# ifdef __cplusplus
14264 extern "C"
14265# endif
14266 int F77_DUMMY_MAIN() { return 1; }
14267#endif
14268int
14269main ()
14270{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014271return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000014272 ;
14273 return 0;
14274}
14275_ACEOF
14276rm -f conftest.$ac_objext
14277if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14278 (eval $ac_compile) 2>&5
14279 ac_status=$?
14280 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14281 (exit $ac_status); } &&
14282 { ac_try='test -s conftest.$ac_objext'
14283 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14284 (eval $ac_try) 2>&5
14285 ac_status=$?
14286 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14287 (exit $ac_status); }; }; then
14288
14289
14290cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014291#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014292_ACEOF
14293
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014294 have_prototypes=yes
14295
Guido van Rossumf78abae1997-01-21 22:02:36 +000014296else
Martin v. Löwis11437992002-04-12 09:54:03 +000014297 echo "$as_me: failed program was:" >&5
14298cat conftest.$ac_ext >&5
Guido van Rossum7f43da71994-08-01 12:15:30 +000014299fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014300rm -f conftest.$ac_objext conftest.$ac_ext
14301echo "$as_me:$LINENO: result: $have_prototypes" >&5
14302echo "${ECHO_T}$have_prototypes" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014303
Guido van Rossumda88dad1995-01-26 00:46:29 +000014304works=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014305echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
14306echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6
14307cat >conftest.$ac_ext <<_ACEOF
14308#line $LINENO "configure"
Guido van Rossum7f43da71994-08-01 12:15:30 +000014309#include "confdefs.h"
14310
14311#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000014312int foo(int x, ...) {
14313 va_list va;
14314 va_start(va, x);
14315 va_arg(va, int);
14316 va_arg(va, char *);
14317 va_arg(va, double);
14318 return 0;
14319}
Guido van Rossum7f43da71994-08-01 12:15:30 +000014320
Martin v. Löwis11437992002-04-12 09:54:03 +000014321#ifdef F77_DUMMY_MAIN
14322# ifdef __cplusplus
14323 extern "C"
14324# endif
14325 int F77_DUMMY_MAIN() { return 1; }
14326#endif
14327int
14328main ()
14329{
Guido van Rossum90eea071996-08-30 20:58:57 +000014330return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000014331 ;
14332 return 0;
14333}
14334_ACEOF
14335rm -f conftest.$ac_objext
14336if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14337 (eval $ac_compile) 2>&5
14338 ac_status=$?
14339 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14340 (exit $ac_status); } &&
14341 { ac_try='test -s conftest.$ac_objext'
14342 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14343 (eval $ac_try) 2>&5
14344 ac_status=$?
14345 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14346 (exit $ac_status); }; }; then
14347
14348
14349cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014350#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014351_ACEOF
14352
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014353 works=yes
14354
Guido van Rossumf78abae1997-01-21 22:02:36 +000014355else
Martin v. Löwis11437992002-04-12 09:54:03 +000014356 echo "$as_me: failed program was:" >&5
14357cat conftest.$ac_ext >&5
Guido van Rossum627b2d71993-12-24 10:39:16 +000014358fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014359rm -f conftest.$ac_objext conftest.$ac_ext
14360echo "$as_me:$LINENO: result: $works" >&5
14361echo "${ECHO_T}$works" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014362
Guido van Rossumda88dad1995-01-26 00:46:29 +000014363if test "$have_prototypes" = yes; then
14364bad_prototypes=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014365echo "$as_me:$LINENO: checking for bad exec* prototypes" >&5
14366echo $ECHO_N "checking for bad exec* prototypes... $ECHO_C" >&6
14367cat >conftest.$ac_ext <<_ACEOF
14368#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014369#include "confdefs.h"
14370#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014371#ifdef F77_DUMMY_MAIN
14372# ifdef __cplusplus
14373 extern "C"
14374# endif
14375 int F77_DUMMY_MAIN() { return 1; }
14376#endif
14377int
14378main ()
14379{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014380char **t;execve("@",t,t);
Martin v. Löwis11437992002-04-12 09:54:03 +000014381 ;
14382 return 0;
14383}
14384_ACEOF
14385rm -f conftest.$ac_objext
14386if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14387 (eval $ac_compile) 2>&5
14388 ac_status=$?
14389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14390 (exit $ac_status); } &&
14391 { ac_try='test -s conftest.$ac_objext'
14392 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14393 (eval $ac_try) 2>&5
14394 ac_status=$?
14395 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14396 (exit $ac_status); }; }; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000014397 :
14398else
Martin v. Löwis11437992002-04-12 09:54:03 +000014399 echo "$as_me: failed program was:" >&5
14400cat conftest.$ac_ext >&5
14401
14402cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014403#define BAD_EXEC_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014404_ACEOF
14405
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014406 bad_prototypes=yes
14407
Guido van Rossum627b2d71993-12-24 10:39:16 +000014408fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014409rm -f conftest.$ac_objext conftest.$ac_ext
14410echo "$as_me:$LINENO: result: $bad_prototypes" >&5
14411echo "${ECHO_T}$bad_prototypes" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +000014412fi
14413
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014414# check if sockaddr has sa_len member
Martin v. Löwis11437992002-04-12 09:54:03 +000014415echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
14416echo $ECHO_N "checking if sockaddr has sa_len member... $ECHO_C" >&6
14417cat >conftest.$ac_ext <<_ACEOF
14418#line $LINENO "configure"
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014419#include "confdefs.h"
14420#include <sys/types.h>
14421#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014422#ifdef F77_DUMMY_MAIN
14423# ifdef __cplusplus
14424 extern "C"
14425# endif
14426 int F77_DUMMY_MAIN() { return 1; }
14427#endif
14428int
14429main ()
14430{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014431struct sockaddr x;
14432x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000014433 ;
14434 return 0;
14435}
14436_ACEOF
14437rm -f conftest.$ac_objext
14438if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14439 (eval $ac_compile) 2>&5
14440 ac_status=$?
14441 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14442 (exit $ac_status); } &&
14443 { ac_try='test -s conftest.$ac_objext'
14444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14445 (eval $ac_try) 2>&5
14446 ac_status=$?
14447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14448 (exit $ac_status); }; }; then
14449 echo "$as_me:$LINENO: result: yes" >&5
14450echo "${ECHO_T}yes" >&6
14451
14452cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014453#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014454_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014455
14456else
Martin v. Löwis11437992002-04-12 09:54:03 +000014457 echo "$as_me: failed program was:" >&5
14458cat conftest.$ac_ext >&5
14459echo "$as_me:$LINENO: result: no" >&5
14460echo "${ECHO_T}no" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014461fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014462rm -f conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000014463
Guido van Rossumda88dad1995-01-26 00:46:29 +000014464va_list_is_array=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014465echo "$as_me:$LINENO: checking whether va_list is an array" >&5
14466echo $ECHO_N "checking whether va_list is an array... $ECHO_C" >&6
14467cat >conftest.$ac_ext <<_ACEOF
14468#line $LINENO "configure"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014469#include "confdefs.h"
14470
14471#ifdef HAVE_STDARG_PROTOTYPES
14472#include <stdarg.h>
14473#else
14474#include <varargs.h>
14475#endif
14476
Martin v. Löwis11437992002-04-12 09:54:03 +000014477#ifdef F77_DUMMY_MAIN
14478# ifdef __cplusplus
14479 extern "C"
14480# endif
14481 int F77_DUMMY_MAIN() { return 1; }
14482#endif
14483int
14484main ()
14485{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014486va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000014487 ;
14488 return 0;
14489}
14490_ACEOF
14491rm -f conftest.$ac_objext
14492if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14493 (eval $ac_compile) 2>&5
14494 ac_status=$?
14495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14496 (exit $ac_status); } &&
14497 { ac_try='test -s conftest.$ac_objext'
14498 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14499 (eval $ac_try) 2>&5
14500 ac_status=$?
14501 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14502 (exit $ac_status); }; }; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014503 :
14504else
Martin v. Löwis11437992002-04-12 09:54:03 +000014505 echo "$as_me: failed program was:" >&5
14506cat conftest.$ac_ext >&5
14507
14508
14509cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014510#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014511_ACEOF
14512
Guido van Rossumda88dad1995-01-26 00:46:29 +000014513 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000014514
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014515fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014516rm -f conftest.$ac_objext conftest.$ac_ext
14517echo "$as_me:$LINENO: result: $va_list_is_array" >&5
14518echo "${ECHO_T}$va_list_is_array" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014519
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014520# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000014521
14522
14523
14524echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
14525echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6
14526if test "${ac_cv_func_gethostbyname_r+set}" = set; then
14527 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014528else
Martin v. Löwis11437992002-04-12 09:54:03 +000014529 cat >conftest.$ac_ext <<_ACEOF
14530#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014531#include "confdefs.h"
14532/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014533 which can conflict with char gethostbyname_r (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014534#include <assert.h>
14535/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014536#ifdef __cplusplus
14537extern "C"
14538#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014539/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014540 builtin and then its argument prototype would still apply. */
14541char gethostbyname_r ();
14542char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014543
Martin v. Löwis11437992002-04-12 09:54:03 +000014544#ifdef F77_DUMMY_MAIN
14545# ifdef __cplusplus
14546 extern "C"
14547# endif
14548 int F77_DUMMY_MAIN() { return 1; }
14549#endif
14550int
14551main ()
14552{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014553/* The GNU C library defines this for functions which it implements
14554 to always fail with ENOSYS. Some functions are actually named
14555 something starting with __ and the normal name is an alias. */
14556#if defined (__stub_gethostbyname_r) || defined (__stub___gethostbyname_r)
14557choke me
14558#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014559f = gethostbyname_r;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014560#endif
14561
Martin v. Löwis11437992002-04-12 09:54:03 +000014562 ;
14563 return 0;
14564}
14565_ACEOF
14566rm -f conftest.$ac_objext conftest$ac_exeext
14567if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14568 (eval $ac_link) 2>&5
14569 ac_status=$?
14570 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14571 (exit $ac_status); } &&
14572 { ac_try='test -s conftest$ac_exeext'
14573 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14574 (eval $ac_try) 2>&5
14575 ac_status=$?
14576 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14577 (exit $ac_status); }; }; then
14578 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014579else
Martin v. Löwis11437992002-04-12 09:54:03 +000014580 echo "$as_me: failed program was:" >&5
14581cat conftest.$ac_ext >&5
14582ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014583fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014584rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014585fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014586echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
14587echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6
14588if test $ac_cv_func_gethostbyname_r = yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014589
Martin v. Löwis11437992002-04-12 09:54:03 +000014590 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014591#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014592_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014593
Martin v. Löwis11437992002-04-12 09:54:03 +000014594 echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
14595echo $ECHO_N "checking gethostbyname_r with 6 args... $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014596 OLD_CFLAGS=$CFLAGS
14597 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014598 cat >conftest.$ac_ext <<_ACEOF
14599#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014600#include "confdefs.h"
14601
14602# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014603
14604#ifdef F77_DUMMY_MAIN
14605# ifdef __cplusplus
14606 extern "C"
14607# endif
14608 int F77_DUMMY_MAIN() { return 1; }
14609#endif
14610int
14611main ()
14612{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014613
14614 char *name;
14615 struct hostent *he, *res;
14616 char buffer[2048];
14617 int buflen = 2048;
14618 int h_errnop;
14619
14620 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014621
14622 ;
14623 return 0;
14624}
14625_ACEOF
14626rm -f conftest.$ac_objext
14627if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14628 (eval $ac_compile) 2>&5
14629 ac_status=$?
14630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14631 (exit $ac_status); } &&
14632 { ac_try='test -s conftest.$ac_objext'
14633 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14634 (eval $ac_try) 2>&5
14635 ac_status=$?
14636 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14637 (exit $ac_status); }; }; then
14638
14639 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014640#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014641_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014642
Martin v. Löwis11437992002-04-12 09:54:03 +000014643
14644cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014645#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014646_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014647
Martin v. Löwis11437992002-04-12 09:54:03 +000014648 echo "$as_me:$LINENO: result: yes" >&5
14649echo "${ECHO_T}yes" >&6
14650
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014651else
Martin v. Löwis11437992002-04-12 09:54:03 +000014652 echo "$as_me: failed program was:" >&5
14653cat conftest.$ac_ext >&5
14654
14655 echo "$as_me:$LINENO: result: no" >&5
14656echo "${ECHO_T}no" >&6
14657 echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
14658echo $ECHO_N "checking gethostbyname_r with 5 args... $ECHO_C" >&6
14659 cat >conftest.$ac_ext <<_ACEOF
14660#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014661#include "confdefs.h"
14662
14663# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014664
14665#ifdef F77_DUMMY_MAIN
14666# ifdef __cplusplus
14667 extern "C"
14668# endif
14669 int F77_DUMMY_MAIN() { return 1; }
14670#endif
14671int
14672main ()
14673{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014674
14675 char *name;
14676 struct hostent *he;
14677 char buffer[2048];
14678 int buflen = 2048;
14679 int h_errnop;
14680
14681 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000014682
14683 ;
14684 return 0;
14685}
14686_ACEOF
14687rm -f conftest.$ac_objext
14688if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14689 (eval $ac_compile) 2>&5
14690 ac_status=$?
14691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14692 (exit $ac_status); } &&
14693 { ac_try='test -s conftest.$ac_objext'
14694 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14695 (eval $ac_try) 2>&5
14696 ac_status=$?
14697 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14698 (exit $ac_status); }; }; then
14699
14700 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014701#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014702_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014703
Martin v. Löwis11437992002-04-12 09:54:03 +000014704
14705cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014706#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014707_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014708
Martin v. Löwis11437992002-04-12 09:54:03 +000014709 echo "$as_me:$LINENO: result: yes" >&5
14710echo "${ECHO_T}yes" >&6
14711
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014712else
Martin v. Löwis11437992002-04-12 09:54:03 +000014713 echo "$as_me: failed program was:" >&5
14714cat conftest.$ac_ext >&5
14715
14716 echo "$as_me:$LINENO: result: no" >&5
14717echo "${ECHO_T}no" >&6
14718 echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
14719echo $ECHO_N "checking gethostbyname_r with 3 args... $ECHO_C" >&6
14720 cat >conftest.$ac_ext <<_ACEOF
14721#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014722#include "confdefs.h"
14723
14724# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014725
14726#ifdef F77_DUMMY_MAIN
14727# ifdef __cplusplus
14728 extern "C"
14729# endif
14730 int F77_DUMMY_MAIN() { return 1; }
14731#endif
14732int
14733main ()
14734{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014735
14736 char *name;
14737 struct hostent *he;
14738 struct hostent_data data;
14739
14740 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000014741
14742 ;
14743 return 0;
14744}
14745_ACEOF
14746rm -f conftest.$ac_objext
14747if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14748 (eval $ac_compile) 2>&5
14749 ac_status=$?
14750 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14751 (exit $ac_status); } &&
14752 { ac_try='test -s conftest.$ac_objext'
14753 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14754 (eval $ac_try) 2>&5
14755 ac_status=$?
14756 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14757 (exit $ac_status); }; }; then
14758
14759 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014760#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014761_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000014762
Martin v. Löwis11437992002-04-12 09:54:03 +000014763
14764cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014765#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014766_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014767
Martin v. Löwis11437992002-04-12 09:54:03 +000014768 echo "$as_me:$LINENO: result: yes" >&5
14769echo "${ECHO_T}yes" >&6
14770
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014771else
Martin v. Löwis11437992002-04-12 09:54:03 +000014772 echo "$as_me: failed program was:" >&5
14773cat conftest.$ac_ext >&5
14774
14775 echo "$as_me:$LINENO: result: no" >&5
14776echo "${ECHO_T}no" >&6
14777
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014778fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014779rm -f conftest.$ac_objext conftest.$ac_ext
14780
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014781fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014782rm -f conftest.$ac_objext conftest.$ac_ext
14783
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014784fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014785rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014786 CFLAGS=$OLD_CFLAGS
14787
14788else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014789
Martin v. Löwis11437992002-04-12 09:54:03 +000014790
14791for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000014792do
Martin v. Löwis11437992002-04-12 09:54:03 +000014793as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14794echo "$as_me:$LINENO: checking for $ac_func" >&5
14795echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14796if eval "test \"\${$as_ac_var+set}\" = set"; then
14797 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014798else
Martin v. Löwis11437992002-04-12 09:54:03 +000014799 cat >conftest.$ac_ext <<_ACEOF
14800#line $LINENO "configure"
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014801#include "confdefs.h"
14802/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014803 which can conflict with char $ac_func (); below. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014804#include <assert.h>
14805/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014806#ifdef __cplusplus
14807extern "C"
14808#endif
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014809/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014810 builtin and then its argument prototype would still apply. */
14811char $ac_func ();
14812char (*f) ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014813
Martin v. Löwis11437992002-04-12 09:54:03 +000014814#ifdef F77_DUMMY_MAIN
14815# ifdef __cplusplus
14816 extern "C"
14817# endif
14818 int F77_DUMMY_MAIN() { return 1; }
14819#endif
14820int
14821main ()
14822{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014823/* The GNU C library defines this for functions which it implements
14824 to always fail with ENOSYS. Some functions are actually named
14825 something starting with __ and the normal name is an alias. */
Thomas Wouters3a584202000-08-05 23:28:51 +000014826#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014827choke me
14828#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014829f = $ac_func;
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014830#endif
14831
Martin v. Löwis11437992002-04-12 09:54:03 +000014832 ;
14833 return 0;
14834}
14835_ACEOF
14836rm -f conftest.$ac_objext conftest$ac_exeext
14837if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14838 (eval $ac_link) 2>&5
14839 ac_status=$?
14840 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14841 (exit $ac_status); } &&
14842 { ac_try='test -s conftest$ac_exeext'
14843 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14844 (eval $ac_try) 2>&5
14845 ac_status=$?
14846 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14847 (exit $ac_status); }; }; then
14848 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000014849else
Martin v. Löwis11437992002-04-12 09:54:03 +000014850 echo "$as_me: failed program was:" >&5
14851cat conftest.$ac_ext >&5
14852eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000014853fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014854rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000014855fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014856echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14857echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14858if test `eval echo '${'$as_ac_var'}'` = yes; then
14859 cat >>confdefs.h <<_ACEOF
14860#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14861_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014862
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014863fi
Thomas Wouters3a584202000-08-05 23:28:51 +000014864done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014865
Michael W. Hudson54241132001-12-07 15:38:26 +000014866
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000014867fi
14868
Michael W. Hudson54241132001-12-07 15:38:26 +000014869
14870
14871
14872
14873
14874
Guido van Rossum627b2d71993-12-24 10:39:16 +000014875# checks for system services
14876# (none yet)
14877
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014878# Linux requires this for correct f.p. operations
Martin v. Löwis11437992002-04-12 09:54:03 +000014879echo "$as_me:$LINENO: checking for __fpu_control" >&5
14880echo $ECHO_N "checking for __fpu_control... $ECHO_C" >&6
14881if test "${ac_cv_func___fpu_control+set}" = set; then
14882 echo $ECHO_N "(cached) $ECHO_C" >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014883else
Martin v. Löwis11437992002-04-12 09:54:03 +000014884 cat >conftest.$ac_ext <<_ACEOF
14885#line $LINENO "configure"
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014886#include "confdefs.h"
14887/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000014888 which can conflict with char __fpu_control (); below. */
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014889#include <assert.h>
14890/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014891#ifdef __cplusplus
14892extern "C"
14893#endif
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014894/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014895 builtin and then its argument prototype would still apply. */
14896char __fpu_control ();
14897char (*f) ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014898
Martin v. Löwis11437992002-04-12 09:54:03 +000014899#ifdef F77_DUMMY_MAIN
14900# ifdef __cplusplus
14901 extern "C"
14902# endif
14903 int F77_DUMMY_MAIN() { return 1; }
14904#endif
14905int
14906main ()
14907{
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014908/* The GNU C library defines this for functions which it implements
14909 to always fail with ENOSYS. Some functions are actually named
14910 something starting with __ and the normal name is an alias. */
14911#if defined (__stub___fpu_control) || defined (__stub_____fpu_control)
14912choke me
14913#else
Martin v. Löwis11437992002-04-12 09:54:03 +000014914f = __fpu_control;
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014915#endif
14916
Martin v. Löwis11437992002-04-12 09:54:03 +000014917 ;
14918 return 0;
14919}
14920_ACEOF
14921rm -f conftest.$ac_objext conftest$ac_exeext
14922if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14923 (eval $ac_link) 2>&5
14924 ac_status=$?
14925 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14926 (exit $ac_status); } &&
14927 { ac_try='test -s conftest$ac_exeext'
14928 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14929 (eval $ac_try) 2>&5
14930 ac_status=$?
14931 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14932 (exit $ac_status); }; }; then
14933 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014934else
Martin v. Löwis11437992002-04-12 09:54:03 +000014935 echo "$as_me: failed program was:" >&5
14936cat conftest.$ac_ext >&5
14937ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014938fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014939rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014940fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014941echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
14942echo "${ECHO_T}$ac_cv_func___fpu_control" >&6
14943if test $ac_cv_func___fpu_control = yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000014944 :
14945else
Martin v. Löwis11437992002-04-12 09:54:03 +000014946
14947echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
14948echo $ECHO_N "checking for __fpu_control in -lieee... $ECHO_C" >&6
14949if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
14950 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014951else
Martin v. Löwis11437992002-04-12 09:54:03 +000014952 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014953LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014954cat >conftest.$ac_ext <<_ACEOF
14955#line $LINENO "configure"
Guido van Rossum627b2d71993-12-24 10:39:16 +000014956#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000014957
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014958/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014959#ifdef __cplusplus
14960extern "C"
14961#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014962/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000014963 builtin and then its argument prototype would still apply. */
14964char __fpu_control ();
14965#ifdef F77_DUMMY_MAIN
14966# ifdef __cplusplus
14967 extern "C"
14968# endif
14969 int F77_DUMMY_MAIN() { return 1; }
14970#endif
14971int
14972main ()
14973{
14974__fpu_control ();
14975 ;
14976 return 0;
14977}
14978_ACEOF
14979rm -f conftest.$ac_objext conftest$ac_exeext
14980if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14981 (eval $ac_link) 2>&5
14982 ac_status=$?
14983 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14984 (exit $ac_status); } &&
14985 { ac_try='test -s conftest$ac_exeext'
14986 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14987 (eval $ac_try) 2>&5
14988 ac_status=$?
14989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14990 (exit $ac_status); }; }; then
14991 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000014992else
Martin v. Löwis11437992002-04-12 09:54:03 +000014993 echo "$as_me: failed program was:" >&5
14994cat conftest.$ac_ext >&5
14995ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000014996fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014997rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14998LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014999fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015000echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
15001echo "${ECHO_T}$ac_cv_lib_ieee___fpu_control" >&6
15002if test $ac_cv_lib_ieee___fpu_control = yes; then
15003 cat >>confdefs.h <<_ACEOF
15004#define HAVE_LIBIEEE 1
15005_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015006
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015007 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015008
Guido van Rossum627b2d71993-12-24 10:39:16 +000015009fi
15010
Michael W. Hudson54241132001-12-07 15:38:26 +000015011
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000015012fi
15013
Michael W. Hudson54241132001-12-07 15:38:26 +000015014
Guido van Rossum7f253911997-05-09 02:42:48 +000015015# Check for --with-fpectl
Martin v. Löwis11437992002-04-12 09:54:03 +000015016echo "$as_me:$LINENO: checking for --with-fpectl" >&5
15017echo $ECHO_N "checking for --with-fpectl... $ECHO_C" >&6
15018
Guido van Rossum7f253911997-05-09 02:42:48 +000015019# Check whether --with-fpectl or --without-fpectl was given.
15020if test "${with_fpectl+set}" = set; then
15021 withval="$with_fpectl"
Martin v. Löwis11437992002-04-12 09:54:03 +000015022
Guido van Rossum7f253911997-05-09 02:42:48 +000015023if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000015024then
15025
15026cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000015027#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015028_ACEOF
15029
15030 echo "$as_me:$LINENO: result: yes" >&5
15031echo "${ECHO_T}yes" >&6
15032else echo "$as_me:$LINENO: result: no" >&5
15033echo "${ECHO_T}no" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015034fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015035else
Martin v. Löwis11437992002-04-12 09:54:03 +000015036 echo "$as_me:$LINENO: result: no" >&5
15037echo "${ECHO_T}no" >&6
15038fi;
Guido van Rossum7f253911997-05-09 02:42:48 +000015039
Guido van Rossum7f43da71994-08-01 12:15:30 +000015040# check for --with-libm=...
15041
Guido van Rossum563e7081996-09-10 18:20:48 +000015042case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000015043Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015044BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000015045*) LIBM=-lm
15046esac
Martin v. Löwis11437992002-04-12 09:54:03 +000015047echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
15048echo $ECHO_N "checking for --with-libm=STRING... $ECHO_C" >&6
15049
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015050# Check whether --with-libm or --without-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015051if test "${with_libm+set}" = set; then
15052 withval="$with_libm"
Martin v. Löwis11437992002-04-12 09:54:03 +000015053
Guido van Rossum7f253911997-05-09 02:42:48 +000015054if test "$withval" = no
15055then LIBM=
Martin v. Löwis11437992002-04-12 09:54:03 +000015056 echo "$as_me:$LINENO: result: force LIBM empty" >&5
15057echo "${ECHO_T}force LIBM empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015058elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000015059then LIBM=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000015060 echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
15061echo "${ECHO_T}set LIBM=\"$withval\"" >&6
15062else { { echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
15063echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
15064 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000015065fi
Guido van Rossum7f253911997-05-09 02:42:48 +000015066else
Martin v. Löwis11437992002-04-12 09:54:03 +000015067 echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
15068echo "${ECHO_T}default LIBM=\"$LIBM\"" >&6
15069fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000015070
15071# check for --with-libc=...
15072
Martin v. Löwis11437992002-04-12 09:54:03 +000015073echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
15074echo $ECHO_N "checking for --with-libc=STRING... $ECHO_C" >&6
15075
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015076# Check whether --with-libc or --without-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015077if test "${with_libc+set}" = set; then
15078 withval="$with_libc"
Martin v. Löwis11437992002-04-12 09:54:03 +000015079
Guido van Rossum7f253911997-05-09 02:42:48 +000015080if test "$withval" = no
15081then LIBC=
Martin v. Löwis11437992002-04-12 09:54:03 +000015082 echo "$as_me:$LINENO: result: force LIBC empty" >&5
15083echo "${ECHO_T}force LIBC empty" >&6
Guido van Rossum7f253911997-05-09 02:42:48 +000015084elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000015085then LIBC=$withval
Martin v. Löwis11437992002-04-12 09:54:03 +000015086 echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
15087echo "${ECHO_T}set LIBC=\"$withval\"" >&6
15088else { { echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
15089echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
15090 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000015091fi
Guido van Rossum7f253911997-05-09 02:42:48 +000015092else
Martin v. Löwis11437992002-04-12 09:54:03 +000015093 echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
15094echo "${ECHO_T}default LIBC=\"$LIBC\"" >&6
15095fi;
Guido van Rossum7f43da71994-08-01 12:15:30 +000015096
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015097# check for hypot() in math library
15098LIBS_SAVE=$LIBS
15099LIBS="$LIBS $LIBM"
Martin v. Löwis11437992002-04-12 09:54:03 +000015100
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015101for ac_func in hypot
15102do
Martin v. Löwis11437992002-04-12 09:54:03 +000015103as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15104echo "$as_me:$LINENO: checking for $ac_func" >&5
15105echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15106if eval "test \"\${$as_ac_var+set}\" = set"; then
15107 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015108else
Martin v. Löwis11437992002-04-12 09:54:03 +000015109 cat >conftest.$ac_ext <<_ACEOF
15110#line $LINENO "configure"
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015111#include "confdefs.h"
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015112/* System header to define __stub macros and hopefully few prototypes,
Martin v. Löwis11437992002-04-12 09:54:03 +000015113 which can conflict with char $ac_func (); below. */
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015114#include <assert.h>
15115/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015116#ifdef __cplusplus
15117extern "C"
15118#endif
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000015119/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000015120 builtin and then its argument prototype would still apply. */
15121char $ac_func ();
15122char (*f) ();
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015123
Martin v. Löwis11437992002-04-12 09:54:03 +000015124#ifdef F77_DUMMY_MAIN
15125# ifdef __cplusplus
15126 extern "C"
15127# endif
15128 int F77_DUMMY_MAIN() { return 1; }
15129#endif
15130int
15131main ()
15132{
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015133/* The GNU C library defines this for functions which it implements
15134 to always fail with ENOSYS. Some functions are actually named
15135 something starting with __ and the normal name is an alias. */
15136#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15137choke me
15138#else
Martin v. Löwis11437992002-04-12 09:54:03 +000015139f = $ac_func;
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015140#endif
15141
Martin v. Löwis11437992002-04-12 09:54:03 +000015142 ;
15143 return 0;
15144}
15145_ACEOF
15146rm -f conftest.$ac_objext conftest$ac_exeext
15147if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15148 (eval $ac_link) 2>&5
15149 ac_status=$?
15150 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15151 (exit $ac_status); } &&
15152 { ac_try='test -s conftest$ac_exeext'
15153 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15154 (eval $ac_try) 2>&5
15155 ac_status=$?
15156 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15157 (exit $ac_status); }; }; then
15158 eval "$as_ac_var=yes"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015159else
Martin v. Löwis11437992002-04-12 09:54:03 +000015160 echo "$as_me: failed program was:" >&5
15161cat conftest.$ac_ext >&5
15162eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000015163fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015164rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000015165fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015166echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15167echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15168if test `eval echo '${'$as_ac_var'}'` = yes; then
15169 cat >>confdefs.h <<_ACEOF
15170#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15171_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000015172
Michael W. Hudson54241132001-12-07 15:38:26 +000015173else
Martin v. Löwis11437992002-04-12 09:54:03 +000015174 LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015175fi
Guido van Rossum2b3ac691996-08-30 15:18:41 +000015176done
15177
Michael W. Hudson54241132001-12-07 15:38:26 +000015178
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000015179LIBS=$LIBS_SAVE
15180
Guido van Rossumad713701997-07-10 22:42:38 +000015181# check whether malloc(0) returns NULL or not
Martin v. Löwis11437992002-04-12 09:54:03 +000015182echo "$as_me:$LINENO: checking what malloc(0) returns" >&5
15183echo $ECHO_N "checking what malloc(0) returns... $ECHO_C" >&6
15184if test "${ac_cv_malloc_zero+set}" = set; then
15185 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad713701997-07-10 22:42:38 +000015186else
15187 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000015188 ac_cv_malloc_zero=nonnull
Guido van Rossumad713701997-07-10 22:42:38 +000015189else
Martin v. Löwis11437992002-04-12 09:54:03 +000015190 cat >conftest.$ac_ext <<_ACEOF
15191#line $LINENO "configure"
Guido van Rossumad713701997-07-10 22:42:38 +000015192#include "confdefs.h"
15193#include <stdio.h>
15194#ifdef HAVE_STDLIB
15195#include <stdlib.h>
15196#else
15197char *malloc(), *realloc();
15198int *free();
15199#endif
15200main() {
15201 char *p;
15202 p = malloc(0);
15203 if (p == NULL) exit(1);
15204 p = realloc(p, 0);
15205 if (p == NULL) exit(1);
15206 free(p);
15207 exit(0);
15208}
Martin v. Löwis11437992002-04-12 09:54:03 +000015209_ACEOF
15210rm -f conftest$ac_exeext
15211if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15212 (eval $ac_link) 2>&5
15213 ac_status=$?
15214 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15215 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15216 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15217 (eval $ac_try) 2>&5
15218 ac_status=$?
15219 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15220 (exit $ac_status); }; }; then
Guido van Rossumad713701997-07-10 22:42:38 +000015221 ac_cv_malloc_zero=nonnull
15222else
Martin v. Löwis11437992002-04-12 09:54:03 +000015223 echo "$as_me: program exited with status $ac_status" >&5
15224echo "$as_me: failed program was:" >&5
15225cat conftest.$ac_ext >&5
15226( exit $ac_status )
15227ac_cv_malloc_zero=null
Guido van Rossumad713701997-07-10 22:42:38 +000015228fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015229rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumad713701997-07-10 22:42:38 +000015230fi
Guido van Rossumad713701997-07-10 22:42:38 +000015231fi
Guido van Rossum3065c942001-09-17 04:03:14 +000015232 # XXX arm cross-compile?
Martin v. Löwis11437992002-04-12 09:54:03 +000015233echo "$as_me:$LINENO: result: $ac_cv_malloc_zero" >&5
15234echo "${ECHO_T}$ac_cv_malloc_zero" >&6
Guido van Rossumad713701997-07-10 22:42:38 +000015235if test "$ac_cv_malloc_zero" = null
15236then
Martin v. Löwis11437992002-04-12 09:54:03 +000015237
15238cat >>confdefs.h <<\_ACEOF
Guido van Rossumad713701997-07-10 22:42:38 +000015239#define MALLOC_ZERO_RETURNS_NULL 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015240_ACEOF
Guido van Rossumad713701997-07-10 22:42:38 +000015241
15242fi
15243
Guido van Rossumef2255b2000-03-10 22:30:29 +000015244# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000015245if test "${ac_cv_header_wchar_h+set}" = set; then
15246 echo "$as_me:$LINENO: checking for wchar.h" >&5
15247echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
15248if test "${ac_cv_header_wchar_h+set}" = set; then
15249 echo $ECHO_N "(cached) $ECHO_C" >&6
15250fi
15251echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
15252echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015253else
Martin v. Löwis11437992002-04-12 09:54:03 +000015254 # Is the header compilable?
15255echo "$as_me:$LINENO: checking wchar.h usability" >&5
15256echo $ECHO_N "checking wchar.h usability... $ECHO_C" >&6
15257cat >conftest.$ac_ext <<_ACEOF
15258#line $LINENO "configure"
15259#include "confdefs.h"
15260$ac_includes_default
15261#include <wchar.h>
15262_ACEOF
15263rm -f conftest.$ac_objext
15264if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15265 (eval $ac_compile) 2>&5
15266 ac_status=$?
15267 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15268 (exit $ac_status); } &&
15269 { ac_try='test -s conftest.$ac_objext'
15270 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15271 (eval $ac_try) 2>&5
15272 ac_status=$?
15273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15274 (exit $ac_status); }; }; then
15275 ac_header_compiler=yes
15276else
15277 echo "$as_me: failed program was:" >&5
15278cat conftest.$ac_ext >&5
15279ac_header_compiler=no
15280fi
15281rm -f conftest.$ac_objext conftest.$ac_ext
15282echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15283echo "${ECHO_T}$ac_header_compiler" >&6
15284
15285# Is the header present?
15286echo "$as_me:$LINENO: checking wchar.h presence" >&5
15287echo $ECHO_N "checking wchar.h presence... $ECHO_C" >&6
15288cat >conftest.$ac_ext <<_ACEOF
15289#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015290#include "confdefs.h"
15291#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015292_ACEOF
15293if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15294 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15295 ac_status=$?
15296 egrep -v '^ *\+' conftest.er1 >conftest.err
15297 rm -f conftest.er1
15298 cat conftest.err >&5
15299 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15300 (exit $ac_status); } >/dev/null; then
15301 if test -s conftest.err; then
15302 ac_cpp_err=$ac_c_preproc_warn_flag
15303 else
15304 ac_cpp_err=
15305 fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015306else
Martin v. Löwis11437992002-04-12 09:54:03 +000015307 ac_cpp_err=yes
15308fi
15309if test -z "$ac_cpp_err"; then
15310 ac_header_preproc=yes
15311else
15312 echo "$as_me: failed program was:" >&5
Guido van Rossumef2255b2000-03-10 22:30:29 +000015313 cat conftest.$ac_ext >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015314 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015315fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015316rm -f conftest.err conftest.$ac_ext
15317echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15318echo "${ECHO_T}$ac_header_preproc" >&6
15319
15320# So? What about this header?
15321case $ac_header_compiler:$ac_header_preproc in
15322 yes:no )
15323 { echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
15324echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15325 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
15326echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
15327 no:yes )
15328 { echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
15329echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
15330 { echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
15331echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
15332 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
15333echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;};;
15334esac
15335echo "$as_me:$LINENO: checking for wchar.h" >&5
15336echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6
15337if test "${ac_cv_header_wchar_h+set}" = set; then
15338 echo $ECHO_N "(cached) $ECHO_C" >&6
15339else
15340 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000015341fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015342echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
15343echo "${ECHO_T}$ac_cv_header_wchar_h" >&6
15344
15345fi
15346if test $ac_cv_header_wchar_h = yes; then
15347
15348
15349cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000015350#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015351_ACEOF
15352
Martin v. Löwisc45929e2002-04-06 10:10:49 +000015353 wchar_h="yes"
15354
Guido van Rossumef2255b2000-03-10 22:30:29 +000015355else
Martin v. Löwis11437992002-04-12 09:54:03 +000015356 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015357
15358fi
15359
Michael W. Hudson54241132001-12-07 15:38:26 +000015360
Martin v. Löwis11437992002-04-12 09:54:03 +000015361
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015362# determine wchar_t size
15363if test "$wchar_h" = yes
15364then
Martin v. Löwis11437992002-04-12 09:54:03 +000015365 echo "$as_me:$LINENO: checking for wchar_t" >&5
15366echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6
15367if test "${ac_cv_type_wchar_t+set}" = set; then
15368 echo $ECHO_N "(cached) $ECHO_C" >&6
15369else
15370 cat >conftest.$ac_ext <<_ACEOF
15371#line $LINENO "configure"
15372#include "confdefs.h"
15373#include <wchar.h>
15374
15375#ifdef F77_DUMMY_MAIN
15376# ifdef __cplusplus
15377 extern "C"
15378# endif
15379 int F77_DUMMY_MAIN() { return 1; }
15380#endif
15381int
15382main ()
15383{
15384if ((wchar_t *) 0)
15385 return 0;
15386if (sizeof (wchar_t))
15387 return 0;
15388 ;
15389 return 0;
15390}
15391_ACEOF
15392rm -f conftest.$ac_objext
15393if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15394 (eval $ac_compile) 2>&5
15395 ac_status=$?
15396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15397 (exit $ac_status); } &&
15398 { ac_try='test -s conftest.$ac_objext'
15399 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15400 (eval $ac_try) 2>&5
15401 ac_status=$?
15402 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15403 (exit $ac_status); }; }; then
15404 ac_cv_type_wchar_t=yes
15405else
15406 echo "$as_me: failed program was:" >&5
15407cat conftest.$ac_ext >&5
15408ac_cv_type_wchar_t=no
15409fi
15410rm -f conftest.$ac_objext conftest.$ac_ext
15411fi
15412echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
15413echo "${ECHO_T}$ac_cv_type_wchar_t" >&6
15414
15415echo "$as_me:$LINENO: checking size of wchar_t" >&5
15416echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6
15417if test "${ac_cv_sizeof_wchar_t+set}" = set; then
15418 echo $ECHO_N "(cached) $ECHO_C" >&6
15419else
15420 if test "$ac_cv_type_wchar_t" = yes; then
15421 # The cast to unsigned long works around a bug in the HP C Compiler
15422 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15423 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15424 # This bug is HP SR number 8606223364.
15425 if test "$cross_compiling" = yes; then
15426 # Depending upon the size, compute the lo and hi bounds.
15427cat >conftest.$ac_ext <<_ACEOF
15428#line $LINENO "configure"
15429#include "confdefs.h"
15430#include <wchar.h>
15431
15432#ifdef F77_DUMMY_MAIN
15433# ifdef __cplusplus
15434 extern "C"
15435# endif
15436 int F77_DUMMY_MAIN() { return 1; }
15437#endif
15438int
15439main ()
15440{
15441static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= 0)];
15442test_array [0] = 0
15443
15444 ;
15445 return 0;
15446}
15447_ACEOF
15448rm -f conftest.$ac_objext
15449if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15450 (eval $ac_compile) 2>&5
15451 ac_status=$?
15452 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15453 (exit $ac_status); } &&
15454 { ac_try='test -s conftest.$ac_objext'
15455 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15456 (eval $ac_try) 2>&5
15457 ac_status=$?
15458 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15459 (exit $ac_status); }; }; then
15460 ac_lo=0 ac_mid=0
15461 while :; do
15462 cat >conftest.$ac_ext <<_ACEOF
15463#line $LINENO "configure"
15464#include "confdefs.h"
15465#include <wchar.h>
15466
15467#ifdef F77_DUMMY_MAIN
15468# ifdef __cplusplus
15469 extern "C"
15470# endif
15471 int F77_DUMMY_MAIN() { return 1; }
15472#endif
15473int
15474main ()
15475{
15476static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15477test_array [0] = 0
15478
15479 ;
15480 return 0;
15481}
15482_ACEOF
15483rm -f conftest.$ac_objext
15484if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15485 (eval $ac_compile) 2>&5
15486 ac_status=$?
15487 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15488 (exit $ac_status); } &&
15489 { ac_try='test -s conftest.$ac_objext'
15490 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15491 (eval $ac_try) 2>&5
15492 ac_status=$?
15493 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15494 (exit $ac_status); }; }; then
15495 ac_hi=$ac_mid; break
15496else
15497 echo "$as_me: failed program was:" >&5
15498cat conftest.$ac_ext >&5
15499ac_lo=`expr $ac_mid + 1`
15500 if test $ac_lo -le $ac_mid; then
15501 ac_lo= ac_hi=
15502 break
15503 fi
15504 ac_mid=`expr 2 '*' $ac_mid + 1`
15505fi
15506rm -f conftest.$ac_objext conftest.$ac_ext
15507 done
15508else
15509 echo "$as_me: failed program was:" >&5
15510cat conftest.$ac_ext >&5
15511cat >conftest.$ac_ext <<_ACEOF
15512#line $LINENO "configure"
15513#include "confdefs.h"
15514#include <wchar.h>
15515
15516#ifdef F77_DUMMY_MAIN
15517# ifdef __cplusplus
15518 extern "C"
15519# endif
15520 int F77_DUMMY_MAIN() { return 1; }
15521#endif
15522int
15523main ()
15524{
15525static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) < 0)];
15526test_array [0] = 0
15527
15528 ;
15529 return 0;
15530}
15531_ACEOF
15532rm -f conftest.$ac_objext
15533if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15534 (eval $ac_compile) 2>&5
15535 ac_status=$?
15536 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15537 (exit $ac_status); } &&
15538 { ac_try='test -s conftest.$ac_objext'
15539 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15540 (eval $ac_try) 2>&5
15541 ac_status=$?
15542 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15543 (exit $ac_status); }; }; then
15544 ac_hi=-1 ac_mid=-1
15545 while :; do
15546 cat >conftest.$ac_ext <<_ACEOF
15547#line $LINENO "configure"
15548#include "confdefs.h"
15549#include <wchar.h>
15550
15551#ifdef F77_DUMMY_MAIN
15552# ifdef __cplusplus
15553 extern "C"
15554# endif
15555 int F77_DUMMY_MAIN() { return 1; }
15556#endif
15557int
15558main ()
15559{
15560static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) >= $ac_mid)];
15561test_array [0] = 0
15562
15563 ;
15564 return 0;
15565}
15566_ACEOF
15567rm -f conftest.$ac_objext
15568if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15569 (eval $ac_compile) 2>&5
15570 ac_status=$?
15571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15572 (exit $ac_status); } &&
15573 { ac_try='test -s conftest.$ac_objext'
15574 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15575 (eval $ac_try) 2>&5
15576 ac_status=$?
15577 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15578 (exit $ac_status); }; }; then
15579 ac_lo=$ac_mid; break
15580else
15581 echo "$as_me: failed program was:" >&5
15582cat conftest.$ac_ext >&5
15583ac_hi=`expr '(' $ac_mid ')' - 1`
15584 if test $ac_mid -le $ac_hi; then
15585 ac_lo= ac_hi=
15586 break
15587 fi
15588 ac_mid=`expr 2 '*' $ac_mid`
15589fi
15590rm -f conftest.$ac_objext conftest.$ac_ext
15591 done
15592else
15593 echo "$as_me: failed program was:" >&5
15594cat conftest.$ac_ext >&5
15595ac_lo= ac_hi=
15596fi
15597rm -f conftest.$ac_objext conftest.$ac_ext
15598fi
15599rm -f conftest.$ac_objext conftest.$ac_ext
15600# Binary search between lo and hi bounds.
15601while test "x$ac_lo" != "x$ac_hi"; do
15602 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15603 cat >conftest.$ac_ext <<_ACEOF
15604#line $LINENO "configure"
15605#include "confdefs.h"
15606#include <wchar.h>
15607
15608#ifdef F77_DUMMY_MAIN
15609# ifdef __cplusplus
15610 extern "C"
15611# endif
15612 int F77_DUMMY_MAIN() { return 1; }
15613#endif
15614int
15615main ()
15616{
15617static int test_array [1 - 2 * !(((long) (sizeof (wchar_t))) <= $ac_mid)];
15618test_array [0] = 0
15619
15620 ;
15621 return 0;
15622}
15623_ACEOF
15624rm -f conftest.$ac_objext
15625if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15626 (eval $ac_compile) 2>&5
15627 ac_status=$?
15628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15629 (exit $ac_status); } &&
15630 { ac_try='test -s conftest.$ac_objext'
15631 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15632 (eval $ac_try) 2>&5
15633 ac_status=$?
15634 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15635 (exit $ac_status); }; }; then
15636 ac_hi=$ac_mid
15637else
15638 echo "$as_me: failed program was:" >&5
15639cat conftest.$ac_ext >&5
15640ac_lo=`expr '(' $ac_mid ')' + 1`
15641fi
15642rm -f conftest.$ac_objext conftest.$ac_ext
15643done
15644case $ac_lo in
15645?*) ac_cv_sizeof_wchar_t=$ac_lo;;
15646'') { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15647echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15648 { (exit 1); exit 1; }; } ;;
15649esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015650else
15651 if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015652 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15653echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15654 { (exit 1); exit 1; }; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000015655else
Martin v. Löwis11437992002-04-12 09:54:03 +000015656 cat >conftest.$ac_ext <<_ACEOF
15657#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015658#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015659#include <wchar.h>
15660
15661long longval () { return (long) (sizeof (wchar_t)); }
15662unsigned long ulongval () { return (long) (sizeof (wchar_t)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000015663#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015664#include <stdlib.h>
15665#ifdef F77_DUMMY_MAIN
15666# ifdef __cplusplus
15667 extern "C"
15668# endif
15669 int F77_DUMMY_MAIN() { return 1; }
15670#endif
15671int
15672main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015673{
Martin v. Löwis11437992002-04-12 09:54:03 +000015674
15675 FILE *f = fopen ("conftest.val", "w");
15676 if (! f)
15677 exit (1);
15678 if (((long) (sizeof (wchar_t))) < 0)
15679 {
15680 long i = longval ();
15681 if (i != ((long) (sizeof (wchar_t))))
15682 exit (1);
15683 fprintf (f, "%ld\n", i);
15684 }
15685 else
15686 {
15687 unsigned long i = ulongval ();
15688 if (i != ((long) (sizeof (wchar_t))))
15689 exit (1);
15690 fprintf (f, "%lu\n", i);
15691 }
15692 exit (ferror (f) || fclose (f) != 0);
15693
15694 ;
15695 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000015696}
Martin v. Löwis11437992002-04-12 09:54:03 +000015697_ACEOF
15698rm -f conftest$ac_exeext
15699if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15700 (eval $ac_link) 2>&5
15701 ac_status=$?
15702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15703 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15704 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15705 (eval $ac_try) 2>&5
15706 ac_status=$?
15707 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15708 (exit $ac_status); }; }; then
15709 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000015710else
Martin v. Löwis11437992002-04-12 09:54:03 +000015711 echo "$as_me: program exited with status $ac_status" >&5
15712echo "$as_me: failed program was:" >&5
15713cat conftest.$ac_ext >&5
15714( exit $ac_status )
15715{ { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t), 77" >&5
15716echo "$as_me: error: cannot compute sizeof (wchar_t), 77" >&2;}
15717 { (exit 1); exit 1; }; }
15718fi
15719rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15720fi
15721fi
15722rm -f conftest.val
15723else
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015724 ac_cv_sizeof_wchar_t=0
Guido van Rossumef2255b2000-03-10 22:30:29 +000015725fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015726fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015727echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
15728echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6
15729cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015730#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015731_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015732
Michael W. Hudson54241132001-12-07 15:38:26 +000015733
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015734fi
15735
Martin v. Löwis11437992002-04-12 09:54:03 +000015736echo "$as_me:$LINENO: checking what type to use for unicode" >&5
15737echo $ECHO_N "checking what type to use for unicode... $ECHO_C" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015738# Check whether --enable-unicode or --disable-unicode was given.
15739if test "${enable_unicode+set}" = set; then
15740 enableval="$enable_unicode"
Martin v. Löwis11437992002-04-12 09:54:03 +000015741
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015742else
15743 enable_unicode=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000015744fi;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015745
15746if test $enable_unicode = yes
15747then
Martin v. Löwisfd917792001-06-27 20:22:04 +000015748 # Without any arguments, Py_UNICODE defaults to two-byte mode
15749 enable_unicode="ucs2"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015750fi
15751
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015752
15753
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015754case "$enable_unicode" in
15755ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000015756 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015757#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000015758_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015759
15760 ;;
15761ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000015762 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015763#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000015764_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015765
15766 ;;
15767esac
15768
Michael W. Hudson54241132001-12-07 15:38:26 +000015769
Martin v. Löwis11437992002-04-12 09:54:03 +000015770
15771
Martin v. Löwis0036cba2002-04-12 09:58:45 +000015772
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015773if test "$enable_unicode" = "no"
15774then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015775 UNICODE_OBJS=""
Martin v. Löwis11437992002-04-12 09:54:03 +000015776 echo "$as_me:$LINENO: result: not used" >&5
15777echo "${ECHO_T}not used" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015778else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000015779 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000015780
15781cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015782#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015783_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015784
15785 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t"
15786 then
15787 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015788
Martin v. Löwis11437992002-04-12 09:54:03 +000015789cat >>confdefs.h <<\_ACEOF
15790#define HAVE_USABLE_WCHAR_T 1
15791_ACEOF
15792
15793 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015794#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000015795_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015796
15797 elif test "$ac_cv_sizeof_short" = "$unicode_size"
15798 then
15799 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000015800 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015801#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000015802_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015803
15804 elif test "$ac_cv_sizeof_long" = "$unicode_size"
15805 then
15806 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000015807 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015808#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000015809_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015810
15811 else
15812 PY_UNICODE_TYPE="no type found"
15813 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015814 echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
15815echo "${ECHO_T}$PY_UNICODE_TYPE" >&6
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000015816fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000015817
15818# check for endianness
Martin v. Löwis11437992002-04-12 09:54:03 +000015819echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
15820echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
15821if test "${ac_cv_c_bigendian+set}" = set; then
15822 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000015823else
Martin v. Löwis11437992002-04-12 09:54:03 +000015824 # See if sys/param.h defines the BYTE_ORDER macro.
15825cat >conftest.$ac_ext <<_ACEOF
15826#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015827#include "confdefs.h"
15828#include <sys/types.h>
15829#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015830
Martin v. Löwis11437992002-04-12 09:54:03 +000015831#ifdef F77_DUMMY_MAIN
15832# ifdef __cplusplus
15833 extern "C"
15834# endif
15835 int F77_DUMMY_MAIN() { return 1; }
15836#endif
15837int
15838main ()
15839{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015840#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
15841 bogus endian macros
15842#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015843
15844 ;
15845 return 0;
15846}
15847_ACEOF
15848rm -f conftest.$ac_objext
15849if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15850 (eval $ac_compile) 2>&5
15851 ac_status=$?
15852 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15853 (exit $ac_status); } &&
15854 { ac_try='test -s conftest.$ac_objext'
15855 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15856 (eval $ac_try) 2>&5
15857 ac_status=$?
15858 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15859 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015860 # It does; now see whether it defined to BIG_ENDIAN or not.
Martin v. Löwis11437992002-04-12 09:54:03 +000015861cat >conftest.$ac_ext <<_ACEOF
15862#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015863#include "confdefs.h"
15864#include <sys/types.h>
15865#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000015866
Martin v. Löwis11437992002-04-12 09:54:03 +000015867#ifdef F77_DUMMY_MAIN
15868# ifdef __cplusplus
15869 extern "C"
15870# endif
15871 int F77_DUMMY_MAIN() { return 1; }
15872#endif
15873int
15874main ()
15875{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015876#if BYTE_ORDER != BIG_ENDIAN
15877 not big endian
15878#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015879
15880 ;
15881 return 0;
15882}
15883_ACEOF
15884rm -f conftest.$ac_objext
15885if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15886 (eval $ac_compile) 2>&5
15887 ac_status=$?
15888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15889 (exit $ac_status); } &&
15890 { ac_try='test -s conftest.$ac_objext'
15891 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15892 (eval $ac_try) 2>&5
15893 ac_status=$?
15894 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15895 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015896 ac_cv_c_bigendian=yes
15897else
Martin v. Löwis11437992002-04-12 09:54:03 +000015898 echo "$as_me: failed program was:" >&5
15899cat conftest.$ac_ext >&5
15900ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000015901fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015902rm -f conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000015903else
Martin v. Löwis11437992002-04-12 09:54:03 +000015904 echo "$as_me: failed program was:" >&5
15905cat conftest.$ac_ext >&5
15906# It does not; compile a test program.
Guido van Rossumef2255b2000-03-10 22:30:29 +000015907if test "$cross_compiling" = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015908 # try to guess the endianess by grep'ing values into an object file
15909 ac_cv_c_bigendian=unknown
15910 cat >conftest.$ac_ext <<_ACEOF
15911#line $LINENO "configure"
Guido van Rossumef2255b2000-03-10 22:30:29 +000015912#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000015913short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
15914short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
15915void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
15916short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
15917short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
15918void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
15919#ifdef F77_DUMMY_MAIN
15920# ifdef __cplusplus
15921 extern "C"
15922# endif
15923 int F77_DUMMY_MAIN() { return 1; }
15924#endif
15925int
15926main ()
15927{
15928 _ascii (); _ebcdic ();
15929 ;
15930 return 0;
15931}
15932_ACEOF
15933rm -f conftest.$ac_objext
15934if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15935 (eval $ac_compile) 2>&5
15936 ac_status=$?
15937 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15938 (exit $ac_status); } &&
15939 { ac_try='test -s conftest.$ac_objext'
15940 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15941 (eval $ac_try) 2>&5
15942 ac_status=$?
15943 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15944 (exit $ac_status); }; }; then
15945 if fgrep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
15946 ac_cv_c_bigendian=yes
15947fi
15948if fgrep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
15949 if test "$ac_cv_c_bigendian" = unknown; then
15950 ac_cv_c_bigendian=no
15951 else
15952 # finding both strings is unlikely to happen, but who knows?
15953 ac_cv_c_bigendian=unknown
15954 fi
15955fi
15956else
15957 echo "$as_me: failed program was:" >&5
15958cat conftest.$ac_ext >&5
15959fi
15960rm -f conftest.$ac_objext conftest.$ac_ext
15961else
15962 cat >conftest.$ac_ext <<_ACEOF
15963#line $LINENO "configure"
15964#include "confdefs.h"
15965int
15966main ()
15967{
Guido van Rossumef2255b2000-03-10 22:30:29 +000015968 /* Are we little or big endian? From Harbison&Steele. */
15969 union
15970 {
15971 long l;
15972 char c[sizeof (long)];
15973 } u;
15974 u.l = 1;
15975 exit (u.c[sizeof (long) - 1] == 1);
15976}
Martin v. Löwis11437992002-04-12 09:54:03 +000015977_ACEOF
15978rm -f conftest$ac_exeext
15979if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15980 (eval $ac_link) 2>&5
15981 ac_status=$?
15982 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15983 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15984 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15985 (eval $ac_try) 2>&5
15986 ac_status=$?
15987 echo "$as_me:$LINENO: \$? = $ac_status" >&5
15988 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000015989 ac_cv_c_bigendian=no
15990else
Martin v. Löwis11437992002-04-12 09:54:03 +000015991 echo "$as_me: program exited with status $ac_status" >&5
15992echo "$as_me: failed program was:" >&5
15993cat conftest.$ac_ext >&5
15994( exit $ac_status )
15995ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000015996fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015997rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000015998fi
Martin v. Löwis11437992002-04-12 09:54:03 +000015999fi
16000rm -f conftest.$ac_objext conftest.$ac_ext
16001fi
16002echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
16003echo "${ECHO_T}$ac_cv_c_bigendian" >&6
16004case $ac_cv_c_bigendian in
16005 yes)
Jack Jansendd19cf82001-12-06 22:36:17 +000016006
Martin v. Löwis11437992002-04-12 09:54:03 +000016007cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000016008#define WORDS_BIGENDIAN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016009_ACEOF
16010 ;;
16011 no)
16012 ;;
16013 *)
16014 { { echo "$as_me:$LINENO: error: unknown endianess
16015presetting ac_cv_c_bigendian=no (or yes) will help" >&5
16016echo "$as_me: error: unknown endianess
16017presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
16018 { (exit 1); exit 1; }; } ;;
16019esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000016020
Michael W. Hudson54241132001-12-07 15:38:26 +000016021
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016022# Check whether right shifting a negative integer extends the sign bit
16023# or fills with zeros (like the Cray J90, according to Tim Peters).
Martin v. Löwis11437992002-04-12 09:54:03 +000016024echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
16025echo $ECHO_N "checking whether right shift extends the sign bit... $ECHO_C" >&6
16026if test "${ac_cv_rshift_extends_sign+set}" = set; then
16027 echo $ECHO_N "(cached) $ECHO_C" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000016028else
Martin v. Löwis11437992002-04-12 09:54:03 +000016029
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016030if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000016031 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016032else
Martin v. Löwis11437992002-04-12 09:54:03 +000016033 cat >conftest.$ac_ext <<_ACEOF
16034#line $LINENO "configure"
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016035#include "confdefs.h"
16036
16037int main()
16038{
Vladimir Marangozova6180282000-07-12 05:05:06 +000016039 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016040}
16041
Martin v. Löwis11437992002-04-12 09:54:03 +000016042_ACEOF
16043rm -f conftest$ac_exeext
16044if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16045 (eval $ac_link) 2>&5
16046 ac_status=$?
16047 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16048 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16049 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16050 (eval $ac_try) 2>&5
16051 ac_status=$?
16052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16053 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000016054 ac_cv_rshift_extends_sign=yes
16055else
Martin v. Löwis11437992002-04-12 09:54:03 +000016056 echo "$as_me: program exited with status $ac_status" >&5
16057echo "$as_me: failed program was:" >&5
16058cat conftest.$ac_ext >&5
16059( exit $ac_status )
16060ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000016061fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016062rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16063fi
Vladimir Marangozova6180282000-07-12 05:05:06 +000016064fi
16065
Martin v. Löwis11437992002-04-12 09:54:03 +000016066echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
16067echo "${ECHO_T}$ac_cv_rshift_extends_sign" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000016068if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016069then
Martin v. Löwis11437992002-04-12 09:54:03 +000016070
16071cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016072#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016073_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016074
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016075fi
16076
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016077# check for getc_unlocked and related locking functions
Martin v. Löwis11437992002-04-12 09:54:03 +000016078echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
16079echo $ECHO_N "checking for getc_unlocked() and friends... $ECHO_C" >&6
16080if test "${ac_cv_have_getc_unlocked+set}" = set; then
16081 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016082else
Martin v. Löwis11437992002-04-12 09:54:03 +000016083
16084cat >conftest.$ac_ext <<_ACEOF
16085#line $LINENO "configure"
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016086#include "confdefs.h"
16087#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016088#ifdef F77_DUMMY_MAIN
16089# ifdef __cplusplus
16090 extern "C"
16091# endif
16092 int F77_DUMMY_MAIN() { return 1; }
16093#endif
16094int
16095main ()
16096{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016097
16098 FILE *f = fopen("/dev/null", "r");
16099 flockfile(f);
16100 getc_unlocked(f);
16101 funlockfile(f);
16102
Martin v. Löwis11437992002-04-12 09:54:03 +000016103 ;
16104 return 0;
16105}
16106_ACEOF
16107rm -f conftest.$ac_objext conftest$ac_exeext
16108if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16109 (eval $ac_link) 2>&5
16110 ac_status=$?
16111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16112 (exit $ac_status); } &&
16113 { ac_try='test -s conftest$ac_exeext'
16114 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16115 (eval $ac_try) 2>&5
16116 ac_status=$?
16117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16118 (exit $ac_status); }; }; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016119 ac_cv_have_getc_unlocked=yes
16120else
Martin v. Löwis11437992002-04-12 09:54:03 +000016121 echo "$as_me: failed program was:" >&5
16122cat conftest.$ac_ext >&5
16123ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016124fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016125rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016126fi
16127
Martin v. Löwis11437992002-04-12 09:54:03 +000016128echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
16129echo "${ECHO_T}$ac_cv_have_getc_unlocked" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016130if test "$ac_cv_have_getc_unlocked" = yes
16131then
Martin v. Löwis11437992002-04-12 09:54:03 +000016132
16133cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016134#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016135_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000016136
16137fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000016138
Martin v. Löwis0daad592001-09-30 21:09:59 +000016139# check for readline 4.0
Martin v. Löwis11437992002-04-12 09:54:03 +000016140echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
16141echo $ECHO_N "checking for rl_pre_input_hook in -lreadline... $ECHO_C" >&6
16142if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
16143 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000016144else
Martin v. Löwis11437992002-04-12 09:54:03 +000016145 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum353ae582001-07-10 16:45:32 +000016146LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016147cat >conftest.$ac_ext <<_ACEOF
16148#line $LINENO "configure"
Guido van Rossum353ae582001-07-10 16:45:32 +000016149#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016150
Guido van Rossum353ae582001-07-10 16:45:32 +000016151/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016152#ifdef __cplusplus
16153extern "C"
16154#endif
Guido van Rossum353ae582001-07-10 16:45:32 +000016155/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016156 builtin and then its argument prototype would still apply. */
16157char rl_pre_input_hook ();
16158#ifdef F77_DUMMY_MAIN
16159# ifdef __cplusplus
16160 extern "C"
16161# endif
16162 int F77_DUMMY_MAIN() { return 1; }
16163#endif
16164int
16165main ()
16166{
16167rl_pre_input_hook ();
16168 ;
16169 return 0;
16170}
16171_ACEOF
16172rm -f conftest.$ac_objext conftest$ac_exeext
16173if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16174 (eval $ac_link) 2>&5
16175 ac_status=$?
16176 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16177 (exit $ac_status); } &&
16178 { ac_try='test -s conftest$ac_exeext'
16179 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16180 (eval $ac_try) 2>&5
16181 ac_status=$?
16182 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16183 (exit $ac_status); }; }; then
16184 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000016185else
Martin v. Löwis11437992002-04-12 09:54:03 +000016186 echo "$as_me: failed program was:" >&5
16187cat conftest.$ac_ext >&5
16188ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000016189fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016190rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16191LIBS=$ac_check_lib_save_LIBS
16192fi
16193echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
16194echo "${ECHO_T}$ac_cv_lib_readline_rl_pre_input_hook" >&6
16195if test $ac_cv_lib_readline_rl_pre_input_hook = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000016196
Martin v. Löwis11437992002-04-12 09:54:03 +000016197cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000016198#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016199_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000016200
Martin v. Löwis0daad592001-09-30 21:09:59 +000016201fi
16202
Michael W. Hudson54241132001-12-07 15:38:26 +000016203
Martin v. Löwis0daad592001-09-30 21:09:59 +000016204# check for readline 4.2
Martin v. Löwis11437992002-04-12 09:54:03 +000016205echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
16206echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6
16207if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
16208 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000016209else
Martin v. Löwis11437992002-04-12 09:54:03 +000016210 ac_check_lib_save_LIBS=$LIBS
Martin v. Löwis0daad592001-09-30 21:09:59 +000016211LIBS="-lreadline -ltermcap $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000016212cat >conftest.$ac_ext <<_ACEOF
16213#line $LINENO "configure"
Martin v. Löwis0daad592001-09-30 21:09:59 +000016214#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016215
Martin v. Löwis0daad592001-09-30 21:09:59 +000016216/* Override any gcc2 internal prototype to avoid an error. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016217#ifdef __cplusplus
16218extern "C"
16219#endif
Martin v. Löwis0daad592001-09-30 21:09:59 +000016220/* We use char because int might match the return type of a gcc2
Martin v. Löwis11437992002-04-12 09:54:03 +000016221 builtin and then its argument prototype would still apply. */
16222char rl_completion_matches ();
16223#ifdef F77_DUMMY_MAIN
16224# ifdef __cplusplus
16225 extern "C"
16226# endif
16227 int F77_DUMMY_MAIN() { return 1; }
16228#endif
16229int
16230main ()
16231{
16232rl_completion_matches ();
16233 ;
16234 return 0;
16235}
16236_ACEOF
16237rm -f conftest.$ac_objext conftest$ac_exeext
16238if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16239 (eval $ac_link) 2>&5
16240 ac_status=$?
16241 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16242 (exit $ac_status); } &&
16243 { ac_try='test -s conftest$ac_exeext'
16244 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16245 (eval $ac_try) 2>&5
16246 ac_status=$?
16247 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16248 (exit $ac_status); }; }; then
16249 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000016250else
Martin v. Löwis11437992002-04-12 09:54:03 +000016251 echo "$as_me: failed program was:" >&5
16252cat conftest.$ac_ext >&5
16253ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000016254fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016255rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
16256LIBS=$ac_check_lib_save_LIBS
16257fi
16258echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
16259echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6
16260if test $ac_cv_lib_readline_rl_completion_matches = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000016261
Martin v. Löwis11437992002-04-12 09:54:03 +000016262cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000016263#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016264_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000016265
Guido van Rossum353ae582001-07-10 16:45:32 +000016266fi
16267
Jack Jansendd19cf82001-12-06 22:36:17 +000016268
Martin v. Löwis11437992002-04-12 09:54:03 +000016269echo "$as_me:$LINENO: checking for broken nice()" >&5
16270echo $ECHO_N "checking for broken nice()... $ECHO_C" >&6
16271if test "${ac_cv_broken_nice+set}" = set; then
16272 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000016273else
Martin v. Löwis11437992002-04-12 09:54:03 +000016274
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016275if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000016276 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016277else
Martin v. Löwis11437992002-04-12 09:54:03 +000016278 cat >conftest.$ac_ext <<_ACEOF
16279#line $LINENO "configure"
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016280#include "confdefs.h"
16281
16282int main()
16283{
16284 int val1 = nice(1);
16285 if (val1 != -1 && val1 == nice(2))
16286 exit(0);
16287 exit(1);
16288}
16289
Martin v. Löwis11437992002-04-12 09:54:03 +000016290_ACEOF
16291rm -f conftest$ac_exeext
16292if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16293 (eval $ac_link) 2>&5
16294 ac_status=$?
16295 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16296 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16297 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16298 (eval $ac_try) 2>&5
16299 ac_status=$?
16300 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16301 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016302 ac_cv_broken_nice=yes
16303else
Martin v. Löwis11437992002-04-12 09:54:03 +000016304 echo "$as_me: program exited with status $ac_status" >&5
16305echo "$as_me: failed program was:" >&5
16306cat conftest.$ac_ext >&5
16307( exit $ac_status )
16308ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016309fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016310rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16311fi
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016312fi
16313
Martin v. Löwis11437992002-04-12 09:54:03 +000016314echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
16315echo "${ECHO_T}$ac_cv_broken_nice" >&6
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016316if test "$ac_cv_broken_nice" = yes
16317then
Martin v. Löwis11437992002-04-12 09:54:03 +000016318
16319cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016320#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016321_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000016322
16323fi
16324
Martin v. Löwis94717ed2002-09-09 14:24:16 +000016325# Look for subsecond timestamps in struct stat
16326echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
16327echo $ECHO_N "checking for tv_nsec in struct stat... $ECHO_C" >&6
16328if test "${ac_cv_stat_tv_nsec+set}" = set; then
16329 echo $ECHO_N "(cached) $ECHO_C" >&6
16330else
16331 cat >conftest.$ac_ext <<_ACEOF
16332#line $LINENO "configure"
16333#include "confdefs.h"
16334#include <sys/stat.h>
16335#ifdef F77_DUMMY_MAIN
16336# ifdef __cplusplus
16337 extern "C"
16338# endif
16339 int F77_DUMMY_MAIN() { return 1; }
16340#endif
16341int
16342main ()
16343{
16344
16345struct stat st;
16346st.st_mtim.tv_nsec = 1;
16347
16348 ;
16349 return 0;
16350}
16351_ACEOF
16352rm -f conftest.$ac_objext
16353if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16354 (eval $ac_compile) 2>&5
16355 ac_status=$?
16356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16357 (exit $ac_status); } &&
16358 { ac_try='test -s conftest.$ac_objext'
16359 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16360 (eval $ac_try) 2>&5
16361 ac_status=$?
16362 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16363 (exit $ac_status); }; }; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000016364 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000016365else
16366 echo "$as_me: failed program was:" >&5
16367cat conftest.$ac_ext >&5
16368ac_cv_stat_tv_nsec=no
16369fi
16370rm -f conftest.$ac_objext conftest.$ac_ext
16371fi
16372
16373echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
16374echo "${ECHO_T}$ac_cv_stat_tv_nsec" >&6
16375if test "$ac_cv_stat_tv_nsec" = yes
16376then
16377
16378cat >>confdefs.h <<\_ACEOF
16379#define HAVE_STAT_TV_NSEC 1
16380_ACEOF
16381
16382fi
16383
Jack Jansen666b1e72001-10-31 12:11:48 +000016384# On HP/UX 11.0, mvwdelch is a block with a return statement
Martin v. Löwis11437992002-04-12 09:54:03 +000016385echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
16386echo $ECHO_N "checking whether mvwdelch is an expression... $ECHO_C" >&6
16387if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
16388 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016389else
Martin v. Löwis11437992002-04-12 09:54:03 +000016390 cat >conftest.$ac_ext <<_ACEOF
16391#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000016392#include "confdefs.h"
16393#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016394#ifdef F77_DUMMY_MAIN
16395# ifdef __cplusplus
16396 extern "C"
16397# endif
16398 int F77_DUMMY_MAIN() { return 1; }
16399#endif
16400int
16401main ()
16402{
Jack Jansen666b1e72001-10-31 12:11:48 +000016403
16404 int rtn;
16405 rtn = mvwdelch(0,0,0);
16406
Martin v. Löwis11437992002-04-12 09:54:03 +000016407 ;
16408 return 0;
16409}
16410_ACEOF
16411rm -f conftest.$ac_objext
16412if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16413 (eval $ac_compile) 2>&5
16414 ac_status=$?
16415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16416 (exit $ac_status); } &&
16417 { ac_try='test -s conftest.$ac_objext'
16418 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16419 (eval $ac_try) 2>&5
16420 ac_status=$?
16421 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16422 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000016423 ac_cv_mvwdelch_is_expression=yes
16424else
Martin v. Löwis11437992002-04-12 09:54:03 +000016425 echo "$as_me: failed program was:" >&5
16426cat conftest.$ac_ext >&5
16427ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000016428fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016429rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000016430fi
16431
Martin v. Löwis11437992002-04-12 09:54:03 +000016432echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
16433echo "${ECHO_T}$ac_cv_mvwdelch_is_expression" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016434
16435if test "$ac_cv_mvwdelch_is_expression" = yes
16436then
Martin v. Löwis11437992002-04-12 09:54:03 +000016437
16438cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016439#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016440_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016441
16442fi
16443
Martin v. Löwis11437992002-04-12 09:54:03 +000016444echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
16445echo $ECHO_N "checking whether WINDOW has _flags... $ECHO_C" >&6
16446if test "${ac_cv_window_has_flags+set}" = set; then
16447 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000016448else
Martin v. Löwis11437992002-04-12 09:54:03 +000016449 cat >conftest.$ac_ext <<_ACEOF
16450#line $LINENO "configure"
Jack Jansen666b1e72001-10-31 12:11:48 +000016451#include "confdefs.h"
16452#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016453#ifdef F77_DUMMY_MAIN
16454# ifdef __cplusplus
16455 extern "C"
16456# endif
16457 int F77_DUMMY_MAIN() { return 1; }
16458#endif
16459int
16460main ()
16461{
Jack Jansen666b1e72001-10-31 12:11:48 +000016462
16463 WINDOW *w;
16464 w->_flags = 0;
16465
Martin v. Löwis11437992002-04-12 09:54:03 +000016466 ;
16467 return 0;
16468}
16469_ACEOF
16470rm -f conftest.$ac_objext
16471if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16472 (eval $ac_compile) 2>&5
16473 ac_status=$?
16474 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16475 (exit $ac_status); } &&
16476 { ac_try='test -s conftest.$ac_objext'
16477 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16478 (eval $ac_try) 2>&5
16479 ac_status=$?
16480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16481 (exit $ac_status); }; }; then
Jack Jansen666b1e72001-10-31 12:11:48 +000016482 ac_cv_window_has_flags=yes
16483else
Martin v. Löwis11437992002-04-12 09:54:03 +000016484 echo "$as_me: failed program was:" >&5
16485cat conftest.$ac_ext >&5
16486ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000016487fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016488rm -f conftest.$ac_objext conftest.$ac_ext
Jack Jansen666b1e72001-10-31 12:11:48 +000016489fi
16490
Martin v. Löwis11437992002-04-12 09:54:03 +000016491echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
16492echo "${ECHO_T}$ac_cv_window_has_flags" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000016493
Jack Jansen666b1e72001-10-31 12:11:48 +000016494
16495if test "$ac_cv_window_has_flags" = yes
16496then
Martin v. Löwis11437992002-04-12 09:54:03 +000016497
16498cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016499#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016500_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000016501
16502fi
16503
Guido van Rossum95713eb2000-05-18 20:53:31 +000016504# THIS MUST BE LAST, IT CAN BREAK OTHER TESTS!
16505# Add sys/socket.h to confdefs.h
16506cat >> confdefs.h <<\EOF
16507#ifdef HAVE_SYS_SOCKET_H
16508#include <sys/socket.h>
16509#endif
16510EOF
Martin v. Löwis11437992002-04-12 09:54:03 +000016511echo "$as_me:$LINENO: checking for socklen_t" >&5
16512echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6
16513if test "${ac_cv_type_socklen_t+set}" = set; then
16514 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000016515else
Martin v. Löwis11437992002-04-12 09:54:03 +000016516 cat >conftest.$ac_ext <<_ACEOF
16517#line $LINENO "configure"
Guido van Rossum95713eb2000-05-18 20:53:31 +000016518#include "confdefs.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000016519$ac_includes_default
16520#ifdef F77_DUMMY_MAIN
16521# ifdef __cplusplus
16522 extern "C"
16523# endif
16524 int F77_DUMMY_MAIN() { return 1; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016525#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016526int
16527main ()
16528{
16529if ((socklen_t *) 0)
16530 return 0;
16531if (sizeof (socklen_t))
16532 return 0;
16533 ;
16534 return 0;
16535}
16536_ACEOF
16537rm -f conftest.$ac_objext
16538if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16539 (eval $ac_compile) 2>&5
16540 ac_status=$?
16541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16542 (exit $ac_status); } &&
16543 { ac_try='test -s conftest.$ac_objext'
16544 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16545 (eval $ac_try) 2>&5
16546 ac_status=$?
16547 echo "$as_me:$LINENO: \$? = $ac_status" >&5
16548 (exit $ac_status); }; }; then
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000016549 ac_cv_type_socklen_t=yes
Guido van Rossum95713eb2000-05-18 20:53:31 +000016550else
Martin v. Löwis11437992002-04-12 09:54:03 +000016551 echo "$as_me: failed program was:" >&5
16552cat conftest.$ac_ext >&5
16553ac_cv_type_socklen_t=no
Guido van Rossum95713eb2000-05-18 20:53:31 +000016554fi
Martin v. Löwis11437992002-04-12 09:54:03 +000016555rm -f conftest.$ac_objext conftest.$ac_ext
16556fi
16557echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
16558echo "${ECHO_T}$ac_cv_type_socklen_t" >&6
16559if test $ac_cv_type_socklen_t = yes; then
16560 :
16561else
Guido van Rossum95713eb2000-05-18 20:53:31 +000016562
Martin v. Löwis11437992002-04-12 09:54:03 +000016563cat >>confdefs.h <<_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016564#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000016565_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000016566
16567fi
16568
Michael W. Hudson54241132001-12-07 15:38:26 +000016569
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016570#AC_MSG_CHECKING(for Modules/Setup)
16571#if test ! -f Modules/Setup ; then
16572# if test ! -d Modules ; then
16573# mkdir Modules
16574# fi
16575# cp "$srcdir/Modules/Setup.dist" Modules/Setup
16576# AC_MSG_RESULT(creating)
16577#else
16578# AC_MSG_RESULT(already exists)
16579#fi
16580
Michael W. Hudson54241132001-12-07 15:38:26 +000016581
16582
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000016583for h in `(cd $srcdir;echo Python/thread_*.h)`
16584do
16585 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
16586done
16587
Michael W. Hudson54241132001-12-07 15:38:26 +000016588
Jack Jansen0b06be72002-06-21 14:48:38 +000016589SRCDIRS="Parser Grammar Objects Python Modules Mac Mac/Python"
Martin v. Löwis11437992002-04-12 09:54:03 +000016590echo "$as_me:$LINENO: checking for build directories" >&5
16591echo $ECHO_N "checking for build directories... $ECHO_C" >&6
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016592for dir in $SRCDIRS; do
16593 if test ! -d $dir; then
16594 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000016595 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000016596done
Martin v. Löwis11437992002-04-12 09:54:03 +000016597echo "$as_me:$LINENO: result: done" >&5
16598echo "${ECHO_T}done" >&6
Fred Drake036144d2000-10-26 17:09:35 +000016599
Guido van Rossum627b2d71993-12-24 10:39:16 +000016600# generate output files
Martin v. Löwis11437992002-04-12 09:54:03 +000016601ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config"
Martin v. Löwis88afe662002-10-26 13:47:44 +000016602
Martin v. Löwis11437992002-04-12 09:54:03 +000016603cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016604# This file is a shell script that caches the results of configure
16605# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000016606# scripts and configure runs, see configure's option --config-cache.
16607# It is not useful on other systems. If it contains results you don't
16608# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016609#
Martin v. Löwis11437992002-04-12 09:54:03 +000016610# config.status only pays attention to the cache file if you give it
16611# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016612#
Martin v. Löwis11437992002-04-12 09:54:03 +000016613# `ac_cv_env_foo' variables (set or unset) will be overriden when
16614# loading this file, other *unset* `ac_cv_foo' will be assigned the
16615# following values.
16616
16617_ACEOF
16618
Guido van Rossumf78abae1997-01-21 22:02:36 +000016619# The following way of writing the cache mishandles newlines in values,
16620# but we know of no workaround that is simple, portable, and efficient.
16621# So, don't put newlines in cache variables' values.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016622# Ultrix sh set writes to stderr and can't be redirected directly,
16623# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwis11437992002-04-12 09:54:03 +000016624{
16625 (set) 2>&1 |
16626 case `(ac_space=' '; set | grep ac_space) 2>&1` in
16627 *ac_space=\ *)
16628 # `set' does not quote correctly, so add quotes (double-quote
16629 # substitution turns \\\\ into \\, and sed turns \\ into \).
16630 sed -n \
16631 "s/'/'\\\\''/g;
16632 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16633 ;;
16634 *)
16635 # `set' quotes correctly as required by POSIX, so do not add quotes.
16636 sed -n \
16637 "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
16638 ;;
16639 esac;
16640} |
16641 sed '
16642 t clear
16643 : clear
16644 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16645 t end
16646 /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16647 : end' >>confcache
16648if cmp -s $cache_file confcache; then :; else
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016649 if test -w $cache_file; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016650 test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
16651 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016652 else
16653 echo "not updating unwritable cache $cache_file"
16654 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016655fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016656rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000016657
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016658test "x$prefix" = xNONE && prefix=$ac_default_prefix
16659# Let make expand exec_prefix.
16660test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000016661
Martin v. Löwis11437992002-04-12 09:54:03 +000016662# VPATH may cause trouble with some makes, so we remove $(srcdir),
16663# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
16664# trailing colons and then remove the whole line if VPATH becomes empty
16665# (actually we leave an empty line to preserve line numbers).
Guido van Rossum7f43da71994-08-01 12:15:30 +000016666if test "x$srcdir" = x.; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016667 ac_vpsub='/^[ ]*VPATH[ ]*=/{
16668s/:*\$(srcdir):*/:/;
16669s/:*\${srcdir}:*/:/;
16670s/:*@srcdir@:*/:/;
16671s/^\([^=]*=[ ]*\):*/\1/;
16672s/:*$//;
16673s/^[^=]*=[ ]*$//;
16674}'
Guido van Rossum7f43da71994-08-01 12:15:30 +000016675fi
16676
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016677DEFS=-DHAVE_CONFIG_H
16678
Martin v. Löwis11437992002-04-12 09:54:03 +000016679
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016680: ${CONFIG_STATUS=./config.status}
Martin v. Löwis11437992002-04-12 09:54:03 +000016681ac_clean_files_save=$ac_clean_files
16682ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16683{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
16684echo "$as_me: creating $CONFIG_STATUS" >&6;}
16685cat >$CONFIG_STATUS <<_ACEOF
16686#! $SHELL
16687# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016688# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016689# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000016690# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000016691
Martin v. Löwis11437992002-04-12 09:54:03 +000016692debug=false
16693SHELL=\${CONFIG_SHELL-$SHELL}
16694_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016695
Martin v. Löwis11437992002-04-12 09:54:03 +000016696cat >>$CONFIG_STATUS <<\_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000016697
Martin v. Löwis11437992002-04-12 09:54:03 +000016698## --------------------- ##
16699## M4sh Initialization. ##
16700## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000016701
Martin v. Löwis11437992002-04-12 09:54:03 +000016702# Be Bourne compatible
16703if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16704 emulate sh
16705 NULLCMD=:
16706elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
16707 set -o posix
Michael W. Hudson54241132001-12-07 15:38:26 +000016708fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016709
Martin v. Löwis11437992002-04-12 09:54:03 +000016710# NLS nuisances.
16711# Support unset when possible.
16712if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
16713 as_unset=unset
16714else
16715 as_unset=false
16716fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016717
Martin v. Löwis11437992002-04-12 09:54:03 +000016718(set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
16719 { $as_unset LANG || test "${LANG+set}" != set; } ||
16720 { LANG=C; export LANG; }
16721(set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
16722 { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
16723 { LC_ALL=C; export LC_ALL; }
16724(set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
16725 { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
16726 { LC_TIME=C; export LC_TIME; }
16727(set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
16728 { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
16729 { LC_CTYPE=C; export LC_CTYPE; }
16730(set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
16731 { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
16732 { LANGUAGE=C; export LANGUAGE; }
16733(set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
16734 { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
16735 { LC_COLLATE=C; export LC_COLLATE; }
16736(set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
16737 { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
16738 { LC_NUMERIC=C; export LC_NUMERIC; }
16739(set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
16740 { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
16741 { LC_MESSAGES=C; export LC_MESSAGES; }
16742
16743
16744# Name of the executable.
16745as_me=`(basename "$0") 2>/dev/null ||
16746$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16747 X"$0" : 'X\(//\)$' \| \
16748 X"$0" : 'X\(/\)$' \| \
16749 . : '\(.\)' 2>/dev/null ||
16750echo X/"$0" |
16751 sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
16752 /^X\/\(\/\/\)$/{ s//\1/; q; }
16753 /^X\/\(\/\).*/{ s//\1/; q; }
16754 s/.*/./; q'`
16755
16756# PATH needs CR, and LINENO needs CR and PATH.
16757# Avoid depending upon Character Ranges.
16758as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16759as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16760as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16761as_cr_digits='0123456789'
16762as_cr_alnum=$as_cr_Letters$as_cr_digits
16763
16764# The user is always right.
16765if test "${PATH_SEPARATOR+set}" != set; then
16766 echo "#! /bin/sh" >conftest.sh
16767 echo "exit 0" >>conftest.sh
16768 chmod +x conftest.sh
16769 if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
16770 PATH_SEPARATOR=';'
16771 else
16772 PATH_SEPARATOR=:
16773 fi
16774 rm -f conftest.sh
16775fi
16776
16777
16778 as_lineno_1=$LINENO
16779 as_lineno_2=$LINENO
16780 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16781 test "x$as_lineno_1" != "x$as_lineno_2" &&
16782 test "x$as_lineno_3" = "x$as_lineno_2" || {
16783 # Find who we are. Look in the path if we contain no path at all
16784 # relative or not.
16785 case $0 in
16786 *[\\/]* ) as_myself=$0 ;;
16787 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16788for as_dir in $PATH
16789do
16790 IFS=$as_save_IFS
16791 test -z "$as_dir" && as_dir=.
16792 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16793done
16794
16795 ;;
16796 esac
16797 # We did not find ourselves, most probably we were run as `sh COMMAND'
16798 # in which case we are not to be found in the path.
16799 if test "x$as_myself" = x; then
16800 as_myself=$0
16801 fi
16802 if test ! -f "$as_myself"; then
16803 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
16804echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
16805 { (exit 1); exit 1; }; }
16806 fi
16807 case $CONFIG_SHELL in
16808 '')
16809 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16810for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
16811do
16812 IFS=$as_save_IFS
16813 test -z "$as_dir" && as_dir=.
16814 for as_base in sh bash ksh sh5; do
16815 case $as_dir in
16816 /*)
16817 if ("$as_dir/$as_base" -c '
16818 as_lineno_1=$LINENO
16819 as_lineno_2=$LINENO
16820 as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
16821 test "x$as_lineno_1" != "x$as_lineno_2" &&
16822 test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
16823 CONFIG_SHELL=$as_dir/$as_base
16824 export CONFIG_SHELL
16825 exec "$CONFIG_SHELL" "$0" ${1+"$@"}
16826 fi;;
16827 esac
16828 done
16829done
16830;;
Jack Jansendd19cf82001-12-06 22:36:17 +000016831 esac
16832
Martin v. Löwis11437992002-04-12 09:54:03 +000016833 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
16834 # uniformly replaced by the line number. The first 'sed' inserts a
16835 # line-number line before each line; the second 'sed' does the real
16836 # work. The second script uses 'N' to pair each line-number line
16837 # with the numbered line, and appends trailing '-' during
16838 # substitution so that $LINENO is not a special case at line end.
16839 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
16840 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
16841 sed '=' <$as_myself |
16842 sed '
16843 N
16844 s,$,-,
16845 : loop
16846 s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
16847 t loop
16848 s,-$,,
16849 s,^['$as_cr_digits']*\n,,
16850 ' >$as_me.lineno &&
16851 chmod +x $as_me.lineno ||
16852 { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
16853echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
16854 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000016855
Martin v. Löwis11437992002-04-12 09:54:03 +000016856 # Don't try to exec as it changes $[0], causing all sort of problems
16857 # (the dirname of $[0] is not the place where we might find the
16858 # original and so on. Autoconf is especially sensible to this).
16859 . ./$as_me.lineno
16860 # Exit status is that of the last command.
16861 exit
16862}
16863
16864
16865case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
16866 *c*,-n*) ECHO_N= ECHO_C='
16867' ECHO_T=' ' ;;
16868 *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
16869 *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
16870esac
16871
16872if expr a : '\(a\)' >/dev/null 2>&1; then
16873 as_expr=expr
16874else
16875 as_expr=false
16876fi
16877
16878rm -f conf$$ conf$$.exe conf$$.file
16879echo >conf$$.file
16880if ln -s conf$$.file conf$$ 2>/dev/null; then
16881 # We could just check for DJGPP; but this test a) works b) is more generic
16882 # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
16883 if test -f conf$$.exe; then
16884 # Don't use ln at all; we don't have any links
16885 as_ln_s='cp -p'
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016886 else
Martin v. Löwis11437992002-04-12 09:54:03 +000016887 as_ln_s='ln -s'
16888 fi
16889elif ln conf$$.file conf$$ 2>/dev/null; then
16890 as_ln_s=ln
16891else
16892 as_ln_s='cp -p'
16893fi
16894rm -f conf$$ conf$$.exe conf$$.file
16895
16896as_executable_p="test -f"
16897
16898# Sed expression to map a string onto a valid CPP name.
16899as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
16900
16901# Sed expression to map a string onto a valid variable name.
16902as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
16903
16904
16905# IFS
16906# We need space, tab and new line, in precisely that order.
16907as_nl='
16908'
16909IFS=" $as_nl"
16910
16911# CDPATH.
16912$as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
16913
16914exec 6>&1
16915
16916# Open the log real soon, to keep \$[0] and so on meaningful, and to
16917# report actual input values of CONFIG_FILES etc. instead of their
16918# values after options handling. Logging --version etc. is OK.
16919exec 5>>config.log
16920{
16921 echo
16922 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16923## Running $as_me. ##
16924_ASBOX
16925} >&5
16926cat >&5 <<_CSEOF
16927
Martin v. Löwis88afe662002-10-26 13:47:44 +000016928This file was extended by python $as_me 2.3, which was
Martin v. Löwis11437992002-04-12 09:54:03 +000016929generated by GNU Autoconf 2.53. Invocation command line was
16930
16931 CONFIG_FILES = $CONFIG_FILES
16932 CONFIG_HEADERS = $CONFIG_HEADERS
16933 CONFIG_LINKS = $CONFIG_LINKS
16934 CONFIG_COMMANDS = $CONFIG_COMMANDS
16935 $ $0 $@
16936
16937_CSEOF
16938echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
16939echo >&5
16940_ACEOF
16941
16942# Files that config.status was made for.
16943if test -n "$ac_config_files"; then
16944 echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
16945fi
16946
16947if test -n "$ac_config_headers"; then
16948 echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
16949fi
16950
16951if test -n "$ac_config_links"; then
16952 echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
16953fi
16954
16955if test -n "$ac_config_commands"; then
16956 echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
16957fi
16958
16959cat >>$CONFIG_STATUS <<\_ACEOF
16960
16961ac_cs_usage="\
16962\`$as_me' instantiates files from templates according to the
16963current configuration.
16964
16965Usage: $0 [OPTIONS] [FILE]...
16966
16967 -h, --help print this help, then exit
16968 -V, --version print version number, then exit
16969 -d, --debug don't remove temporary files
16970 --recheck update $as_me by reconfiguring in the same conditions
16971 --file=FILE[:TEMPLATE]
16972 instantiate the configuration file FILE
16973 --header=FILE[:TEMPLATE]
16974 instantiate the configuration header FILE
16975
16976Configuration files:
16977$config_files
16978
16979Configuration headers:
16980$config_headers
16981
16982Report bugs to <bug-autoconf@gnu.org>."
16983_ACEOF
16984
16985cat >>$CONFIG_STATUS <<_ACEOF
16986ac_cs_version="\\
Martin v. Löwis88afe662002-10-26 13:47:44 +000016987python config.status 2.3
Martin v. Löwis11437992002-04-12 09:54:03 +000016988configured by $0, generated by GNU Autoconf 2.53,
16989 with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
16990
16991Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
16992Free Software Foundation, Inc.
16993This config.status script is free software; the Free Software Foundation
16994gives unlimited permission to copy, distribute and modify it."
16995srcdir=$srcdir
16996INSTALL="$INSTALL"
16997_ACEOF
16998
16999cat >>$CONFIG_STATUS <<\_ACEOF
17000# If no file are specified by the user, then we need to provide default
17001# value. By we need to know if files were specified by the user.
17002ac_need_defaults=:
17003while test $# != 0
17004do
17005 case $1 in
17006 --*=*)
17007 ac_option=`expr "x$1" : 'x\([^=]*\)='`
17008 ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
17009 shift
17010 set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
17011 shift
17012 ;;
17013 -*);;
17014 *) # This is not an option, so the user has probably given explicit
17015 # arguments.
17016 ac_need_defaults=false;;
17017 esac
17018
17019 case $1 in
17020 # Handling of the options.
17021_ACEOF
17022cat >>$CONFIG_STATUS <<_ACEOF
17023 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
17024 echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
17025 exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
17026_ACEOF
17027cat >>$CONFIG_STATUS <<\_ACEOF
17028 --version | --vers* | -V )
17029 echo "$ac_cs_version"; exit 0 ;;
17030 --he | --h)
17031 # Conflict between --help and --header
17032 { { echo "$as_me:$LINENO: error: ambiguous option: $1
17033Try \`$0 --help' for more information." >&5
17034echo "$as_me: error: ambiguous option: $1
17035Try \`$0 --help' for more information." >&2;}
17036 { (exit 1); exit 1; }; };;
17037 --help | --hel | -h )
17038 echo "$ac_cs_usage"; exit 0 ;;
17039 --debug | --d* | -d )
17040 debug=: ;;
17041 --file | --fil | --fi | --f )
17042 shift
17043 CONFIG_FILES="$CONFIG_FILES $1"
17044 ac_need_defaults=false;;
17045 --header | --heade | --head | --hea )
17046 shift
17047 CONFIG_HEADERS="$CONFIG_HEADERS $1"
17048 ac_need_defaults=false;;
17049
17050 # This is an error.
17051 -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
17052Try \`$0 --help' for more information." >&5
17053echo "$as_me: error: unrecognized option: $1
17054Try \`$0 --help' for more information." >&2;}
17055 { (exit 1); exit 1; }; } ;;
17056
17057 *) ac_config_targets="$ac_config_targets $1" ;;
17058
17059 esac
17060 shift
17061done
17062
17063_ACEOF
17064
17065
17066
17067
17068
17069cat >>$CONFIG_STATUS <<\_ACEOF
17070for ac_config_target in $ac_config_targets
17071do
17072 case "$ac_config_target" in
17073 # Handling of arguments.
17074 "Makefile.pre" ) CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
17075 "Modules/Setup.config" ) CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
17076 "pyconfig.h" ) CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
17077 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
17078echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
17079 { (exit 1); exit 1; }; };;
17080 esac
17081done
17082
17083# If the user did not use the arguments to specify the items to instantiate,
17084# then the envvar interface is used. Set only those that are not.
17085# We use the long form for the default assignment because of an extremely
17086# bizarre bug on SunOS 4.1.3.
17087if $ac_need_defaults; then
17088 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
17089 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
17090fi
17091
17092# Create a temporary directory, and hook for its removal unless debugging.
17093$debug ||
17094{
17095 trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
17096 trap '{ (exit 1); exit 1; }' 1 2 13 15
17097}
17098
17099# Create a (secure) tmp directory for tmp files.
17100: ${TMPDIR=/tmp}
17101{
17102 tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
17103 test -n "$tmp" && test -d "$tmp"
17104} ||
17105{
17106 tmp=$TMPDIR/cs$$-$RANDOM
17107 (umask 077 && mkdir $tmp)
17108} ||
17109{
17110 echo "$me: cannot create a temporary directory in $TMPDIR" >&2
17111 { (exit 1); exit 1; }
17112}
17113
17114_ACEOF
17115
17116cat >>$CONFIG_STATUS <<_ACEOF
17117
17118#
17119# CONFIG_FILES section.
17120#
17121
17122# No need to generate the scripts if there are no CONFIG_FILES.
17123# This happens for instance when ./config.status config.h
17124if test -n "\$CONFIG_FILES"; then
17125 # Protect against being on the right side of a sed subst in config.status.
17126 sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
17127 s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
17128s,@SHELL@,$SHELL,;t t
17129s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
17130s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
17131s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
17132s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
17133s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
17134s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
17135s,@exec_prefix@,$exec_prefix,;t t
17136s,@prefix@,$prefix,;t t
17137s,@program_transform_name@,$program_transform_name,;t t
17138s,@bindir@,$bindir,;t t
17139s,@sbindir@,$sbindir,;t t
17140s,@libexecdir@,$libexecdir,;t t
17141s,@datadir@,$datadir,;t t
17142s,@sysconfdir@,$sysconfdir,;t t
17143s,@sharedstatedir@,$sharedstatedir,;t t
17144s,@localstatedir@,$localstatedir,;t t
17145s,@libdir@,$libdir,;t t
17146s,@includedir@,$includedir,;t t
17147s,@oldincludedir@,$oldincludedir,;t t
17148s,@infodir@,$infodir,;t t
17149s,@mandir@,$mandir,;t t
17150s,@build_alias@,$build_alias,;t t
17151s,@host_alias@,$host_alias,;t t
17152s,@target_alias@,$target_alias,;t t
17153s,@DEFS@,$DEFS,;t t
17154s,@ECHO_C@,$ECHO_C,;t t
17155s,@ECHO_N@,$ECHO_N,;t t
17156s,@ECHO_T@,$ECHO_T,;t t
17157s,@LIBS@,$LIBS,;t t
17158s,@VERSION@,$VERSION,;t t
17159s,@SOVERSION@,$SOVERSION,;t t
17160s,@CONFIG_ARGS@,$CONFIG_ARGS,;t t
17161s,@PYTHONFRAMEWORK@,$PYTHONFRAMEWORK,;t t
17162s,@PYTHONFRAMEWORKDIR@,$PYTHONFRAMEWORKDIR,;t t
17163s,@PYTHONFRAMEWORKPREFIX@,$PYTHONFRAMEWORKPREFIX,;t t
17164s,@PYTHONFRAMEWORKINSTALLDIR@,$PYTHONFRAMEWORKINSTALLDIR,;t t
17165s,@MACHDEP@,$MACHDEP,;t t
17166s,@SGI_ABI@,$SGI_ABI,;t t
17167s,@CXX@,$CXX,;t t
17168s,@MAINOBJ@,$MAINOBJ,;t t
17169s,@EXEEXT@,$EXEEXT,;t t
17170s,@CC@,$CC,;t t
17171s,@CFLAGS@,$CFLAGS,;t t
17172s,@LDFLAGS@,$LDFLAGS,;t t
17173s,@CPPFLAGS@,$CPPFLAGS,;t t
17174s,@ac_ct_CC@,$ac_ct_CC,;t t
17175s,@OBJEXT@,$OBJEXT,;t t
17176s,@CPP@,$CPP,;t t
17177s,@BUILDEXEEXT@,$BUILDEXEEXT,;t t
17178s,@LIBRARY@,$LIBRARY,;t t
17179s,@LDLIBRARY@,$LDLIBRARY,;t t
17180s,@DLLLIBRARY@,$DLLLIBRARY,;t t
17181s,@BLDLIBRARY@,$BLDLIBRARY,;t t
17182s,@LDLIBRARYDIR@,$LDLIBRARYDIR,;t t
17183s,@INSTSONAME@,$INSTSONAME,;t t
17184s,@RUNSHARED@,$RUNSHARED,;t t
17185s,@LINKCC@,$LINKCC,;t t
17186s,@RANLIB@,$RANLIB,;t t
17187s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
17188s,@AR@,$AR,;t t
17189s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
17190s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
17191s,@INSTALL_DATA@,$INSTALL_DATA,;t t
17192s,@LN@,$LN,;t t
17193s,@OPT@,$OPT,;t t
17194s,@LIBTOOL_CRUFT@,$LIBTOOL_CRUFT,;t t
17195s,@SO@,$SO,;t t
17196s,@LDSHARED@,$LDSHARED,;t t
17197s,@BLDSHARED@,$BLDSHARED,;t t
17198s,@CCSHARED@,$CCSHARED,;t t
17199s,@LINKFORSHARED@,$LINKFORSHARED,;t t
17200s,@CFLAGSFORSHARED@,$CFLAGSFORSHARED,;t t
Martin v. Löwisf90ae202002-06-11 06:22:31 +000017201s,@SHLIBS@,$SHLIBS,;t t
Martin v. Löwis11437992002-04-12 09:54:03 +000017202s,@USE_SIGNAL_MODULE@,$USE_SIGNAL_MODULE,;t t
17203s,@SIGNAL_OBJS@,$SIGNAL_OBJS,;t t
17204s,@USE_THREAD_MODULE@,$USE_THREAD_MODULE,;t t
17205s,@LDLAST@,$LDLAST,;t t
17206s,@THREADOBJ@,$THREADOBJ,;t t
17207s,@DLINCLDIR@,$DLINCLDIR,;t t
17208s,@DYNLOADFILE@,$DYNLOADFILE,;t t
17209s,@MACHDEP_OBJS@,$MACHDEP_OBJS,;t t
17210s,@LIBOBJS@,$LIBOBJS,;t t
17211s,@HAVE_GETHOSTBYNAME_R_6_ARG@,$HAVE_GETHOSTBYNAME_R_6_ARG,;t t
17212s,@HAVE_GETHOSTBYNAME_R_5_ARG@,$HAVE_GETHOSTBYNAME_R_5_ARG,;t t
17213s,@HAVE_GETHOSTBYNAME_R_3_ARG@,$HAVE_GETHOSTBYNAME_R_3_ARG,;t t
17214s,@HAVE_GETHOSTBYNAME_R@,$HAVE_GETHOSTBYNAME_R,;t t
17215s,@HAVE_GETHOSTBYNAME@,$HAVE_GETHOSTBYNAME,;t t
17216s,@LIBM@,$LIBM,;t t
17217s,@LIBC@,$LIBC,;t t
17218s,@UNICODE_OBJS@,$UNICODE_OBJS,;t t
17219s,@THREADHEADERS@,$THREADHEADERS,;t t
17220s,@SRCDIRS@,$SRCDIRS,;t t
17221CEOF
17222
17223_ACEOF
17224
17225 cat >>$CONFIG_STATUS <<\_ACEOF
17226 # Split the substitutions into bite-sized pieces for seds with
17227 # small command number limits, like on Digital OSF/1 and HP-UX.
17228 ac_max_sed_lines=48
17229 ac_sed_frag=1 # Number of current file.
17230 ac_beg=1 # First line for current file.
17231 ac_end=$ac_max_sed_lines # Line after last line for current file.
17232 ac_more_lines=:
17233 ac_sed_cmds=
17234 while $ac_more_lines; do
17235 if test $ac_beg -gt 1; then
17236 sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17237 else
17238 sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
17239 fi
17240 if test ! -s $tmp/subs.frag; then
17241 ac_more_lines=false
17242 else
17243 # The purpose of the label and of the branching condition is to
17244 # speed up the sed processing (if there are no `@' at all, there
17245 # is no need to browse any of the substitutions).
17246 # These are the two extra sed commands mentioned above.
17247 (echo ':t
17248 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
17249 if test -z "$ac_sed_cmds"; then
17250 ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
17251 else
17252 ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
17253 fi
17254 ac_sed_frag=`expr $ac_sed_frag + 1`
17255 ac_beg=$ac_end
17256 ac_end=`expr $ac_end + $ac_max_sed_lines`
17257 fi
17258 done
17259 if test -z "$ac_sed_cmds"; then
17260 ac_sed_cmds=cat
17261 fi
17262fi # test -n "$CONFIG_FILES"
17263
17264_ACEOF
17265cat >>$CONFIG_STATUS <<\_ACEOF
17266for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
17267 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
17268 case $ac_file in
17269 - | *:- | *:-:* ) # input from stdin
17270 cat >$tmp/stdin
17271 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17272 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17273 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17274 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17275 * ) ac_file_in=$ac_file.in ;;
17276 esac
17277
17278 # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
17279 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17280$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17281 X"$ac_file" : 'X\(//\)[^/]' \| \
17282 X"$ac_file" : 'X\(//\)$' \| \
17283 X"$ac_file" : 'X\(/\)' \| \
17284 . : '\(.\)' 2>/dev/null ||
17285echo X"$ac_file" |
17286 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17287 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17288 /^X\(\/\/\)$/{ s//\1/; q; }
17289 /^X\(\/\).*/{ s//\1/; q; }
17290 s/.*/./; q'`
17291 { case "$ac_dir" in
17292 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17293 *) as_incr_dir=.;;
17294esac
17295as_dummy="$ac_dir"
17296for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17297 case $as_mkdir_dir in
17298 # Skip DOS drivespec
17299 ?:) as_incr_dir=$as_mkdir_dir ;;
17300 *)
17301 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17302 test -d "$as_incr_dir" ||
17303 mkdir "$as_incr_dir" ||
17304 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17305echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17306 { (exit 1); exit 1; }; }
17307 ;;
17308 esac
17309done; }
17310
17311 ac_builddir=.
17312
17313if test "$ac_dir" != .; then
17314 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
17315 # A "../" for each directory in $ac_dir_suffix.
17316 ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
17317else
17318 ac_dir_suffix= ac_top_builddir=
17319fi
17320
17321case $srcdir in
17322 .) # No --srcdir option. We are building in place.
17323 ac_srcdir=.
17324 if test -z "$ac_top_builddir"; then
17325 ac_top_srcdir=.
17326 else
17327 ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
17328 fi ;;
17329 [\\/]* | ?:[\\/]* ) # Absolute path.
17330 ac_srcdir=$srcdir$ac_dir_suffix;
17331 ac_top_srcdir=$srcdir ;;
17332 *) # Relative path.
17333 ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
17334 ac_top_srcdir=$ac_top_builddir$srcdir ;;
17335esac
17336# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
17337# absolute.
17338ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
Martin v. Löwise3271202002-11-07 07:42:30 +000017339ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
Martin v. Löwis11437992002-04-12 09:54:03 +000017340ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
17341ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
17342
17343
17344 case $INSTALL in
17345 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17346 *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
17347 esac
17348
17349 if test x"$ac_file" != x-; then
17350 { echo "$as_me:$LINENO: creating $ac_file" >&5
17351echo "$as_me: creating $ac_file" >&6;}
17352 rm -f "$ac_file"
17353 fi
17354 # Let's still pretend it is `configure' which instantiates (i.e., don't
17355 # use $as_me), people would be surprised to read:
17356 # /* config.h. Generated by config.status. */
17357 if test x"$ac_file" = x-; then
17358 configure_input=
17359 else
17360 configure_input="$ac_file. "
17361 fi
17362 configure_input=$configure_input"Generated from `echo $ac_file_in |
17363 sed 's,.*/,,'` by configure."
17364
17365 # First look for the input files in the build tree, otherwise in the
17366 # src tree.
17367 ac_file_inputs=`IFS=:
17368 for f in $ac_file_in; do
17369 case $f in
17370 -) echo $tmp/stdin ;;
17371 [\\/$]*)
17372 # Absolute (can't be DOS-style, as IFS=:)
17373 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17374echo "$as_me: error: cannot find input file: $f" >&2;}
17375 { (exit 1); exit 1; }; }
17376 echo $f;;
17377 *) # Relative
17378 if test -f "$f"; then
17379 # Build tree
17380 echo $f
17381 elif test -f "$srcdir/$f"; then
17382 # Source tree
17383 echo $srcdir/$f
17384 else
17385 # /dev/null tree
17386 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17387echo "$as_me: error: cannot find input file: $f" >&2;}
17388 { (exit 1); exit 1; }; }
17389 fi;;
17390 esac
17391 done` || { (exit 1); exit 1; }
17392_ACEOF
17393cat >>$CONFIG_STATUS <<_ACEOF
17394 sed "$ac_vpsub
17395$extrasub
17396_ACEOF
17397cat >>$CONFIG_STATUS <<\_ACEOF
17398:t
17399/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17400s,@configure_input@,$configure_input,;t t
17401s,@srcdir@,$ac_srcdir,;t t
17402s,@abs_srcdir@,$ac_abs_srcdir,;t t
17403s,@top_srcdir@,$ac_top_srcdir,;t t
17404s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
17405s,@builddir@,$ac_builddir,;t t
17406s,@abs_builddir@,$ac_abs_builddir,;t t
17407s,@top_builddir@,$ac_top_builddir,;t t
17408s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
17409s,@INSTALL@,$ac_INSTALL,;t t
17410" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
17411 rm -f $tmp/stdin
17412 if test x"$ac_file" != x-; then
17413 mv $tmp/out $ac_file
17414 else
17415 cat $tmp/out
17416 rm -f $tmp/out
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017417 fi
17418
Martin v. Löwis11437992002-04-12 09:54:03 +000017419done
17420_ACEOF
17421cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017422
Martin v. Löwis11437992002-04-12 09:54:03 +000017423#
17424# CONFIG_HEADER section.
17425#
Guido van Rossum627b2d71993-12-24 10:39:16 +000017426
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017427# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
17428# NAME is the cpp macro being defined and VALUE is the value it is being given.
Guido van Rossum7f43da71994-08-01 12:15:30 +000017429#
17430# ac_d sets the value in "#define NAME VALUE" lines.
Martin v. Löwis11437992002-04-12 09:54:03 +000017431ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
17432ac_dB='[ ].*$,\1#\2'
17433ac_dC=' '
17434ac_dD=',;t'
17435# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
17436ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
17437ac_uB='$,\1#\2define\3'
Guido van Rossum7f43da71994-08-01 12:15:30 +000017438ac_uC=' '
Martin v. Löwis11437992002-04-12 09:54:03 +000017439ac_uD=',;t'
Guido van Rossum7f43da71994-08-01 12:15:30 +000017440
Martin v. Löwis11437992002-04-12 09:54:03 +000017441for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
Guido van Rossumf78abae1997-01-21 22:02:36 +000017442 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
Martin v. Löwis11437992002-04-12 09:54:03 +000017443 case $ac_file in
17444 - | *:- | *:-:* ) # input from stdin
17445 cat >$tmp/stdin
17446 ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17447 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17448 *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
17449 ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
17450 * ) ac_file_in=$ac_file.in ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017451 esac
17452
Martin v. Löwis11437992002-04-12 09:54:03 +000017453 test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
17454echo "$as_me: creating $ac_file" >&6;}
Guido van Rossum7f43da71994-08-01 12:15:30 +000017455
Martin v. Löwis11437992002-04-12 09:54:03 +000017456 # First look for the input files in the build tree, otherwise in the
17457 # src tree.
17458 ac_file_inputs=`IFS=:
17459 for f in $ac_file_in; do
17460 case $f in
17461 -) echo $tmp/stdin ;;
17462 [\\/$]*)
17463 # Absolute (can't be DOS-style, as IFS=:)
17464 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17465echo "$as_me: error: cannot find input file: $f" >&2;}
17466 { (exit 1); exit 1; }; }
17467 echo $f;;
17468 *) # Relative
17469 if test -f "$f"; then
17470 # Build tree
17471 echo $f
17472 elif test -f "$srcdir/$f"; then
17473 # Source tree
17474 echo $srcdir/$f
17475 else
17476 # /dev/null tree
17477 { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
17478echo "$as_me: error: cannot find input file: $f" >&2;}
17479 { (exit 1); exit 1; }; }
17480 fi;;
17481 esac
17482 done` || { (exit 1); exit 1; }
17483 # Remove the trailing spaces.
17484 sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017485
Martin v. Löwis11437992002-04-12 09:54:03 +000017486_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017487
Martin v. Löwis11437992002-04-12 09:54:03 +000017488# Transform confdefs.h into two sed scripts, `conftest.defines' and
17489# `conftest.undefs', that substitutes the proper values into
17490# config.h.in to produce config.h. The first handles `#define'
17491# templates, and the second `#undef' templates.
17492# And first: Protect against being on the right side of a sed subst in
17493# config.status. Protect against being in an unquoted here document
17494# in config.status.
17495rm -f conftest.defines conftest.undefs
17496# Using a here document instead of a string reduces the quoting nightmare.
17497# Putting comments in sed scripts is not portable.
17498#
17499# `end' is used to avoid that the second main sed command (meant for
17500# 0-ary CPP macros) applies to n-ary macro definitions.
17501# See the Autoconf documentation for `clear'.
17502cat >confdef2sed.sed <<\_ACEOF
17503s/[\\&,]/\\&/g
17504s,[\\$`],\\&,g
17505t clear
17506: clear
17507s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
17508t end
17509s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
17510: end
17511_ACEOF
17512# If some macros were called several times there might be several times
17513# the same #defines, which is useless. Nevertheless, we may not want to
17514# sort them, since we want the *last* AC-DEFINE to be honored.
17515uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
17516sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
17517rm -f confdef2sed.sed
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017518
17519# This sed command replaces #undef with comments. This is necessary, for
17520# example, in the case of _POSIX_SOURCE, which is predefined and required
17521# on some systems where configure will not decide to define it.
Martin v. Löwis11437992002-04-12 09:54:03 +000017522cat >>conftest.undefs <<\_ACEOF
17523s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
17524_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017525
Martin v. Löwis11437992002-04-12 09:54:03 +000017526# Break up conftest.defines because some shells have a limit on the size
17527# of here documents, and old seds have small limits too (100 cmds).
17528echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
17529echo ' if egrep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
17530echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
17531echo ' :' >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017532rm -f conftest.tail
Martin v. Löwis11437992002-04-12 09:54:03 +000017533while grep . conftest.defines >/dev/null
Jack Jansendd19cf82001-12-06 22:36:17 +000017534do
Martin v. Löwis11437992002-04-12 09:54:03 +000017535 # Write a limited-size here document to $tmp/defines.sed.
17536 echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
17537 # Speed up: don't consider the non `#define' lines.
17538 echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
17539 # Work around the forget-to-reset-the-flag bug.
17540 echo 't clr' >>$CONFIG_STATUS
17541 echo ': clr' >>$CONFIG_STATUS
17542 sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017543 echo 'CEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000017544 sed -f $tmp/defines.sed $tmp/in >$tmp/out
17545 rm -f $tmp/in
17546 mv $tmp/out $tmp/in
17547' >>$CONFIG_STATUS
17548 sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
17549 rm -f conftest.defines
17550 mv conftest.tail conftest.defines
Jack Jansendd19cf82001-12-06 22:36:17 +000017551done
Martin v. Löwis11437992002-04-12 09:54:03 +000017552rm -f conftest.defines
17553echo ' fi # egrep' >>$CONFIG_STATUS
17554echo >>$CONFIG_STATUS
Jack Jansendd19cf82001-12-06 22:36:17 +000017555
Martin v. Löwis11437992002-04-12 09:54:03 +000017556# Break up conftest.undefs because some shells have a limit on the size
17557# of here documents, and old seds have small limits too (100 cmds).
17558echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
17559rm -f conftest.tail
17560while grep . conftest.undefs >/dev/null
17561do
17562 # Write a limited-size here document to $tmp/undefs.sed.
17563 echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
17564 # Speed up: don't consider the non `#undef'
17565 echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
17566 # Work around the forget-to-reset-the-flag bug.
17567 echo 't clr' >>$CONFIG_STATUS
17568 echo ': clr' >>$CONFIG_STATUS
17569 sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
17570 echo 'CEOF
17571 sed -f $tmp/undefs.sed $tmp/in >$tmp/out
17572 rm -f $tmp/in
17573 mv $tmp/out $tmp/in
17574' >>$CONFIG_STATUS
17575 sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
17576 rm -f conftest.undefs
17577 mv conftest.tail conftest.undefs
17578done
17579rm -f conftest.undefs
17580
17581cat >>$CONFIG_STATUS <<\_ACEOF
17582 # Let's still pretend it is `configure' which instantiates (i.e., don't
17583 # use $as_me), people would be surprised to read:
17584 # /* config.h. Generated by config.status. */
17585 if test x"$ac_file" = x-; then
17586 echo "/* Generated by configure. */" >$tmp/config.h
Guido van Rossum7f43da71994-08-01 12:15:30 +000017587 else
Martin v. Löwis11437992002-04-12 09:54:03 +000017588 echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
Jack Jansendd19cf82001-12-06 22:36:17 +000017589 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000017590 cat $tmp/in >>$tmp/config.h
17591 rm -f $tmp/in
17592 if test x"$ac_file" != x-; then
17593 if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
17594 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
17595echo "$as_me: $ac_file is unchanged" >&6;}
17596 else
17597 ac_dir=`(dirname "$ac_file") 2>/dev/null ||
17598$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17599 X"$ac_file" : 'X\(//\)[^/]' \| \
17600 X"$ac_file" : 'X\(//\)$' \| \
17601 X"$ac_file" : 'X\(/\)' \| \
17602 . : '\(.\)' 2>/dev/null ||
17603echo X"$ac_file" |
17604 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
17605 /^X\(\/\/\)[^/].*/{ s//\1/; q; }
17606 /^X\(\/\/\)$/{ s//\1/; q; }
17607 /^X\(\/\).*/{ s//\1/; q; }
17608 s/.*/./; q'`
17609 { case "$ac_dir" in
17610 [\\/]* | ?:[\\/]* ) as_incr_dir=;;
17611 *) as_incr_dir=.;;
17612esac
17613as_dummy="$ac_dir"
17614for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
17615 case $as_mkdir_dir in
17616 # Skip DOS drivespec
17617 ?:) as_incr_dir=$as_mkdir_dir ;;
17618 *)
17619 as_incr_dir=$as_incr_dir/$as_mkdir_dir
17620 test -d "$as_incr_dir" ||
17621 mkdir "$as_incr_dir" ||
17622 { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
17623echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
17624 { (exit 1); exit 1; }; }
17625 ;;
17626 esac
17627done; }
Michael W. Hudson54241132001-12-07 15:38:26 +000017628
Martin v. Löwis11437992002-04-12 09:54:03 +000017629 rm -f $ac_file
17630 mv $tmp/config.h $ac_file
17631 fi
17632 else
17633 cat $tmp/config.h
17634 rm -f $tmp/config.h
17635 fi
17636done
17637_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000017638
Martin v. Löwis11437992002-04-12 09:54:03 +000017639cat >>$CONFIG_STATUS <<\_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000017640
Martin v. Löwis11437992002-04-12 09:54:03 +000017641{ (exit 0); exit 0; }
17642_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000017643chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000017644ac_clean_files=$ac_clean_files_save
17645
17646
17647# configure is writing to config.log, and then calls config.status.
17648# config.status does its own redirection, appending to config.log.
17649# Unfortunately, on DOS this fails, as config.log is still kept open
17650# by configure, so config.status won't be able to write to it; its
17651# output is simply discarded. So we exec the FD to /dev/null,
17652# effectively closing config.log, so it can be properly (re)opened and
17653# appended to by config.status. When coming back to configure, we
17654# need to make the FD available again.
17655if test "$no_create" != yes; then
17656 ac_cs_success=:
17657 exec 5>/dev/null
17658 $SHELL $CONFIG_STATUS || ac_cs_success=false
17659 exec 5>>config.log
17660 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17661 # would make configure fail if this is the last instruction.
17662 $ac_cs_success || { (exit 1); exit 1; }
17663fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000017664
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000017665
17666echo "creating Setup"
17667if test ! -f Modules/Setup
17668then
17669 cp $srcdir/Modules/Setup.dist Modules/Setup
17670fi
17671
17672echo "creating Setup.local"
17673if test ! -f Modules/Setup.local
17674then
17675 echo "# Edit this file for local setup changes" >Modules/Setup.local
17676fi
17677
17678echo "creating Makefile"
17679$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
17680 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000017681 Modules/Setup.local Modules/Setup
Neil Schemenauerc761fc82001-02-19 04:50:49 +000017682mv config.c Modules