blob: 000c9fce01964e66d19d4589fdbe9b8514e97dc6 [file] [log] [blame]
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +00001#! /bin/sh
Ronald Oussoren450d5612009-06-08 21:12:41 +00002# From configure.in Revision: 72898 .
Guido van Rossum627b2d71993-12-24 10:39:16 +00003# Guess values for system-dependent variables and create Makefiles.
Ronald Oussoren450d5612009-06-08 21:12:41 +00004# Generated by GNU Autoconf 2.61 for python 2.7.
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005#
Georg Brandl464432d2009-05-20 18:24:08 +00006# Report bugs to <http://bugs.python.org/>.
Martin v. Löwis1d459062005-03-14 21:23:33 +00007#
Martin v. Löwiseba40652007-08-30 20:10:57 +00008# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
Ronald Oussoren450d5612009-06-08 21:12:41 +00009# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000010# This configure script is free software; the Free Software Foundation
11# gives unlimited permission to copy, distribute and modify it.
Martin v. Löwis11437992002-04-12 09:54:03 +000012## --------------------- ##
13## M4sh Initialization. ##
14## --------------------- ##
15
Martin v. Löwiseba40652007-08-30 20:10:57 +000016# Be more Bourne compatible
17DUALCASE=1; export DUALCASE # for MKS sh
Martin v. Löwis11437992002-04-12 09:54:03 +000018if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
19 emulate sh
20 NULLCMD=:
Ronald Oussoren450d5612009-06-08 21:12:41 +000021 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
Skip Montanaro6dead952003-09-25 14:50:04 +000022 # is contrary to our usage. Disable this feature.
23 alias -g '${1+"$@"}'='"$@"'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024 setopt NO_GLOB_SUBST
Skip Montanaro89e975f2007-08-22 19:05:21 +000025else
Martin v. Löwiseba40652007-08-30 20:10:57 +000026 case `(set -o) 2>/dev/null` in
27 *posix*) set -o posix ;;
28esac
29
Martin v. Löwis11437992002-04-12 09:54:03 +000030fi
31
Skip Montanaro6dead952003-09-25 14:50:04 +000032
Martin v. Löwis11437992002-04-12 09:54:03 +000033
34
Martin v. Löwiseba40652007-08-30 20:10:57 +000035# PATH needs CR
Martin v. Löwis11437992002-04-12 09:54:03 +000036# Avoid depending upon Character Ranges.
37as_cr_letters='abcdefghijklmnopqrstuvwxyz'
38as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
39as_cr_Letters=$as_cr_letters$as_cr_LETTERS
40as_cr_digits='0123456789'
41as_cr_alnum=$as_cr_Letters$as_cr_digits
42
43# The user is always right.
44if test "${PATH_SEPARATOR+set}" != set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000045 echo "#! /bin/sh" >conf$$.sh
46 echo "exit 0" >>conf$$.sh
47 chmod +x conf$$.sh
48 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
49 PATH_SEPARATOR=';'
50 else
51 PATH_SEPARATOR=:
52 fi
53 rm -f conf$$.sh
Martin v. Löwis11437992002-04-12 09:54:03 +000054fi
55
Martin v. Löwiseba40652007-08-30 20:10:57 +000056# Support unset when possible.
57if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
58 as_unset=unset
59else
60 as_unset=false
61fi
Martin v. Löwis11437992002-04-12 09:54:03 +000062
Martin v. Löwiseba40652007-08-30 20:10:57 +000063
64# IFS
65# We need space, tab and new line, in precisely that order. Quoting is
66# there to prevent editors from complaining about space-tab.
67# (If _AS_PATH_WALK were called with IFS unset, it would disable word
68# splitting by setting IFS to empty value.)
Ronald Oussoren450d5612009-06-08 21:12:41 +000069as_nl='
70'
Martin v. Löwiseba40652007-08-30 20:10:57 +000071IFS=" "" $as_nl"
72
73# Find who we are. Look in the path if we contain no directory separator.
74case $0 in
75 *[\\/]* ) as_myself=$0 ;;
76 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwis11437992002-04-12 09:54:03 +000077for as_dir in $PATH
78do
79 IFS=$as_save_IFS
80 test -z "$as_dir" && as_dir=.
81 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
82done
Martin v. Löwiseba40652007-08-30 20:10:57 +000083IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +000084
Martin v. Löwiseba40652007-08-30 20:10:57 +000085 ;;
86esac
87# We did not find ourselves, most probably we were run as `sh COMMAND'
88# in which case we are not to be found in the path.
89if test "x$as_myself" = x; then
90 as_myself=$0
91fi
92if test ! -f "$as_myself"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000093 echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +000094 { (exit 1); exit 1; }
95fi
96
97# Work around bugs in pre-3.0 UWIN ksh.
98for as_var in ENV MAIL MAILPATH
99do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
100done
101PS1='$ '
102PS2='> '
103PS4='+ '
104
105# NLS nuisances.
Ronald Oussoren450d5612009-06-08 21:12:41 +0000106for as_var in \
107 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
108 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
109 LC_TELEPHONE LC_TIME
110do
111 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
112 eval $as_var=C; export $as_var
113 else
114 ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
115 fi
116done
Martin v. Löwiseba40652007-08-30 20:10:57 +0000117
118# Required to use basename.
119if expr a : '\(a\)' >/dev/null 2>&1 &&
120 test "X`expr 00001 : '.*\(...\)'`" = X001; then
121 as_expr=expr
122else
123 as_expr=false
124fi
125
126if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
127 as_basename=basename
128else
129 as_basename=false
130fi
131
132
133# Name of the executable.
134as_me=`$as_basename -- "$0" ||
135$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
136 X"$0" : 'X\(//\)$' \| \
137 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
Ronald Oussoren450d5612009-06-08 21:12:41 +0000138echo X/"$0" |
Martin v. Löwiseba40652007-08-30 20:10:57 +0000139 sed '/^.*\/\([^/][^/]*\)\/*$/{
140 s//\1/
141 q
142 }
143 /^X\/\(\/\/\)$/{
144 s//\1/
145 q
146 }
147 /^X\/\(\/\).*/{
148 s//\1/
149 q
150 }
151 s/.*/./; q'`
152
153# CDPATH.
154$as_unset CDPATH
155
156
157if test "x$CONFIG_SHELL" = x; then
158 if (eval ":") 2>/dev/null; then
159 as_have_required=yes
160else
161 as_have_required=no
162fi
163
Ronald Oussoren450d5612009-06-08 21:12:41 +0000164 if test $as_have_required = yes && (eval ":
Martin v. Löwiseba40652007-08-30 20:10:57 +0000165(as_func_return () {
166 (exit \$1)
167}
168as_func_success () {
169 as_func_return 0
170}
171as_func_failure () {
172 as_func_return 1
173}
174as_func_ret_success () {
175 return 0
176}
177as_func_ret_failure () {
178 return 1
179}
180
181exitcode=0
182if as_func_success; then
183 :
184else
185 exitcode=1
186 echo as_func_success failed.
187fi
188
189if as_func_failure; then
190 exitcode=1
191 echo as_func_failure succeeded.
192fi
193
194if as_func_ret_success; then
195 :
196else
197 exitcode=1
198 echo as_func_ret_success failed.
199fi
200
201if as_func_ret_failure; then
202 exitcode=1
203 echo as_func_ret_failure succeeded.
204fi
205
206if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
207 :
208else
209 exitcode=1
210 echo positional parameters were not saved.
211fi
212
213test \$exitcode = 0) || { (exit 1); exit 1; }
214
215(
216 as_lineno_1=\$LINENO
217 as_lineno_2=\$LINENO
218 test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
219 test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
220") 2> /dev/null; then
221 :
222else
223 as_candidate_shells=
Martin v. Löwis11437992002-04-12 09:54:03 +0000224 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
225for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
226do
227 IFS=$as_save_IFS
228 test -z "$as_dir" && as_dir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000229 case $as_dir in
Martin v. Löwis11437992002-04-12 09:54:03 +0000230 /*)
Martin v. Löwiseba40652007-08-30 20:10:57 +0000231 for as_base in sh bash ksh sh5; do
232 as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
233 done;;
234 esac
235done
236IFS=$as_save_IFS
237
238
239 for as_shell in $as_candidate_shells $SHELL; do
240 # Try only shells that exist, to save several forks.
241 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
242 { ("$as_shell") 2> /dev/null <<\_ASEOF
243if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
244 emulate sh
245 NULLCMD=:
Ronald Oussoren450d5612009-06-08 21:12:41 +0000246 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
Martin v. Löwiseba40652007-08-30 20:10:57 +0000247 # is contrary to our usage. Disable this feature.
248 alias -g '${1+"$@"}'='"$@"'
249 setopt NO_GLOB_SUBST
250else
251 case `(set -o) 2>/dev/null` in
252 *posix*) set -o posix ;;
253esac
254
255fi
256
257
258:
259_ASEOF
260}; then
261 CONFIG_SHELL=$as_shell
262 as_have_required=yes
263 if { "$as_shell" 2> /dev/null <<\_ASEOF
264if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
265 emulate sh
266 NULLCMD=:
Ronald Oussoren450d5612009-06-08 21:12:41 +0000267 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
Martin v. Löwiseba40652007-08-30 20:10:57 +0000268 # is contrary to our usage. Disable this feature.
269 alias -g '${1+"$@"}'='"$@"'
270 setopt NO_GLOB_SUBST
271else
272 case `(set -o) 2>/dev/null` in
273 *posix*) set -o posix ;;
274esac
275
276fi
277
278
279:
280(as_func_return () {
281 (exit $1)
282}
283as_func_success () {
284 as_func_return 0
285}
286as_func_failure () {
287 as_func_return 1
288}
289as_func_ret_success () {
290 return 0
291}
292as_func_ret_failure () {
293 return 1
294}
295
296exitcode=0
297if as_func_success; then
298 :
299else
300 exitcode=1
301 echo as_func_success failed.
302fi
303
304if as_func_failure; then
305 exitcode=1
306 echo as_func_failure succeeded.
307fi
308
309if as_func_ret_success; then
310 :
311else
312 exitcode=1
313 echo as_func_ret_success failed.
314fi
315
316if as_func_ret_failure; then
317 exitcode=1
318 echo as_func_ret_failure succeeded.
319fi
320
321if ( set x; as_func_ret_success y && test x = "$1" ); then
322 :
323else
324 exitcode=1
325 echo positional parameters were not saved.
326fi
327
328test $exitcode = 0) || { (exit 1); exit 1; }
329
330(
Skip Montanaro89e975f2007-08-22 19:05:21 +0000331 as_lineno_1=$LINENO
332 as_lineno_2=$LINENO
Skip Montanaro89e975f2007-08-22 19:05:21 +0000333 test "x$as_lineno_1" != "x$as_lineno_2" &&
Martin v. Löwiseba40652007-08-30 20:10:57 +0000334 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
335
336_ASEOF
337}; then
338 break
339fi
340
341fi
342
343 done
344
345 if test "x$CONFIG_SHELL" != x; then
346 for as_var in BASH_ENV ENV
Ronald Oussoren450d5612009-06-08 21:12:41 +0000347 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
348 done
349 export CONFIG_SHELL
350 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
Martin v. Löwiseba40652007-08-30 20:10:57 +0000351fi
352
353
354 if test $as_have_required = no; then
355 echo This script requires a shell more modern than all the
356 echo shells that I found on your system. Please install a
357 echo modern shell, or manually run the script under such a
358 echo shell if you do have one.
359 { (exit 1); exit 1; }
360fi
361
362
363fi
364
365fi
366
367
368
369(eval "as_func_return () {
370 (exit \$1)
371}
372as_func_success () {
373 as_func_return 0
374}
375as_func_failure () {
376 as_func_return 1
377}
378as_func_ret_success () {
379 return 0
380}
381as_func_ret_failure () {
382 return 1
383}
384
385exitcode=0
386if as_func_success; then
387 :
388else
389 exitcode=1
390 echo as_func_success failed.
391fi
392
393if as_func_failure; then
394 exitcode=1
395 echo as_func_failure succeeded.
396fi
397
398if as_func_ret_success; then
399 :
400else
401 exitcode=1
402 echo as_func_ret_success failed.
403fi
404
405if as_func_ret_failure; then
406 exitcode=1
407 echo as_func_ret_failure succeeded.
408fi
409
410if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
411 :
412else
413 exitcode=1
414 echo positional parameters were not saved.
415fi
416
417test \$exitcode = 0") || {
418 echo No shell found that supports shell functions.
Ronald Oussoren450d5612009-06-08 21:12:41 +0000419 echo Please tell autoconf@gnu.org about your system,
420 echo including any error possibly output before this
421 echo message
Martin v. Löwiseba40652007-08-30 20:10:57 +0000422}
423
424
425
426 as_lineno_1=$LINENO
427 as_lineno_2=$LINENO
428 test "x$as_lineno_1" != "x$as_lineno_2" &&
429 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
Martin v. Löwis11437992002-04-12 09:54:03 +0000430
431 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
432 # uniformly replaced by the line number. The first 'sed' inserts a
Martin v. Löwiseba40652007-08-30 20:10:57 +0000433 # line-number line after each line using $LINENO; the second 'sed'
434 # does the real work. The second script uses 'N' to pair each
435 # line-number line with the line containing $LINENO, and appends
436 # trailing '-' during substitution so that $LINENO is not a special
437 # case at line end.
Martin v. Löwis11437992002-04-12 09:54:03 +0000438 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
Martin v. Löwiseba40652007-08-30 20:10:57 +0000439 # scripts with optimization help from Paolo Bonzini. Blame Lee
440 # E. McMahon (1931-1989) for sed's syntax. :-)
441 sed -n '
442 p
443 /[$]LINENO/=
444 ' <$as_myself |
Martin v. Löwis11437992002-04-12 09:54:03 +0000445 sed '
Martin v. Löwiseba40652007-08-30 20:10:57 +0000446 s/[$]LINENO.*/&-/
447 t lineno
448 b
449 :lineno
Martin v. Löwis11437992002-04-12 09:54:03 +0000450 N
Martin v. Löwiseba40652007-08-30 20:10:57 +0000451 :loop
452 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
Martin v. Löwis11437992002-04-12 09:54:03 +0000453 t loop
Martin v. Löwiseba40652007-08-30 20:10:57 +0000454 s/-\n.*//
Martin v. Löwis11437992002-04-12 09:54:03 +0000455 ' >$as_me.lineno &&
Martin v. Löwiseba40652007-08-30 20:10:57 +0000456 chmod +x "$as_me.lineno" ||
Ronald Oussoren450d5612009-06-08 21:12:41 +0000457 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +0000458 { (exit 1); exit 1; }; }
459
460 # Don't try to exec as it changes $[0], causing all sort of problems
461 # (the dirname of $[0] is not the place where we might find the
Martin v. Löwiseba40652007-08-30 20:10:57 +0000462 # original and so on. Autoconf is especially sensitive to this).
463 . "./$as_me.lineno"
Martin v. Löwis11437992002-04-12 09:54:03 +0000464 # Exit status is that of the last command.
465 exit
466}
467
468
Martin v. Löwiseba40652007-08-30 20:10:57 +0000469if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
470 as_dirname=dirname
471else
472 as_dirname=false
473fi
474
475ECHO_C= ECHO_N= ECHO_T=
476case `echo -n x` in
477-n*)
478 case `echo 'x\c'` in
479 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
480 *) ECHO_C='\c';;
481 esac;;
482*)
483 ECHO_N='-n';;
Martin v. Löwis11437992002-04-12 09:54:03 +0000484esac
Ronald Oussoren450d5612009-06-08 21:12:41 +0000485
Martin v. Löwiseba40652007-08-30 20:10:57 +0000486if expr a : '\(a\)' >/dev/null 2>&1 &&
487 test "X`expr 00001 : '.*\(...\)'`" = X001; then
Martin v. Löwis11437992002-04-12 09:54:03 +0000488 as_expr=expr
489else
490 as_expr=false
491fi
492
493rm -f conf$$ conf$$.exe conf$$.file
Martin v. Löwiseba40652007-08-30 20:10:57 +0000494if test -d conf$$.dir; then
495 rm -f conf$$.dir/conf$$.file
496else
497 rm -f conf$$.dir
Ronald Oussoren450d5612009-06-08 21:12:41 +0000498 mkdir conf$$.dir
Martin v. Löwiseba40652007-08-30 20:10:57 +0000499fi
Ronald Oussoren450d5612009-06-08 21:12:41 +0000500echo >conf$$.file
501if ln -s conf$$.file conf$$ 2>/dev/null; then
502 as_ln_s='ln -s'
503 # ... but there are two gotchas:
504 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
505 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
506 # In both cases, we have to default to `cp -p'.
507 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
Martin v. Löwis11437992002-04-12 09:54:03 +0000508 as_ln_s='cp -p'
Ronald Oussoren450d5612009-06-08 21:12:41 +0000509elif ln conf$$.file conf$$ 2>/dev/null; then
510 as_ln_s=ln
Martin v. Löwis11437992002-04-12 09:54:03 +0000511else
512 as_ln_s='cp -p'
513fi
Martin v. Löwiseba40652007-08-30 20:10:57 +0000514rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
515rmdir conf$$.dir 2>/dev/null
Martin v. Löwis11437992002-04-12 09:54:03 +0000516
Skip Montanaro6dead952003-09-25 14:50:04 +0000517if mkdir -p . 2>/dev/null; then
518 as_mkdir_p=:
519else
Skip Montanarof0d5f792004-08-15 14:08:23 +0000520 test -d ./-p && rmdir ./-p
Skip Montanaro6dead952003-09-25 14:50:04 +0000521 as_mkdir_p=false
522fi
523
Martin v. Löwiseba40652007-08-30 20:10:57 +0000524if test -x / >/dev/null 2>&1; then
525 as_test_x='test -x'
526else
527 if ls -dL / >/dev/null 2>&1; then
528 as_ls_L_option=L
529 else
530 as_ls_L_option=
531 fi
532 as_test_x='
533 eval sh -c '\''
534 if test -d "$1"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +0000535 test -d "$1/.";
Martin v. Löwiseba40652007-08-30 20:10:57 +0000536 else
537 case $1 in
Ronald Oussoren450d5612009-06-08 21:12:41 +0000538 -*)set "./$1";;
Martin v. Löwiseba40652007-08-30 20:10:57 +0000539 esac;
540 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
541 ???[sx]*):;;*)false;;esac;fi
542 '\'' sh
543 '
544fi
545as_executable_p=$as_test_x
Martin v. Löwis11437992002-04-12 09:54:03 +0000546
547# Sed expression to map a string onto a valid CPP name.
Skip Montanarof0d5f792004-08-15 14:08:23 +0000548as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +0000549
550# Sed expression to map a string onto a valid variable name.
Skip Montanarof0d5f792004-08-15 14:08:23 +0000551as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +0000552
553
Martin v. Löwis11437992002-04-12 09:54:03 +0000554
Martin v. Löwiseba40652007-08-30 20:10:57 +0000555exec 7<&0 </dev/null 6>&1
Martin v. Löwis11437992002-04-12 09:54:03 +0000556
557# Name of the host.
558# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
559# so uname gets run too.
560ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
561
Martin v. Löwis11437992002-04-12 09:54:03 +0000562#
563# Initializations.
564#
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000565ac_default_prefix=/usr/local
Martin v. Löwiseba40652007-08-30 20:10:57 +0000566ac_clean_files=
Skip Montanaro6dead952003-09-25 14:50:04 +0000567ac_config_libobj_dir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000568LIBOBJS=
Martin v. Löwis11437992002-04-12 09:54:03 +0000569cross_compiling=no
570subdirs=
571MFLAGS=
572MAKEFLAGS=
573SHELL=${CONFIG_SHELL-/bin/sh}
574
Martin v. Löwis11437992002-04-12 09:54:03 +0000575# Identity of this package.
Martin v. Löwis88afe662002-10-26 13:47:44 +0000576PACKAGE_NAME='python'
577PACKAGE_TARNAME='python'
Martin v. Löwis174440b2008-10-03 08:59:41 +0000578PACKAGE_VERSION='2.7'
579PACKAGE_STRING='python 2.7'
Georg Brandl464432d2009-05-20 18:24:08 +0000580PACKAGE_BUGREPORT='http://bugs.python.org/'
Martin v. Löwis11437992002-04-12 09:54:03 +0000581
582ac_unique_file="Include/object.h"
583# Factoring default headers for most tests.
584ac_includes_default="\
585#include <stdio.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +0000586#ifdef HAVE_SYS_TYPES_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000587# include <sys/types.h>
588#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000589#ifdef HAVE_SYS_STAT_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000590# include <sys/stat.h>
591#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000592#ifdef STDC_HEADERS
Martin v. Löwis11437992002-04-12 09:54:03 +0000593# include <stdlib.h>
594# include <stddef.h>
595#else
Martin v. Löwiseba40652007-08-30 20:10:57 +0000596# ifdef HAVE_STDLIB_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000597# include <stdlib.h>
598# endif
599#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000600#ifdef HAVE_STRING_H
601# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000602# include <memory.h>
603# endif
604# include <string.h>
605#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000606#ifdef HAVE_STRINGS_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000607# include <strings.h>
608#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000609#ifdef HAVE_INTTYPES_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000610# include <inttypes.h>
Martin v. Löwis11437992002-04-12 09:54:03 +0000611#endif
Martin v. Löwiseba40652007-08-30 20:10:57 +0000612#ifdef HAVE_STDINT_H
613# include <stdint.h>
614#endif
615#ifdef HAVE_UNISTD_H
Martin v. Löwis11437992002-04-12 09:54:03 +0000616# include <unistd.h>
617#endif"
618
Ronald Oussoren450d5612009-06-08 21:12:41 +0000619ac_subst_vars='SHELL
Antoine Pitrouf2caeed2009-05-24 20:23:57 +0000620PATH_SEPARATOR
Ronald Oussoren450d5612009-06-08 21:12:41 +0000621PACKAGE_NAME
622PACKAGE_TARNAME
623PACKAGE_VERSION
624PACKAGE_STRING
625PACKAGE_BUGREPORT
626exec_prefix
627prefix
628program_transform_name
629bindir
630sbindir
631libexecdir
632datarootdir
633datadir
634sysconfdir
635sharedstatedir
636localstatedir
637includedir
638oldincludedir
639docdir
640infodir
641htmldir
642dvidir
643pdfdir
644psdir
645libdir
646localedir
647mandir
648DEFS
649ECHO_C
650ECHO_N
651ECHO_T
652LIBS
653build_alias
654host_alias
655target_alias
656VERSION
657SOVERSION
658CONFIG_ARGS
659UNIVERSALSDK
660ARCH_RUN_32BIT
661PYTHONFRAMEWORK
662PYTHONFRAMEWORKIDENTIFIER
663PYTHONFRAMEWORKDIR
664PYTHONFRAMEWORKPREFIX
665PYTHONFRAMEWORKINSTALLDIR
666FRAMEWORKINSTALLFIRST
667FRAMEWORKINSTALLLAST
668FRAMEWORKALTINSTALLFIRST
669FRAMEWORKALTINSTALLLAST
670FRAMEWORKUNIXTOOLSPREFIX
671MACHDEP
672SGI_ABI
673EXTRAPLATDIR
674EXTRAMACHDEPPATH
675CONFIGURE_MACOSX_DEPLOYMENT_TARGET
676EXPORT_MACOSX_DEPLOYMENT_TARGET
677CC
678CFLAGS
679LDFLAGS
680CPPFLAGS
681ac_ct_CC
682EXEEXT
683OBJEXT
684CXX
685MAINCC
686CPP
687GREP
688EGREP
689BUILDEXEEXT
690LIBRARY
691LDLIBRARY
692DLLLIBRARY
693BLDLIBRARY
694LDLIBRARYDIR
695INSTSONAME
696RUNSHARED
697LINKCC
698GNULD
699RANLIB
700AR
701ARFLAGS
702SVNVERSION
703INSTALL_PROGRAM
704INSTALL_SCRIPT
705INSTALL_DATA
706LN
707OPT
708BASECFLAGS
709UNIVERSAL_ARCH_FLAGS
710OTHER_LIBTOOL_OPT
711LIBTOOL_CRUFT
712SO
713LDSHARED
714BLDSHARED
715CCSHARED
716LINKFORSHARED
717CFLAGSFORSHARED
718SHLIBS
719USE_SIGNAL_MODULE
720SIGNAL_OBJS
721USE_THREAD_MODULE
722LDLAST
723THREADOBJ
724DLINCLDIR
725DYNLOADFILE
726MACHDEP_OBJS
727TRUE
728LIBOBJS
729HAVE_GETHOSTBYNAME_R_6_ARG
730HAVE_GETHOSTBYNAME_R_5_ARG
731HAVE_GETHOSTBYNAME_R_3_ARG
732HAVE_GETHOSTBYNAME_R
733HAVE_GETHOSTBYNAME
734LIBM
735LIBC
736UNICODE_OBJS
737THREADHEADERS
738SRCDIRS
739LTLIBOBJS'
Skip Montanaro6dead952003-09-25 14:50:04 +0000740ac_subst_files=''
Martin v. Löwiseba40652007-08-30 20:10:57 +0000741 ac_precious_vars='build_alias
742host_alias
743target_alias
744CC
745CFLAGS
746LDFLAGS
747LIBS
748CPPFLAGS
749CPP'
750
Guido van Rossum627b2d71993-12-24 10:39:16 +0000751
Guido van Rossum7f43da71994-08-01 12:15:30 +0000752# Initialize some variables set by options.
Martin v. Löwis11437992002-04-12 09:54:03 +0000753ac_init_help=
754ac_init_version=false
Guido van Rossum7f43da71994-08-01 12:15:30 +0000755# The variables have the same names as the options, with
756# dashes changed to underlines.
Martin v. Löwis11437992002-04-12 09:54:03 +0000757cache_file=/dev/null
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000758exec_prefix=NONE
Guido van Rossum7f43da71994-08-01 12:15:30 +0000759no_create=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000760no_recursion=
761prefix=NONE
762program_prefix=NONE
763program_suffix=NONE
764program_transform_name=s,x,x,
Guido van Rossum7f43da71994-08-01 12:15:30 +0000765silent=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000766site=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000767srcdir=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000768verbose=
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000769x_includes=NONE
770x_libraries=NONE
Martin v. Löwis11437992002-04-12 09:54:03 +0000771
772# Installation directory options.
773# These are left unexpanded so users can "make install exec_prefix=/foo"
774# and all the variables that are supposed to be based on exec_prefix
775# by default will actually change.
776# Use braces instead of parens because sh, perl, etc. also accept them.
Martin v. Löwiseba40652007-08-30 20:10:57 +0000777# (The list follows the same order as the GNU Coding Standards.)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000778bindir='${exec_prefix}/bin'
779sbindir='${exec_prefix}/sbin'
780libexecdir='${exec_prefix}/libexec'
Martin v. Löwiseba40652007-08-30 20:10:57 +0000781datarootdir='${prefix}/share'
782datadir='${datarootdir}'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000783sysconfdir='${prefix}/etc'
784sharedstatedir='${prefix}/com'
785localstatedir='${prefix}/var'
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000786includedir='${prefix}/include'
787oldincludedir='/usr/include'
Martin v. Löwiseba40652007-08-30 20:10:57 +0000788docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
789infodir='${datarootdir}/info'
790htmldir='${docdir}'
791dvidir='${docdir}'
792pdfdir='${docdir}'
793psdir='${docdir}'
794libdir='${exec_prefix}/lib'
795localedir='${datarootdir}/locale'
796mandir='${datarootdir}/man'
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000797
Guido van Rossum7f43da71994-08-01 12:15:30 +0000798ac_prev=
Martin v. Löwiseba40652007-08-30 20:10:57 +0000799ac_dashdash=
Guido van Rossum7f43da71994-08-01 12:15:30 +0000800for ac_option
Guido van Rossum627b2d71993-12-24 10:39:16 +0000801do
Guido van Rossum7f43da71994-08-01 12:15:30 +0000802 # If the previous option needs an argument, assign it.
803 if test -n "$ac_prev"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +0000804 eval $ac_prev=\$ac_option
Guido van Rossum7f43da71994-08-01 12:15:30 +0000805 ac_prev=
806 continue
Guido van Rossum627b2d71993-12-24 10:39:16 +0000807 fi
Guido van Rossum7f43da71994-08-01 12:15:30 +0000808
Martin v. Löwiseba40652007-08-30 20:10:57 +0000809 case $ac_option in
810 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
811 *) ac_optarg=yes ;;
812 esac
Guido van Rossum7f43da71994-08-01 12:15:30 +0000813
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000814 # Accept the important Cygnus configure options, so we can diagnose typos.
815
Martin v. Löwiseba40652007-08-30 20:10:57 +0000816 case $ac_dashdash$ac_option in
817 --)
818 ac_dashdash=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000819
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000820 -bindir | --bindir | --bindi | --bind | --bin | --bi)
821 ac_prev=bindir ;;
822 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000823 bindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000824
825 -build | --build | --buil | --bui | --bu)
Martin v. Löwis11437992002-04-12 09:54:03 +0000826 ac_prev=build_alias ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000827 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000828 build_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000829
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000830 -cache-file | --cache-file | --cache-fil | --cache-fi \
831 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
832 ac_prev=cache_file ;;
833 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
834 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000835 cache_file=$ac_optarg ;;
836
837 --config-cache | -C)
838 cache_file=config.cache ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000839
Martin v. Löwiseba40652007-08-30 20:10:57 +0000840 -datadir | --datadir | --datadi | --datad)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000841 ac_prev=datadir ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +0000842 -datadir=* | --datadir=* | --datadi=* | --datad=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000843 datadir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000844
Martin v. Löwiseba40652007-08-30 20:10:57 +0000845 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
846 | --dataroo | --dataro | --datar)
847 ac_prev=datarootdir ;;
848 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
849 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
850 datarootdir=$ac_optarg ;;
851
Guido van Rossum7f43da71994-08-01 12:15:30 +0000852 -disable-* | --disable-*)
Ronald Oussoren450d5612009-06-08 21:12:41 +0000853 ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000854 # Reject names that are not valid shell variable names.
Ronald Oussoren450d5612009-06-08 21:12:41 +0000855 expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
856 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +0000857 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +0000858 ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
859 eval enable_$ac_feature=no ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +0000860
861 -docdir | --docdir | --docdi | --doc | --do)
862 ac_prev=docdir ;;
863 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
864 docdir=$ac_optarg ;;
865
866 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
867 ac_prev=dvidir ;;
868 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
869 dvidir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000870
871 -enable-* | --enable-*)
Ronald Oussoren450d5612009-06-08 21:12:41 +0000872 ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000873 # Reject names that are not valid shell variable names.
Ronald Oussoren450d5612009-06-08 21:12:41 +0000874 expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
875 { echo "$as_me: error: invalid feature name: $ac_feature" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +0000876 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +0000877 ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
878 eval enable_$ac_feature=\$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000879
Guido van Rossum7f43da71994-08-01 12:15:30 +0000880 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
881 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
882 | --exec | --exe | --ex)
883 ac_prev=exec_prefix ;;
884 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
885 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
886 | --exec=* | --exe=* | --ex=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000887 exec_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000888
889 -gas | --gas | --ga | --g)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000890 # Obsolete; use --with-gas.
891 with_gas=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000892
Martin v. Löwis11437992002-04-12 09:54:03 +0000893 -help | --help | --hel | --he | -h)
894 ac_init_help=long ;;
895 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
896 ac_init_help=recursive ;;
897 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
898 ac_init_help=short ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000899
900 -host | --host | --hos | --ho)
Martin v. Löwis11437992002-04-12 09:54:03 +0000901 ac_prev=host_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000902 -host=* | --host=* | --hos=* | --ho=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000903 host_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000904
Martin v. Löwiseba40652007-08-30 20:10:57 +0000905 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
906 ac_prev=htmldir ;;
907 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
908 | --ht=*)
909 htmldir=$ac_optarg ;;
910
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000911 -includedir | --includedir | --includedi | --included | --include \
912 | --includ | --inclu | --incl | --inc)
913 ac_prev=includedir ;;
914 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
915 | --includ=* | --inclu=* | --incl=* | --inc=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000916 includedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000917
918 -infodir | --infodir | --infodi | --infod | --info | --inf)
919 ac_prev=infodir ;;
920 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000921 infodir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000922
923 -libdir | --libdir | --libdi | --libd)
924 ac_prev=libdir ;;
925 -libdir=* | --libdir=* | --libdi=* | --libd=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000926 libdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000927
928 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
929 | --libexe | --libex | --libe)
930 ac_prev=libexecdir ;;
931 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
932 | --libexe=* | --libex=* | --libe=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000933 libexecdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000934
Martin v. Löwiseba40652007-08-30 20:10:57 +0000935 -localedir | --localedir | --localedi | --localed | --locale)
936 ac_prev=localedir ;;
937 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
938 localedir=$ac_optarg ;;
939
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000940 -localstatedir | --localstatedir | --localstatedi | --localstated \
Martin v. Löwiseba40652007-08-30 20:10:57 +0000941 | --localstate | --localstat | --localsta | --localst | --locals)
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000942 ac_prev=localstatedir ;;
943 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
Martin v. Löwiseba40652007-08-30 20:10:57 +0000944 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000945 localstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000946
947 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
948 ac_prev=mandir ;;
949 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000950 mandir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000951
Guido van Rossum7f43da71994-08-01 12:15:30 +0000952 -nfp | --nfp | --nf)
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000953 # Obsolete; use --without-fp.
954 with_fp=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000955
956 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
Martin v. Löwis11437992002-04-12 09:54:03 +0000957 | --no-cr | --no-c | -n)
Guido van Rossum7f43da71994-08-01 12:15:30 +0000958 no_create=yes ;;
959
Guido van Rossum76be6ed1995-01-02 18:33:54 +0000960 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
961 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
962 no_recursion=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000963
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000964 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
965 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
966 | --oldin | --oldi | --old | --ol | --o)
967 ac_prev=oldincludedir ;;
968 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
969 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
970 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000971 oldincludedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +0000972
Guido van Rossum7f43da71994-08-01 12:15:30 +0000973 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
974 ac_prev=prefix ;;
975 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000976 prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000977
978 -program-prefix | --program-prefix | --program-prefi | --program-pref \
979 | --program-pre | --program-pr | --program-p)
980 ac_prev=program_prefix ;;
981 -program-prefix=* | --program-prefix=* | --program-prefi=* \
982 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000983 program_prefix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000984
985 -program-suffix | --program-suffix | --program-suffi | --program-suff \
986 | --program-suf | --program-su | --program-s)
987 ac_prev=program_suffix ;;
988 -program-suffix=* | --program-suffix=* | --program-suffi=* \
989 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
Martin v. Löwis11437992002-04-12 09:54:03 +0000990 program_suffix=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +0000991
992 -program-transform-name | --program-transform-name \
993 | --program-transform-nam | --program-transform-na \
994 | --program-transform-n | --program-transform- \
995 | --program-transform | --program-transfor \
996 | --program-transfo | --program-transf \
997 | --program-trans | --program-tran \
998 | --progr-tra | --program-tr | --program-t)
999 ac_prev=program_transform_name ;;
1000 -program-transform-name=* | --program-transform-name=* \
1001 | --program-transform-nam=* | --program-transform-na=* \
1002 | --program-transform-n=* | --program-transform-=* \
1003 | --program-transform=* | --program-transfor=* \
1004 | --program-transfo=* | --program-transf=* \
1005 | --program-trans=* | --program-tran=* \
1006 | --progr-tra=* | --program-tr=* | --program-t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001007 program_transform_name=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001008
Martin v. Löwiseba40652007-08-30 20:10:57 +00001009 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1010 ac_prev=pdfdir ;;
1011 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1012 pdfdir=$ac_optarg ;;
1013
1014 -psdir | --psdir | --psdi | --psd | --ps)
1015 ac_prev=psdir ;;
1016 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1017 psdir=$ac_optarg ;;
1018
Guido van Rossum7f43da71994-08-01 12:15:30 +00001019 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1020 | -silent | --silent | --silen | --sile | --sil)
1021 silent=yes ;;
1022
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001023 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1024 ac_prev=sbindir ;;
1025 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1026 | --sbi=* | --sb=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001027 sbindir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001028
1029 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1030 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1031 | --sharedst | --shareds | --shared | --share | --shar \
1032 | --sha | --sh)
1033 ac_prev=sharedstatedir ;;
1034 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1035 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1036 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1037 | --sha=* | --sh=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001038 sharedstatedir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001039
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001040 -site | --site | --sit)
1041 ac_prev=site ;;
1042 -site=* | --site=* | --sit=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001043 site=$ac_optarg ;;
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001044
Guido van Rossum7f43da71994-08-01 12:15:30 +00001045 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1046 ac_prev=srcdir ;;
1047 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001048 srcdir=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001049
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001050 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1051 | --syscon | --sysco | --sysc | --sys | --sy)
1052 ac_prev=sysconfdir ;;
1053 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1054 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001055 sysconfdir=$ac_optarg ;;
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001056
Guido van Rossum7f43da71994-08-01 12:15:30 +00001057 -target | --target | --targe | --targ | --tar | --ta | --t)
Martin v. Löwis11437992002-04-12 09:54:03 +00001058 ac_prev=target_alias ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001059 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001060 target_alias=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001061
1062 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1063 verbose=yes ;;
1064
Martin v. Löwis11437992002-04-12 09:54:03 +00001065 -version | --version | --versio | --versi | --vers | -V)
1066 ac_init_version=: ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001067
1068 -with-* | --with-*)
Ronald Oussoren450d5612009-06-08 21:12:41 +00001069 ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001070 # Reject names that are not valid shell variable names.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001071 expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1072 { echo "$as_me: error: invalid package name: $ac_package" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001073 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +00001074 ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1075 eval with_$ac_package=\$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001076
1077 -without-* | --without-*)
Ronald Oussoren450d5612009-06-08 21:12:41 +00001078 ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001079 # Reject names that are not valid shell variable names.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001080 expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1081 { echo "$as_me: error: invalid package name: $ac_package" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001082 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +00001083 ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1084 eval with_$ac_package=no ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001085
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001086 --x)
1087 # Obsolete; use --with-x.
1088 with_x=yes ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001089
1090 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1091 | --x-incl | --x-inc | --x-in | --x-i)
1092 ac_prev=x_includes ;;
1093 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1094 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001095 x_includes=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001096
1097 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1098 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1099 ac_prev=x_libraries ;;
1100 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1101 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
Martin v. Löwis11437992002-04-12 09:54:03 +00001102 x_libraries=$ac_optarg ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001103
Ronald Oussoren450d5612009-06-08 21:12:41 +00001104 -*) { echo "$as_me: error: unrecognized option: $ac_option
Martin v. Löwis11437992002-04-12 09:54:03 +00001105Try \`$0 --help' for more information." >&2
1106 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00001107 ;;
1108
Martin v. Löwis11437992002-04-12 09:54:03 +00001109 *=*)
1110 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1111 # Reject names that are not valid shell variable names.
1112 expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
Ronald Oussoren450d5612009-06-08 21:12:41 +00001113 { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001114 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00001115 eval $ac_envvar=\$ac_optarg
Martin v. Löwis11437992002-04-12 09:54:03 +00001116 export $ac_envvar ;;
1117
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00001118 *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001119 # FIXME: should be removed in autoconf 3.0.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001120 echo "$as_me: WARNING: you should use --build, --host, --target" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001121 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
Ronald Oussoren450d5612009-06-08 21:12:41 +00001122 echo "$as_me: WARNING: invalid host type: $ac_option" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001123 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
Guido van Rossum7f43da71994-08-01 12:15:30 +00001124 ;;
1125
1126 esac
Guido van Rossum627b2d71993-12-24 10:39:16 +00001127done
1128
Guido van Rossum7f43da71994-08-01 12:15:30 +00001129if test -n "$ac_prev"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001130 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
Ronald Oussoren450d5612009-06-08 21:12:41 +00001131 { echo "$as_me: error: missing argument to $ac_option" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001132 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +00001133fi
1134
Ronald Oussoren450d5612009-06-08 21:12:41 +00001135# Be sure to have absolute directory names.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001136for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1137 datadir sysconfdir sharedstatedir localstatedir includedir \
1138 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1139 libdir localedir mandir
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001140do
Martin v. Löwiseba40652007-08-30 20:10:57 +00001141 eval ac_val=\$$ac_var
Martin v. Löwis11437992002-04-12 09:54:03 +00001142 case $ac_val in
Martin v. Löwiseba40652007-08-30 20:10:57 +00001143 [\\/$]* | ?:[\\/]* ) continue;;
1144 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00001145 esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00001146 { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001147 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001148done
Guido van Rossum627b2d71993-12-24 10:39:16 +00001149
Martin v. Löwis11437992002-04-12 09:54:03 +00001150# There might be people who depend on the old broken behavior: `$host'
1151# used to hold the argument of --host etc.
1152# FIXME: To remove some day.
1153build=$build_alias
1154host=$host_alias
1155target=$target_alias
Guido van Rossum627b2d71993-12-24 10:39:16 +00001156
Martin v. Löwis11437992002-04-12 09:54:03 +00001157# FIXME: To remove some day.
1158if test "x$host_alias" != x; then
1159 if test "x$build_alias" = x; then
1160 cross_compiling=maybe
Ronald Oussoren450d5612009-06-08 21:12:41 +00001161 echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
Martin v. Löwis11437992002-04-12 09:54:03 +00001162 If a cross compiler is detected then cross compile mode will be used." >&2
1163 elif test "x$build_alias" != "x$host_alias"; then
1164 cross_compiling=yes
1165 fi
1166fi
1167
1168ac_tool_prefix=
1169test -n "$host_alias" && ac_tool_prefix=$host_alias-
1170
1171test "$silent" = yes && exec 6>/dev/null
1172
Guido van Rossum627b2d71993-12-24 10:39:16 +00001173
Martin v. Löwiseba40652007-08-30 20:10:57 +00001174ac_pwd=`pwd` && test -n "$ac_pwd" &&
1175ac_ls_di=`ls -di .` &&
1176ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
Ronald Oussoren450d5612009-06-08 21:12:41 +00001177 { echo "$as_me: error: Working directory cannot be determined" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001178 { (exit 1); exit 1; }; }
1179test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
Ronald Oussoren450d5612009-06-08 21:12:41 +00001180 { echo "$as_me: error: pwd does not report name of working directory" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001181 { (exit 1); exit 1; }; }
1182
1183
Guido van Rossum627b2d71993-12-24 10:39:16 +00001184# Find the source files, if location was not specified.
1185if test -z "$srcdir"; then
Guido van Rossum7f43da71994-08-01 12:15:30 +00001186 ac_srcdir_defaulted=yes
Martin v. Löwiseba40652007-08-30 20:10:57 +00001187 # Try the directory containing this script, then the parent directory.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001188 ac_confdir=`$as_dirname -- "$0" ||
1189$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1190 X"$0" : 'X\(//\)[^/]' \| \
1191 X"$0" : 'X\(//\)$' \| \
1192 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
1193echo X"$0" |
Martin v. Löwiseba40652007-08-30 20:10:57 +00001194 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1195 s//\1/
1196 q
1197 }
1198 /^X\(\/\/\)[^/].*/{
1199 s//\1/
1200 q
1201 }
1202 /^X\(\/\/\)$/{
1203 s//\1/
1204 q
1205 }
1206 /^X\(\/\).*/{
1207 s//\1/
1208 q
1209 }
1210 s/.*/./; q'`
Guido van Rossum7f43da71994-08-01 12:15:30 +00001211 srcdir=$ac_confdir
Martin v. Löwiseba40652007-08-30 20:10:57 +00001212 if test ! -r "$srcdir/$ac_unique_file"; then
Guido van Rossum627b2d71993-12-24 10:39:16 +00001213 srcdir=..
1214 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001215else
1216 ac_srcdir_defaulted=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00001217fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001218if test ! -r "$srcdir/$ac_unique_file"; then
1219 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
Ronald Oussoren450d5612009-06-08 21:12:41 +00001220 { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +00001221 { (exit 1); exit 1; }; }
Brett Cannon19fab762007-06-02 03:02:29 +00001222fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001223ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1224ac_abs_confdir=`(
Ronald Oussoren450d5612009-06-08 21:12:41 +00001225 cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
Skip Montanaro89e975f2007-08-22 19:05:21 +00001226 { (exit 1); exit 1; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00001227 pwd)`
1228# When building in place, set srcdir=.
1229if test "$ac_abs_confdir" = "$ac_pwd"; then
1230 srcdir=.
1231fi
1232# Remove unnecessary trailing slashes from srcdir.
1233# Double slashes in file names in object file debugging info
1234# mess up M-x gdb in Emacs.
1235case $srcdir in
1236*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1237esac
1238for ac_var in $ac_precious_vars; do
1239 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1240 eval ac_env_${ac_var}_value=\$${ac_var}
1241 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1242 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1243done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001244
Martin v. Löwis11437992002-04-12 09:54:03 +00001245#
1246# Report the --help message.
1247#
1248if test "$ac_init_help" = "long"; then
1249 # Omit some internal or obsolete options to make the list less imposing.
1250 # This message is too long to be a string in the A/UX 3.1 sh.
1251 cat <<_ACEOF
Martin v. Löwis174440b2008-10-03 08:59:41 +00001252\`configure' configures python 2.7 to adapt to many kinds of systems.
Martin v. Löwis11437992002-04-12 09:54:03 +00001253
1254Usage: $0 [OPTION]... [VAR=VALUE]...
1255
1256To assign environment variables (e.g., CC, CFLAGS...), specify them as
1257VAR=VALUE. See below for descriptions of some of the useful variables.
1258
1259Defaults for the options are specified in brackets.
1260
1261Configuration:
1262 -h, --help display this help and exit
1263 --help=short display options specific to this package
1264 --help=recursive display the short help of all the included packages
1265 -V, --version display version information and exit
1266 -q, --quiet, --silent do not print \`checking...' messages
1267 --cache-file=FILE cache test results in FILE [disabled]
1268 -C, --config-cache alias for \`--cache-file=config.cache'
1269 -n, --no-create do not create output files
1270 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1271
Martin v. Löwis11437992002-04-12 09:54:03 +00001272Installation directories:
1273 --prefix=PREFIX install architecture-independent files in PREFIX
Ronald Oussoren450d5612009-06-08 21:12:41 +00001274 [$ac_default_prefix]
Martin v. Löwis11437992002-04-12 09:54:03 +00001275 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
Ronald Oussoren450d5612009-06-08 21:12:41 +00001276 [PREFIX]
Martin v. Löwis11437992002-04-12 09:54:03 +00001277
1278By default, \`make install' will install all the files in
1279\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1280an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1281for instance \`--prefix=\$HOME'.
1282
1283For better control, use the options below.
1284
1285Fine tuning of the installation directories:
Ronald Oussoren450d5612009-06-08 21:12:41 +00001286 --bindir=DIR user executables [EPREFIX/bin]
1287 --sbindir=DIR system admin executables [EPREFIX/sbin]
1288 --libexecdir=DIR program executables [EPREFIX/libexec]
1289 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1290 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1291 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1292 --libdir=DIR object code libraries [EPREFIX/lib]
1293 --includedir=DIR C header files [PREFIX/include]
1294 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1295 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1296 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1297 --infodir=DIR info documentation [DATAROOTDIR/info]
1298 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1299 --mandir=DIR man documentation [DATAROOTDIR/man]
1300 --docdir=DIR documentation root [DATAROOTDIR/doc/python]
1301 --htmldir=DIR html documentation [DOCDIR]
1302 --dvidir=DIR dvi documentation [DOCDIR]
1303 --pdfdir=DIR pdf documentation [DOCDIR]
1304 --psdir=DIR ps documentation [DOCDIR]
Martin v. Löwis11437992002-04-12 09:54:03 +00001305_ACEOF
1306
1307 cat <<\_ACEOF
1308_ACEOF
1309fi
1310
1311if test -n "$ac_init_help"; then
Martin v. Löwis88afe662002-10-26 13:47:44 +00001312 case $ac_init_help in
Martin v. Löwis174440b2008-10-03 08:59:41 +00001313 short | recursive ) echo "Configuration of python 2.7:";;
Martin v. Löwis88afe662002-10-26 13:47:44 +00001314 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00001315 cat <<\_ACEOF
1316
1317Optional Features:
1318 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1319 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
Brett Cannon91a1dec2008-02-13 19:15:44 +00001320 --enable-universalsdk[=SDKDIR]
Brett Cannon9a8bb0e2008-02-03 02:07:55 +00001321 Build against Mac OS X 10.4u SDK (ppc/i386)
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001322 --enable-framework[=INSTALLDIR]
1323 Build (MacOSX|Darwin) framework
1324 --enable-shared disable/enable building shared python library
Skip Montanaro56f6a4f2004-06-18 02:47:22 +00001325 --enable-profiling enable C-level code profiling
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001326 --enable-toolbox-glue disable/enable MacOSX glue code for extensions
1327 --enable-ipv6 Enable ipv6 (with ipv4) support
1328 --disable-ipv6 Disable ipv6 support
Mark Dickinsonefc82f72009-03-20 15:51:55 +00001329 --enable-big-digits[=BITS]
1330 use big digits for Python longs [BITS=30]
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001331 --enable-unicode[=ucs[24]]
1332 Enable Unicode strings (default is yes)
Martin v. Löwis11437992002-04-12 09:54:03 +00001333
1334Optional Packages:
1335 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1336 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001337 --with-universal-archs=ARCH
1338 select architectures for universal build ("32-bit",
1339 "64-bit" or "all")
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00001340 --with-framework-name=FRAMEWORK
1341 specify an alternate name of the framework built
1342 with --enable-framework
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001343 --without-gcc never use gcc
Martin v. Löwis0f48d982006-04-14 14:34:26 +00001344 --with-cxx-main=<compiler>
1345 compile main() and link python executable with C++
1346 compiler
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001347 --with-suffix=.exe set executable suffix
1348 --with-pydebug build with Py_DEBUG defined
1349 --with-libs='lib1 ...' link against additional libs
Martin v. Löwis9176fc12006-04-11 11:12:43 +00001350 --with-system-ffi build _ctypes module using an installed ffi library
Benjamin Peterson867475c2009-04-29 20:36:25 +00001351 --with-dbmliborder=db1:db2:...
1352 order to check db backends for dbm. Valid value is a
1353 colon separated string with the backend names
1354 `ndbm', `gdbm' and `bdb'.
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001355 --with-signal-module disable/enable signal module
1356 --with-dec-threads use DEC Alpha/OSF1 thread-safe libraries
1357 --with(out)-threads[=DIRECTORY]
1358 disable/enable thread support
1359 --with(out)-thread[=DIRECTORY]
1360 deprecated; use --with(out)-threads
1361 --with-pth use GNU pth threading libraries
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001362 --with(out)-doc-strings disable/enable documentation strings
Martin v. Löwisf30d60e2004-06-08 08:17:44 +00001363 --with(out)-tsc enable/disable timestamp counter profile
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001364 --with(out)-pymalloc disable/enable specialized mallocs
1365 --with-wctype-functions use wctype.h functions
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00001366 --with-fpectl enable SIGFPE catching
1367 --with-libm=STRING math library
1368 --with-libc=STRING C library
Martin v. Löwis11437992002-04-12 09:54:03 +00001369
1370Some influential environment variables:
1371 CC C compiler command
1372 CFLAGS C compiler flags
1373 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1374 nonstandard directory <lib dir>
Martin v. Löwiseba40652007-08-30 20:10:57 +00001375 LIBS libraries to pass to the linker, e.g. -l<library>
1376 CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1377 you have headers in a nonstandard directory <include dir>
Martin v. Löwis11437992002-04-12 09:54:03 +00001378 CPP C preprocessor
1379
1380Use these variables to override the choices made by `configure' or to help
1381it to find libraries and programs with nonstandard names/locations.
1382
Georg Brandl464432d2009-05-20 18:24:08 +00001383Report bugs to <http://bugs.python.org/>.
Martin v. Löwis11437992002-04-12 09:54:03 +00001384_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00001385ac_status=$?
Martin v. Löwis11437992002-04-12 09:54:03 +00001386fi
1387
1388if test "$ac_init_help" = "recursive"; then
1389 # If there are subdirs, report their specific --help.
Martin v. Löwis11437992002-04-12 09:54:03 +00001390 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
Ronald Oussoren450d5612009-06-08 21:12:41 +00001391 test -d "$ac_dir" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00001392 ac_builddir=.
1393
Martin v. Löwiseba40652007-08-30 20:10:57 +00001394case "$ac_dir" in
1395.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1396*)
Ronald Oussoren450d5612009-06-08 21:12:41 +00001397 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
Martin v. Löwiseba40652007-08-30 20:10:57 +00001398 # A ".." for each directory in $ac_dir_suffix.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001399 ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
Martin v. Löwiseba40652007-08-30 20:10:57 +00001400 case $ac_top_builddir_sub in
1401 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1402 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1403 esac ;;
1404esac
1405ac_abs_top_builddir=$ac_pwd
1406ac_abs_builddir=$ac_pwd$ac_dir_suffix
1407# for backward compatibility:
1408ac_top_builddir=$ac_top_build_prefix
Martin v. Löwis11437992002-04-12 09:54:03 +00001409
1410case $srcdir in
Martin v. Löwiseba40652007-08-30 20:10:57 +00001411 .) # We are building in place.
Martin v. Löwis11437992002-04-12 09:54:03 +00001412 ac_srcdir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001413 ac_top_srcdir=$ac_top_builddir_sub
1414 ac_abs_top_srcdir=$ac_pwd ;;
1415 [\\/]* | ?:[\\/]* ) # Absolute name.
Martin v. Löwis11437992002-04-12 09:54:03 +00001416 ac_srcdir=$srcdir$ac_dir_suffix;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001417 ac_top_srcdir=$srcdir
1418 ac_abs_top_srcdir=$srcdir ;;
1419 *) # Relative name.
1420 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1421 ac_top_srcdir=$ac_top_build_prefix$srcdir
1422 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001423esac
Martin v. Löwiseba40652007-08-30 20:10:57 +00001424ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
Skip Montanarof0d5f792004-08-15 14:08:23 +00001425
Martin v. Löwiseba40652007-08-30 20:10:57 +00001426 cd "$ac_dir" || { ac_status=$?; continue; }
1427 # Check for guested configure.
1428 if test -f "$ac_srcdir/configure.gnu"; then
1429 echo &&
1430 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1431 elif test -f "$ac_srcdir/configure"; then
1432 echo &&
1433 $SHELL "$ac_srcdir/configure" --help=recursive
Martin v. Löwis11437992002-04-12 09:54:03 +00001434 else
Ronald Oussoren450d5612009-06-08 21:12:41 +00001435 echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +00001436 fi || ac_status=$?
1437 cd "$ac_pwd" || { ac_status=$?; break; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001438 done
1439fi
1440
Martin v. Löwiseba40652007-08-30 20:10:57 +00001441test -n "$ac_init_help" && exit $ac_status
Martin v. Löwis11437992002-04-12 09:54:03 +00001442if $ac_init_version; then
1443 cat <<\_ACEOF
Martin v. Löwis174440b2008-10-03 08:59:41 +00001444python configure 2.7
Ronald Oussoren450d5612009-06-08 21:12:41 +00001445generated by GNU Autoconf 2.61
Martin v. Löwis11437992002-04-12 09:54:03 +00001446
Martin v. Löwiseba40652007-08-30 20:10:57 +00001447Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
Ronald Oussoren450d5612009-06-08 21:12:41 +000014482002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
Martin v. Löwis11437992002-04-12 09:54:03 +00001449This configure script is free software; the Free Software Foundation
1450gives unlimited permission to copy, distribute and modify it.
1451_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00001452 exit
Martin v. Löwis11437992002-04-12 09:54:03 +00001453fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001454cat >config.log <<_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +00001455This file contains any messages produced by compilers while
1456running configure, to aid debugging if configure makes a mistake.
1457
Martin v. Löwis174440b2008-10-03 08:59:41 +00001458It was created by python $as_me 2.7, which was
Ronald Oussoren450d5612009-06-08 21:12:41 +00001459generated by GNU Autoconf 2.61. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +00001460
1461 $ $0 $@
1462
1463_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00001464exec 5>>config.log
Martin v. Löwis11437992002-04-12 09:54:03 +00001465{
1466cat <<_ASUNAME
1467## --------- ##
1468## Platform. ##
1469## --------- ##
1470
1471hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1472uname -m = `(uname -m) 2>/dev/null || echo unknown`
1473uname -r = `(uname -r) 2>/dev/null || echo unknown`
1474uname -s = `(uname -s) 2>/dev/null || echo unknown`
1475uname -v = `(uname -v) 2>/dev/null || echo unknown`
1476
1477/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1478/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1479
1480/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1481/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1482/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
Martin v. Löwiseba40652007-08-30 20:10:57 +00001483/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
Martin v. Löwis11437992002-04-12 09:54:03 +00001484/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1485/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1486/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1487
1488_ASUNAME
1489
1490as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1491for as_dir in $PATH
1492do
1493 IFS=$as_save_IFS
1494 test -z "$as_dir" && as_dir=.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001495 echo "PATH: $as_dir"
Martin v. Löwis11437992002-04-12 09:54:03 +00001496done
Martin v. Löwiseba40652007-08-30 20:10:57 +00001497IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00001498
1499} >&5
1500
1501cat >&5 <<_ACEOF
1502
1503
1504## ----------- ##
1505## Core tests. ##
1506## ----------- ##
1507
1508_ACEOF
1509
1510
1511# Keep a trace of the command line.
1512# Strip out --no-create and --no-recursion so they do not pile up.
Skip Montanaro6dead952003-09-25 14:50:04 +00001513# Strip out --silent because we don't want to record it for future runs.
Martin v. Löwis11437992002-04-12 09:54:03 +00001514# Also quote any args containing shell meta-characters.
Skip Montanaro6dead952003-09-25 14:50:04 +00001515# Make two passes to allow for proper duplicate-argument suppression.
Martin v. Löwis11437992002-04-12 09:54:03 +00001516ac_configure_args=
Skip Montanaro6dead952003-09-25 14:50:04 +00001517ac_configure_args0=
1518ac_configure_args1=
Skip Montanaro6dead952003-09-25 14:50:04 +00001519ac_must_keep_next=false
1520for ac_pass in 1 2
Martin v. Löwis11437992002-04-12 09:54:03 +00001521do
Skip Montanaro6dead952003-09-25 14:50:04 +00001522 for ac_arg
1523 do
1524 case $ac_arg in
1525 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1526 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1527 | -silent | --silent | --silen | --sile | --sil)
1528 continue ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001529 *\'*)
Ronald Oussoren450d5612009-06-08 21:12:41 +00001530 ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00001531 esac
1532 case $ac_pass in
1533 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1534 2)
1535 ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1536 if test $ac_must_keep_next = true; then
Skip Montanarof0d5f792004-08-15 14:08:23 +00001537 ac_must_keep_next=false # Got value, back to normal.
Skip Montanaro6dead952003-09-25 14:50:04 +00001538 else
Skip Montanarof0d5f792004-08-15 14:08:23 +00001539 case $ac_arg in
1540 *=* | --config-cache | -C | -disable-* | --disable-* \
1541 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1542 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1543 | -with-* | --with-* | -without-* | --without-* | --x)
1544 case "$ac_configure_args0 " in
1545 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1546 esac
1547 ;;
1548 -* ) ac_must_keep_next=true ;;
1549 esac
Skip Montanaro6dead952003-09-25 14:50:04 +00001550 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00001551 ac_configure_args="$ac_configure_args '$ac_arg'"
Skip Montanaro6dead952003-09-25 14:50:04 +00001552 ;;
1553 esac
1554 done
Martin v. Löwis11437992002-04-12 09:54:03 +00001555done
Skip Montanaro6dead952003-09-25 14:50:04 +00001556$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1557$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
Martin v. Löwis11437992002-04-12 09:54:03 +00001558
1559# When interrupted or exit'd, cleanup temporary files, and complete
1560# config.log. We remove comments because anyway the quotes in there
1561# would cause problems or look ugly.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001562# WARNING: Use '\'' to represent an apostrophe within the trap.
1563# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
Martin v. Löwis11437992002-04-12 09:54:03 +00001564trap 'exit_status=$?
1565 # Save into config.log some information that might help in debugging.
1566 {
1567 echo
Skip Montanaro6dead952003-09-25 14:50:04 +00001568
Martin v. Löwis11437992002-04-12 09:54:03 +00001569 cat <<\_ASBOX
1570## ---------------- ##
1571## Cache variables. ##
1572## ---------------- ##
1573_ASBOX
1574 echo
1575 # The following way of writing the cache mishandles newlines in values,
Martin v. Löwiseba40652007-08-30 20:10:57 +00001576(
1577 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1578 eval ac_val=\$$ac_var
1579 case $ac_val in #(
1580 *${as_nl}*)
1581 case $ac_var in #(
Ronald Oussoren450d5612009-06-08 21:12:41 +00001582 *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
1583echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001584 esac
1585 case $ac_var in #(
1586 _ | IFS | as_nl) ;; #(
1587 *) $as_unset $ac_var ;;
1588 esac ;;
1589 esac
1590 done
Martin v. Löwis11437992002-04-12 09:54:03 +00001591 (set) 2>&1 |
Martin v. Löwiseba40652007-08-30 20:10:57 +00001592 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1593 *${as_nl}ac_space=\ *)
Martin v. Löwis11437992002-04-12 09:54:03 +00001594 sed -n \
Martin v. Löwiseba40652007-08-30 20:10:57 +00001595 "s/'\''/'\''\\\\'\'''\''/g;
1596 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1597 ;; #(
Skip Montanaro89e975f2007-08-22 19:05:21 +00001598 *)
Martin v. Löwiseba40652007-08-30 20:10:57 +00001599 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
Skip Montanaro89e975f2007-08-22 19:05:21 +00001600 ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001601 esac |
1602 sort
1603)
Martin v. Löwis11437992002-04-12 09:54:03 +00001604 echo
Skip Montanaro6dead952003-09-25 14:50:04 +00001605
1606 cat <<\_ASBOX
1607## ----------------- ##
1608## Output variables. ##
1609## ----------------- ##
1610_ASBOX
1611 echo
1612 for ac_var in $ac_subst_vars
1613 do
Martin v. Löwiseba40652007-08-30 20:10:57 +00001614 eval ac_val=\$$ac_var
1615 case $ac_val in
Ronald Oussoren450d5612009-06-08 21:12:41 +00001616 *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001617 esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00001618 echo "$ac_var='\''$ac_val'\''"
Skip Montanaro6dead952003-09-25 14:50:04 +00001619 done | sort
1620 echo
1621
1622 if test -n "$ac_subst_files"; then
1623 cat <<\_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00001624## ------------------- ##
1625## File substitutions. ##
1626## ------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00001627_ASBOX
1628 echo
1629 for ac_var in $ac_subst_files
1630 do
Martin v. Löwiseba40652007-08-30 20:10:57 +00001631 eval ac_val=\$$ac_var
1632 case $ac_val in
Ronald Oussoren450d5612009-06-08 21:12:41 +00001633 *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00001634 esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00001635 echo "$ac_var='\''$ac_val'\''"
Skip Montanaro6dead952003-09-25 14:50:04 +00001636 done | sort
1637 echo
1638 fi
1639
Martin v. Löwis11437992002-04-12 09:54:03 +00001640 if test -s confdefs.h; then
1641 cat <<\_ASBOX
1642## ----------- ##
1643## confdefs.h. ##
1644## ----------- ##
1645_ASBOX
1646 echo
Martin v. Löwiseba40652007-08-30 20:10:57 +00001647 cat confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00001648 echo
1649 fi
1650 test "$ac_signal" != 0 &&
Ronald Oussoren450d5612009-06-08 21:12:41 +00001651 echo "$as_me: caught signal $ac_signal"
1652 echo "$as_me: exit $exit_status"
Martin v. Löwis11437992002-04-12 09:54:03 +00001653 } >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00001654 rm -f core *.core core.conftest.* &&
1655 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
Martin v. Löwis11437992002-04-12 09:54:03 +00001656 exit $exit_status
Martin v. Löwiseba40652007-08-30 20:10:57 +00001657' 0
Martin v. Löwis11437992002-04-12 09:54:03 +00001658for ac_signal in 1 2 13 15; do
1659 trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1660done
1661ac_signal=0
1662
1663# confdefs.h avoids OS command line length limits that DEFS can exceed.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001664rm -f -r conftest* confdefs.h
Martin v. Löwis11437992002-04-12 09:54:03 +00001665
1666# Predefined preprocessor variables.
1667
1668cat >>confdefs.h <<_ACEOF
1669#define PACKAGE_NAME "$PACKAGE_NAME"
1670_ACEOF
1671
1672
1673cat >>confdefs.h <<_ACEOF
1674#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1675_ACEOF
1676
1677
1678cat >>confdefs.h <<_ACEOF
1679#define PACKAGE_VERSION "$PACKAGE_VERSION"
1680_ACEOF
1681
1682
1683cat >>confdefs.h <<_ACEOF
1684#define PACKAGE_STRING "$PACKAGE_STRING"
1685_ACEOF
1686
1687
1688cat >>confdefs.h <<_ACEOF
1689#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1690_ACEOF
1691
1692
1693# Let the site file select an alternate cache file if it wants to.
Ronald Oussoren450d5612009-06-08 21:12:41 +00001694# Prefer explicitly selected file to automatically selected ones.
Martin v. Löwiseba40652007-08-30 20:10:57 +00001695if test -n "$CONFIG_SITE"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00001696 set x "$CONFIG_SITE"
Martin v. Löwiseba40652007-08-30 20:10:57 +00001697elif test "x$prefix" != xNONE; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00001698 set x "$prefix/share/config.site" "$prefix/etc/config.site"
Martin v. Löwiseba40652007-08-30 20:10:57 +00001699else
Ronald Oussoren450d5612009-06-08 21:12:41 +00001700 set x "$ac_default_prefix/share/config.site" \
1701 "$ac_default_prefix/etc/config.site"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001702fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00001703shift
1704for ac_site_file
Martin v. Löwiseba40652007-08-30 20:10:57 +00001705do
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001706 if test -r "$ac_site_file"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00001707 { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1708echo "$as_me: loading site script $ac_site_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001709 sed 's/^/| /' "$ac_site_file" >&5
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001710 . "$ac_site_file"
1711 fi
1712done
1713
1714if test -r "$cache_file"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00001715 # Some versions of bash will fail to source /dev/null (special
1716 # files actually), so we avoid doing that.
1717 if test -f "$cache_file"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00001718 { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1719echo "$as_me: loading cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001720 case $cache_file in
Martin v. Löwiseba40652007-08-30 20:10:57 +00001721 [\\/]* | ?:[\\/]* ) . "$cache_file";;
1722 *) . "./$cache_file";;
Martin v. Löwis11437992002-04-12 09:54:03 +00001723 esac
1724 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001725else
Ronald Oussoren450d5612009-06-08 21:12:41 +00001726 { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1727echo "$as_me: creating cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001728 >$cache_file
1729fi
1730
1731# Check that the precious variables saved in the cache have kept the same
1732# value.
1733ac_cache_corrupted=false
Martin v. Löwiseba40652007-08-30 20:10:57 +00001734for ac_var in $ac_precious_vars; do
Martin v. Löwis11437992002-04-12 09:54:03 +00001735 eval ac_old_set=\$ac_cv_env_${ac_var}_set
1736 eval ac_new_set=\$ac_env_${ac_var}_set
Martin v. Löwiseba40652007-08-30 20:10:57 +00001737 eval ac_old_val=\$ac_cv_env_${ac_var}_value
1738 eval ac_new_val=\$ac_env_${ac_var}_value
Martin v. Löwis11437992002-04-12 09:54:03 +00001739 case $ac_old_set,$ac_new_set in
1740 set,)
Ronald Oussoren450d5612009-06-08 21:12:41 +00001741 { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1742echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001743 ac_cache_corrupted=: ;;
1744 ,set)
Ronald Oussoren450d5612009-06-08 21:12:41 +00001745 { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1746echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001747 ac_cache_corrupted=: ;;
1748 ,);;
1749 *)
1750 if test "x$ac_old_val" != "x$ac_new_val"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00001751 { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1752echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1753 { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
1754echo "$as_me: former value: $ac_old_val" >&2;}
1755 { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
1756echo "$as_me: current value: $ac_new_val" >&2;}
1757 ac_cache_corrupted=:
Martin v. Löwis11437992002-04-12 09:54:03 +00001758 fi;;
1759 esac
1760 # Pass precious variables to config.status.
1761 if test "$ac_new_set" = set; then
1762 case $ac_new_val in
Ronald Oussoren450d5612009-06-08 21:12:41 +00001763 *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00001764 *) ac_arg=$ac_var=$ac_new_val ;;
1765 esac
1766 case " $ac_configure_args " in
1767 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
1768 *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1769 esac
1770 fi
1771done
1772if $ac_cache_corrupted; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00001773 { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1774echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1775 { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1776echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00001777 { (exit 1); exit 1; }; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001778fi
1779
Martin v. Löwiseba40652007-08-30 20:10:57 +00001780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
Guido van Rossum7f43da71994-08-01 12:15:30 +00001804ac_ext=c
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001805ac_cpp='$CPP $CPPFLAGS'
Martin v. Löwis11437992002-04-12 09:54:03 +00001806ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1807ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1808ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00001809
Guido van Rossum627b2d71993-12-24 10:39:16 +00001810
Michael W. Hudson54241132001-12-07 15:38:26 +00001811
Martin v. Löwiseba40652007-08-30 20:10:57 +00001812ac_config_headers="$ac_config_headers pyconfig.h"
Martin v. Löwis11437992002-04-12 09:54:03 +00001813
1814
Martin v. Löwis11437992002-04-12 09:54:03 +00001815
Georg Brandlbcd64a32009-03-31 21:45:18 +00001816if test "$prefix" != "/"; then
1817 prefix=`echo "$prefix" | sed -e 's/\/$//g'`
1818fi
1819
1820
Martin v. Löwis11437992002-04-12 09:54:03 +00001821
1822
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001823
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001824
Martin v. Löwis8316feb2003-06-14 07:48:07 +00001825# We don't use PACKAGE_ variables, and they cause conflicts
1826# with other autoconf-based packages that include Python.h
1827grep -v 'define PACKAGE_' <confdefs.h >confdefs.h.new
1828rm confdefs.h
1829mv confdefs.h.new confdefs.h
1830
Martin v. Löwisbddf5a52002-11-11 13:37:28 +00001831
Martin v. Löwis174440b2008-10-03 08:59:41 +00001832VERSION=2.7
Guido van Rossum1fd74a71997-07-19 19:36:02 +00001833
Martin v. Löwis1142de32002-03-29 16:28:31 +00001834
1835SOVERSION=1.0
1836
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001837# The later defininition of _XOPEN_SOURCE disables certain features
1838# on Linux, so we need _GNU_SOURCE to re-enable them (makedev, tm_zone).
1839
1840cat >>confdefs.h <<\_ACEOF
1841#define _GNU_SOURCE 1
1842_ACEOF
1843
1844
Martin v. Löwisbcd93962003-05-03 10:32:18 +00001845# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1846# certain features on NetBSD, so we need _NETBSD_SOURCE to re-enable
1847# them.
1848
1849cat >>confdefs.h <<\_ACEOF
1850#define _NETBSD_SOURCE 1
1851_ACEOF
1852
1853
Andrew MacIntyreabccf412003-07-02 13:53:25 +00001854# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1855# certain features on FreeBSD, so we need __BSD_VISIBLE to re-enable
1856# them.
1857
1858cat >>confdefs.h <<\_ACEOF
1859#define __BSD_VISIBLE 1
1860_ACEOF
1861
1862
Martin v. Löwisd6320502004-08-12 13:45:08 +00001863# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1864# u_int on Irix 5.3. Defining _BSD_TYPES brings it back.
1865
1866cat >>confdefs.h <<\_ACEOF
1867#define _BSD_TYPES 1
1868_ACEOF
1869
1870
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001871# The later defininition of _XOPEN_SOURCE and _POSIX_C_SOURCE disables
1872# certain features on Mac OS X, so we need _DARWIN_C_SOURCE to re-enable
1873# them.
1874
1875cat >>confdefs.h <<\_ACEOF
1876#define _DARWIN_C_SOURCE 1
1877_ACEOF
1878
1879
1880
Martin v. Löwis35195ad2002-11-11 13:26:51 +00001881define_xopen_source=yes
Martin v. Löwis6f18a3c2002-07-20 08:51:52 +00001882
Neil Schemenauer4edbc2a2001-03-22 00:34:03 +00001883# Arguments passed to configure.
1884
1885CONFIG_ARGS="$ac_configure_args"
1886
Martin v. Löwiseba40652007-08-30 20:10:57 +00001887# Check whether --enable-universalsdk was given.
Ronald Oussoren988117f2006-04-29 11:31:35 +00001888if test "${enable_universalsdk+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00001889 enableval=$enable_universalsdk;
Ronald Oussoren988117f2006-04-29 11:31:35 +00001890 case $enableval in
1891 yes)
1892 enableval=/Developer/SDKs/MacOSX10.4u.sdk
1893 ;;
1894 esac
1895 case $enableval in
1896 no)
1897 UNIVERSALSDK=
1898 enable_universalsdk=
1899 ;;
1900 *)
1901 UNIVERSALSDK=$enableval
1902 ;;
1903 esac
1904
1905else
1906
1907 UNIVERSALSDK=
1908 enable_universalsdk=
1909
Martin v. Löwiseba40652007-08-30 20:10:57 +00001910fi
Ronald Oussoren988117f2006-04-29 11:31:35 +00001911
1912
Martin v. Löwiseba40652007-08-30 20:10:57 +00001913
Benjamin Peterson0e6ea5d2008-07-16 20:17:04 +00001914ARCH_RUN_32BIT=
1915
1916
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001917UNIVERSAL_ARCHS="32-bit"
Ronald Oussoren450d5612009-06-08 21:12:41 +00001918{ echo "$as_me:$LINENO: checking for --with-universal-archs" >&5
1919echo $ECHO_N "checking for --with-universal-archs... $ECHO_C" >&6; }
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001920
1921# Check whether --with-universal-archs was given.
1922if test "${with_universal_archs+set}" = set; then
1923 withval=$with_universal_archs;
Ronald Oussoren450d5612009-06-08 21:12:41 +00001924 { echo "$as_me:$LINENO: result: $withval" >&5
1925echo "${ECHO_T}$withval" >&6; }
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001926 UNIVERSAL_ARCHS="$withval"
1927
1928else
1929
Ronald Oussoren450d5612009-06-08 21:12:41 +00001930 { echo "$as_me:$LINENO: result: 32-bit" >&5
1931echo "${ECHO_T}32-bit" >&6; }
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001932
1933fi
1934
1935
1936
1937
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00001938
1939# Check whether --with-framework-name was given.
1940if test "${with_framework_name+set}" = set; then
1941 withval=$with_framework_name;
1942 PYTHONFRAMEWORK=${withval}
1943 PYTHONFRAMEWORKDIR=${withval}.framework
1944 PYTHONFRAMEWORKIDENTIFIER=org.python.`echo $withval | tr 'A-Z' 'a-z'`
1945
1946else
1947
1948 PYTHONFRAMEWORK=Python
1949 PYTHONFRAMEWORKDIR=Python.framework
1950 PYTHONFRAMEWORKIDENTIFIER=org.python.python
1951
1952fi
1953
Martin v. Löwiseba40652007-08-30 20:10:57 +00001954# Check whether --enable-framework was given.
Jack Jansene578a632001-08-15 01:27:14 +00001955if test "${enable_framework+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00001956 enableval=$enable_framework;
Jack Jansene578a632001-08-15 01:27:14 +00001957 case $enableval in
Martin v. Löwis11437992002-04-12 09:54:03 +00001958 yes)
Jack Jansene578a632001-08-15 01:27:14 +00001959 enableval=/Library/Frameworks
Jack Jansen127e56e2001-09-11 14:41:54 +00001960 esac
1961 case $enableval in
1962 no)
1963 PYTHONFRAMEWORK=
1964 PYTHONFRAMEWORKDIR=no-framework
1965 PYTHONFRAMEWORKPREFIX=
1966 PYTHONFRAMEWORKINSTALLDIR=
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00001967 FRAMEWORKINSTALLFIRST=
1968 FRAMEWORKINSTALLLAST=
Ronald Oussoren5b787322006-06-06 19:50:24 +00001969 FRAMEWORKALTINSTALLFIRST=
1970 FRAMEWORKALTINSTALLLAST=
Ronald Oussoren2db3a8f2006-06-07 19:06:01 +00001971 if test "x${prefix}" = "xNONE"; then
1972 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
1973 else
1974 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
1975 fi
Jack Jansen127e56e2001-09-11 14:41:54 +00001976 enable_framework=
Jack Jansene578a632001-08-15 01:27:14 +00001977 ;;
1978 *)
1979 PYTHONFRAMEWORKPREFIX=$enableval
Jack Jansen127e56e2001-09-11 14:41:54 +00001980 PYTHONFRAMEWORKINSTALLDIR=$PYTHONFRAMEWORKPREFIX/$PYTHONFRAMEWORKDIR
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00001981 FRAMEWORKINSTALLFIRST="frameworkinstallstructure"
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001982 FRAMEWORKALTINSTALLFIRST="frameworkinstallstructure bininstall maninstall"
1983 if test "$UNIVERSAL_ARCHS" = "all"
1984 then
1985 FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps4way frameworkinstallunixtools4way"
Ronald Oussorenbb8cb0e2009-03-30 17:53:39 +00001986 FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps4way frameworkaltinstallunixtools4way"
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001987 else
Ronald Oussorenbb8cb0e2009-03-30 17:53:39 +00001988 FRAMEWORKINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools"
Ronald Oussoren5640ce22008-06-05 12:58:24 +00001989 FRAMEWORKALTINSTALLLAST="frameworkinstallmaclib frameworkinstallapps frameworkaltinstallunixtools"
1990 fi
1991
Ronald Oussoren2db3a8f2006-06-07 19:06:01 +00001992 if test "x${prefix}" = "xNONE" ; then
1993 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
1994 else
1995 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
1996 fi
Jack Jansen127e56e2001-09-11 14:41:54 +00001997 prefix=$PYTHONFRAMEWORKINSTALLDIR/Versions/$VERSION
Ronald Oussoren836b0392006-05-14 19:56:34 +00001998
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00001999 # Add files for Mac specific code to the list of output
Ronald Oussoren836b0392006-05-14 19:56:34 +00002000 # files:
Martin v. Löwiseba40652007-08-30 20:10:57 +00002001 ac_config_files="$ac_config_files Mac/Makefile"
Ronald Oussoren836b0392006-05-14 19:56:34 +00002002
Martin v. Löwiseba40652007-08-30 20:10:57 +00002003 ac_config_files="$ac_config_files Mac/PythonLauncher/Makefile"
Ronald Oussoren836b0392006-05-14 19:56:34 +00002004
Martin v. Löwiseba40652007-08-30 20:10:57 +00002005 ac_config_files="$ac_config_files Mac/IDLE/Makefile"
Ronald Oussoren836b0392006-05-14 19:56:34 +00002006
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00002007 ac_config_files="$ac_config_files Mac/Resources/framework/Info.plist"
2008
2009 ac_config_files="$ac_config_files Mac/Resources/app/Info.plist"
2010
Jack Jansene578a632001-08-15 01:27:14 +00002011 esac
Martin v. Löwis11437992002-04-12 09:54:03 +00002012
Guido van Rossum563e7081996-09-10 18:20:48 +00002013else
Martin v. Löwis11437992002-04-12 09:54:03 +00002014
Jack Jansene578a632001-08-15 01:27:14 +00002015 PYTHONFRAMEWORK=
Jack Jansen127e56e2001-09-11 14:41:54 +00002016 PYTHONFRAMEWORKDIR=no-framework
Jack Jansene578a632001-08-15 01:27:14 +00002017 PYTHONFRAMEWORKPREFIX=
2018 PYTHONFRAMEWORKINSTALLDIR=
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00002019 FRAMEWORKINSTALLFIRST=
2020 FRAMEWORKINSTALLLAST=
Ronald Oussoren5b787322006-06-06 19:50:24 +00002021 FRAMEWORKALTINSTALLFIRST=
2022 FRAMEWORKALTINSTALLLAST=
Ronald Oussoren2db3a8f2006-06-07 19:06:01 +00002023 if test "x${prefix}" = "xNONE" ; then
2024 FRAMEWORKUNIXTOOLSPREFIX="${ac_default_prefix}"
2025 else
2026 FRAMEWORKUNIXTOOLSPREFIX="${prefix}"
2027 fi
Jack Jansene578a632001-08-15 01:27:14 +00002028 enable_framework=
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002029
Ronald Oussoren5640ce22008-06-05 12:58:24 +00002030 if test "$UNIVERSAL_ARCHS" = "all"
2031 then
2032 FRAMEWORKINSTALLLAST=update4wayuniversal
2033 FRAMEWORKALTINSTALLLAST=update4wayuniversal
2034 fi
2035
Martin v. Löwiseba40652007-08-30 20:10:57 +00002036fi
2037
Michael W. Hudson54241132001-12-07 15:38:26 +00002038
2039
2040
2041
Jack Jansene578a632001-08-15 01:27:14 +00002042
Ronald Oussoren567a8ff2006-05-26 11:43:26 +00002043
2044
Ronald Oussoren5b787322006-06-06 19:50:24 +00002045
2046
2047
Ronald Oussoren580c7fe2008-05-02 19:45:11 +00002048
Jack Jansene578a632001-08-15 01:27:14 +00002049##AC_ARG_WITH(dyld,
Martin v. Löwis3e2c6322002-10-29 10:07:43 +00002050## AC_HELP_STRING(--with-dyld,
2051## Use (OpenStep|Rhapsody) dynamic linker))
Jack Jansene578a632001-08-15 01:27:14 +00002052##
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002053# Set name for machine-dependent library files
2054
Ronald Oussoren450d5612009-06-08 21:12:41 +00002055{ echo "$as_me:$LINENO: checking MACHDEP" >&5
2056echo $ECHO_N "checking MACHDEP... $ECHO_C" >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002057if test -z "$MACHDEP"
2058then
Guido van Rossum563e7081996-09-10 18:20:48 +00002059 ac_sys_system=`uname -s`
Martin v. Löwis21ee4092002-09-30 16:19:48 +00002060 if test "$ac_sys_system" = "AIX" -o "$ac_sys_system" = "Monterey64" \
2061 -o "$ac_sys_system" = "UnixWare" -o "$ac_sys_system" = "OpenUNIX"; then
Guido van Rossum563e7081996-09-10 18:20:48 +00002062 ac_sys_release=`uname -v`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002063 else
Guido van Rossum563e7081996-09-10 18:20:48 +00002064 ac_sys_release=`uname -r`
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002065 fi
Guido van Rossum563e7081996-09-10 18:20:48 +00002066 ac_md_system=`echo $ac_sys_system |
2067 tr -d '/ ' | tr '[A-Z]' '[a-z]'`
2068 ac_md_release=`echo $ac_sys_release |
Guido van Rossum67b26592001-10-20 14:21:45 +00002069 tr -d '/ ' | sed 's/^[A-Z]\.//' | sed 's/\..*//'`
Guido van Rossumb97ef171997-09-28 05:44:03 +00002070 MACHDEP="$ac_md_system$ac_md_release"
Guido van Rossum563e7081996-09-10 18:20:48 +00002071
Guido van Rossum07397971997-04-29 21:49:50 +00002072 case $MACHDEP in
Andrew M. Kuchling5a3e4cb2001-07-20 19:29:04 +00002073 cygwin*) MACHDEP="cygwin";;
Jack Jansen8a97f4a2001-12-05 23:27:32 +00002074 darwin*) MACHDEP="darwin";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +00002075 atheos*) MACHDEP="atheos";;
Martin v. Löwisf3322282003-07-13 09:46:13 +00002076 irix646) MACHDEP="irix6";;
Guido van Rossumb97ef171997-09-28 05:44:03 +00002077 '') MACHDEP="unknown";;
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002078 esac
2079fi
Guido van Rossum91922671997-10-09 20:24:13 +00002080
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002081# Some systems cannot stand _XOPEN_SOURCE being defined at all; they
2082# disable features if it is defined, without any means to access these
2083# features as extensions. For these systems, we skip the definition of
2084# _XOPEN_SOURCE. Before adding a system to the list to gain access to
2085# some feature, make sure there is no alternative way to access this
2086# feature. Also, when using wildcards, make sure you have verified the
2087# need for not defining _XOPEN_SOURCE on all systems matching the
2088# wildcard, and that the wildcard does not include future systems
2089# (which may remove their limitations).
2090case $ac_sys_system/$ac_sys_release in
2091 # On OpenBSD, select(2) is not available if _XOPEN_SOURCE is defined,
2092 # even though select is a POSIX function. Reported by J. Ribbens.
Martin v. Löwis76bafc62003-10-03 13:47:44 +00002093 # Reconfirmed for OpenBSD 3.3 by Zachary Hamm, for 3.4 by Jason Ish.
Gregory P. Smithcc023f12008-09-07 05:15:58 +00002094 OpenBSD/2.* | OpenBSD/3.[0123456789] | OpenBSD/4.[0123])
Martin v. Löwiscb78de62007-12-29 18:49:21 +00002095 define_xopen_source=no
2096 # OpenBSD undoes our definition of __BSD_VISIBLE if _XOPEN_SOURCE is
2097 # also defined. This can be overridden by defining _BSD_SOURCE
2098 # As this has a different meaning on Linux, only define it on OpenBSD
2099
2100cat >>confdefs.h <<\_ACEOF
2101#define _BSD_SOURCE 1
2102_ACEOF
2103
2104 ;;
Martin v. Löwis4d542ec2006-11-25 15:39:19 +00002105 # Defining _XOPEN_SOURCE on NetBSD version prior to the introduction of
2106 # _NETBSD_SOURCE disables certain features (eg. setgroups). Reported by
2107 # Marc Recht
Benjamin Petersoneac68f42008-11-16 17:54:55 +00002108 NetBSD/1.5 | NetBSD/1.5.* | NetBSD/1.6 | NetBSD/1.6.* | NetBSD/1.6[A-S])
Martin v. Löwis4d542ec2006-11-25 15:39:19 +00002109 define_xopen_source=no;;
Martin v. Löwisa9d71422003-03-28 18:43:31 +00002110 # On Solaris 2.6, sys/wait.h is inconsistent in the usage
2111 # of union __?sigval. Reported by Stuart Bishop.
2112 SunOS/5.6)
2113 define_xopen_source=no;;
Martin v. Löwisc2409b42003-05-11 05:53:41 +00002114 # On UnixWare 7, u_long is never defined with _XOPEN_SOURCE,
2115 # but used in /usr/include/netinet/tcp.h. Reported by Tim Rice.
Jack Jansen6b08a402004-06-03 12:41:45 +00002116 # Reconfirmed for 7.1.4 by Martin v. Loewis.
Martin v. Löwis253d1f42004-05-07 19:14:14 +00002117 OpenUNIX/8.0.0| UnixWare/7.1.[0-4])
Martin v. Löwisc2409b42003-05-11 05:53:41 +00002118 define_xopen_source=no;;
2119 # On OpenServer 5, u_short is never defined with _XOPEN_SOURCE,
Martin v. Löwis53e73c32003-05-05 05:13:18 +00002120 # but used in struct sockaddr.sa_family. Reported by Tim Rice.
Martin v. Löwisc2409b42003-05-11 05:53:41 +00002121 SCO_SV/3.2)
Martin v. Löwis53e73c32003-05-05 05:13:18 +00002122 define_xopen_source=no;;
Martin v. Löwisbb86d832008-11-04 20:40:09 +00002123 # On FreeBSD 4, the math functions C89 does not cover are never defined
2124 # with _XOPEN_SOURCE and __BSD_VISIBLE does not re-enable them.
2125 FreeBSD/4.*)
2126 define_xopen_source=no;;
2127 # On MacOS X 10.2, a bug in ncurses.h means that it craps out if
2128 # _XOPEN_EXTENDED_SOURCE is defined. Apparently, this is fixed in 10.3, which
2129 # identifies itself as Darwin/7.*
2130 # On Mac OS X 10.4, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
2131 # disables platform specific features beyond repair.
2132 # On Mac OS X 10.3, defining _POSIX_C_SOURCE or _XOPEN_SOURCE
2133 # has no effect, don't bother defining them
2134 Darwin/[6789].*)
Anthony Baxter6169c6b2003-10-04 07:46:23 +00002135 define_xopen_source=no;;
Trent Mickc5625ba2004-08-25 23:59:39 +00002136 # On AIX 4 and 5.1, mbstate_t is defined only when _XOPEN_SOURCE == 500 but
2137 # used in wcsnrtombs() and mbsnrtowcs() even if _XOPEN_SOURCE is not defined
2138 # or has another value. By not (re)defining it, the defaults come in place.
Martin v. Löwisc19c5a62003-11-18 20:00:44 +00002139 AIX/4)
2140 define_xopen_source=no;;
Trent Mickc5625ba2004-08-25 23:59:39 +00002141 AIX/5)
2142 if test `uname -r` -eq 1; then
2143 define_xopen_source=no
2144 fi
2145 ;;
Martin v. Löwis8c255e42008-05-23 15:06:50 +00002146 # On QNX 6.3.2, defining _XOPEN_SOURCE prevents netdb.h from
2147 # defining NI_NUMERICHOST.
2148 QNX/6.3.2)
2149 define_xopen_source=no
2150 ;;
Martin v. Löwisa0588362006-04-04 06:03:50 +00002151
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002152esac
2153
2154if test $define_xopen_source = yes
2155then
Skip Montanarof0d5f792004-08-15 14:08:23 +00002156 # On Solaris w/ g++ it appears that _XOPEN_SOURCE has to be
2157 # defined precisely as g++ defines it
Martin v. Löwis7dece662005-11-26 11:38:24 +00002158 # Furthermore, on Solaris 10, XPG6 requires the use of a C99
2159 # compiler
Skip Montanarof0d5f792004-08-15 14:08:23 +00002160 case $ac_sys_system/$ac_sys_release in
Martin v. Löwis7dece662005-11-26 11:38:24 +00002161 SunOS/5.8|SunOS/5.9|SunOS/5.10)
Skip Montanarof0d5f792004-08-15 14:08:23 +00002162
2163cat >>confdefs.h <<\_ACEOF
2164#define _XOPEN_SOURCE 500
2165_ACEOF
2166
2167 ;;
2168 *)
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002169
2170cat >>confdefs.h <<\_ACEOF
2171#define _XOPEN_SOURCE 600
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002172_ACEOF
2173
Skip Montanarof0d5f792004-08-15 14:08:23 +00002174 ;;
2175 esac
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002176
2177 # On Tru64 Unix 4.0F, defining _XOPEN_SOURCE also requires
2178 # definition of _XOPEN_SOURCE_EXTENDED and _POSIX_C_SOURCE, or else
2179 # several APIs are not declared. Since this is also needed in some
2180 # cases for HP-UX, we define it globally.
Martin v. Löwis7dece662005-11-26 11:38:24 +00002181 # except for Solaris 10, where it must not be defined,
2182 # as it implies XPG4.2
2183 case $ac_sys_system/$ac_sys_release in
2184 SunOS/5.10)
2185 ;;
2186 *)
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002187
2188cat >>confdefs.h <<\_ACEOF
2189#define _XOPEN_SOURCE_EXTENDED 1
2190_ACEOF
2191
Martin v. Löwis7dece662005-11-26 11:38:24 +00002192 ;;
2193 esac
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002194
Bob Ippolito7026a0a2005-03-28 23:23:47 +00002195
Martin v. Löwis678fc1e2002-11-12 06:04:39 +00002196cat >>confdefs.h <<\_ACEOF
2197#define _POSIX_C_SOURCE 200112L
2198_ACEOF
2199
2200
Martin v. Löwis35195ad2002-11-11 13:26:51 +00002201fi
2202
Guido van Rossum91922671997-10-09 20:24:13 +00002203#
2204# SGI compilers allow the specification of the both the ABI and the
2205# ISA on the command line. Depending on the values of these switches,
2206# different and often incompatable code will be generated.
2207#
2208# The SGI_ABI variable can be used to modify the CC and LDFLAGS and
2209# thus supply support for various ABI/ISA combinations. The MACHDEP
2210# variable is also adjusted.
2211#
2212
2213if test ! -z "$SGI_ABI"
2214then
2215 CC="cc $SGI_ABI"
2216 LDFLAGS="$SGI_ABI $LDFLAGS"
2217 MACHDEP=`echo "${MACHDEP}${SGI_ABI}" | sed 's/ *//g'`
2218fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00002219{ echo "$as_me:$LINENO: result: $MACHDEP" >&5
2220echo "${ECHO_T}$MACHDEP" >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002221
Jack Jansen83f898c2002-12-30 22:23:40 +00002222# And add extra plat-mac for darwin
2223
Jack Jansen7b59b422003-03-17 15:44:10 +00002224
Ronald Oussoren450d5612009-06-08 21:12:41 +00002225{ echo "$as_me:$LINENO: checking EXTRAPLATDIR" >&5
2226echo $ECHO_N "checking EXTRAPLATDIR... $ECHO_C" >&6; }
Jack Jansen83f898c2002-12-30 22:23:40 +00002227if test -z "$EXTRAPLATDIR"
2228then
2229 case $MACHDEP in
Jack Jansen7b59b422003-03-17 15:44:10 +00002230 darwin)
2231 EXTRAPLATDIR="\$(PLATMACDIRS)"
2232 EXTRAMACHDEPPATH="\$(PLATMACPATH)"
2233 ;;
2234 *)
2235 EXTRAPLATDIR=""
2236 EXTRAMACHDEPPATH=""
2237 ;;
Jack Jansen83f898c2002-12-30 22:23:40 +00002238 esac
2239fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00002240{ echo "$as_me:$LINENO: result: $EXTRAPLATDIR" >&5
2241echo "${ECHO_T}$EXTRAPLATDIR" >&6; }
Jack Jansen83f898c2002-12-30 22:23:40 +00002242
Jack Jansen6b08a402004-06-03 12:41:45 +00002243# Record the configure-time value of MACOSX_DEPLOYMENT_TARGET,
2244# it may influence the way we can build extensions, so distutils
2245# needs to check it
2246
Ronald Oussoren988117f2006-04-29 11:31:35 +00002247
Jack Jansen6b08a402004-06-03 12:41:45 +00002248CONFIGURE_MACOSX_DEPLOYMENT_TARGET=
Ronald Oussoren988117f2006-04-29 11:31:35 +00002249EXPORT_MACOSX_DEPLOYMENT_TARGET='#'
Jack Jansen6b08a402004-06-03 12:41:45 +00002250
Ronald Oussoren450d5612009-06-08 21:12:41 +00002251{ echo "$as_me:$LINENO: checking machine type as reported by uname -m" >&5
2252echo $ECHO_N "checking machine type as reported by uname -m... $ECHO_C" >&6; }
Mark Dickinson65134662008-04-25 16:11:04 +00002253ac_sys_machine=`uname -m`
Ronald Oussoren450d5612009-06-08 21:12:41 +00002254{ echo "$as_me:$LINENO: result: $ac_sys_machine" >&5
2255echo "${ECHO_T}$ac_sys_machine" >&6; }
Mark Dickinson65134662008-04-25 16:11:04 +00002256
Guido van Rossum627b2d71993-12-24 10:39:16 +00002257# checks for alternative programs
Skip Montanarodecc6a42003-01-01 20:07:49 +00002258
2259# compiler flags are generated in two sets, BASECFLAGS and OPT. OPT is just
2260# for debug/optimization stuff. BASECFLAGS is for flags that are required
2261# just to get things to compile and link. Users are free to override OPT
2262# when running configure or make. The build should not break if they do.
2263# BASECFLAGS should generally not be messed with, however.
2264
2265# XXX shouldn't some/most/all of this code be merged with the stuff later
2266# on that fiddles with OPT and BASECFLAGS?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002267{ echo "$as_me:$LINENO: checking for --without-gcc" >&5
2268echo $ECHO_N "checking for --without-gcc... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002269
Martin v. Löwiseba40652007-08-30 20:10:57 +00002270# Check whether --with-gcc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002271if test "${with_gcc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002272 withval=$with_gcc;
Guido van Rossum7f43da71994-08-01 12:15:30 +00002273 case $withval in
Mark Dickinson04b27232009-01-04 12:29:36 +00002274 no) CC=${CC:-cc}
Guido van Rossumda88dad1995-01-26 00:46:29 +00002275 without_gcc=yes;;
2276 yes) CC=gcc
2277 without_gcc=no;;
2278 *) CC=$withval
2279 without_gcc=$withval;;
Guido van Rossum7f43da71994-08-01 12:15:30 +00002280 esac
Guido van Rossumda88dad1995-01-26 00:46:29 +00002281else
Martin v. Löwis11437992002-04-12 09:54:03 +00002282
Guido van Rossum7b3853f1996-07-30 18:09:35 +00002283 case $ac_sys_system in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00002284 AIX*) CC=cc_r
2285 without_gcc=;;
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002286 BeOS*)
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002287 case $BE_HOST_CPU in
2288 ppc)
Fred Drake5790be12000-10-09 17:06:13 +00002289 CC=mwcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002290 without_gcc=yes
Skip Montanarodecc6a42003-01-01 20:07:49 +00002291 BASECFLAGS="$BASECFLAGS -export pragma"
2292 OPT="$OPT -O"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002293 LDFLAGS="$LDFLAGS -nodup"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002294 ;;
2295 x86)
Fred Drake5790be12000-10-09 17:06:13 +00002296 CC=gcc
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002297 without_gcc=no
Skip Montanarodecc6a42003-01-01 20:07:49 +00002298 OPT="$OPT -O"
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002299 ;;
2300 *)
Ronald Oussoren450d5612009-06-08 21:12:41 +00002301 { { echo "$as_me:$LINENO: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&5
2302echo "$as_me: error: Unknown BeOS platform \"$BE_HOST_CPU\"" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +00002303 { (exit 1); exit 1; }; }
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002304 ;;
2305 esac
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +00002306 AR="\$(srcdir)/Modules/ar_beos"
2307 RANLIB=:
Guido van Rossum7a5f4201999-01-12 20:30:23 +00002308 ;;
Trent Mick635f6fb2000-08-23 21:33:05 +00002309 Monterey*)
2310 RANLIB=:
Martin v. Löwis130fb172001-07-19 11:00:41 +00002311 without_gcc=;;
2312 *) without_gcc=no;;
Guido van Rossume77438c1995-09-13 18:59:59 +00002313 esac
Martin v. Löwiseba40652007-08-30 20:10:57 +00002314fi
2315
Ronald Oussoren450d5612009-06-08 21:12:41 +00002316{ echo "$as_me:$LINENO: result: $without_gcc" >&5
2317echo "${ECHO_T}$without_gcc" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002318
Guido van Rossum8b131c51995-03-09 14:10:13 +00002319# If the user switches compilers, we can't believe the cache
2320if test ! -z "$ac_cv_prog_CC" -a ! -z "$CC" -a "$CC" != "$ac_cv_prog_CC"
2321then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002322 { { echo "$as_me:$LINENO: error: cached CC is different -- throw away $cache_file
Martin v. Löwis11437992002-04-12 09:54:03 +00002323(it is also a good idea to do 'make clean' before compiling)" >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002324echo "$as_me: error: cached CC is different -- throw away $cache_file
Martin v. Löwis11437992002-04-12 09:54:03 +00002325(it is also a good idea to do 'make clean' before compiling)" >&2;}
2326 { (exit 1); exit 1; }; }
Guido van Rossum8b131c51995-03-09 14:10:13 +00002327fi
2328
Martin v. Löwis11437992002-04-12 09:54:03 +00002329ac_ext=c
2330ac_cpp='$CPP $CPPFLAGS'
2331ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2332ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2333ac_compiler_gnu=$ac_cv_c_compiler_gnu
2334if test -n "$ac_tool_prefix"; then
2335 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2336set dummy ${ac_tool_prefix}gcc; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00002337{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2338echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002339if test "${ac_cv_prog_CC+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002340 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002341else
2342 if test -n "$CC"; then
2343 ac_cv_prog_CC="$CC" # Let the user override the test.
2344else
Martin v. Löwis11437992002-04-12 09:54:03 +00002345as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2346for as_dir in $PATH
2347do
2348 IFS=$as_save_IFS
2349 test -z "$as_dir" && as_dir=.
2350 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002351 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002352 ac_cv_prog_CC="${ac_tool_prefix}gcc"
Ronald Oussoren450d5612009-06-08 21:12:41 +00002353 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002354 break 2
2355 fi
2356done
2357done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002358IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002359
Jack Jansendd19cf82001-12-06 22:36:17 +00002360fi
2361fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002362CC=$ac_cv_prog_CC
Jack Jansendd19cf82001-12-06 22:36:17 +00002363if test -n "$CC"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002364 { echo "$as_me:$LINENO: result: $CC" >&5
2365echo "${ECHO_T}$CC" >&6; }
Jack Jansendd19cf82001-12-06 22:36:17 +00002366else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002367 { echo "$as_me:$LINENO: result: no" >&5
2368echo "${ECHO_T}no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002369fi
2370
Martin v. Löwiseba40652007-08-30 20:10:57 +00002371
Martin v. Löwis11437992002-04-12 09:54:03 +00002372fi
2373if test -z "$ac_cv_prog_CC"; then
2374 ac_ct_CC=$CC
2375 # Extract the first word of "gcc", so it can be a program name with args.
2376set dummy gcc; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00002377{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2378echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002379if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002380 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002381else
2382 if test -n "$ac_ct_CC"; then
2383 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2384else
2385as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2386for as_dir in $PATH
2387do
2388 IFS=$as_save_IFS
2389 test -z "$as_dir" && as_dir=.
2390 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002391 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002392 ac_cv_prog_ac_ct_CC="gcc"
Ronald Oussoren450d5612009-06-08 21:12:41 +00002393 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002394 break 2
2395 fi
2396done
2397done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002398IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002399
2400fi
2401fi
2402ac_ct_CC=$ac_cv_prog_ac_ct_CC
2403if test -n "$ac_ct_CC"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002404 { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2405echo "${ECHO_T}$ac_ct_CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002406else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002407 { echo "$as_me:$LINENO: result: no" >&5
2408echo "${ECHO_T}no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002409fi
2410
Martin v. Löwiseba40652007-08-30 20:10:57 +00002411 if test "x$ac_ct_CC" = x; then
2412 CC=""
2413 else
2414 case $cross_compiling:$ac_tool_warned in
2415yes:)
Ronald Oussoren450d5612009-06-08 21:12:41 +00002416{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
2417whose name does not start with the host triplet. If you think this
2418configuration is useful to you, please write to autoconf@gnu.org." >&5
2419echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
2420whose name does not start with the host triplet. If you think this
2421configuration is useful to you, please write to autoconf@gnu.org." >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00002422ac_tool_warned=yes ;;
2423esac
2424 CC=$ac_ct_CC
2425 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002426else
2427 CC="$ac_cv_prog_CC"
Jack Jansendd19cf82001-12-06 22:36:17 +00002428fi
2429
Jack Jansendd19cf82001-12-06 22:36:17 +00002430if test -z "$CC"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002431 if test -n "$ac_tool_prefix"; then
2432 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
Martin v. Löwis11437992002-04-12 09:54:03 +00002433set dummy ${ac_tool_prefix}cc; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00002434{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2435echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002436if test "${ac_cv_prog_CC+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002437 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +00002438else
2439 if test -n "$CC"; then
2440 ac_cv_prog_CC="$CC" # Let the user override the test.
2441else
Martin v. Löwis11437992002-04-12 09:54:03 +00002442as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2443for as_dir in $PATH
2444do
2445 IFS=$as_save_IFS
2446 test -z "$as_dir" && as_dir=.
2447 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002448 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002449 ac_cv_prog_CC="${ac_tool_prefix}cc"
Ronald Oussoren450d5612009-06-08 21:12:41 +00002450 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002451 break 2
2452 fi
2453done
2454done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002455IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002456
2457fi
2458fi
2459CC=$ac_cv_prog_CC
2460if test -n "$CC"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002461 { echo "$as_me:$LINENO: result: $CC" >&5
2462echo "${ECHO_T}$CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002463else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002464 { echo "$as_me:$LINENO: result: no" >&5
2465echo "${ECHO_T}no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002466fi
2467
Martin v. Löwiseba40652007-08-30 20:10:57 +00002468
Martin v. Löwis11437992002-04-12 09:54:03 +00002469 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002470fi
2471if test -z "$CC"; then
2472 # Extract the first word of "cc", so it can be a program name with args.
2473set dummy cc; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00002474{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2475echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002476if test "${ac_cv_prog_CC+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002477 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002478else
2479 if test -n "$CC"; then
2480 ac_cv_prog_CC="$CC" # Let the user override the test.
2481else
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002482 ac_prog_rejected=no
Martin v. Löwis11437992002-04-12 09:54:03 +00002483as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2484for as_dir in $PATH
2485do
2486 IFS=$as_save_IFS
2487 test -z "$as_dir" && as_dir=.
2488 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002489 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002490 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2491 ac_prog_rejected=yes
2492 continue
2493 fi
2494 ac_cv_prog_CC="cc"
Ronald Oussoren450d5612009-06-08 21:12:41 +00002495 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002496 break 2
2497 fi
2498done
2499done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002500IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002501
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002502if test $ac_prog_rejected = yes; then
2503 # We found a bogon in the path, so make sure we never use it.
2504 set dummy $ac_cv_prog_CC
2505 shift
Martin v. Löwis11437992002-04-12 09:54:03 +00002506 if test $# != 0; then
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002507 # We chose a different compiler from the bogus one.
2508 # However, it has the same basename, so the bogon will be chosen
2509 # first if we set CC to just the basename; use the full file name.
2510 shift
Skip Montanaro6dead952003-09-25 14:50:04 +00002511 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002512 fi
2513fi
2514fi
2515fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002516CC=$ac_cv_prog_CC
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002517if test -n "$CC"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002518 { echo "$as_me:$LINENO: result: $CC" >&5
2519echo "${ECHO_T}$CC" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002520else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002521 { echo "$as_me:$LINENO: result: no" >&5
2522echo "${ECHO_T}no" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00002523fi
2524
Martin v. Löwiseba40652007-08-30 20:10:57 +00002525
Martin v. Löwis11437992002-04-12 09:54:03 +00002526fi
2527if test -z "$CC"; then
2528 if test -n "$ac_tool_prefix"; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002529 for ac_prog in cl.exe
Martin v. Löwis11437992002-04-12 09:54:03 +00002530 do
2531 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2532set dummy $ac_tool_prefix$ac_prog; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00002533{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2534echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002535if test "${ac_cv_prog_CC+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002536 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002537else
2538 if test -n "$CC"; then
2539 ac_cv_prog_CC="$CC" # Let the user override the test.
2540else
Martin v. Löwis11437992002-04-12 09:54:03 +00002541as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2542for as_dir in $PATH
2543do
2544 IFS=$as_save_IFS
2545 test -z "$as_dir" && as_dir=.
2546 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002547 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002548 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
Ronald Oussoren450d5612009-06-08 21:12:41 +00002549 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002550 break 2
Guido van Rossumf78abae1997-01-21 22:02:36 +00002551 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002552done
2553done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002554IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +00002555
2556fi
2557fi
2558CC=$ac_cv_prog_CC
2559if test -n "$CC"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002560 { echo "$as_me:$LINENO: result: $CC" >&5
2561echo "${ECHO_T}$CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002562else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002563 { echo "$as_me:$LINENO: result: no" >&5
2564echo "${ECHO_T}no" >&6; }
Jack Jansendd19cf82001-12-06 22:36:17 +00002565fi
2566
Martin v. Löwiseba40652007-08-30 20:10:57 +00002567
Martin v. Löwis11437992002-04-12 09:54:03 +00002568 test -n "$CC" && break
2569 done
2570fi
2571if test -z "$CC"; then
2572 ac_ct_CC=$CC
Martin v. Löwiseba40652007-08-30 20:10:57 +00002573 for ac_prog in cl.exe
Martin v. Löwis11437992002-04-12 09:54:03 +00002574do
2575 # Extract the first word of "$ac_prog", so it can be a program name with args.
2576set dummy $ac_prog; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00002577{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2578echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002579if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002580 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002581else
2582 if test -n "$ac_ct_CC"; then
2583 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2584else
2585as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2586for as_dir in $PATH
2587do
2588 IFS=$as_save_IFS
2589 test -z "$as_dir" && as_dir=.
2590 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00002591 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002592 ac_cv_prog_ac_ct_CC="$ac_prog"
Ronald Oussoren450d5612009-06-08 21:12:41 +00002593 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002594 break 2
2595 fi
2596done
2597done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002598IFS=$as_save_IFS
Jack Jansendd19cf82001-12-06 22:36:17 +00002599
Martin v. Löwis11437992002-04-12 09:54:03 +00002600fi
2601fi
2602ac_ct_CC=$ac_cv_prog_ac_ct_CC
2603if test -n "$ac_ct_CC"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002604 { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2605echo "${ECHO_T}$ac_ct_CC" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002606else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002607 { echo "$as_me:$LINENO: result: no" >&5
2608echo "${ECHO_T}no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002609fi
Michael W. Hudson54241132001-12-07 15:38:26 +00002610
Martin v. Löwiseba40652007-08-30 20:10:57 +00002611
Martin v. Löwis11437992002-04-12 09:54:03 +00002612 test -n "$ac_ct_CC" && break
2613done
Michael W. Hudson54241132001-12-07 15:38:26 +00002614
Martin v. Löwiseba40652007-08-30 20:10:57 +00002615 if test "x$ac_ct_CC" = x; then
2616 CC=""
2617 else
2618 case $cross_compiling:$ac_tool_warned in
2619yes:)
Ronald Oussoren450d5612009-06-08 21:12:41 +00002620{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
2621whose name does not start with the host triplet. If you think this
2622configuration is useful to you, please write to autoconf@gnu.org." >&5
2623echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
2624whose name does not start with the host triplet. If you think this
2625configuration is useful to you, please write to autoconf@gnu.org." >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00002626ac_tool_warned=yes ;;
2627esac
2628 CC=$ac_ct_CC
2629 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00002630fi
2631
2632fi
2633
2634
Ronald Oussoren450d5612009-06-08 21:12:41 +00002635test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
Skip Montanaro6dead952003-09-25 14:50:04 +00002636See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002637echo "$as_me: error: no acceptable C compiler found in \$PATH
Skip Montanaro6dead952003-09-25 14:50:04 +00002638See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00002639 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002640
2641# Provide some information about the compiler.
Ronald Oussoren450d5612009-06-08 21:12:41 +00002642echo "$as_me:$LINENO: checking for C compiler version" >&5
2643ac_compiler=`set X $ac_compile; echo $2`
Martin v. Löwiseba40652007-08-30 20:10:57 +00002644{ (ac_try="$ac_compiler --version >&5"
2645case "(($ac_try" in
2646 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2647 *) ac_try_echo=$ac_try;;
2648esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002649eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002650 (eval "$ac_compiler --version >&5") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002651 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002652 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002653 (exit $ac_status); }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002654{ (ac_try="$ac_compiler -v >&5"
2655case "(($ac_try" in
2656 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2657 *) ac_try_echo=$ac_try;;
2658esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002659eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002660 (eval "$ac_compiler -v >&5") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002661 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002662 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002663 (exit $ac_status); }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002664{ (ac_try="$ac_compiler -V >&5"
2665case "(($ac_try" in
2666 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2667 *) ac_try_echo=$ac_try;;
2668esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002669eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002670 (eval "$ac_compiler -V >&5") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002671 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002672 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002673 (exit $ac_status); }
2674
2675cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00002676/* confdefs.h. */
2677_ACEOF
2678cat confdefs.h >>conftest.$ac_ext
2679cat >>conftest.$ac_ext <<_ACEOF
2680/* end confdefs.h. */
Jack Jansendd19cf82001-12-06 22:36:17 +00002681
Martin v. Löwis11437992002-04-12 09:54:03 +00002682int
2683main ()
2684{
2685
2686 ;
2687 return 0;
2688}
2689_ACEOF
2690ac_clean_files_save=$ac_clean_files
Ronald Oussoren450d5612009-06-08 21:12:41 +00002691ac_clean_files="$ac_clean_files a.out a.exe b.out"
Martin v. Löwis11437992002-04-12 09:54:03 +00002692# Try to create an executable without -o first, disregard a.out.
2693# It will help us diagnose broken compilers, and finding out an intuition
2694# of exeext.
Ronald Oussoren450d5612009-06-08 21:12:41 +00002695{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2696echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
2697ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2698#
2699# List of possible output files, starting from the most likely.
2700# The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
2701# only as a last resort. b.out is created by i960 compilers.
2702ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
2703#
2704# The IRIX 6 linker writes into existing files which may not be
2705# executable, retaining their permissions. Remove them first so a
2706# subsequent execution test works.
Martin v. Löwiseba40652007-08-30 20:10:57 +00002707ac_rmfiles=
2708for ac_file in $ac_files
2709do
2710 case $ac_file in
Ronald Oussoren450d5612009-06-08 21:12:41 +00002711 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00002712 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2713 esac
2714done
2715rm -f $ac_rmfiles
2716
2717if { (ac_try="$ac_link_default"
2718case "(($ac_try" in
2719 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2720 *) ac_try_echo=$ac_try;;
2721esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002722eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002723 (eval "$ac_link_default") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002724 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002725 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002726 (exit $ac_status); }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002727 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2728# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2729# in a Makefile. We should not override ac_cv_exeext if it was cached,
2730# so that the user can short-circuit this test for compilers unknown to
2731# Autoconf.
2732for ac_file in $ac_files ''
Skip Montanaro6dead952003-09-25 14:50:04 +00002733do
2734 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00002735 case $ac_file in
Ronald Oussoren450d5612009-06-08 21:12:41 +00002736 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
Skip Montanarof0d5f792004-08-15 14:08:23 +00002737 ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002738 [ab].out )
Skip Montanarof0d5f792004-08-15 14:08:23 +00002739 # We found the default executable, but exeext='' is most
2740 # certainly right.
2741 break;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002742 *.* )
Martin v. Löwiseba40652007-08-30 20:10:57 +00002743 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2744 then :; else
2745 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2746 fi
2747 # We set ac_cv_exeext here because the later test for it is not
2748 # safe: cross compilers may not add the suffix if given an `-o'
2749 # argument, so we may need to know it at that point already.
2750 # Even if this section looks crufty: it has the advantage of
2751 # actually working.
Skip Montanarof0d5f792004-08-15 14:08:23 +00002752 break;;
Skip Montanaro6dead952003-09-25 14:50:04 +00002753 * )
Skip Montanarof0d5f792004-08-15 14:08:23 +00002754 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002755 esac
2756done
Martin v. Löwiseba40652007-08-30 20:10:57 +00002757test "$ac_cv_exeext" = no && ac_cv_exeext=
2758
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002759else
Martin v. Löwiseba40652007-08-30 20:10:57 +00002760 ac_file=''
2761fi
2762
Ronald Oussoren450d5612009-06-08 21:12:41 +00002763{ echo "$as_me:$LINENO: result: $ac_file" >&5
2764echo "${ECHO_T}$ac_file" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002765if test -z "$ac_file"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002766 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00002767sed 's/^/| /' conftest.$ac_ext >&5
2768
Ronald Oussoren450d5612009-06-08 21:12:41 +00002769{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
Skip Montanaro6dead952003-09-25 14:50:04 +00002770See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002771echo "$as_me: error: C compiler cannot create executables
Skip Montanaro6dead952003-09-25 14:50:04 +00002772See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00002773 { (exit 77); exit 77; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002774fi
Guido van Rossume6c2cf11999-01-08 21:08:33 +00002775
Martin v. Löwis11437992002-04-12 09:54:03 +00002776ac_exeext=$ac_cv_exeext
Michael W. Hudson54241132001-12-07 15:38:26 +00002777
Martin v. Löwiseba40652007-08-30 20:10:57 +00002778# Check that the compiler produces executables we can run. If not, either
Martin v. Löwis11437992002-04-12 09:54:03 +00002779# the compiler is broken, or we cross compile.
Ronald Oussoren450d5612009-06-08 21:12:41 +00002780{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2781echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002782# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2783# If not cross compiling, check that we can run a simple program.
2784if test "$cross_compiling" != yes; then
2785 if { ac_try='./$ac_file'
Martin v. Löwiseba40652007-08-30 20:10:57 +00002786 { (case "(($ac_try" in
2787 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2788 *) ac_try_echo=$ac_try;;
2789esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002790eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002791 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002792 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002793 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002794 (exit $ac_status); }; }; then
2795 cross_compiling=no
2796 else
2797 if test "$cross_compiling" = maybe; then
2798 cross_compiling=yes
2799 else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002800 { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
Skip Montanaro6dead952003-09-25 14:50:04 +00002801If you meant to cross compile, use \`--host'.
2802See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002803echo "$as_me: error: cannot run C compiled programs.
Skip Montanaro6dead952003-09-25 14:50:04 +00002804If you meant to cross compile, use \`--host'.
2805See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00002806 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002807 fi
2808 fi
2809fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00002810{ echo "$as_me:$LINENO: result: yes" >&5
2811echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002812
Ronald Oussoren450d5612009-06-08 21:12:41 +00002813rm -f a.out a.exe conftest$ac_cv_exeext b.out
Martin v. Löwis11437992002-04-12 09:54:03 +00002814ac_clean_files=$ac_clean_files_save
Martin v. Löwiseba40652007-08-30 20:10:57 +00002815# Check that the compiler produces executables we can run. If not, either
Martin v. Löwis11437992002-04-12 09:54:03 +00002816# the compiler is broken, or we cross compile.
Ronald Oussoren450d5612009-06-08 21:12:41 +00002817{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2818echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
2819{ echo "$as_me:$LINENO: result: $cross_compiling" >&5
2820echo "${ECHO_T}$cross_compiling" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002821
Ronald Oussoren450d5612009-06-08 21:12:41 +00002822{ echo "$as_me:$LINENO: checking for suffix of executables" >&5
2823echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00002824if { (ac_try="$ac_link"
2825case "(($ac_try" in
2826 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2827 *) ac_try_echo=$ac_try;;
2828esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002829eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002830 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002831 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002833 (exit $ac_status); }; then
2834 # If both `conftest.exe' and `conftest' are `present' (well, observable)
2835# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
2836# work properly (i.e., refer to `conftest.exe'), while it won't with
2837# `rm'.
Skip Montanaro6dead952003-09-25 14:50:04 +00002838for ac_file in conftest.exe conftest conftest.*; do
2839 test -f "$ac_file" || continue
Martin v. Löwis11437992002-04-12 09:54:03 +00002840 case $ac_file in
Ronald Oussoren450d5612009-06-08 21:12:41 +00002841 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002842 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
Skip Montanarof0d5f792004-08-15 14:08:23 +00002843 break;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002844 * ) break;;
2845 esac
2846done
Guido van Rossum76be6ed1995-01-02 18:33:54 +00002847else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002848 { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
Skip Montanaro6dead952003-09-25 14:50:04 +00002849See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002850echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
Skip Montanaro6dead952003-09-25 14:50:04 +00002851See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00002852 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +00002853fi
Jack Jansendd19cf82001-12-06 22:36:17 +00002854
Martin v. Löwis11437992002-04-12 09:54:03 +00002855rm -f conftest$ac_cv_exeext
Ronald Oussoren450d5612009-06-08 21:12:41 +00002856{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2857echo "${ECHO_T}$ac_cv_exeext" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002858
2859rm -f conftest.$ac_ext
2860EXEEXT=$ac_cv_exeext
2861ac_exeext=$EXEEXT
Ronald Oussoren450d5612009-06-08 21:12:41 +00002862{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
2863echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002864if test "${ac_cv_objext+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002865 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00002866else
Martin v. Löwis11437992002-04-12 09:54:03 +00002867 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00002868/* confdefs.h. */
2869_ACEOF
2870cat confdefs.h >>conftest.$ac_ext
2871cat >>conftest.$ac_ext <<_ACEOF
2872/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002873
Martin v. Löwis11437992002-04-12 09:54:03 +00002874int
2875main ()
2876{
2877
2878 ;
2879 return 0;
2880}
2881_ACEOF
2882rm -f conftest.o conftest.obj
Martin v. Löwiseba40652007-08-30 20:10:57 +00002883if { (ac_try="$ac_compile"
2884case "(($ac_try" in
2885 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2886 *) ac_try_echo=$ac_try;;
2887esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002888eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002889 (eval "$ac_compile") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002890 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00002891 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00002892 (exit $ac_status); }; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00002893 for ac_file in conftest.o conftest.obj conftest.*; do
2894 test -f "$ac_file" || continue;
Martin v. Löwis11437992002-04-12 09:54:03 +00002895 case $ac_file in
Ronald Oussoren450d5612009-06-08 21:12:41 +00002896 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00002897 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2898 break;;
2899 esac
2900done
2901else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002902 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00002903sed 's/^/| /' conftest.$ac_ext >&5
2904
Ronald Oussoren450d5612009-06-08 21:12:41 +00002905{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
Skip Montanaro6dead952003-09-25 14:50:04 +00002906See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002907echo "$as_me: error: cannot compute suffix of object files: cannot compile
Skip Montanaro6dead952003-09-25 14:50:04 +00002908See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00002909 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002910fi
2911
2912rm -f conftest.$ac_cv_objext conftest.$ac_ext
2913fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00002914{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2915echo "${ECHO_T}$ac_cv_objext" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002916OBJEXT=$ac_cv_objext
2917ac_objext=$OBJEXT
Ronald Oussoren450d5612009-06-08 21:12:41 +00002918{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2919echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002920if test "${ac_cv_c_compiler_gnu+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002921 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002922else
2923 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00002924/* confdefs.h. */
2925_ACEOF
2926cat confdefs.h >>conftest.$ac_ext
2927cat >>conftest.$ac_ext <<_ACEOF
2928/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002929
Martin v. Löwis11437992002-04-12 09:54:03 +00002930int
2931main ()
2932{
2933#ifndef __GNUC__
2934 choke me
2935#endif
2936
2937 ;
2938 return 0;
2939}
2940_ACEOF
2941rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00002942if { (ac_try="$ac_compile"
2943case "(($ac_try" in
2944 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2945 *) ac_try_echo=$ac_try;;
2946esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00002947eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002948 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00002949 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00002950 grep -v '^ *+' conftest.er1 >conftest.err
2951 rm -f conftest.er1
2952 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00002953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00002954 (exit $ac_status); } && {
2955 test -z "$ac_c_werror_flag" ||
2956 test ! -s conftest.err
2957 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00002958 ac_compiler_gnu=yes
2959else
Ronald Oussoren450d5612009-06-08 21:12:41 +00002960 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00002961sed 's/^/| /' conftest.$ac_ext >&5
2962
Martin v. Löwiseba40652007-08-30 20:10:57 +00002963 ac_compiler_gnu=no
Martin v. Löwis11437992002-04-12 09:54:03 +00002964fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00002965
2966rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00002967ac_cv_c_compiler_gnu=$ac_compiler_gnu
2968
2969fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00002970{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2971echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
2972GCC=`test $ac_compiler_gnu = yes && echo yes`
Martin v. Löwis11437992002-04-12 09:54:03 +00002973ac_test_CFLAGS=${CFLAGS+set}
2974ac_save_CFLAGS=$CFLAGS
Ronald Oussoren450d5612009-06-08 21:12:41 +00002975{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2976echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00002977if test "${ac_cv_prog_cc_g+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00002978 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00002979else
Martin v. Löwiseba40652007-08-30 20:10:57 +00002980 ac_save_c_werror_flag=$ac_c_werror_flag
2981 ac_c_werror_flag=yes
2982 ac_cv_prog_cc_g=no
2983 CFLAGS="-g"
2984 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00002985/* confdefs.h. */
2986_ACEOF
2987cat confdefs.h >>conftest.$ac_ext
2988cat >>conftest.$ac_ext <<_ACEOF
2989/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00002990
Martin v. Löwis11437992002-04-12 09:54:03 +00002991int
2992main ()
2993{
2994
2995 ;
2996 return 0;
2997}
2998_ACEOF
2999rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00003000if { (ac_try="$ac_compile"
3001case "(($ac_try" in
3002 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3003 *) ac_try_echo=$ac_try;;
3004esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003005eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003006 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003007 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00003008 grep -v '^ *+' conftest.er1 >conftest.err
3009 rm -f conftest.er1
3010 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003011 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003012 (exit $ac_status); } && {
3013 test -z "$ac_c_werror_flag" ||
3014 test ! -s conftest.err
3015 } && test -s conftest.$ac_objext; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003016 ac_cv_prog_cc_g=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003017else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003018 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003019sed 's/^/| /' conftest.$ac_ext >&5
3020
Martin v. Löwiseba40652007-08-30 20:10:57 +00003021 CFLAGS=""
3022 cat >conftest.$ac_ext <<_ACEOF
3023/* confdefs.h. */
3024_ACEOF
3025cat confdefs.h >>conftest.$ac_ext
3026cat >>conftest.$ac_ext <<_ACEOF
3027/* end confdefs.h. */
3028
3029int
3030main ()
3031{
3032
3033 ;
3034 return 0;
3035}
3036_ACEOF
3037rm -f conftest.$ac_objext
3038if { (ac_try="$ac_compile"
3039case "(($ac_try" in
3040 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3041 *) ac_try_echo=$ac_try;;
3042esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003043eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003044 (eval "$ac_compile") 2>conftest.er1
3045 ac_status=$?
3046 grep -v '^ *+' conftest.er1 >conftest.err
3047 rm -f conftest.er1
3048 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003050 (exit $ac_status); } && {
3051 test -z "$ac_c_werror_flag" ||
3052 test ! -s conftest.err
3053 } && test -s conftest.$ac_objext; then
3054 :
3055else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003056 echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003057sed 's/^/| /' conftest.$ac_ext >&5
3058
3059 ac_c_werror_flag=$ac_save_c_werror_flag
3060 CFLAGS="-g"
3061 cat >conftest.$ac_ext <<_ACEOF
3062/* confdefs.h. */
3063_ACEOF
3064cat confdefs.h >>conftest.$ac_ext
3065cat >>conftest.$ac_ext <<_ACEOF
3066/* end confdefs.h. */
3067
3068int
3069main ()
3070{
3071
3072 ;
3073 return 0;
3074}
3075_ACEOF
3076rm -f conftest.$ac_objext
3077if { (ac_try="$ac_compile"
3078case "(($ac_try" in
3079 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3080 *) ac_try_echo=$ac_try;;
3081esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003082eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003083 (eval "$ac_compile") 2>conftest.er1
3084 ac_status=$?
3085 grep -v '^ *+' conftest.er1 >conftest.err
3086 rm -f conftest.er1
3087 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003089 (exit $ac_status); } && {
3090 test -z "$ac_c_werror_flag" ||
3091 test ! -s conftest.err
3092 } && test -s conftest.$ac_objext; then
3093 ac_cv_prog_cc_g=yes
3094else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003095 echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003096sed 's/^/| /' conftest.$ac_ext >&5
3097
3098
Guido van Rossum627b2d71993-12-24 10:39:16 +00003099fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003100
3101rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003102fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003103
3104rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3105fi
3106
3107rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3108 ac_c_werror_flag=$ac_save_c_werror_flag
3109fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003110{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3111echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003112if test "$ac_test_CFLAGS" = set; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003113 CFLAGS=$ac_save_CFLAGS
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003114elif test $ac_cv_prog_cc_g = yes; then
3115 if test "$GCC" = yes; then
Guido van Rossumf78abae1997-01-21 22:02:36 +00003116 CFLAGS="-g -O2"
3117 else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003118 CFLAGS="-g"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003119 fi
3120else
Guido van Rossume6c2cf11999-01-08 21:08:33 +00003121 if test "$GCC" = yes; then
3122 CFLAGS="-O2"
3123 else
3124 CFLAGS=
3125 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003126fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003127{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3128echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003129if test "${ac_cv_prog_cc_c89+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003130 echo $ECHO_N "(cached) $ECHO_C" >&6
Skip Montanaro6dead952003-09-25 14:50:04 +00003131else
Martin v. Löwiseba40652007-08-30 20:10:57 +00003132 ac_cv_prog_cc_c89=no
Skip Montanaro6dead952003-09-25 14:50:04 +00003133ac_save_CC=$CC
3134cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003135/* confdefs.h. */
3136_ACEOF
3137cat confdefs.h >>conftest.$ac_ext
3138cat >>conftest.$ac_ext <<_ACEOF
3139/* end confdefs.h. */
3140#include <stdarg.h>
3141#include <stdio.h>
3142#include <sys/types.h>
3143#include <sys/stat.h>
3144/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3145struct buf { int x; };
3146FILE * (*rcsopen) (struct buf *, struct stat *, int);
3147static char *e (p, i)
3148 char **p;
3149 int i;
3150{
3151 return p[i];
3152}
3153static char *f (char * (*g) (char **, int), char **p, ...)
3154{
3155 char *s;
3156 va_list v;
3157 va_start (v,p);
3158 s = g (p, va_arg (v,int));
3159 va_end (v);
3160 return s;
3161}
Skip Montanarof0d5f792004-08-15 14:08:23 +00003162
3163/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3164 function prototypes and stuff, but not '\xHH' hex character constants.
3165 These don't provoke an error unfortunately, instead are silently treated
Martin v. Löwiseba40652007-08-30 20:10:57 +00003166 as 'x'. The following induces an error, until -std is added to get
Skip Montanarof0d5f792004-08-15 14:08:23 +00003167 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3168 array size at least. It's necessary to write '\x00'==0 to get something
Martin v. Löwiseba40652007-08-30 20:10:57 +00003169 that's true only with -std. */
Skip Montanarof0d5f792004-08-15 14:08:23 +00003170int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3171
Martin v. Löwiseba40652007-08-30 20:10:57 +00003172/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3173 inside strings and character constants. */
3174#define FOO(x) 'x'
3175int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3176
Skip Montanaro6dead952003-09-25 14:50:04 +00003177int test (int i, double x);
3178struct s1 {int (*f) (int a);};
3179struct s2 {int (*f) (double a);};
3180int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3181int argc;
3182char **argv;
3183int
3184main ()
3185{
3186return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3187 ;
3188 return 0;
3189}
3190_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003191for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3192 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
Skip Montanaro6dead952003-09-25 14:50:04 +00003193do
3194 CC="$ac_save_CC $ac_arg"
3195 rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00003196if { (ac_try="$ac_compile"
3197case "(($ac_try" in
3198 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3199 *) ac_try_echo=$ac_try;;
3200esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003201eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003202 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +00003203 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00003204 grep -v '^ *+' conftest.er1 >conftest.err
3205 rm -f conftest.er1
3206 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003208 (exit $ac_status); } && {
3209 test -z "$ac_c_werror_flag" ||
3210 test ! -s conftest.err
3211 } && test -s conftest.$ac_objext; then
3212 ac_cv_prog_cc_c89=$ac_arg
Skip Montanaro6dead952003-09-25 14:50:04 +00003213else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003214 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003215sed 's/^/| /' conftest.$ac_ext >&5
3216
Martin v. Löwiseba40652007-08-30 20:10:57 +00003217
Skip Montanaro6dead952003-09-25 14:50:04 +00003218fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003219
3220rm -f core conftest.err conftest.$ac_objext
3221 test "x$ac_cv_prog_cc_c89" != "xno" && break
Skip Montanaro6dead952003-09-25 14:50:04 +00003222done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003223rm -f conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +00003224CC=$ac_save_CC
3225
3226fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003227# AC_CACHE_VAL
3228case "x$ac_cv_prog_cc_c89" in
3229 x)
Ronald Oussoren450d5612009-06-08 21:12:41 +00003230 { echo "$as_me:$LINENO: result: none needed" >&5
3231echo "${ECHO_T}none needed" >&6; } ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00003232 xno)
Ronald Oussoren450d5612009-06-08 21:12:41 +00003233 { echo "$as_me:$LINENO: result: unsupported" >&5
3234echo "${ECHO_T}unsupported" >&6; } ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00003235 *)
Martin v. Löwiseba40652007-08-30 20:10:57 +00003236 CC="$CC $ac_cv_prog_cc_c89"
Ronald Oussoren450d5612009-06-08 21:12:41 +00003237 { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3238echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
Skip Montanaro6dead952003-09-25 14:50:04 +00003239esac
3240
Skip Montanaro6dead952003-09-25 14:50:04 +00003241
Martin v. Löwis11437992002-04-12 09:54:03 +00003242ac_ext=c
3243ac_cpp='$CPP $CPPFLAGS'
3244ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3245ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3246ac_compiler_gnu=$ac_cv_c_compiler_gnu
Guido van Rossum76be6ed1995-01-02 18:33:54 +00003247
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003248
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003249
3250
Ronald Oussoren450d5612009-06-08 21:12:41 +00003251{ echo "$as_me:$LINENO: checking for --with-cxx-main=<compiler>" >&5
3252echo $ECHO_N "checking for --with-cxx-main=<compiler>... $ECHO_C" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003253
Martin v. Löwiseba40652007-08-30 20:10:57 +00003254# Check whether --with-cxx_main was given.
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003255if test "${with_cxx_main+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00003256 withval=$with_cxx_main;
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003257
3258 case $withval in
3259 no) with_cxx_main=no
3260 MAINCC='$(CC)';;
3261 yes) with_cxx_main=yes
3262 MAINCC='$(CXX)';;
3263 *) with_cxx_main=yes
3264 MAINCC=$withval
3265 if test -z "$CXX"
3266 then
3267 CXX=$withval
3268 fi;;
3269 esac
3270else
3271
3272 with_cxx_main=no
3273 MAINCC='$(CC)'
3274
Martin v. Löwiseba40652007-08-30 20:10:57 +00003275fi
3276
Ronald Oussoren450d5612009-06-08 21:12:41 +00003277{ echo "$as_me:$LINENO: result: $with_cxx_main" >&5
3278echo "${ECHO_T}$with_cxx_main" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003279
3280preset_cxx="$CXX"
3281if test -z "$CXX"
3282then
3283 case "$CC" in
3284 gcc) # Extract the first word of "g++", so it can be a program name with args.
3285set dummy g++; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00003286{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3287echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003288if test "${ac_cv_path_CXX+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003289 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003290else
3291 case $CXX in
3292 [\\/]* | ?:[\\/]*)
3293 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
3294 ;;
3295 *)
3296 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3297for as_dir in notfound
3298do
3299 IFS=$as_save_IFS
3300 test -z "$as_dir" && as_dir=.
3301 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00003302 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003303 ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
Ronald Oussoren450d5612009-06-08 21:12:41 +00003304 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003305 break 2
3306 fi
3307done
3308done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003309IFS=$as_save_IFS
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003310
3311 test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="g++"
3312 ;;
3313esac
3314fi
3315CXX=$ac_cv_path_CXX
Skip Montanaro89e975f2007-08-22 19:05:21 +00003316if test -n "$CXX"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003317 { echo "$as_me:$LINENO: result: $CXX" >&5
3318echo "${ECHO_T}$CXX" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003319else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003320 { echo "$as_me:$LINENO: result: no" >&5
3321echo "${ECHO_T}no" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003322fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003323
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003324 ;;
3325 cc) # Extract the first word of "c++", so it can be a program name with args.
3326set dummy c++; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00003327{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3328echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003329if test "${ac_cv_path_CXX+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003330 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003331else
3332 case $CXX in
3333 [\\/]* | ?:[\\/]*)
3334 ac_cv_path_CXX="$CXX" # Let the user override the test with a path.
3335 ;;
3336 *)
3337 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3338for as_dir in notfound
3339do
3340 IFS=$as_save_IFS
3341 test -z "$as_dir" && as_dir=.
3342 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00003343 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003344 ac_cv_path_CXX="$as_dir/$ac_word$ac_exec_ext"
Ronald Oussoren450d5612009-06-08 21:12:41 +00003345 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003346 break 2
3347 fi
3348done
3349done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003350IFS=$as_save_IFS
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003351
3352 test -z "$ac_cv_path_CXX" && ac_cv_path_CXX="c++"
3353 ;;
3354esac
3355fi
3356CXX=$ac_cv_path_CXX
Skip Montanaro89e975f2007-08-22 19:05:21 +00003357if test -n "$CXX"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003358 { echo "$as_me:$LINENO: result: $CXX" >&5
3359echo "${ECHO_T}$CXX" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003360else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003361 { echo "$as_me:$LINENO: result: no" >&5
3362echo "${ECHO_T}no" >&6; }
Skip Montanaro89e975f2007-08-22 19:05:21 +00003363fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003364
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003365 ;;
3366 esac
3367 if test "$CXX" = "notfound"
3368 then
3369 CXX=""
3370 fi
3371fi
3372if test -z "$CXX"
3373then
3374 for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
3375do
3376 # Extract the first word of "$ac_prog", so it can be a program name with args.
3377set dummy $ac_prog; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00003378{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3379echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003380if test "${ac_cv_prog_CXX+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003381 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003382else
3383 if test -n "$CXX"; then
3384 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3385else
3386as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3387for as_dir in $PATH
3388do
3389 IFS=$as_save_IFS
3390 test -z "$as_dir" && as_dir=.
3391 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +00003392 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003393 ac_cv_prog_CXX="$ac_prog"
Ronald Oussoren450d5612009-06-08 21:12:41 +00003394 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003395 break 2
3396 fi
3397done
3398done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003399IFS=$as_save_IFS
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003400
3401fi
3402fi
3403CXX=$ac_cv_prog_CXX
3404if test -n "$CXX"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003405 { echo "$as_me:$LINENO: result: $CXX" >&5
3406echo "${ECHO_T}$CXX" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003407else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003408 { echo "$as_me:$LINENO: result: no" >&5
3409echo "${ECHO_T}no" >&6; }
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003410fi
3411
Martin v. Löwiseba40652007-08-30 20:10:57 +00003412
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003413 test -n "$CXX" && break
3414done
3415test -n "$CXX" || CXX="notfound"
3416
3417 if test "$CXX" = "notfound"
3418 then
3419 CXX=""
3420 fi
3421fi
3422if test "$preset_cxx" != "$CXX"
3423then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003424 { echo "$as_me:$LINENO: WARNING:
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003425
3426 By default, distutils will build C++ extension modules with \"$CXX\".
3427 If this is not intended, then set CXX on the configure command line.
3428 " >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003429echo "$as_me: WARNING:
Martin v. Löwis0f48d982006-04-14 14:34:26 +00003430
3431 By default, distutils will build C++ extension modules with \"$CXX\".
3432 If this is not intended, then set CXX on the configure command line.
3433 " >&2;}
3434fi
3435
3436
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003437# checks for UNIX variants that set C preprocessor variables
Martin v. Löwis11437992002-04-12 09:54:03 +00003438
3439ac_ext=c
3440ac_cpp='$CPP $CPPFLAGS'
3441ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3442ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3443ac_compiler_gnu=$ac_cv_c_compiler_gnu
Ronald Oussoren450d5612009-06-08 21:12:41 +00003444{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3445echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003446# On Suns, sometimes $CPP names a directory.
3447if test -n "$CPP" && test -d "$CPP"; then
3448 CPP=
3449fi
3450if test -z "$CPP"; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003451 if test "${ac_cv_prog_CPP+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003452 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003453else
Martin v. Löwis11437992002-04-12 09:54:03 +00003454 # Double quotes because CPP needs to be expanded
3455 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3456 do
3457 ac_preproc_ok=false
3458for ac_c_preproc_warn_flag in '' yes
3459do
3460 # Use a header file that comes with gcc, so configuring glibc
3461 # with a fresh cross-compiler works.
Skip Montanaro6dead952003-09-25 14:50:04 +00003462 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3463 # <limits.h> exists even on freestanding compilers.
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003464 # On the NeXT, cc -E runs the code through the compiler's parser,
Martin v. Löwis11437992002-04-12 09:54:03 +00003465 # not just through cpp. "Syntax error" is here to catch this case.
3466 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003467/* confdefs.h. */
3468_ACEOF
3469cat confdefs.h >>conftest.$ac_ext
3470cat >>conftest.$ac_ext <<_ACEOF
3471/* end confdefs.h. */
3472#ifdef __STDC__
3473# include <limits.h>
3474#else
3475# include <assert.h>
3476#endif
Skip Montanarof0d5f792004-08-15 14:08:23 +00003477 Syntax error
Martin v. Löwis11437992002-04-12 09:54:03 +00003478_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003479if { (ac_try="$ac_cpp conftest.$ac_ext"
3480case "(($ac_try" in
3481 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3482 *) ac_try_echo=$ac_try;;
3483esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003484eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003485 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003486 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003487 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003488 rm -f conftest.er1
3489 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003490 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003491 (exit $ac_status); } >/dev/null && {
3492 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3493 test ! -s conftest.err
3494 }; then
Martin v. Löwis1d5ecb72001-08-09 10:29:44 +00003495 :
3496else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003497 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003498sed 's/^/| /' conftest.$ac_ext >&5
3499
Martin v. Löwis11437992002-04-12 09:54:03 +00003500 # Broken: fails on valid input.
3501continue
Jack Jansendd19cf82001-12-06 22:36:17 +00003502fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003503
Martin v. Löwis11437992002-04-12 09:54:03 +00003504rm -f conftest.err conftest.$ac_ext
Jack Jansendd19cf82001-12-06 22:36:17 +00003505
Martin v. Löwiseba40652007-08-30 20:10:57 +00003506 # OK, works on sane cases. Now check whether nonexistent headers
Martin v. Löwis11437992002-04-12 09:54:03 +00003507 # can be detected and how.
3508 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003509/* confdefs.h. */
3510_ACEOF
3511cat confdefs.h >>conftest.$ac_ext
3512cat >>conftest.$ac_ext <<_ACEOF
3513/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003514#include <ac_nonexistent.h>
3515_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003516if { (ac_try="$ac_cpp conftest.$ac_ext"
3517case "(($ac_try" in
3518 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3519 *) ac_try_echo=$ac_try;;
3520esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003521eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003522 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003523 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003524 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003525 rm -f conftest.er1
3526 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003528 (exit $ac_status); } >/dev/null && {
3529 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3530 test ! -s conftest.err
3531 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003532 # Broken: success on invalid input.
3533continue
3534else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003535 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003536sed 's/^/| /' conftest.$ac_ext >&5
3537
Martin v. Löwis11437992002-04-12 09:54:03 +00003538 # Passes both tests.
3539ac_preproc_ok=:
3540break
3541fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003542
Martin v. Löwis11437992002-04-12 09:54:03 +00003543rm -f conftest.err conftest.$ac_ext
3544
3545done
3546# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3547rm -f conftest.err conftest.$ac_ext
3548if $ac_preproc_ok; then
3549 break
3550fi
3551
3552 done
3553 ac_cv_prog_CPP=$CPP
3554
3555fi
3556 CPP=$ac_cv_prog_CPP
3557else
3558 ac_cv_prog_CPP=$CPP
3559fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003560{ echo "$as_me:$LINENO: result: $CPP" >&5
3561echo "${ECHO_T}$CPP" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003562ac_preproc_ok=false
3563for ac_c_preproc_warn_flag in '' yes
3564do
3565 # Use a header file that comes with gcc, so configuring glibc
3566 # with a fresh cross-compiler works.
Skip Montanaro6dead952003-09-25 14:50:04 +00003567 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3568 # <limits.h> exists even on freestanding compilers.
Martin v. Löwis11437992002-04-12 09:54:03 +00003569 # On the NeXT, cc -E runs the code through the compiler's parser,
3570 # not just through cpp. "Syntax error" is here to catch this case.
3571 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003572/* confdefs.h. */
3573_ACEOF
3574cat confdefs.h >>conftest.$ac_ext
3575cat >>conftest.$ac_ext <<_ACEOF
3576/* end confdefs.h. */
3577#ifdef __STDC__
3578# include <limits.h>
3579#else
3580# include <assert.h>
3581#endif
Skip Montanarof0d5f792004-08-15 14:08:23 +00003582 Syntax error
Martin v. Löwis11437992002-04-12 09:54:03 +00003583_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003584if { (ac_try="$ac_cpp conftest.$ac_ext"
3585case "(($ac_try" in
3586 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3587 *) ac_try_echo=$ac_try;;
3588esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003589eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003590 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003591 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003592 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003593 rm -f conftest.er1
3594 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003595 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003596 (exit $ac_status); } >/dev/null && {
3597 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3598 test ! -s conftest.err
3599 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003600 :
3601else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003602 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003603sed 's/^/| /' conftest.$ac_ext >&5
3604
Martin v. Löwis11437992002-04-12 09:54:03 +00003605 # Broken: fails on valid input.
3606continue
3607fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003608
Martin v. Löwis11437992002-04-12 09:54:03 +00003609rm -f conftest.err conftest.$ac_ext
3610
Martin v. Löwiseba40652007-08-30 20:10:57 +00003611 # OK, works on sane cases. Now check whether nonexistent headers
Martin v. Löwis11437992002-04-12 09:54:03 +00003612 # can be detected and how.
3613 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003614/* confdefs.h. */
3615_ACEOF
3616cat confdefs.h >>conftest.$ac_ext
3617cat >>conftest.$ac_ext <<_ACEOF
3618/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00003619#include <ac_nonexistent.h>
3620_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00003621if { (ac_try="$ac_cpp conftest.$ac_ext"
3622case "(($ac_try" in
3623 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3624 *) ac_try_echo=$ac_try;;
3625esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00003626eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003627 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00003628 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00003629 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00003630 rm -f conftest.er1
3631 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003632 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00003633 (exit $ac_status); } >/dev/null && {
3634 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3635 test ! -s conftest.err
3636 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00003637 # Broken: success on invalid input.
3638continue
3639else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003640 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00003641sed 's/^/| /' conftest.$ac_ext >&5
3642
Martin v. Löwis11437992002-04-12 09:54:03 +00003643 # Passes both tests.
3644ac_preproc_ok=:
3645break
3646fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003647
Martin v. Löwis11437992002-04-12 09:54:03 +00003648rm -f conftest.err conftest.$ac_ext
3649
3650done
3651# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3652rm -f conftest.err conftest.$ac_ext
3653if $ac_preproc_ok; then
3654 :
3655else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003656 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
Skip Montanaro6dead952003-09-25 14:50:04 +00003657See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00003658echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
Skip Montanaro6dead952003-09-25 14:50:04 +00003659See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00003660 { (exit 1); exit 1; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003661fi
3662
3663ac_ext=c
3664ac_cpp='$CPP $CPPFLAGS'
3665ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3666ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3667ac_compiler_gnu=$ac_cv_c_compiler_gnu
3668
3669
Ronald Oussoren450d5612009-06-08 21:12:41 +00003670{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
3671echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003672if test "${ac_cv_path_GREP+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003673 echo $ECHO_N "(cached) $ECHO_C" >&6
Skip Montanaro6dead952003-09-25 14:50:04 +00003674else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003675 # Extract the first word of "grep ggrep" to use in msg output
3676if test -z "$GREP"; then
3677set dummy grep ggrep; ac_prog_name=$2
3678if test "${ac_cv_path_GREP+set}" = set; then
3679 echo $ECHO_N "(cached) $ECHO_C" >&6
3680else
Martin v. Löwiseba40652007-08-30 20:10:57 +00003681 ac_path_GREP_found=false
Ronald Oussoren450d5612009-06-08 21:12:41 +00003682# Loop through the user's path and test for each of PROGNAME-LIST
3683as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwiseba40652007-08-30 20:10:57 +00003684for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3685do
3686 IFS=$as_save_IFS
3687 test -z "$as_dir" && as_dir=.
3688 for ac_prog in grep ggrep; do
Ronald Oussoren450d5612009-06-08 21:12:41 +00003689 for ac_exec_ext in '' $ac_executable_extensions; do
3690 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3691 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3692 # Check for GNU ac_path_GREP and select it if it is found.
Martin v. Löwiseba40652007-08-30 20:10:57 +00003693 # Check for GNU $ac_path_GREP
3694case `"$ac_path_GREP" --version 2>&1` in
3695*GNU*)
3696 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3697*)
3698 ac_count=0
Ronald Oussoren450d5612009-06-08 21:12:41 +00003699 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003700 while :
3701 do
3702 cat "conftest.in" "conftest.in" >"conftest.tmp"
3703 mv "conftest.tmp" "conftest.in"
3704 cp "conftest.in" "conftest.nl"
Ronald Oussoren450d5612009-06-08 21:12:41 +00003705 echo 'GREP' >> "conftest.nl"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003706 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3707 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3708 ac_count=`expr $ac_count + 1`
3709 if test $ac_count -gt ${ac_path_GREP_max-0}; then
3710 # Best one so far, save it but keep looking for a better one
3711 ac_cv_path_GREP="$ac_path_GREP"
3712 ac_path_GREP_max=$ac_count
Skip Montanaro6dead952003-09-25 14:50:04 +00003713 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00003714 # 10*(2^10) chars as input seems more than enough
3715 test $ac_count -gt 10 && break
3716 done
3717 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3718esac
3719
Ronald Oussoren450d5612009-06-08 21:12:41 +00003720
3721 $ac_path_GREP_found && break 3
Martin v. Löwiseba40652007-08-30 20:10:57 +00003722 done
3723done
Ronald Oussoren450d5612009-06-08 21:12:41 +00003724
3725done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003726IFS=$as_save_IFS
Ronald Oussoren450d5612009-06-08 21:12:41 +00003727
3728
3729fi
3730
3731GREP="$ac_cv_path_GREP"
3732if test -z "$GREP"; then
3733 { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
3734echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00003735 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +00003736fi
3737
Martin v. Löwiseba40652007-08-30 20:10:57 +00003738else
3739 ac_cv_path_GREP=$GREP
3740fi
3741
Ronald Oussoren450d5612009-06-08 21:12:41 +00003742
Martin v. Löwiseba40652007-08-30 20:10:57 +00003743fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003744{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
3745echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003746 GREP="$ac_cv_path_GREP"
3747
3748
Ronald Oussoren450d5612009-06-08 21:12:41 +00003749{ echo "$as_me:$LINENO: checking for egrep" >&5
3750echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003751if test "${ac_cv_path_EGREP+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003752 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwiseba40652007-08-30 20:10:57 +00003753else
3754 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3755 then ac_cv_path_EGREP="$GREP -E"
3756 else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003757 # Extract the first word of "egrep" to use in msg output
3758if test -z "$EGREP"; then
3759set dummy egrep; ac_prog_name=$2
3760if test "${ac_cv_path_EGREP+set}" = set; then
3761 echo $ECHO_N "(cached) $ECHO_C" >&6
3762else
Martin v. Löwiseba40652007-08-30 20:10:57 +00003763 ac_path_EGREP_found=false
Ronald Oussoren450d5612009-06-08 21:12:41 +00003764# Loop through the user's path and test for each of PROGNAME-LIST
3765as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwiseba40652007-08-30 20:10:57 +00003766for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3767do
3768 IFS=$as_save_IFS
3769 test -z "$as_dir" && as_dir=.
3770 for ac_prog in egrep; do
Ronald Oussoren450d5612009-06-08 21:12:41 +00003771 for ac_exec_ext in '' $ac_executable_extensions; do
3772 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3773 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3774 # Check for GNU ac_path_EGREP and select it if it is found.
Martin v. Löwiseba40652007-08-30 20:10:57 +00003775 # Check for GNU $ac_path_EGREP
3776case `"$ac_path_EGREP" --version 2>&1` in
3777*GNU*)
3778 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3779*)
3780 ac_count=0
Ronald Oussoren450d5612009-06-08 21:12:41 +00003781 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003782 while :
3783 do
3784 cat "conftest.in" "conftest.in" >"conftest.tmp"
3785 mv "conftest.tmp" "conftest.in"
3786 cp "conftest.in" "conftest.nl"
Ronald Oussoren450d5612009-06-08 21:12:41 +00003787 echo 'EGREP' >> "conftest.nl"
Martin v. Löwiseba40652007-08-30 20:10:57 +00003788 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3789 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3790 ac_count=`expr $ac_count + 1`
3791 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3792 # Best one so far, save it but keep looking for a better one
3793 ac_cv_path_EGREP="$ac_path_EGREP"
3794 ac_path_EGREP_max=$ac_count
3795 fi
3796 # 10*(2^10) chars as input seems more than enough
3797 test $ac_count -gt 10 && break
3798 done
3799 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3800esac
3801
Ronald Oussoren450d5612009-06-08 21:12:41 +00003802
3803 $ac_path_EGREP_found && break 3
Martin v. Löwiseba40652007-08-30 20:10:57 +00003804 done
3805done
Ronald Oussoren450d5612009-06-08 21:12:41 +00003806
3807done
Martin v. Löwiseba40652007-08-30 20:10:57 +00003808IFS=$as_save_IFS
Ronald Oussoren450d5612009-06-08 21:12:41 +00003809
3810
3811fi
3812
3813EGREP="$ac_cv_path_EGREP"
3814if test -z "$EGREP"; then
3815 { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
3816echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00003817 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +00003818fi
3819
Martin v. Löwiseba40652007-08-30 20:10:57 +00003820else
3821 ac_cv_path_EGREP=$EGREP
3822fi
3823
Ronald Oussoren450d5612009-06-08 21:12:41 +00003824
Martin v. Löwiseba40652007-08-30 20:10:57 +00003825 fi
3826fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003827{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
3828echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00003829 EGREP="$ac_cv_path_EGREP"
Skip Montanaro6dead952003-09-25 14:50:04 +00003830
3831
Ronald Oussoren450d5612009-06-08 21:12:41 +00003832
3833{ echo "$as_me:$LINENO: checking for AIX" >&5
3834echo $ECHO_N "checking for AIX... $ECHO_C" >&6; }
3835cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00003836/* confdefs.h. */
3837_ACEOF
3838cat confdefs.h >>conftest.$ac_ext
3839cat >>conftest.$ac_ext <<_ACEOF
3840/* end confdefs.h. */
Ronald Oussoren450d5612009-06-08 21:12:41 +00003841#ifdef _AIX
3842 yes
Martin v. Löwis11437992002-04-12 09:54:03 +00003843#endif
Michael W. Hudson54241132001-12-07 15:38:26 +00003844
Martin v. Löwis11437992002-04-12 09:54:03 +00003845_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +00003846if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3847 $EGREP "yes" >/dev/null 2>&1; then
3848 { echo "$as_me:$LINENO: result: yes" >&5
3849echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00003850cat >>confdefs.h <<\_ACEOF
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003851#define _ALL_SOURCE 1
3852_ACEOF
3853
Ronald Oussoren450d5612009-06-08 21:12:41 +00003854else
3855 { echo "$as_me:$LINENO: result: no" >&5
3856echo "${ECHO_T}no" >&6; }
3857fi
3858rm -f conftest*
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003859
3860
3861
3862# Check for unsupported systems
3863case $ac_sys_system/$ac_sys_release in
3864atheos*|Linux*/1*)
3865 echo This system \($ac_sys_system/$ac_sys_release\) is no longer supported.
3866 echo See README for details.
3867 exit 1;;
3868esac
3869
3870
Ronald Oussoren450d5612009-06-08 21:12:41 +00003871{ echo "$as_me:$LINENO: checking for --with-suffix" >&5
3872echo $ECHO_N "checking for --with-suffix... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003873
3874# Check whether --with-suffix was given.
3875if test "${with_suffix+set}" = set; then
3876 withval=$with_suffix;
3877 case $withval in
3878 no) EXEEXT=;;
3879 yes) EXEEXT=.exe;;
3880 *) EXEEXT=$withval;;
3881 esac
3882fi
3883
Ronald Oussoren450d5612009-06-08 21:12:41 +00003884{ echo "$as_me:$LINENO: result: $EXEEXT" >&5
3885echo "${ECHO_T}$EXEEXT" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003886
3887# Test whether we're running on a non-case-sensitive system, in which
3888# case we give a warning if no ext is given
3889
Ronald Oussoren450d5612009-06-08 21:12:41 +00003890{ echo "$as_me:$LINENO: checking for case-insensitive build directory" >&5
3891echo $ECHO_N "checking for case-insensitive build directory... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003892if test ! -d CaseSensitiveTestDir; then
3893mkdir CaseSensitiveTestDir
3894fi
3895
3896if test -d casesensitivetestdir
3897then
Ronald Oussoren450d5612009-06-08 21:12:41 +00003898 { echo "$as_me:$LINENO: result: yes" >&5
3899echo "${ECHO_T}yes" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003900 BUILDEXEEXT=.exe
3901else
Ronald Oussoren450d5612009-06-08 21:12:41 +00003902 { echo "$as_me:$LINENO: result: no" >&5
3903echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003904 BUILDEXEEXT=$EXEEXT
3905fi
3906rmdir CaseSensitiveTestDir
3907
3908case $MACHDEP in
3909bsdos*)
3910 case $CC in
3911 gcc) CC="$CC -D_HAVE_BSDI";;
3912 esac;;
3913esac
3914
3915case $ac_sys_system in
3916hp*|HP*)
3917 case $CC in
3918 cc|*/cc) CC="$CC -Ae";;
3919 esac;;
3920Monterey*)
3921 case $CC in
3922 cc) CC="$CC -Wl,-Bexport";;
3923 esac;;
3924SunOS*)
3925 # Some functions have a prototype only with that define, e.g. confstr
3926
3927cat >>confdefs.h <<\_ACEOF
3928#define __EXTENSIONS__ 1
3929_ACEOF
3930
3931 ;;
3932esac
3933
3934
3935
Ronald Oussoren450d5612009-06-08 21:12:41 +00003936{ echo "$as_me:$LINENO: checking LIBRARY" >&5
3937echo $ECHO_N "checking LIBRARY... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003938if test -z "$LIBRARY"
3939then
3940 LIBRARY='libpython$(VERSION).a'
3941fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003942{ echo "$as_me:$LINENO: result: $LIBRARY" >&5
3943echo "${ECHO_T}$LIBRARY" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003944
3945# LDLIBRARY is the name of the library to link against (as opposed to the
3946# name of the library into which to insert object files). BLDLIBRARY is also
3947# the library to link against, usually. On Mac OS X frameworks, BLDLIBRARY
3948# is blank as the main program is not linked directly against LDLIBRARY.
3949# LDLIBRARYDIR is the path to LDLIBRARY, which is made in a subdirectory. On
3950# systems without shared libraries, LDLIBRARY is the same as LIBRARY
3951# (defined in the Makefiles). On Cygwin LDLIBRARY is the import library,
3952# DLLLIBRARY is the shared (i.e., DLL) library.
3953#
3954# RUNSHARED is used to run shared python without installed libraries
3955#
3956# INSTSONAME is the name of the shared library that will be use to install
3957# on the system - some systems like version suffix, others don't
3958
3959
3960
3961
3962
3963
3964LDLIBRARY="$LIBRARY"
3965BLDLIBRARY='$(LDLIBRARY)'
3966INSTSONAME='$(LDLIBRARY)'
3967DLLLIBRARY=''
3968LDLIBRARYDIR=''
3969RUNSHARED=''
3970
3971# LINKCC is the command that links the python executable -- default is $(CC).
3972# If CXX is set, and if it is needed to link a main function that was
3973# compiled with CXX, LINKCC is CXX instead. Always using CXX is undesirable:
3974# python might then depend on the C++ runtime
3975# This is altered for AIX in order to build the export list before
3976# linking.
3977
Ronald Oussoren450d5612009-06-08 21:12:41 +00003978{ echo "$as_me:$LINENO: checking LINKCC" >&5
3979echo $ECHO_N "checking LINKCC... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00003980if test -z "$LINKCC"
3981then
3982 LINKCC='$(PURIFY) $(MAINCC)'
3983 case $ac_sys_system in
3984 AIX*)
3985 exp_extra="\"\""
3986 if test $ac_sys_release -ge 5 -o \
3987 $ac_sys_release -eq 4 -a `uname -r` -ge 2 ; then
3988 exp_extra="."
3989 fi
3990 LINKCC="\$(srcdir)/Modules/makexp_aix Modules/python.exp $exp_extra \$(LIBRARY); $LINKCC";;
3991 Monterey64*)
3992 LINKCC="$LINKCC -L/usr/lib/ia64l64";;
3993 QNX*)
3994 # qcc must be used because the other compilers do not
3995 # support -N.
3996 LINKCC=qcc;;
3997 esac
3998fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00003999{ echo "$as_me:$LINENO: result: $LINKCC" >&5
4000echo "${ECHO_T}$LINKCC" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004001
4002# GNULD is set to "yes" if the GNU linker is used. If this goes wrong
4003# make sure we default having it set to "no": this is used by
4004# distutils.unixccompiler to know if it should add --enable-new-dtags
4005# to linker command lines, and failing to detect GNU ld simply results
4006# in the same bahaviour as before.
4007
Ronald Oussoren450d5612009-06-08 21:12:41 +00004008{ echo "$as_me:$LINENO: checking for GNU ld" >&5
4009echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004010ac_prog=ld
4011if test "$GCC" = yes; then
4012 ac_prog=`$CC -print-prog-name=ld`
4013fi
4014case `"$ac_prog" -V 2>&1 < /dev/null` in
4015 *GNU*)
4016 GNULD=yes;;
4017 *)
4018 GNULD=no;;
4019esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004020{ echo "$as_me:$LINENO: result: $GNULD" >&5
4021echo "${ECHO_T}$GNULD" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004022
Ronald Oussoren450d5612009-06-08 21:12:41 +00004023{ echo "$as_me:$LINENO: checking for --enable-shared" >&5
4024echo $ECHO_N "checking for --enable-shared... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004025# Check whether --enable-shared was given.
4026if test "${enable_shared+set}" = set; then
4027 enableval=$enable_shared;
4028fi
4029
4030
4031if test -z "$enable_shared"
4032then
4033 case $ac_sys_system in
4034 CYGWIN* | atheos*)
4035 enable_shared="yes";;
4036 *)
4037 enable_shared="no";;
4038 esac
4039fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00004040{ echo "$as_me:$LINENO: result: $enable_shared" >&5
4041echo "${ECHO_T}$enable_shared" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004042
Ronald Oussoren450d5612009-06-08 21:12:41 +00004043{ echo "$as_me:$LINENO: checking for --enable-profiling" >&5
4044echo $ECHO_N "checking for --enable-profiling... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004045# Check whether --enable-profiling was given.
4046if test "${enable_profiling+set}" = set; then
4047 enableval=$enable_profiling; ac_save_cc="$CC"
4048 CC="$CC -pg"
4049 if test "$cross_compiling" = yes; then
4050 ac_enable_profiling="no"
4051else
4052 cat >conftest.$ac_ext <<_ACEOF
4053/* confdefs.h. */
4054_ACEOF
4055cat confdefs.h >>conftest.$ac_ext
4056cat >>conftest.$ac_ext <<_ACEOF
4057/* end confdefs.h. */
4058int main() { return 0; }
4059_ACEOF
4060rm -f conftest$ac_exeext
4061if { (ac_try="$ac_link"
4062case "(($ac_try" in
4063 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4064 *) ac_try_echo=$ac_try;;
4065esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004066eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004067 (eval "$ac_link") 2>&5
4068 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004069 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004070 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4071 { (case "(($ac_try" in
4072 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4073 *) ac_try_echo=$ac_try;;
4074esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004075eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004076 (eval "$ac_try") 2>&5
4077 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004079 (exit $ac_status); }; }; then
4080 ac_enable_profiling="yes"
4081else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004082 echo "$as_me: program exited with status $ac_status" >&5
4083echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004084sed 's/^/| /' conftest.$ac_ext >&5
4085
4086( exit $ac_status )
4087ac_enable_profiling="no"
4088fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004089rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4090fi
4091
4092
4093 CC="$ac_save_cc"
4094fi
4095
Ronald Oussoren450d5612009-06-08 21:12:41 +00004096{ echo "$as_me:$LINENO: result: $ac_enable_profiling" >&5
4097echo "${ECHO_T}$ac_enable_profiling" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004098
4099case "$ac_enable_profiling" in
4100 "yes")
4101 BASECFLAGS="-pg $BASECFLAGS"
4102 LDFLAGS="-pg $LDFLAGS"
4103 ;;
4104esac
4105
Ronald Oussoren450d5612009-06-08 21:12:41 +00004106{ echo "$as_me:$LINENO: checking LDLIBRARY" >&5
4107echo $ECHO_N "checking LDLIBRARY... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004108
4109# MacOSX framework builds need more magic. LDLIBRARY is the dynamic
4110# library that we build, but we do not want to link against it (we
4111# will find it with a -framework option). For this reason there is an
4112# extra variable BLDLIBRARY against which Python and the extension
4113# modules are linked, BLDLIBRARY. This is normally the same as
4114# LDLIBRARY, but empty for MacOSX framework builds.
4115if test "$enable_framework"
4116then
4117 LDLIBRARY='$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
4118 RUNSHARED=DYLD_FRAMEWORK_PATH="`pwd`:$DYLD_FRAMEWORK_PATH"
4119 BLDLIBRARY=''
4120else
4121 BLDLIBRARY='$(LDLIBRARY)'
4122fi
4123
4124# Other platforms follow
4125if test $enable_shared = "yes"; then
4126
4127cat >>confdefs.h <<\_ACEOF
4128#define Py_ENABLE_SHARED 1
4129_ACEOF
4130
4131 case $ac_sys_system in
4132 BeOS*)
4133 LDLIBRARY='libpython$(VERSION).so'
4134 ;;
4135 CYGWIN*)
4136 LDLIBRARY='libpython$(VERSION).dll.a'
4137 DLLLIBRARY='libpython$(VERSION).dll'
4138 ;;
4139 SunOS*)
4140 LDLIBRARY='libpython$(VERSION).so'
4141 BLDLIBRARY='-Wl,-R,$(LIBDIR) -L. -lpython$(VERSION)'
4142 RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
4143 INSTSONAME="$LDLIBRARY".$SOVERSION
4144 ;;
4145 Linux*|GNU*|NetBSD*|FreeBSD*|DragonFly*)
4146 LDLIBRARY='libpython$(VERSION).so'
4147 BLDLIBRARY='-L. -lpython$(VERSION)'
4148 RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
4149 case $ac_sys_system in
4150 FreeBSD*)
4151 SOVERSION=`echo $SOVERSION|cut -d "." -f 1`
4152 ;;
4153 esac
4154 INSTSONAME="$LDLIBRARY".$SOVERSION
4155 ;;
4156 hp*|HP*)
4157 case `uname -m` in
4158 ia64)
4159 LDLIBRARY='libpython$(VERSION).so'
4160 ;;
4161 *)
4162 LDLIBRARY='libpython$(VERSION).sl'
4163 ;;
4164 esac
4165 BLDLIBRARY='-Wl,+b,$(LIBDIR) -L. -lpython$(VERSION)'
4166 RUNSHARED=SHLIB_PATH=`pwd`:${SHLIB_PATH}
4167 ;;
4168 OSF*)
4169 LDLIBRARY='libpython$(VERSION).so'
4170 BLDLIBRARY='-rpath $(LIBDIR) -L. -lpython$(VERSION)'
4171 RUNSHARED=LD_LIBRARY_PATH=`pwd`:${LD_LIBRARY_PATH}
4172 ;;
4173 atheos*)
4174 LDLIBRARY='libpython$(VERSION).so'
4175 BLDLIBRARY='-L. -lpython$(VERSION)'
4176 RUNSHARED=DLL_PATH=`pwd`:${DLL_PATH:-/atheos/sys/libs:/atheos/autolnk/lib}
4177 ;;
4178 Darwin*)
4179 LDLIBRARY='libpython$(VERSION).dylib'
4180 BLDLIBRARY='-L. -lpython$(VERSION)'
4181 RUNSHARED='DYLD_LIBRARY_PATH=`pwd`:${DYLD_LIBRARY_PATH}'
4182 ;;
4183
4184 esac
4185else # shared is disabled
4186 case $ac_sys_system in
4187 CYGWIN*)
4188 BLDLIBRARY='$(LIBRARY)'
4189 LDLIBRARY='libpython$(VERSION).dll.a'
4190 ;;
4191 esac
4192fi
4193
Ronald Oussoren450d5612009-06-08 21:12:41 +00004194{ echo "$as_me:$LINENO: result: $LDLIBRARY" >&5
4195echo "${ECHO_T}$LDLIBRARY" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004196
4197if test -n "$ac_tool_prefix"; then
4198 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4199set dummy ${ac_tool_prefix}ranlib; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00004200{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4201echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004202if test "${ac_cv_prog_RANLIB+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004203 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004204else
4205 if test -n "$RANLIB"; then
4206 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4207else
4208as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4209for as_dir in $PATH
4210do
4211 IFS=$as_save_IFS
4212 test -z "$as_dir" && as_dir=.
4213 for ac_exec_ext in '' $ac_executable_extensions; do
4214 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4215 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
Ronald Oussoren450d5612009-06-08 21:12:41 +00004216 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004217 break 2
4218 fi
4219done
4220done
4221IFS=$as_save_IFS
4222
4223fi
4224fi
4225RANLIB=$ac_cv_prog_RANLIB
4226if test -n "$RANLIB"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004227 { echo "$as_me:$LINENO: result: $RANLIB" >&5
4228echo "${ECHO_T}$RANLIB" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004229else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004230 { echo "$as_me:$LINENO: result: no" >&5
4231echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004232fi
4233
4234
4235fi
4236if test -z "$ac_cv_prog_RANLIB"; then
4237 ac_ct_RANLIB=$RANLIB
4238 # Extract the first word of "ranlib", so it can be a program name with args.
4239set dummy ranlib; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00004240{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4241echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004242if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004243 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004244else
4245 if test -n "$ac_ct_RANLIB"; then
4246 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4247else
4248as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4249for as_dir in $PATH
4250do
4251 IFS=$as_save_IFS
4252 test -z "$as_dir" && as_dir=.
4253 for ac_exec_ext in '' $ac_executable_extensions; do
4254 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4255 ac_cv_prog_ac_ct_RANLIB="ranlib"
Ronald Oussoren450d5612009-06-08 21:12:41 +00004256 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004257 break 2
4258 fi
4259done
4260done
4261IFS=$as_save_IFS
4262
4263fi
4264fi
4265ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4266if test -n "$ac_ct_RANLIB"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004267 { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4268echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004269else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004270 { echo "$as_me:$LINENO: result: no" >&5
4271echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004272fi
4273
4274 if test "x$ac_ct_RANLIB" = x; then
4275 RANLIB=":"
4276 else
4277 case $cross_compiling:$ac_tool_warned in
4278yes:)
Ronald Oussoren450d5612009-06-08 21:12:41 +00004279{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
4280whose name does not start with the host triplet. If you think this
4281configuration is useful to you, please write to autoconf@gnu.org." >&5
4282echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
4283whose name does not start with the host triplet. If you think this
4284configuration is useful to you, please write to autoconf@gnu.org." >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004285ac_tool_warned=yes ;;
4286esac
4287 RANLIB=$ac_ct_RANLIB
4288 fi
4289else
4290 RANLIB="$ac_cv_prog_RANLIB"
4291fi
4292
4293
4294for ac_prog in ar aal
4295do
4296 # Extract the first word of "$ac_prog", so it can be a program name with args.
4297set dummy $ac_prog; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00004298{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4299echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004300if test "${ac_cv_prog_AR+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004301 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004302else
4303 if test -n "$AR"; then
4304 ac_cv_prog_AR="$AR" # Let the user override the test.
4305else
4306as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4307for as_dir in $PATH
4308do
4309 IFS=$as_save_IFS
4310 test -z "$as_dir" && as_dir=.
4311 for ac_exec_ext in '' $ac_executable_extensions; do
4312 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4313 ac_cv_prog_AR="$ac_prog"
Ronald Oussoren450d5612009-06-08 21:12:41 +00004314 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004315 break 2
4316 fi
4317done
4318done
4319IFS=$as_save_IFS
4320
4321fi
4322fi
4323AR=$ac_cv_prog_AR
4324if test -n "$AR"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004325 { echo "$as_me:$LINENO: result: $AR" >&5
4326echo "${ECHO_T}$AR" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004327else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004328 { echo "$as_me:$LINENO: result: no" >&5
4329echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004330fi
4331
4332
4333 test -n "$AR" && break
4334done
4335test -n "$AR" || AR="ar"
4336
4337
4338# tweak ARFLAGS only if the user didn't set it on the command line
4339
4340if test -z "$ARFLAGS"
4341then
4342 ARFLAGS="rc"
4343fi
4344
4345
4346# Extract the first word of "svnversion", so it can be a program name with args.
4347set dummy svnversion; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +00004348{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4349echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004350if test "${ac_cv_prog_SVNVERSION+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004351 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004352else
4353 if test -n "$SVNVERSION"; then
4354 ac_cv_prog_SVNVERSION="$SVNVERSION" # Let the user override the test.
4355else
4356as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4357for as_dir in $PATH
4358do
4359 IFS=$as_save_IFS
4360 test -z "$as_dir" && as_dir=.
4361 for ac_exec_ext in '' $ac_executable_extensions; do
4362 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4363 ac_cv_prog_SVNVERSION="found"
Ronald Oussoren450d5612009-06-08 21:12:41 +00004364 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004365 break 2
4366 fi
4367done
4368done
4369IFS=$as_save_IFS
4370
4371 test -z "$ac_cv_prog_SVNVERSION" && ac_cv_prog_SVNVERSION="not-found"
4372fi
4373fi
4374SVNVERSION=$ac_cv_prog_SVNVERSION
4375if test -n "$SVNVERSION"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004376 { echo "$as_me:$LINENO: result: $SVNVERSION" >&5
4377echo "${ECHO_T}$SVNVERSION" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004378else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004379 { echo "$as_me:$LINENO: result: no" >&5
4380echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004381fi
4382
4383
4384if test $SVNVERSION = found
4385then
4386 SVNVERSION="svnversion \$(srcdir)"
4387else
4388 SVNVERSION="echo Unversioned directory"
4389fi
4390
4391case $MACHDEP in
4392bsdos*|hp*|HP*)
4393 # install -d does not work on BSDI or HP-UX
4394 if test -z "$INSTALL"
4395 then
4396 INSTALL="${srcdir}/install-sh -c"
4397 fi
4398esac
4399ac_aux_dir=
4400for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
4401 if test -f "$ac_dir/install-sh"; then
4402 ac_aux_dir=$ac_dir
4403 ac_install_sh="$ac_aux_dir/install-sh -c"
4404 break
4405 elif test -f "$ac_dir/install.sh"; then
4406 ac_aux_dir=$ac_dir
4407 ac_install_sh="$ac_aux_dir/install.sh -c"
4408 break
4409 elif test -f "$ac_dir/shtool"; then
4410 ac_aux_dir=$ac_dir
4411 ac_install_sh="$ac_aux_dir/shtool install -c"
4412 break
4413 fi
4414done
4415if test -z "$ac_aux_dir"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004416 { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
4417echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004418 { (exit 1); exit 1; }; }
4419fi
4420
4421# These three variables are undocumented and unsupported,
4422# and are intended to be withdrawn in a future Autoconf release.
4423# They can cause serious problems if a builder's source tree is in a directory
4424# whose full name contains unusual characters.
4425ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
4426ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
4427ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
4428
4429
4430# Find a good install program. We prefer a C program (faster),
4431# so one script is as good as another. But avoid the broken or
4432# incompatible versions:
4433# SysV /etc/install, /usr/sbin/install
4434# SunOS /usr/etc/install
4435# IRIX /sbin/install
4436# AIX /bin/install
4437# AmigaOS /C/install, which installs bootblocks on floppy discs
4438# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4439# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4440# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4441# OS/2's system install, which has a completely different semantic
4442# ./install, which can be erroneously created by make from ./install.sh.
Ronald Oussoren450d5612009-06-08 21:12:41 +00004443{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
4444echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004445if test -z "$INSTALL"; then
4446if test "${ac_cv_path_install+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004447 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004448else
4449 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4450for as_dir in $PATH
4451do
4452 IFS=$as_save_IFS
4453 test -z "$as_dir" && as_dir=.
4454 # Account for people who put trailing slashes in PATH elements.
4455case $as_dir/ in
4456 ./ | .// | /cC/* | \
4457 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4458 ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
4459 /usr/ucb/* ) ;;
4460 *)
4461 # OSF1 and SCO ODT 3.0 have their own names for install.
4462 # Don't use installbsd from OSF since it installs stuff as root
4463 # by default.
4464 for ac_prog in ginstall scoinst install; do
4465 for ac_exec_ext in '' $ac_executable_extensions; do
4466 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
4467 if test $ac_prog = install &&
4468 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4469 # AIX install. It has an incompatible calling convention.
4470 :
4471 elif test $ac_prog = install &&
4472 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4473 # program-specific install script used by HP pwplus--don't use.
4474 :
4475 else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004476 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4477 break 3
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004478 fi
4479 fi
4480 done
4481 done
4482 ;;
4483esac
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004484done
4485IFS=$as_save_IFS
4486
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004487
4488fi
4489 if test "${ac_cv_path_install+set}" = set; then
4490 INSTALL=$ac_cv_path_install
4491 else
4492 # As a last resort, use the slow shell script. Don't cache a
4493 # value for INSTALL within a source directory, because that will
4494 # break other packages using the cache if that directory is
4495 # removed, or if the value is a relative name.
4496 INSTALL=$ac_install_sh
4497 fi
4498fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00004499{ echo "$as_me:$LINENO: result: $INSTALL" >&5
4500echo "${ECHO_T}$INSTALL" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004501
4502# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4503# It thinks the first close brace ends the variable substitution.
4504test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4505
4506test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4507
4508test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4509
4510
4511# Not every filesystem supports hard links
4512
4513if test -z "$LN" ; then
4514 case $ac_sys_system in
4515 BeOS*) LN="ln -s";;
4516 CYGWIN*) LN="ln -s";;
4517 atheos*) LN="ln -s";;
4518 *) LN=ln;;
4519 esac
4520fi
4521
4522# Check for --with-pydebug
Ronald Oussoren450d5612009-06-08 21:12:41 +00004523{ echo "$as_me:$LINENO: checking for --with-pydebug" >&5
4524echo $ECHO_N "checking for --with-pydebug... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004525
4526# Check whether --with-pydebug was given.
4527if test "${with_pydebug+set}" = set; then
4528 withval=$with_pydebug;
4529if test "$withval" != no
4530then
4531
4532cat >>confdefs.h <<\_ACEOF
4533#define Py_DEBUG 1
4534_ACEOF
4535
Ronald Oussoren450d5612009-06-08 21:12:41 +00004536 { echo "$as_me:$LINENO: result: yes" >&5
4537echo "${ECHO_T}yes" >&6; };
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004538 Py_DEBUG='true'
Ronald Oussoren450d5612009-06-08 21:12:41 +00004539else { echo "$as_me:$LINENO: result: no" >&5
4540echo "${ECHO_T}no" >&6; }; Py_DEBUG='false'
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004541fi
4542else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004543 { echo "$as_me:$LINENO: result: no" >&5
4544echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004545fi
4546
4547
4548# XXX Shouldn't the code above that fiddles with BASECFLAGS and OPT be
4549# merged with this chunk of code?
4550
4551# Optimizer/debugger flags
4552# ------------------------
4553# (The following bit of code is complicated enough - please keep things
4554# indented properly. Just pretend you're editing Python code. ;-)
4555
4556# There are two parallel sets of case statements below, one that checks to
4557# see if OPT was set and one that does BASECFLAGS setting based upon
4558# compiler and platform. BASECFLAGS tweaks need to be made even if the
4559# user set OPT.
4560
4561# tweak OPT based on compiler and platform, only if the user didn't set
4562# it on the command line
4563
4564if test -z "$OPT"
4565then
4566 case $GCC in
4567 yes)
4568 if test "$CC" != 'g++' ; then
4569 STRICT_PROTO="-Wstrict-prototypes"
4570 fi
4571 # For gcc 4.x we need to use -fwrapv so lets check if its supported
4572 if "$CC" -v --help 2>/dev/null |grep -- -fwrapv > /dev/null; then
4573 WRAP="-fwrapv"
4574 fi
4575 case $ac_cv_prog_cc_g in
4576 yes)
4577 if test "$Py_DEBUG" = 'true' ; then
4578 # Optimization messes up debuggers, so turn it off for
4579 # debug builds.
4580 OPT="-g -Wall $STRICT_PROTO"
4581 else
4582 OPT="-g $WRAP -O3 -Wall $STRICT_PROTO"
4583 fi
4584 ;;
4585 *)
4586 OPT="-O3 -Wall $STRICT_PROTO"
4587 ;;
4588 esac
4589 case $ac_sys_system in
4590 SCO_SV*) OPT="$OPT -m486 -DSCO5"
4591 ;;
4592 esac
4593 ;;
4594
4595 *)
4596 OPT="-O"
4597 ;;
4598 esac
4599
4600 # The current (beta) Monterey compiler dies with optimizations
4601 # XXX what is Monterey? Does it still die w/ -O? Can we get rid of this?
4602 case $ac_sys_system in
4603 Monterey*)
4604 OPT=""
4605 ;;
4606 esac
4607
4608fi
4609
4610
4611
4612# The -arch flags for universal builds on OSX
4613UNIVERSAL_ARCH_FLAGS=
4614
4615
4616# tweak BASECFLAGS based on compiler and platform
4617case $GCC in
4618yes)
4619 # Python violates C99 rules, by casting between incompatible
4620 # pointer types. GCC may generate bad code as a result of that,
4621 # so use -fno-strict-aliasing if supported.
Ronald Oussoren450d5612009-06-08 21:12:41 +00004622 { echo "$as_me:$LINENO: checking whether $CC accepts -fno-strict-aliasing" >&5
4623echo $ECHO_N "checking whether $CC accepts -fno-strict-aliasing... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004624 ac_save_cc="$CC"
4625 CC="$CC -fno-strict-aliasing"
4626 if test "$cross_compiling" = yes; then
4627 ac_cv_no_strict_aliasing_ok=no
4628else
4629 cat >conftest.$ac_ext <<_ACEOF
4630/* confdefs.h. */
4631_ACEOF
4632cat confdefs.h >>conftest.$ac_ext
4633cat >>conftest.$ac_ext <<_ACEOF
4634/* end confdefs.h. */
4635int main() { return 0; }
4636_ACEOF
4637rm -f conftest$ac_exeext
4638if { (ac_try="$ac_link"
4639case "(($ac_try" in
4640 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4641 *) ac_try_echo=$ac_try;;
4642esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004643eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004644 (eval "$ac_link") 2>&5
4645 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004646 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004647 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4648 { (case "(($ac_try" in
4649 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4650 *) ac_try_echo=$ac_try;;
4651esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004652eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004653 (eval "$ac_try") 2>&5
4654 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004655 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004656 (exit $ac_status); }; }; then
4657 ac_cv_no_strict_aliasing_ok=yes
4658else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004659 echo "$as_me: program exited with status $ac_status" >&5
4660echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004661sed 's/^/| /' conftest.$ac_ext >&5
4662
4663( exit $ac_status )
4664ac_cv_no_strict_aliasing_ok=no
4665fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004666rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4667fi
4668
4669
4670 CC="$ac_save_cc"
Ronald Oussoren450d5612009-06-08 21:12:41 +00004671 { echo "$as_me:$LINENO: result: $ac_cv_no_strict_aliasing_ok" >&5
4672echo "${ECHO_T}$ac_cv_no_strict_aliasing_ok" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004673 if test $ac_cv_no_strict_aliasing_ok = yes
4674 then
4675 BASECFLAGS="$BASECFLAGS -fno-strict-aliasing"
4676 fi
4677
4678 # if using gcc on alpha, use -mieee to get (near) full IEEE 754
4679 # support. Without this, treatment of subnormals doesn't follow
4680 # the standard.
4681 case $ac_sys_machine in
4682 alpha*)
4683 BASECFLAGS="$BASECFLAGS -mieee"
4684 ;;
4685 esac
4686
4687 case $ac_sys_system in
4688 SCO_SV*)
4689 BASECFLAGS="$BASECFLAGS -m486 -DSCO5"
4690 ;;
4691 # is there any other compiler on Darwin besides gcc?
4692 Darwin*)
4693 # -Wno-long-double, -no-cpp-precomp, and -mno-fused-madd
4694 # used to be here, but non-Apple gcc doesn't accept them.
4695
4696
4697 if test "${enable_universalsdk}"; then
4698 UNIVERSAL_ARCH_FLAGS=""
4699 if test "$UNIVERSAL_ARCHS" = "32-bit" ; then
4700 UNIVERSAL_ARCH_FLAGS="-arch ppc -arch i386"
4701 ARCH_RUN_32BIT=""
4702
4703 elif test "$UNIVERSAL_ARCHS" = "64-bit" ; then
4704 UNIVERSAL_ARCH_FLAGS="-arch ppc64 -arch x86_64"
4705
4706 elif test "$UNIVERSAL_ARCHS" = "all" ; then
4707 UNIVERSAL_ARCH_FLAGS="-arch i386 -arch ppc -arch ppc64 -arch x86_64"
4708 ARCH_RUN_32BIT="arch -i386 -ppc"
4709
4710 else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004711 { { echo "$as_me:$LINENO: error: proper usage is --with-universalarch=32-bit|64-bit|all" >&5
4712echo "$as_me: error: proper usage is --with-universalarch=32-bit|64-bit|all" >&2;}
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004713 { (exit 1); exit 1; }; }
4714
4715 fi
4716
4717
4718 BASECFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${BASECFLAGS}"
4719 tgt=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
4720 if test "${UNIVERSALSDK}" != "/" -a "${tgt}" '>' '10.4' ; then
4721 CFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${CFLAGS}"
4722 fi
4723 fi
4724
4725 # Calculate the right deployment target for this build.
4726 #
4727 cur_target=`sw_vers -productVersion | sed 's/\(10\.[0-9]*\).*/\1/'`
4728 if test ${cur_target} '>' 10.2; then
4729 cur_target=10.3
4730 fi
4731 if test "${UNIVERSAL_ARCHS}" = "all"; then
4732 # Ensure that the default platform for a 4-way
4733 # universal build is OSX 10.5, that's the first
4734 # OS release where 4-way builds make sense.
4735 cur_target='10.5'
4736 fi
4737 CONFIGURE_MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET-${cur_target}}
4738
4739 # Make sure that MACOSX_DEPLOYMENT_TARGET is set in the
4740 # environment with a value that is the same as what we'll use
4741 # in the Makefile to ensure that we'll get the same compiler
4742 # environment during configure and build time.
4743 MACOSX_DEPLOYMENT_TARGET="$CONFIGURE_MACOSX_DEPLOYMENT_TARGET"
4744 export MACOSX_DEPLOYMENT_TARGET
4745 EXPORT_MACOSX_DEPLOYMENT_TARGET=''
4746
4747 ;;
4748 OSF*)
4749 BASECFLAGS="$BASECFLAGS -mieee"
4750 ;;
4751 esac
4752 ;;
4753
4754*)
4755 case $ac_sys_system in
4756 OpenUNIX*|UnixWare*)
4757 BASECFLAGS="$BASECFLAGS -K pentium,host,inline,loop_unroll,alloca "
4758 ;;
4759 OSF*)
4760 BASECFLAGS="$BASECFLAGS -ieee -std"
4761 ;;
4762 SCO_SV*)
4763 BASECFLAGS="$BASECFLAGS -belf -Ki486 -DSCO5"
4764 ;;
4765 esac
4766 ;;
4767esac
4768
4769if test "$Py_DEBUG" = 'true'; then
4770 :
4771else
4772 OPT="-DNDEBUG $OPT"
4773fi
4774
4775if test "$ac_arch_flags"
4776then
4777 BASECFLAGS="$BASECFLAGS $ac_arch_flags"
4778fi
4779
4780# disable check for icc since it seems to pass, but generates a warning
4781if test "$CC" = icc
4782then
4783 ac_cv_opt_olimit_ok=no
4784fi
4785
Ronald Oussoren450d5612009-06-08 21:12:41 +00004786{ echo "$as_me:$LINENO: checking whether $CC accepts -OPT:Olimit=0" >&5
4787echo $ECHO_N "checking whether $CC accepts -OPT:Olimit=0... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004788if test "${ac_cv_opt_olimit_ok+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004789 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004790else
4791 ac_save_cc="$CC"
4792CC="$CC -OPT:Olimit=0"
4793if test "$cross_compiling" = yes; then
4794 ac_cv_opt_olimit_ok=no
4795else
4796 cat >conftest.$ac_ext <<_ACEOF
4797/* confdefs.h. */
4798_ACEOF
4799cat confdefs.h >>conftest.$ac_ext
4800cat >>conftest.$ac_ext <<_ACEOF
4801/* end confdefs.h. */
4802int main() { return 0; }
4803_ACEOF
4804rm -f conftest$ac_exeext
4805if { (ac_try="$ac_link"
4806case "(($ac_try" in
4807 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4808 *) ac_try_echo=$ac_try;;
4809esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004810eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004811 (eval "$ac_link") 2>&5
4812 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004814 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4815 { (case "(($ac_try" in
4816 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4817 *) ac_try_echo=$ac_try;;
4818esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004819eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004820 (eval "$ac_try") 2>&5
4821 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004822 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004823 (exit $ac_status); }; }; then
4824 ac_cv_opt_olimit_ok=yes
4825else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004826 echo "$as_me: program exited with status $ac_status" >&5
4827echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004828sed 's/^/| /' conftest.$ac_ext >&5
4829
4830( exit $ac_status )
4831ac_cv_opt_olimit_ok=no
4832fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004833rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4834fi
4835
4836
4837CC="$ac_save_cc"
4838fi
4839
Ronald Oussoren450d5612009-06-08 21:12:41 +00004840{ echo "$as_me:$LINENO: result: $ac_cv_opt_olimit_ok" >&5
4841echo "${ECHO_T}$ac_cv_opt_olimit_ok" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004842if test $ac_cv_opt_olimit_ok = yes; then
4843 case $ac_sys_system in
4844 # XXX is this branch needed? On MacOSX 10.2.2 the result of the
4845 # olimit_ok test is "no". Is it "yes" in some other Darwin-esque
4846 # environment?
4847 Darwin*)
4848 ;;
4849 *)
4850 BASECFLAGS="$BASECFLAGS -OPT:Olimit=0"
4851 ;;
4852 esac
4853else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004854 { echo "$as_me:$LINENO: checking whether $CC accepts -Olimit 1500" >&5
4855echo $ECHO_N "checking whether $CC accepts -Olimit 1500... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004856 if test "${ac_cv_olimit_ok+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004857 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004858else
4859 ac_save_cc="$CC"
4860 CC="$CC -Olimit 1500"
4861 if test "$cross_compiling" = yes; then
4862 ac_cv_olimit_ok=no
4863else
4864 cat >conftest.$ac_ext <<_ACEOF
4865/* confdefs.h. */
4866_ACEOF
4867cat confdefs.h >>conftest.$ac_ext
4868cat >>conftest.$ac_ext <<_ACEOF
4869/* end confdefs.h. */
4870int main() { return 0; }
4871_ACEOF
4872rm -f conftest$ac_exeext
4873if { (ac_try="$ac_link"
4874case "(($ac_try" in
4875 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4876 *) ac_try_echo=$ac_try;;
4877esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004878eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004879 (eval "$ac_link") 2>&5
4880 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004881 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004882 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
4883 { (case "(($ac_try" in
4884 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4885 *) ac_try_echo=$ac_try;;
4886esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004887eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004888 (eval "$ac_try") 2>&5
4889 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00004890 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004891 (exit $ac_status); }; }; then
4892 ac_cv_olimit_ok=yes
4893else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004894 echo "$as_me: program exited with status $ac_status" >&5
4895echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004896sed 's/^/| /' conftest.$ac_ext >&5
4897
4898( exit $ac_status )
4899ac_cv_olimit_ok=no
4900fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004901rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
4902fi
4903
4904
4905 CC="$ac_save_cc"
4906fi
4907
Ronald Oussoren450d5612009-06-08 21:12:41 +00004908 { echo "$as_me:$LINENO: result: $ac_cv_olimit_ok" >&5
4909echo "${ECHO_T}$ac_cv_olimit_ok" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004910 if test $ac_cv_olimit_ok = yes; then
4911 BASECFLAGS="$BASECFLAGS -Olimit 1500"
4912 fi
4913fi
4914
4915# Check whether GCC supports PyArg_ParseTuple format
4916if test "$GCC" = "yes"
4917then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004918 { echo "$as_me:$LINENO: checking whether gcc supports ParseTuple __format__" >&5
4919echo $ECHO_N "checking whether gcc supports ParseTuple __format__... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004920 save_CFLAGS=$CFLAGS
4921 CFLAGS="$CFLAGS -Werror"
4922 cat >conftest.$ac_ext <<_ACEOF
4923/* confdefs.h. */
4924_ACEOF
4925cat confdefs.h >>conftest.$ac_ext
4926cat >>conftest.$ac_ext <<_ACEOF
4927/* end confdefs.h. */
4928
4929 void f(char*,...)__attribute((format(PyArg_ParseTuple, 1, 2)));
4930
4931int
4932main ()
4933{
4934
4935 ;
4936 return 0;
4937}
4938_ACEOF
4939rm -f conftest.$ac_objext
4940if { (ac_try="$ac_compile"
4941case "(($ac_try" in
4942 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4943 *) ac_try_echo=$ac_try;;
4944esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00004945eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004946 (eval "$ac_compile") 2>conftest.er1
4947 ac_status=$?
4948 grep -v '^ *+' conftest.er1 >conftest.err
4949 rm -f conftest.er1
4950 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00004951 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004952 (exit $ac_status); } && {
4953 test -z "$ac_c_werror_flag" ||
4954 test ! -s conftest.err
4955 } && test -s conftest.$ac_objext; then
4956
4957cat >>confdefs.h <<\_ACEOF
4958#define HAVE_ATTRIBUTE_FORMAT_PARSETUPLE 1
4959_ACEOF
4960
Ronald Oussoren450d5612009-06-08 21:12:41 +00004961 { echo "$as_me:$LINENO: result: yes" >&5
4962echo "${ECHO_T}yes" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004963else
Ronald Oussoren450d5612009-06-08 21:12:41 +00004964 echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004965sed 's/^/| /' conftest.$ac_ext >&5
4966
Ronald Oussoren450d5612009-06-08 21:12:41 +00004967 { echo "$as_me:$LINENO: result: no" >&5
4968echo "${ECHO_T}no" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004969
4970fi
4971
4972rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4973 CFLAGS=$save_CFLAGS
4974fi
4975
4976# On some compilers, pthreads are available without further options
4977# (e.g. MacOS X). On some of these systems, the compiler will not
4978# complain if unaccepted options are passed (e.g. gcc on Mac OS X).
4979# So we have to see first whether pthreads are available without
4980# options before we can check whether -Kpthread improves anything.
Ronald Oussoren450d5612009-06-08 21:12:41 +00004981{ echo "$as_me:$LINENO: checking whether pthreads are available without options" >&5
4982echo $ECHO_N "checking whether pthreads are available without options... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004983if test "${ac_cv_pthread_is_default+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00004984 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00004985else
4986 if test "$cross_compiling" = yes; then
4987 ac_cv_pthread_is_default=no
4988else
4989 cat >conftest.$ac_ext <<_ACEOF
4990/* confdefs.h. */
4991_ACEOF
4992cat confdefs.h >>conftest.$ac_ext
4993cat >>conftest.$ac_ext <<_ACEOF
4994/* end confdefs.h. */
4995
4996#include <pthread.h>
4997
4998void* routine(void* p){return NULL;}
4999
5000int main(){
5001 pthread_t p;
5002 if(pthread_create(&p,NULL,routine,NULL)!=0)
5003 return 1;
5004 (void)pthread_detach(p);
5005 return 0;
5006}
5007
5008_ACEOF
5009rm -f conftest$ac_exeext
5010if { (ac_try="$ac_link"
5011case "(($ac_try" in
5012 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5013 *) ac_try_echo=$ac_try;;
5014esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005015eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005016 (eval "$ac_link") 2>&5
5017 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005018 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005019 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5020 { (case "(($ac_try" in
5021 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5022 *) ac_try_echo=$ac_try;;
5023esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005024eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005025 (eval "$ac_try") 2>&5
5026 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005027 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005028 (exit $ac_status); }; }; then
5029
5030 ac_cv_pthread_is_default=yes
5031 ac_cv_kthread=no
5032 ac_cv_pthread=no
5033
5034else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005035 echo "$as_me: program exited with status $ac_status" >&5
5036echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005037sed 's/^/| /' conftest.$ac_ext >&5
5038
5039( exit $ac_status )
5040ac_cv_pthread_is_default=no
5041fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005042rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5043fi
5044
5045
5046
5047fi
5048
Ronald Oussoren450d5612009-06-08 21:12:41 +00005049{ echo "$as_me:$LINENO: result: $ac_cv_pthread_is_default" >&5
5050echo "${ECHO_T}$ac_cv_pthread_is_default" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005051
5052
5053if test $ac_cv_pthread_is_default = yes
5054then
5055 ac_cv_kpthread=no
5056else
5057# -Kpthread, if available, provides the right #defines
5058# and linker options to make pthread_create available
5059# Some compilers won't report that they do not support -Kpthread,
5060# so we need to run a program to see whether it really made the
5061# function available.
Ronald Oussoren450d5612009-06-08 21:12:41 +00005062{ echo "$as_me:$LINENO: checking whether $CC accepts -Kpthread" >&5
5063echo $ECHO_N "checking whether $CC accepts -Kpthread... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005064if test "${ac_cv_kpthread+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005065 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005066else
5067 ac_save_cc="$CC"
5068CC="$CC -Kpthread"
5069if test "$cross_compiling" = yes; then
5070 ac_cv_kpthread=no
5071else
5072 cat >conftest.$ac_ext <<_ACEOF
5073/* confdefs.h. */
5074_ACEOF
5075cat confdefs.h >>conftest.$ac_ext
5076cat >>conftest.$ac_ext <<_ACEOF
5077/* end confdefs.h. */
5078
5079#include <pthread.h>
5080
5081void* routine(void* p){return NULL;}
5082
5083int main(){
5084 pthread_t p;
5085 if(pthread_create(&p,NULL,routine,NULL)!=0)
5086 return 1;
5087 (void)pthread_detach(p);
5088 return 0;
5089}
5090
5091_ACEOF
5092rm -f conftest$ac_exeext
5093if { (ac_try="$ac_link"
5094case "(($ac_try" in
5095 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5096 *) ac_try_echo=$ac_try;;
5097esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005098eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005099 (eval "$ac_link") 2>&5
5100 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005101 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005102 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5103 { (case "(($ac_try" in
5104 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5105 *) ac_try_echo=$ac_try;;
5106esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005107eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005108 (eval "$ac_try") 2>&5
5109 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005111 (exit $ac_status); }; }; then
5112 ac_cv_kpthread=yes
5113else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005114 echo "$as_me: program exited with status $ac_status" >&5
5115echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005116sed 's/^/| /' conftest.$ac_ext >&5
5117
5118( exit $ac_status )
5119ac_cv_kpthread=no
5120fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005121rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5122fi
5123
5124
5125CC="$ac_save_cc"
5126fi
5127
Ronald Oussoren450d5612009-06-08 21:12:41 +00005128{ echo "$as_me:$LINENO: result: $ac_cv_kpthread" >&5
5129echo "${ECHO_T}$ac_cv_kpthread" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005130fi
5131
5132if test $ac_cv_kpthread = no -a $ac_cv_pthread_is_default = no
5133then
5134# -Kthread, if available, provides the right #defines
5135# and linker options to make pthread_create available
5136# Some compilers won't report that they do not support -Kthread,
5137# so we need to run a program to see whether it really made the
5138# function available.
Ronald Oussoren450d5612009-06-08 21:12:41 +00005139{ echo "$as_me:$LINENO: checking whether $CC accepts -Kthread" >&5
5140echo $ECHO_N "checking whether $CC accepts -Kthread... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005141if test "${ac_cv_kthread+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005142 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005143else
5144 ac_save_cc="$CC"
5145CC="$CC -Kthread"
5146if test "$cross_compiling" = yes; then
5147 ac_cv_kthread=no
5148else
5149 cat >conftest.$ac_ext <<_ACEOF
5150/* confdefs.h. */
5151_ACEOF
5152cat confdefs.h >>conftest.$ac_ext
5153cat >>conftest.$ac_ext <<_ACEOF
5154/* end confdefs.h. */
5155
5156#include <pthread.h>
5157
5158void* routine(void* p){return NULL;}
5159
5160int main(){
5161 pthread_t p;
5162 if(pthread_create(&p,NULL,routine,NULL)!=0)
5163 return 1;
5164 (void)pthread_detach(p);
5165 return 0;
5166}
5167
5168_ACEOF
5169rm -f conftest$ac_exeext
5170if { (ac_try="$ac_link"
5171case "(($ac_try" in
5172 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5173 *) ac_try_echo=$ac_try;;
5174esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005175eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005176 (eval "$ac_link") 2>&5
5177 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005178 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005179 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5180 { (case "(($ac_try" in
5181 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5182 *) ac_try_echo=$ac_try;;
5183esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005184eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005185 (eval "$ac_try") 2>&5
5186 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005187 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005188 (exit $ac_status); }; }; then
5189 ac_cv_kthread=yes
5190else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005191 echo "$as_me: program exited with status $ac_status" >&5
5192echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005193sed 's/^/| /' conftest.$ac_ext >&5
5194
5195( exit $ac_status )
5196ac_cv_kthread=no
5197fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005198rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5199fi
5200
5201
5202CC="$ac_save_cc"
5203fi
5204
Ronald Oussoren450d5612009-06-08 21:12:41 +00005205{ echo "$as_me:$LINENO: result: $ac_cv_kthread" >&5
5206echo "${ECHO_T}$ac_cv_kthread" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005207fi
5208
5209if test $ac_cv_kthread = no -a $ac_cv_pthread_is_default = no
5210then
5211# -pthread, if available, provides the right #defines
5212# and linker options to make pthread_create available
5213# Some compilers won't report that they do not support -pthread,
5214# so we need to run a program to see whether it really made the
5215# function available.
Ronald Oussoren450d5612009-06-08 21:12:41 +00005216{ echo "$as_me:$LINENO: checking whether $CC accepts -pthread" >&5
5217echo $ECHO_N "checking whether $CC accepts -pthread... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005218if test "${ac_cv_thread+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005219 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005220else
5221 ac_save_cc="$CC"
5222CC="$CC -pthread"
5223if test "$cross_compiling" = yes; then
5224 ac_cv_pthread=no
5225else
5226 cat >conftest.$ac_ext <<_ACEOF
5227/* confdefs.h. */
5228_ACEOF
5229cat confdefs.h >>conftest.$ac_ext
5230cat >>conftest.$ac_ext <<_ACEOF
5231/* end confdefs.h. */
5232
5233#include <pthread.h>
5234
5235void* routine(void* p){return NULL;}
5236
5237int main(){
5238 pthread_t p;
5239 if(pthread_create(&p,NULL,routine,NULL)!=0)
5240 return 1;
5241 (void)pthread_detach(p);
5242 return 0;
5243}
5244
5245_ACEOF
5246rm -f conftest$ac_exeext
5247if { (ac_try="$ac_link"
5248case "(($ac_try" in
5249 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5250 *) ac_try_echo=$ac_try;;
5251esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005252eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005253 (eval "$ac_link") 2>&5
5254 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005256 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5257 { (case "(($ac_try" in
5258 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5259 *) ac_try_echo=$ac_try;;
5260esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005261eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005262 (eval "$ac_try") 2>&5
5263 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005264 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005265 (exit $ac_status); }; }; then
5266 ac_cv_pthread=yes
5267else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005268 echo "$as_me: program exited with status $ac_status" >&5
5269echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005270sed 's/^/| /' conftest.$ac_ext >&5
5271
5272( exit $ac_status )
5273ac_cv_pthread=no
5274fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005275rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5276fi
5277
5278
5279CC="$ac_save_cc"
5280fi
5281
Ronald Oussoren450d5612009-06-08 21:12:41 +00005282{ echo "$as_me:$LINENO: result: $ac_cv_pthread" >&5
5283echo "${ECHO_T}$ac_cv_pthread" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005284fi
5285
5286# If we have set a CC compiler flag for thread support then
5287# check if it works for CXX, too.
5288ac_cv_cxx_thread=no
5289if test ! -z "$CXX"
5290then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005291{ echo "$as_me:$LINENO: checking whether $CXX also accepts flags for thread support" >&5
5292echo $ECHO_N "checking whether $CXX also accepts flags for thread support... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005293ac_save_cxx="$CXX"
5294
5295if test "$ac_cv_kpthread" = "yes"
5296then
5297 CXX="$CXX -Kpthread"
5298 ac_cv_cxx_thread=yes
5299elif test "$ac_cv_kthread" = "yes"
5300then
5301 CXX="$CXX -Kthread"
5302 ac_cv_cxx_thread=yes
5303elif test "$ac_cv_pthread" = "yes"
5304then
5305 CXX="$CXX -pthread"
5306 ac_cv_cxx_thread=yes
5307fi
5308
5309if test $ac_cv_cxx_thread = yes
5310then
5311 echo 'void foo();int main(){foo();}void foo(){}' > conftest.$ac_ext
5312 $CXX -c conftest.$ac_ext 2>&5
5313 if $CXX -o conftest$ac_exeext conftest.$ac_objext 2>&5 \
5314 && test -s conftest$ac_exeext && ./conftest$ac_exeext
5315 then
5316 ac_cv_cxx_thread=yes
5317 else
5318 ac_cv_cxx_thread=no
5319 fi
5320 rm -fr conftest*
5321fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005322{ echo "$as_me:$LINENO: result: $ac_cv_cxx_thread" >&5
5323echo "${ECHO_T}$ac_cv_cxx_thread" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005324fi
5325CXX="$ac_save_cxx"
5326
5327
5328# checks for header files
Ronald Oussoren450d5612009-06-08 21:12:41 +00005329{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
5330echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005331if test "${ac_cv_header_stdc+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005332 echo $ECHO_N "(cached) $ECHO_C" >&6
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005333else
5334 cat >conftest.$ac_ext <<_ACEOF
5335/* confdefs.h. */
5336_ACEOF
5337cat confdefs.h >>conftest.$ac_ext
5338cat >>conftest.$ac_ext <<_ACEOF
5339/* end confdefs.h. */
5340#include <stdlib.h>
5341#include <stdarg.h>
5342#include <string.h>
5343#include <float.h>
5344
5345int
5346main ()
5347{
5348
5349 ;
5350 return 0;
5351}
5352_ACEOF
5353rm -f conftest.$ac_objext
5354if { (ac_try="$ac_compile"
5355case "(($ac_try" in
5356 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5357 *) ac_try_echo=$ac_try;;
5358esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005359eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005360 (eval "$ac_compile") 2>conftest.er1
5361 ac_status=$?
5362 grep -v '^ *+' conftest.er1 >conftest.err
5363 rm -f conftest.er1
5364 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00005365 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005366 (exit $ac_status); } && {
5367 test -z "$ac_c_werror_flag" ||
5368 test ! -s conftest.err
5369 } && test -s conftest.$ac_objext; then
5370 ac_cv_header_stdc=yes
5371else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005372 echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005373sed 's/^/| /' conftest.$ac_ext >&5
5374
5375 ac_cv_header_stdc=no
5376fi
5377
5378rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5379
5380if test $ac_cv_header_stdc = yes; then
5381 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
5382 cat >conftest.$ac_ext <<_ACEOF
5383/* confdefs.h. */
5384_ACEOF
5385cat confdefs.h >>conftest.$ac_ext
5386cat >>conftest.$ac_ext <<_ACEOF
5387/* end confdefs.h. */
5388#include <string.h>
5389
5390_ACEOF
5391if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5392 $EGREP "memchr" >/dev/null 2>&1; then
5393 :
5394else
5395 ac_cv_header_stdc=no
5396fi
5397rm -f conftest*
5398
5399fi
5400
5401if test $ac_cv_header_stdc = yes; then
5402 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
5403 cat >conftest.$ac_ext <<_ACEOF
5404/* confdefs.h. */
5405_ACEOF
5406cat confdefs.h >>conftest.$ac_ext
5407cat >>conftest.$ac_ext <<_ACEOF
5408/* end confdefs.h. */
5409#include <stdlib.h>
5410
5411_ACEOF
5412if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5413 $EGREP "free" >/dev/null 2>&1; then
5414 :
5415else
5416 ac_cv_header_stdc=no
5417fi
5418rm -f conftest*
5419
5420fi
5421
5422if test $ac_cv_header_stdc = yes; then
5423 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
5424 if test "$cross_compiling" = yes; then
5425 :
5426else
5427 cat >conftest.$ac_ext <<_ACEOF
5428/* confdefs.h. */
5429_ACEOF
5430cat confdefs.h >>conftest.$ac_ext
5431cat >>conftest.$ac_ext <<_ACEOF
5432/* end confdefs.h. */
5433#include <ctype.h>
5434#include <stdlib.h>
5435#if ((' ' & 0x0FF) == 0x020)
5436# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
5437# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
5438#else
5439# define ISLOWER(c) \
5440 (('a' <= (c) && (c) <= 'i') \
5441 || ('j' <= (c) && (c) <= 'r') \
5442 || ('s' <= (c) && (c) <= 'z'))
5443# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
5444#endif
5445
5446#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
5447int
5448main ()
5449{
5450 int i;
5451 for (i = 0; i < 256; i++)
5452 if (XOR (islower (i), ISLOWER (i))
5453 || toupper (i) != TOUPPER (i))
5454 return 2;
5455 return 0;
5456}
5457_ACEOF
5458rm -f conftest$ac_exeext
5459if { (ac_try="$ac_link"
5460case "(($ac_try" in
5461 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5462 *) ac_try_echo=$ac_try;;
5463esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005464eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005465 (eval "$ac_link") 2>&5
5466 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005467 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005468 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
5469 { (case "(($ac_try" in
5470 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5471 *) ac_try_echo=$ac_try;;
5472esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005473eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005474 (eval "$ac_try") 2>&5
5475 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005476 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005477 (exit $ac_status); }; }; then
5478 :
5479else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005480 echo "$as_me: program exited with status $ac_status" >&5
5481echo "$as_me: failed program was:" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005482sed 's/^/| /' conftest.$ac_ext >&5
5483
5484( exit $ac_status )
5485ac_cv_header_stdc=no
5486fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005487rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
5488fi
5489
5490
5491fi
5492fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005493{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
5494echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005495if test $ac_cv_header_stdc = yes; then
5496
5497cat >>confdefs.h <<\_ACEOF
5498#define STDC_HEADERS 1
5499_ACEOF
5500
5501fi
5502
Ronald Oussoren450d5612009-06-08 21:12:41 +00005503# On IRIX 5.3, sys/types and inttypes.h are conflicting.
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
5514 inttypes.h stdint.h unistd.h
5515do
5516as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
5517{ echo "$as_me:$LINENO: checking for $ac_header" >&5
5518echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
5519if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
5520 echo $ECHO_N "(cached) $ECHO_C" >&6
5521else
5522 cat >conftest.$ac_ext <<_ACEOF
5523/* confdefs.h. */
5524_ACEOF
5525cat confdefs.h >>conftest.$ac_ext
5526cat >>conftest.$ac_ext <<_ACEOF
5527/* end confdefs.h. */
5528$ac_includes_default
5529
5530#include <$ac_header>
5531_ACEOF
5532rm -f conftest.$ac_objext
5533if { (ac_try="$ac_compile"
5534case "(($ac_try" in
5535 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5536 *) ac_try_echo=$ac_try;;
5537esac
5538eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5539 (eval "$ac_compile") 2>conftest.er1
5540 ac_status=$?
5541 grep -v '^ *+' conftest.er1 >conftest.err
5542 rm -f conftest.er1
5543 cat conftest.err >&5
5544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5545 (exit $ac_status); } && {
5546 test -z "$ac_c_werror_flag" ||
5547 test ! -s conftest.err
5548 } && test -s conftest.$ac_objext; then
5549 eval "$as_ac_Header=yes"
5550else
5551 echo "$as_me: failed program was:" >&5
5552sed 's/^/| /' conftest.$ac_ext >&5
5553
5554 eval "$as_ac_Header=no"
5555fi
5556
5557rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5558fi
5559ac_res=`eval echo '${'$as_ac_Header'}'`
5560 { echo "$as_me:$LINENO: result: $ac_res" >&5
5561echo "${ECHO_T}$ac_res" >&6; }
5562if test `eval echo '${'$as_ac_Header'}'` = yes; then
5563 cat >>confdefs.h <<_ACEOF
5564#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
5565_ACEOF
5566
5567fi
5568
5569done
5570
5571
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00005572
Martin v. Löwis11437992002-04-12 09:54:03 +00005573
5574
5575
5576
5577
5578
5579
5580
5581
5582
5583
5584
5585
5586
5587
5588
5589
5590
5591
5592
5593
5594
5595
5596
5597
5598
5599
5600
5601
5602
5603
5604
5605
5606
5607
Anthony Baxter8a560de2004-10-13 15:30:56 +00005608
Martin v. Löwisc3001752005-01-23 09:27:24 +00005609
Martin v. Löwis11017b12006-01-14 18:12:57 +00005610
Martin v. Löwis5f5d99c2006-05-16 07:05:37 +00005611
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00005612
5613
5614
5615
5616
5617
5618
5619
Martin v. Löwis40e9aed2006-10-02 15:20:37 +00005620
Christian Heimesfb2d25a2008-01-07 16:12:44 +00005621
Christian Heimes0e9ab5f2008-03-21 23:49:44 +00005622
5623
Neal Norwitz9fdfaaf2008-03-28 05:34:59 +00005624
Martin v. Löwis8c255e42008-05-23 15:06:50 +00005625
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00005626for ac_header in asm/types.h conio.h curses.h direct.h dlfcn.h errno.h \
5627fcntl.h grp.h \
Neal Norwitz9fdfaaf2008-03-28 05:34:59 +00005628ieeefp.h io.h langinfo.h libintl.h ncurses.h poll.h process.h pthread.h \
Martin v. Löwis40e9aed2006-10-02 15:20:37 +00005629shadow.h signal.h stdint.h stropts.h termios.h thread.h \
Martin v. Löwis14e73b12003-01-01 09:51:12 +00005630unistd.h utime.h \
Christian Heimes0e9ab5f2008-03-21 23:49:44 +00005631sys/audioio.h sys/bsdtty.h sys/epoll.h sys/event.h sys/file.h sys/loadavg.h \
5632sys/lock.h sys/mkdev.h sys/modem.h \
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00005633sys/param.h sys/poll.h sys/select.h sys/socket.h sys/statvfs.h sys/stat.h \
Martin v. Löwis8c255e42008-05-23 15:06:50 +00005634sys/termio.h sys/time.h \
Martin v. Löwis0e8bd7e2006-06-10 12:23:46 +00005635sys/times.h sys/types.h sys/un.h sys/utsname.h sys/wait.h pty.h libutil.h \
Martin v. Löwis0347a9a2006-10-27 07:06:52 +00005636sys/resource.h netpacket/packet.h sysexits.h bluetooth.h \
Christian Heimesfb2d25a2008-01-07 16:12:44 +00005637bluetooth/bluetooth.h linux/tipc.h
Guido van Rossum627b2d71993-12-24 10:39:16 +00005638do
Ronald Oussoren450d5612009-06-08 21:12:41 +00005639as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
Martin v. Löwiseba40652007-08-30 20:10:57 +00005640if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005641 { echo "$as_me:$LINENO: checking for $ac_header" >&5
5642echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00005643if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005644 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00005645fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005646ac_res=`eval echo '${'$as_ac_Header'}'`
5647 { echo "$as_me:$LINENO: result: $ac_res" >&5
5648echo "${ECHO_T}$ac_res" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005649else
Martin v. Löwis11437992002-04-12 09:54:03 +00005650 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005651{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
5652echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005653cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00005654/* confdefs.h. */
5655_ACEOF
5656cat confdefs.h >>conftest.$ac_ext
5657cat >>conftest.$ac_ext <<_ACEOF
5658/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005659$ac_includes_default
5660#include <$ac_header>
5661_ACEOF
5662rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00005663if { (ac_try="$ac_compile"
5664case "(($ac_try" in
5665 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5666 *) ac_try_echo=$ac_try;;
5667esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005668eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005669 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00005670 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00005671 grep -v '^ *+' conftest.er1 >conftest.err
5672 rm -f conftest.er1
5673 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00005674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005675 (exit $ac_status); } && {
5676 test -z "$ac_c_werror_flag" ||
5677 test ! -s conftest.err
5678 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005679 ac_header_compiler=yes
Michael W. Hudson54241132001-12-07 15:38:26 +00005680else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005681 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00005682sed 's/^/| /' conftest.$ac_ext >&5
5683
Martin v. Löwiseba40652007-08-30 20:10:57 +00005684 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +00005685fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00005686
5687rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00005688{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
5689echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005690
5691# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +00005692{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
5693echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005694cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00005695/* confdefs.h. */
5696_ACEOF
5697cat confdefs.h >>conftest.$ac_ext
5698cat >>conftest.$ac_ext <<_ACEOF
5699/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005700#include <$ac_header>
5701_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00005702if { (ac_try="$ac_cpp conftest.$ac_ext"
5703case "(($ac_try" in
5704 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5705 *) ac_try_echo=$ac_try;;
5706esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005707eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005708 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00005709 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00005710 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +00005711 rm -f conftest.er1
5712 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00005713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005714 (exit $ac_status); } >/dev/null && {
5715 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
5716 test ! -s conftest.err
5717 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005718 ac_header_preproc=yes
5719else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005720 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00005721sed 's/^/| /' conftest.$ac_ext >&5
5722
Martin v. Löwis11437992002-04-12 09:54:03 +00005723 ac_header_preproc=no
Michael W. Hudson54241132001-12-07 15:38:26 +00005724fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00005725
Martin v. Löwis11437992002-04-12 09:54:03 +00005726rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00005727{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
5728echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005729
5730# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +00005731case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
5732 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +00005733 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
5734echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
5735 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
5736echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +00005737 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +00005738 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +00005739 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +00005740 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
5741echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
5742 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
5743echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
5744 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
5745echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
5746 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
5747echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
5748 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
5749echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
5750 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
5751echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00005752 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +00005753## -------------------------------------- ##
5754## Report this to http://bugs.python.org/ ##
5755## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00005756_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00005757 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +00005758 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00005759esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005760{ echo "$as_me:$LINENO: checking for $ac_header" >&5
5761echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00005762if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005763 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +00005764else
Skip Montanarof0d5f792004-08-15 14:08:23 +00005765 eval "$as_ac_Header=\$ac_header_preproc"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005766fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005767ac_res=`eval echo '${'$as_ac_Header'}'`
5768 { echo "$as_me:$LINENO: result: $ac_res" >&5
5769echo "${ECHO_T}$ac_res" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005770
5771fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005772if test `eval echo '${'$as_ac_Header'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005773 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +00005774#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +00005775_ACEOF
5776
5777fi
5778
Guido van Rossum627b2d71993-12-24 10:39:16 +00005779done
5780
Martin v. Löwis11437992002-04-12 09:54:03 +00005781
5782
5783
5784
5785
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005786ac_header_dirent=no
Martin v. Löwis11437992002-04-12 09:54:03 +00005787for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
Ronald Oussoren450d5612009-06-08 21:12:41 +00005788 as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
5789{ echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5
5790echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00005791if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005792 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum627b2d71993-12-24 10:39:16 +00005793else
Martin v. Löwis11437992002-04-12 09:54:03 +00005794 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00005795/* confdefs.h. */
5796_ACEOF
5797cat confdefs.h >>conftest.$ac_ext
5798cat >>conftest.$ac_ext <<_ACEOF
5799/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005800#include <sys/types.h>
5801#include <$ac_hdr>
Martin v. Löwis11437992002-04-12 09:54:03 +00005802
Martin v. Löwis11437992002-04-12 09:54:03 +00005803int
5804main ()
5805{
5806if ((DIR *) 0)
5807return 0;
5808 ;
5809 return 0;
5810}
5811_ACEOF
5812rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00005813if { (ac_try="$ac_compile"
5814case "(($ac_try" in
5815 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5816 *) ac_try_echo=$ac_try;;
5817esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005818eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005819 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00005820 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00005821 grep -v '^ *+' conftest.er1 >conftest.err
5822 rm -f conftest.er1
5823 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00005824 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005825 (exit $ac_status); } && {
5826 test -z "$ac_c_werror_flag" ||
5827 test ! -s conftest.err
5828 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005829 eval "$as_ac_Header=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +00005830else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005831 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00005832sed 's/^/| /' conftest.$ac_ext >&5
5833
Martin v. Löwiseba40652007-08-30 20:10:57 +00005834 eval "$as_ac_Header=no"
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005835fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00005836
5837rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00005838fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005839ac_res=`eval echo '${'$as_ac_Header'}'`
5840 { echo "$as_me:$LINENO: result: $ac_res" >&5
5841echo "${ECHO_T}$ac_res" >&6; }
5842if test `eval echo '${'$as_ac_Header'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00005843 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +00005844#define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +00005845_ACEOF
5846
5847ac_header_dirent=$ac_hdr; break
Michael W. Hudson54241132001-12-07 15:38:26 +00005848fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005849
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005850done
5851# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
5852if test $ac_header_dirent = dirent.h; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005853 { echo "$as_me:$LINENO: checking for library containing opendir" >&5
5854echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005855if test "${ac_cv_search_opendir+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005856 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005857else
Martin v. Löwis11437992002-04-12 09:54:03 +00005858 ac_func_search_save_LIBS=$LIBS
Martin v. Löwis11437992002-04-12 09:54:03 +00005859cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00005860/* confdefs.h. */
5861_ACEOF
5862cat confdefs.h >>conftest.$ac_ext
5863cat >>conftest.$ac_ext <<_ACEOF
5864/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005865
Martin v. Löwiseba40652007-08-30 20:10:57 +00005866/* Override any GCC internal prototype to avoid an error.
5867 Use char because int might match the return type of a GCC
5868 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005869#ifdef __cplusplus
5870extern "C"
5871#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00005872char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00005873int
5874main ()
5875{
Martin v. Löwiseba40652007-08-30 20:10:57 +00005876return opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00005877 ;
5878 return 0;
5879}
5880_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00005881for ac_lib in '' dir; do
5882 if test -z "$ac_lib"; then
5883 ac_res="none required"
5884 else
5885 ac_res=-l$ac_lib
Skip Montanaro89e975f2007-08-22 19:05:21 +00005886 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Martin v. Löwiseba40652007-08-30 20:10:57 +00005887 fi
5888 rm -f conftest.$ac_objext conftest$ac_exeext
5889if { (ac_try="$ac_link"
5890case "(($ac_try" in
5891 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5892 *) ac_try_echo=$ac_try;;
5893esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005894eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005895 (eval "$ac_link") 2>conftest.er1
Skip Montanaro89e975f2007-08-22 19:05:21 +00005896 ac_status=$?
5897 grep -v '^ *+' conftest.er1 >conftest.err
5898 rm -f conftest.er1
5899 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00005900 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005901 (exit $ac_status); } && {
5902 test -z "$ac_c_werror_flag" ||
5903 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +00005904 } && test -s conftest$ac_exeext &&
5905 $as_test_x conftest$ac_exeext; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00005906 ac_cv_search_opendir=$ac_res
Brett Cannon19fab762007-06-02 03:02:29 +00005907else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005908 echo "$as_me: failed program was:" >&5
Skip Montanaro89e975f2007-08-22 19:05:21 +00005909sed 's/^/| /' conftest.$ac_ext >&5
5910
Martin v. Löwiseba40652007-08-30 20:10:57 +00005911
Brett Cannon19fab762007-06-02 03:02:29 +00005912fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00005913
5914rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5915 conftest$ac_exeext
5916 if test "${ac_cv_search_opendir+set}" = set; then
5917 break
Skip Montanaro89e975f2007-08-22 19:05:21 +00005918fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00005919done
5920if test "${ac_cv_search_opendir+set}" = set; then
5921 :
5922else
5923 ac_cv_search_opendir=no
5924fi
5925rm conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00005926LIBS=$ac_func_search_save_LIBS
5927fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00005928{ echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
5929echo "${ECHO_T}$ac_cv_search_opendir" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00005930ac_res=$ac_cv_search_opendir
5931if test "$ac_res" != no; then
5932 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Michael W. Hudson54241132001-12-07 15:38:26 +00005933
Guido van Rossum76be6ed1995-01-02 18:33:54 +00005934fi
Martin v. Löwis11437992002-04-12 09:54:03 +00005935
Michael W. Hudson54241132001-12-07 15:38:26 +00005936else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005937 { echo "$as_me:$LINENO: checking for library containing opendir" >&5
5938echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00005939if test "${ac_cv_search_opendir+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00005940 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00005941else
5942 ac_func_search_save_LIBS=$LIBS
Martin v. Löwis11437992002-04-12 09:54:03 +00005943cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00005944/* confdefs.h. */
5945_ACEOF
5946cat confdefs.h >>conftest.$ac_ext
5947cat >>conftest.$ac_ext <<_ACEOF
5948/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005949
Martin v. Löwiseba40652007-08-30 20:10:57 +00005950/* Override any GCC internal prototype to avoid an error.
5951 Use char because int might match the return type of a GCC
5952 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +00005953#ifdef __cplusplus
5954extern "C"
5955#endif
Martin v. Löwis11437992002-04-12 09:54:03 +00005956char opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00005957int
5958main ()
5959{
Martin v. Löwiseba40652007-08-30 20:10:57 +00005960return opendir ();
Martin v. Löwis11437992002-04-12 09:54:03 +00005961 ;
5962 return 0;
5963}
5964_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00005965for ac_lib in '' x; do
5966 if test -z "$ac_lib"; then
5967 ac_res="none required"
5968 else
5969 ac_res=-l$ac_lib
Skip Montanaro89e975f2007-08-22 19:05:21 +00005970 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Martin v. Löwiseba40652007-08-30 20:10:57 +00005971 fi
5972 rm -f conftest.$ac_objext conftest$ac_exeext
5973if { (ac_try="$ac_link"
5974case "(($ac_try" in
5975 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5976 *) ac_try_echo=$ac_try;;
5977esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00005978eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005979 (eval "$ac_link") 2>conftest.er1
Skip Montanaro89e975f2007-08-22 19:05:21 +00005980 ac_status=$?
5981 grep -v '^ *+' conftest.er1 >conftest.err
5982 rm -f conftest.er1
5983 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00005984 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00005985 (exit $ac_status); } && {
5986 test -z "$ac_c_werror_flag" ||
5987 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +00005988 } && test -s conftest$ac_exeext &&
5989 $as_test_x conftest$ac_exeext; then
Martin v. Löwiseba40652007-08-30 20:10:57 +00005990 ac_cv_search_opendir=$ac_res
Brett Cannon19fab762007-06-02 03:02:29 +00005991else
Ronald Oussoren450d5612009-06-08 21:12:41 +00005992 echo "$as_me: failed program was:" >&5
Skip Montanaro89e975f2007-08-22 19:05:21 +00005993sed 's/^/| /' conftest.$ac_ext >&5
5994
Martin v. Löwiseba40652007-08-30 20:10:57 +00005995
Brett Cannon19fab762007-06-02 03:02:29 +00005996fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00005997
5998rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5999 conftest$ac_exeext
6000 if test "${ac_cv_search_opendir+set}" = set; then
6001 break
Skip Montanaro89e975f2007-08-22 19:05:21 +00006002fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006003done
6004if test "${ac_cv_search_opendir+set}" = set; then
6005 :
6006else
6007 ac_cv_search_opendir=no
6008fi
6009rm conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00006010LIBS=$ac_func_search_save_LIBS
6011fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006012{ echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5
6013echo "${ECHO_T}$ac_cv_search_opendir" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006014ac_res=$ac_cv_search_opendir
6015if test "$ac_res" != no; then
6016 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +00006017
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006018fi
6019
6020fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00006021
Ronald Oussoren450d5612009-06-08 21:12:41 +00006022{ echo "$as_me:$LINENO: checking whether sys/types.h defines makedev" >&5
6023echo $ECHO_N "checking whether sys/types.h defines makedev... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006024if test "${ac_cv_header_sys_types_h_makedev+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006025 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006026else
6027 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006028/* confdefs.h. */
6029_ACEOF
6030cat confdefs.h >>conftest.$ac_ext
6031cat >>conftest.$ac_ext <<_ACEOF
6032/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006033#include <sys/types.h>
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006034int
6035main ()
6036{
6037return makedev(0, 0);
6038 ;
6039 return 0;
6040}
6041_ACEOF
6042rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006043if { (ac_try="$ac_link"
6044case "(($ac_try" in
6045 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6046 *) ac_try_echo=$ac_try;;
6047esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006048eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006049 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006050 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006051 grep -v '^ *+' conftest.er1 >conftest.err
6052 rm -f conftest.er1
6053 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006054 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006055 (exit $ac_status); } && {
6056 test -z "$ac_c_werror_flag" ||
6057 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +00006058 } && test -s conftest$ac_exeext &&
6059 $as_test_x conftest$ac_exeext; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006060 ac_cv_header_sys_types_h_makedev=yes
6061else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006062 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006063sed 's/^/| /' conftest.$ac_ext >&5
6064
Martin v. Löwiseba40652007-08-30 20:10:57 +00006065 ac_cv_header_sys_types_h_makedev=no
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006066fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006067
6068rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +00006069 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006070
6071fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006072{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_types_h_makedev" >&5
6073echo "${ECHO_T}$ac_cv_header_sys_types_h_makedev" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006074
6075if test $ac_cv_header_sys_types_h_makedev = no; then
6076if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006077 { echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
6078echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006079if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006080 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006081fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006082{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
6083echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006084else
6085 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +00006086{ echo "$as_me:$LINENO: checking sys/mkdev.h usability" >&5
6087echo $ECHO_N "checking sys/mkdev.h usability... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006088cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006089/* confdefs.h. */
6090_ACEOF
6091cat confdefs.h >>conftest.$ac_ext
6092cat >>conftest.$ac_ext <<_ACEOF
6093/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006094$ac_includes_default
6095#include <sys/mkdev.h>
6096_ACEOF
6097rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006098if { (ac_try="$ac_compile"
6099case "(($ac_try" in
6100 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6101 *) ac_try_echo=$ac_try;;
6102esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006103eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006104 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006105 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006106 grep -v '^ *+' conftest.er1 >conftest.err
6107 rm -f conftest.er1
6108 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006109 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006110 (exit $ac_status); } && {
6111 test -z "$ac_c_werror_flag" ||
6112 test ! -s conftest.err
6113 } && test -s conftest.$ac_objext; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006114 ac_header_compiler=yes
6115else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006116 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006117sed 's/^/| /' conftest.$ac_ext >&5
6118
Martin v. Löwiseba40652007-08-30 20:10:57 +00006119 ac_header_compiler=no
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006120fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006121
6122rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00006123{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6124echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006125
6126# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +00006127{ echo "$as_me:$LINENO: checking sys/mkdev.h presence" >&5
6128echo $ECHO_N "checking sys/mkdev.h presence... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006129cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006130/* confdefs.h. */
6131_ACEOF
6132cat confdefs.h >>conftest.$ac_ext
6133cat >>conftest.$ac_ext <<_ACEOF
6134/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006135#include <sys/mkdev.h>
6136_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006137if { (ac_try="$ac_cpp conftest.$ac_ext"
6138case "(($ac_try" in
6139 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6140 *) ac_try_echo=$ac_try;;
6141esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006142eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006143 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006144 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00006145 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006146 rm -f conftest.er1
6147 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006148 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006149 (exit $ac_status); } >/dev/null && {
6150 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6151 test ! -s conftest.err
6152 }; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006153 ac_header_preproc=yes
6154else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006155 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006156sed 's/^/| /' conftest.$ac_ext >&5
6157
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006158 ac_header_preproc=no
6159fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006160
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006161rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00006162{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6163echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006164
6165# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006166case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6167 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +00006168 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&5
6169echo "$as_me: WARNING: sys/mkdev.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
6170 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the compiler's result" >&5
6171echo "$as_me: WARNING: sys/mkdev.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +00006172 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +00006173 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +00006174 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +00006175 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: present but cannot be compiled" >&5
6176echo "$as_me: WARNING: sys/mkdev.h: present but cannot be compiled" >&2;}
6177 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&5
6178echo "$as_me: WARNING: sys/mkdev.h: check for missing prerequisite headers?" >&2;}
6179 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: see the Autoconf documentation" >&5
6180echo "$as_me: WARNING: sys/mkdev.h: see the Autoconf documentation" >&2;}
6181 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: section \"Present But Cannot Be Compiled\"" >&5
6182echo "$as_me: WARNING: sys/mkdev.h: section \"Present But Cannot Be Compiled\"" >&2;}
6183 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&5
6184echo "$as_me: WARNING: sys/mkdev.h: proceeding with the preprocessor's result" >&2;}
6185 { echo "$as_me:$LINENO: WARNING: sys/mkdev.h: in the future, the compiler will take precedence" >&5
6186echo "$as_me: WARNING: sys/mkdev.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00006187 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +00006188## -------------------------------------- ##
6189## Report this to http://bugs.python.org/ ##
6190## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00006191_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00006192 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +00006193 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006194esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006195{ echo "$as_me:$LINENO: checking for sys/mkdev.h" >&5
6196echo $ECHO_N "checking for sys/mkdev.h... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006197if test "${ac_cv_header_sys_mkdev_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006198 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006199else
6200 ac_cv_header_sys_mkdev_h=$ac_header_preproc
6201fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006202{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_mkdev_h" >&5
6203echo "${ECHO_T}$ac_cv_header_sys_mkdev_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006204
6205fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006206if test $ac_cv_header_sys_mkdev_h = yes; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006207
6208cat >>confdefs.h <<\_ACEOF
6209#define MAJOR_IN_MKDEV 1
6210_ACEOF
6211
6212fi
6213
6214
6215
6216 if test $ac_cv_header_sys_mkdev_h = no; then
6217 if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006218 { echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
6219echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006220if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006221 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006222fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006223{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
6224echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006225else
6226 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +00006227{ echo "$as_me:$LINENO: checking sys/sysmacros.h usability" >&5
6228echo $ECHO_N "checking sys/sysmacros.h usability... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006229cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006230/* confdefs.h. */
6231_ACEOF
6232cat confdefs.h >>conftest.$ac_ext
6233cat >>conftest.$ac_ext <<_ACEOF
6234/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006235$ac_includes_default
6236#include <sys/sysmacros.h>
6237_ACEOF
6238rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006239if { (ac_try="$ac_compile"
6240case "(($ac_try" in
6241 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6242 *) ac_try_echo=$ac_try;;
6243esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006244eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006245 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006246 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006247 grep -v '^ *+' conftest.er1 >conftest.err
6248 rm -f conftest.er1
6249 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006250 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006251 (exit $ac_status); } && {
6252 test -z "$ac_c_werror_flag" ||
6253 test ! -s conftest.err
6254 } && test -s conftest.$ac_objext; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006255 ac_header_compiler=yes
6256else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006257 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006258sed 's/^/| /' conftest.$ac_ext >&5
6259
Martin v. Löwiseba40652007-08-30 20:10:57 +00006260 ac_header_compiler=no
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006261fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006262
6263rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00006264{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
6265echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006266
6267# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +00006268{ echo "$as_me:$LINENO: checking sys/sysmacros.h presence" >&5
6269echo $ECHO_N "checking sys/sysmacros.h presence... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006270cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006271/* confdefs.h. */
6272_ACEOF
6273cat confdefs.h >>conftest.$ac_ext
6274cat >>conftest.$ac_ext <<_ACEOF
6275/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006276#include <sys/sysmacros.h>
6277_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006278if { (ac_try="$ac_cpp conftest.$ac_ext"
6279case "(($ac_try" in
6280 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6281 *) ac_try_echo=$ac_try;;
6282esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006283eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006284 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006285 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +00006286 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006287 rm -f conftest.er1
6288 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006289 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006290 (exit $ac_status); } >/dev/null && {
6291 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6292 test ! -s conftest.err
6293 }; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006294 ac_header_preproc=yes
6295else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006296 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006297sed 's/^/| /' conftest.$ac_ext >&5
6298
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006299 ac_header_preproc=no
6300fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006301
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006302rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00006303{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
6304echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006305
6306# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006307case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
6308 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +00006309 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&5
6310echo "$as_me: WARNING: sys/sysmacros.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
6311 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the compiler's result" >&5
6312echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +00006313 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +00006314 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +00006315 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +00006316 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: present but cannot be compiled" >&5
6317echo "$as_me: WARNING: sys/sysmacros.h: present but cannot be compiled" >&2;}
6318 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&5
6319echo "$as_me: WARNING: sys/sysmacros.h: check for missing prerequisite headers?" >&2;}
6320 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: see the Autoconf documentation" >&5
6321echo "$as_me: WARNING: sys/sysmacros.h: see the Autoconf documentation" >&2;}
6322 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: section \"Present But Cannot Be Compiled\"" >&5
6323echo "$as_me: WARNING: sys/sysmacros.h: section \"Present But Cannot Be Compiled\"" >&2;}
6324 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&5
6325echo "$as_me: WARNING: sys/sysmacros.h: proceeding with the preprocessor's result" >&2;}
6326 { echo "$as_me:$LINENO: WARNING: sys/sysmacros.h: in the future, the compiler will take precedence" >&5
6327echo "$as_me: WARNING: sys/sysmacros.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +00006328 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +00006329## -------------------------------------- ##
6330## Report this to http://bugs.python.org/ ##
6331## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +00006332_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +00006333 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +00006334 ;;
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006335esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006336{ echo "$as_me:$LINENO: checking for sys/sysmacros.h" >&5
6337echo $ECHO_N "checking for sys/sysmacros.h... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006338if test "${ac_cv_header_sys_sysmacros_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006339 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006340else
6341 ac_cv_header_sys_sysmacros_h=$ac_header_preproc
6342fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006343{ echo "$as_me:$LINENO: result: $ac_cv_header_sys_sysmacros_h" >&5
6344echo "${ECHO_T}$ac_cv_header_sys_sysmacros_h" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006345
6346fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006347if test $ac_cv_header_sys_sysmacros_h = yes; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +00006348
6349cat >>confdefs.h <<\_ACEOF
6350#define MAJOR_IN_SYSMACROS 1
6351_ACEOF
6352
6353fi
6354
6355
6356 fi
6357fi
6358
Michael W. Hudson54241132001-12-07 15:38:26 +00006359
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006360# On Solaris, term.h requires curses.h
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006361
6362for ac_header in term.h
6363do
Ronald Oussoren450d5612009-06-08 21:12:41 +00006364as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6365{ echo "$as_me:$LINENO: checking for $ac_header" >&5
6366echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006367if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006368 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006369else
6370 cat >conftest.$ac_ext <<_ACEOF
6371/* confdefs.h. */
6372_ACEOF
6373cat confdefs.h >>conftest.$ac_ext
6374cat >>conftest.$ac_ext <<_ACEOF
6375/* end confdefs.h. */
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006376
Martin v. Löwis5d52e782004-09-18 10:07:03 +00006377#ifdef HAVE_CURSES_H
6378#include <curses.h>
6379#endif
6380
6381
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006382#include <$ac_header>
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006383_ACEOF
6384rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006385if { (ac_try="$ac_compile"
6386case "(($ac_try" in
6387 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6388 *) ac_try_echo=$ac_try;;
6389esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006390eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006391 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006392 ac_status=$?
6393 grep -v '^ *+' conftest.er1 >conftest.err
6394 rm -f conftest.er1
6395 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006396 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006397 (exit $ac_status); } && {
6398 test -z "$ac_c_werror_flag" ||
6399 test ! -s conftest.err
6400 } && test -s conftest.$ac_objext; then
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006401 eval "$as_ac_Header=yes"
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006402else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006403 echo "$as_me: failed program was:" >&5
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006404sed 's/^/| /' conftest.$ac_ext >&5
6405
Martin v. Löwiseba40652007-08-30 20:10:57 +00006406 eval "$as_ac_Header=no"
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006407fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006408
6409rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006410fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006411ac_res=`eval echo '${'$as_ac_Header'}'`
6412 { echo "$as_me:$LINENO: result: $ac_res" >&5
6413echo "${ECHO_T}$ac_res" >&6; }
6414if test `eval echo '${'$as_ac_Header'}'` = yes; then
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006415 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +00006416#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006417_ACEOF
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006418
Martin v. Löwisfd1c69e2004-11-30 22:09:37 +00006419fi
6420
6421done
Martin v. Löwisae2830c2004-09-18 09:54:52 +00006422
6423
Martin v. Löwis11017b12006-01-14 18:12:57 +00006424# On Linux, netlink.h requires asm/types.h
6425
6426for ac_header in linux/netlink.h
6427do
Ronald Oussoren450d5612009-06-08 21:12:41 +00006428as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
6429{ echo "$as_me:$LINENO: checking for $ac_header" >&5
6430echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00006431if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006432 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11017b12006-01-14 18:12:57 +00006433else
6434 cat >conftest.$ac_ext <<_ACEOF
6435/* confdefs.h. */
6436_ACEOF
6437cat confdefs.h >>conftest.$ac_ext
6438cat >>conftest.$ac_ext <<_ACEOF
6439/* end confdefs.h. */
6440
6441#ifdef HAVE_ASM_TYPES_H
6442#include <asm/types.h>
6443#endif
6444#ifdef HAVE_SYS_SOCKET_H
6445#include <sys/socket.h>
6446#endif
6447
6448
6449#include <$ac_header>
6450_ACEOF
6451rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006452if { (ac_try="$ac_compile"
6453case "(($ac_try" in
6454 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6455 *) ac_try_echo=$ac_try;;
6456esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006457eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006458 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11017b12006-01-14 18:12:57 +00006459 ac_status=$?
6460 grep -v '^ *+' conftest.er1 >conftest.err
6461 rm -f conftest.er1
6462 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006463 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006464 (exit $ac_status); } && {
6465 test -z "$ac_c_werror_flag" ||
6466 test ! -s conftest.err
6467 } && test -s conftest.$ac_objext; then
Martin v. Löwis11017b12006-01-14 18:12:57 +00006468 eval "$as_ac_Header=yes"
6469else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006470 echo "$as_me: failed program was:" >&5
Martin v. Löwis11017b12006-01-14 18:12:57 +00006471sed 's/^/| /' conftest.$ac_ext >&5
6472
Martin v. Löwiseba40652007-08-30 20:10:57 +00006473 eval "$as_ac_Header=no"
Martin v. Löwis11017b12006-01-14 18:12:57 +00006474fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006475
6476rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11017b12006-01-14 18:12:57 +00006477fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006478ac_res=`eval echo '${'$as_ac_Header'}'`
6479 { echo "$as_me:$LINENO: result: $ac_res" >&5
6480echo "${ECHO_T}$ac_res" >&6; }
6481if test `eval echo '${'$as_ac_Header'}'` = yes; then
Martin v. Löwis11017b12006-01-14 18:12:57 +00006482 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +00006483#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
Martin v. Löwis11017b12006-01-14 18:12:57 +00006484_ACEOF
6485
6486fi
6487
6488done
6489
6490
Guido van Rossum627b2d71993-12-24 10:39:16 +00006491# checks for typedefs
Guido van Rossumda88dad1995-01-26 00:46:29 +00006492was_it_defined=no
Ronald Oussoren450d5612009-06-08 21:12:41 +00006493{ echo "$as_me:$LINENO: checking for clock_t in time.h" >&5
6494echo $ECHO_N "checking for clock_t in time.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006495cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006496/* confdefs.h. */
6497_ACEOF
6498cat confdefs.h >>conftest.$ac_ext
6499cat >>conftest.$ac_ext <<_ACEOF
6500/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006501#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00006502
6503_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006504if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +00006505 $EGREP "clock_t" >/dev/null 2>&1; then
Guido van Rossumda88dad1995-01-26 00:46:29 +00006506 was_it_defined=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00006507else
Martin v. Löwis11437992002-04-12 09:54:03 +00006508
6509
6510cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006511#define clock_t long
Martin v. Löwis11437992002-04-12 09:54:03 +00006512_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00006513
Martin v. Löwisc45929e2002-04-06 10:10:49 +00006514
Guido van Rossum627b2d71993-12-24 10:39:16 +00006515fi
6516rm -f conftest*
6517
Ronald Oussoren450d5612009-06-08 21:12:41 +00006518{ echo "$as_me:$LINENO: result: $was_it_defined" >&5
6519echo "${ECHO_T}$was_it_defined" >&6; }
Guido van Rossumda88dad1995-01-26 00:46:29 +00006520
Neal Norwitz11690112002-07-30 01:08:28 +00006521# Check whether using makedev requires defining _OSF_SOURCE
Ronald Oussoren450d5612009-06-08 21:12:41 +00006522{ echo "$as_me:$LINENO: checking for makedev" >&5
6523echo $ECHO_N "checking for makedev... $ECHO_C" >&6; }
Neal Norwitz11690112002-07-30 01:08:28 +00006524cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006525/* confdefs.h. */
6526_ACEOF
6527cat confdefs.h >>conftest.$ac_ext
6528cat >>conftest.$ac_ext <<_ACEOF
6529/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +00006530#include <sys/types.h>
Neal Norwitz11690112002-07-30 01:08:28 +00006531int
6532main ()
6533{
6534 makedev(0, 0)
6535 ;
6536 return 0;
6537}
6538_ACEOF
6539rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006540if { (ac_try="$ac_link"
6541case "(($ac_try" in
6542 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6543 *) ac_try_echo=$ac_try;;
6544esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006545eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006546 (eval "$ac_link") 2>conftest.er1
Neal Norwitz11690112002-07-30 01:08:28 +00006547 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006548 grep -v '^ *+' conftest.er1 >conftest.err
6549 rm -f conftest.er1
6550 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006551 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006552 (exit $ac_status); } && {
6553 test -z "$ac_c_werror_flag" ||
6554 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +00006555 } && test -s conftest$ac_exeext &&
6556 $as_test_x conftest$ac_exeext; then
Neal Norwitz11690112002-07-30 01:08:28 +00006557 ac_cv_has_makedev=yes
6558else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006559 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006560sed 's/^/| /' conftest.$ac_ext >&5
6561
Martin v. Löwiseba40652007-08-30 20:10:57 +00006562 ac_cv_has_makedev=no
Neal Norwitz11690112002-07-30 01:08:28 +00006563fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006564
6565rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +00006566 conftest$ac_exeext conftest.$ac_ext
Neal Norwitz11690112002-07-30 01:08:28 +00006567if test "$ac_cv_has_makedev" = "no"; then
6568 # we didn't link, try if _OSF_SOURCE will allow us to link
6569 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006570/* confdefs.h. */
6571_ACEOF
6572cat confdefs.h >>conftest.$ac_ext
6573cat >>conftest.$ac_ext <<_ACEOF
6574/* end confdefs.h. */
Neal Norwitz11690112002-07-30 01:08:28 +00006575
Neal Norwitz6eb37f02003-02-23 23:28:15 +00006576#define _OSF_SOURCE 1
6577#include <sys/types.h>
Neal Norwitz11690112002-07-30 01:08:28 +00006578
Neal Norwitz11690112002-07-30 01:08:28 +00006579int
6580main ()
6581{
6582 makedev(0, 0)
6583 ;
6584 return 0;
6585}
6586_ACEOF
6587rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006588if { (ac_try="$ac_link"
6589case "(($ac_try" in
6590 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6591 *) ac_try_echo=$ac_try;;
6592esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006593eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006594 (eval "$ac_link") 2>conftest.er1
Neal Norwitz11690112002-07-30 01:08:28 +00006595 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006596 grep -v '^ *+' conftest.er1 >conftest.err
6597 rm -f conftest.er1
6598 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006600 (exit $ac_status); } && {
6601 test -z "$ac_c_werror_flag" ||
6602 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +00006603 } && test -s conftest$ac_exeext &&
6604 $as_test_x conftest$ac_exeext; then
Neal Norwitz11690112002-07-30 01:08:28 +00006605 ac_cv_has_makedev=yes
6606else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006607 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006608sed 's/^/| /' conftest.$ac_ext >&5
6609
Martin v. Löwiseba40652007-08-30 20:10:57 +00006610 ac_cv_has_makedev=no
Neal Norwitz11690112002-07-30 01:08:28 +00006611fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006612
6613rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +00006614 conftest$ac_exeext conftest.$ac_ext
Neal Norwitz11690112002-07-30 01:08:28 +00006615 if test "$ac_cv_has_makedev" = "yes"; then
6616
6617cat >>confdefs.h <<\_ACEOF
6618#define _OSF_SOURCE 1
6619_ACEOF
6620
6621 fi
6622fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006623{ echo "$as_me:$LINENO: result: $ac_cv_has_makedev" >&5
6624echo "${ECHO_T}$ac_cv_has_makedev" >&6; }
Neal Norwitz11690112002-07-30 01:08:28 +00006625if test "$ac_cv_has_makedev" = "yes"; then
6626
6627cat >>confdefs.h <<\_ACEOF
6628#define HAVE_MAKEDEV 1
6629_ACEOF
6630
6631fi
6632
Martin v. Löwis399a6892002-10-04 10:22:02 +00006633# Enabling LFS on Solaris (2.6 to 9) with gcc 2.95 triggers a bug in
6634# the system headers: If _XOPEN_SOURCE and _LARGEFILE_SOURCE are
6635# defined, but the compiler does not support pragma redefine_extname,
6636# and _LARGEFILE64_SOURCE is not defined, the headers refer to 64-bit
6637# structures (such as rlimit64) without declaring them. As a
6638# work-around, disable LFS on such configurations
6639
6640use_lfs=yes
Ronald Oussoren450d5612009-06-08 21:12:41 +00006641{ echo "$as_me:$LINENO: checking Solaris LFS bug" >&5
6642echo $ECHO_N "checking Solaris LFS bug... $ECHO_C" >&6; }
Martin v. Löwis399a6892002-10-04 10:22:02 +00006643cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006644/* confdefs.h. */
6645_ACEOF
6646cat confdefs.h >>conftest.$ac_ext
6647cat >>conftest.$ac_ext <<_ACEOF
6648/* end confdefs.h. */
Martin v. Löwis399a6892002-10-04 10:22:02 +00006649
6650#define _LARGEFILE_SOURCE 1
6651#define _FILE_OFFSET_BITS 64
6652#include <sys/resource.h>
6653
Martin v. Löwis399a6892002-10-04 10:22:02 +00006654int
6655main ()
6656{
6657struct rlimit foo;
6658 ;
6659 return 0;
6660}
6661_ACEOF
6662rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006663if { (ac_try="$ac_compile"
6664case "(($ac_try" in
6665 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6666 *) ac_try_echo=$ac_try;;
6667esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006668eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006669 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis399a6892002-10-04 10:22:02 +00006670 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006671 grep -v '^ *+' conftest.er1 >conftest.err
6672 rm -f conftest.er1
6673 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006675 (exit $ac_status); } && {
6676 test -z "$ac_c_werror_flag" ||
6677 test ! -s conftest.err
6678 } && test -s conftest.$ac_objext; then
Martin v. Löwis399a6892002-10-04 10:22:02 +00006679 sol_lfs_bug=no
6680else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006681 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006682sed 's/^/| /' conftest.$ac_ext >&5
6683
Martin v. Löwiseba40652007-08-30 20:10:57 +00006684 sol_lfs_bug=yes
Martin v. Löwis399a6892002-10-04 10:22:02 +00006685fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006686
6687rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +00006688{ echo "$as_me:$LINENO: result: $sol_lfs_bug" >&5
6689echo "${ECHO_T}$sol_lfs_bug" >&6; }
Martin v. Löwis399a6892002-10-04 10:22:02 +00006690if test "$sol_lfs_bug" = "yes"; then
6691 use_lfs=no
6692fi
6693
6694if test "$use_lfs" = "yes"; then
Guido van Rossum810cc512001-09-09 23:51:39 +00006695# Two defines needed to enable largefile support on various platforms
6696# These may affect some typedefs
Guido van Rossum810cc512001-09-09 23:51:39 +00006697
Martin v. Löwis11437992002-04-12 09:54:03 +00006698cat >>confdefs.h <<\_ACEOF
6699#define _LARGEFILE_SOURCE 1
6700_ACEOF
6701
6702
6703cat >>confdefs.h <<\_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00006704#define _FILE_OFFSET_BITS 64
Martin v. Löwis11437992002-04-12 09:54:03 +00006705_ACEOF
Guido van Rossum810cc512001-09-09 23:51:39 +00006706
Martin v. Löwis399a6892002-10-04 10:22:02 +00006707fi
Michael W. Hudson54241132001-12-07 15:38:26 +00006708
Guido van Rossum84e7b241996-08-19 21:59:00 +00006709# Add some code to confdefs.h so that the test for off_t works on SCO
6710cat >> confdefs.h <<\EOF
6711#if defined(SCO_DS)
6712#undef _OFF_T
6713#endif
6714EOF
6715
Guido van Rossumef2255b2000-03-10 22:30:29 +00006716# Type availability checks
Ronald Oussoren450d5612009-06-08 21:12:41 +00006717{ echo "$as_me:$LINENO: checking for mode_t" >&5
6718echo $ECHO_N "checking for mode_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006719if test "${ac_cv_type_mode_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006720 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006721else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006722 cat >conftest.$ac_ext <<_ACEOF
6723/* confdefs.h. */
6724_ACEOF
6725cat confdefs.h >>conftest.$ac_ext
6726cat >>conftest.$ac_ext <<_ACEOF
6727/* end confdefs.h. */
6728$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00006729typedef mode_t ac__type_new_;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006730int
6731main ()
6732{
Ronald Oussoren450d5612009-06-08 21:12:41 +00006733if ((ac__type_new_ *) 0)
6734 return 0;
6735if (sizeof (ac__type_new_))
6736 return 0;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006737 ;
6738 return 0;
6739}
6740_ACEOF
6741rm -f conftest.$ac_objext
6742if { (ac_try="$ac_compile"
6743case "(($ac_try" in
6744 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6745 *) ac_try_echo=$ac_try;;
6746esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006747eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006748 (eval "$ac_compile") 2>conftest.er1
6749 ac_status=$?
6750 grep -v '^ *+' conftest.er1 >conftest.err
6751 rm -f conftest.er1
6752 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006753 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006754 (exit $ac_status); } && {
6755 test -z "$ac_c_werror_flag" ||
6756 test ! -s conftest.err
6757 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006758 ac_cv_type_mode_t=yes
Jack Jansendd19cf82001-12-06 22:36:17 +00006759else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006760 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006761sed 's/^/| /' conftest.$ac_ext >&5
6762
Ronald Oussoren450d5612009-06-08 21:12:41 +00006763 ac_cv_type_mode_t=no
Jack Jansendd19cf82001-12-06 22:36:17 +00006764fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006765
6766rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00006767fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006768{ echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5
6769echo "${ECHO_T}$ac_cv_type_mode_t" >&6; }
6770if test $ac_cv_type_mode_t = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006771 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006772else
Martin v. Löwis11437992002-04-12 09:54:03 +00006773
6774cat >>confdefs.h <<_ACEOF
6775#define mode_t int
6776_ACEOF
6777
6778fi
6779
Ronald Oussoren450d5612009-06-08 21:12:41 +00006780{ echo "$as_me:$LINENO: checking for off_t" >&5
6781echo $ECHO_N "checking for off_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006782if test "${ac_cv_type_off_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006783 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00006784else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006785 cat >conftest.$ac_ext <<_ACEOF
6786/* confdefs.h. */
6787_ACEOF
6788cat confdefs.h >>conftest.$ac_ext
6789cat >>conftest.$ac_ext <<_ACEOF
6790/* end confdefs.h. */
6791$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00006792typedef off_t ac__type_new_;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006793int
6794main ()
6795{
Ronald Oussoren450d5612009-06-08 21:12:41 +00006796if ((ac__type_new_ *) 0)
6797 return 0;
6798if (sizeof (ac__type_new_))
6799 return 0;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006800 ;
6801 return 0;
6802}
6803_ACEOF
6804rm -f conftest.$ac_objext
6805if { (ac_try="$ac_compile"
6806case "(($ac_try" in
6807 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6808 *) ac_try_echo=$ac_try;;
6809esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006810eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006811 (eval "$ac_compile") 2>conftest.er1
6812 ac_status=$?
6813 grep -v '^ *+' conftest.er1 >conftest.err
6814 rm -f conftest.er1
6815 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006816 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006817 (exit $ac_status); } && {
6818 test -z "$ac_c_werror_flag" ||
6819 test ! -s conftest.err
6820 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006821 ac_cv_type_off_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00006822else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006823 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006824sed 's/^/| /' conftest.$ac_ext >&5
6825
Ronald Oussoren450d5612009-06-08 21:12:41 +00006826 ac_cv_type_off_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00006827fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006828
6829rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00006830fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006831{ echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5
6832echo "${ECHO_T}$ac_cv_type_off_t" >&6; }
6833if test $ac_cv_type_off_t = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006834 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006835else
Martin v. Löwis11437992002-04-12 09:54:03 +00006836
6837cat >>confdefs.h <<_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00006838#define off_t long int
Martin v. Löwis11437992002-04-12 09:54:03 +00006839_ACEOF
6840
6841fi
6842
Ronald Oussoren450d5612009-06-08 21:12:41 +00006843{ echo "$as_me:$LINENO: checking for pid_t" >&5
6844echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006845if test "${ac_cv_type_pid_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006846 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00006847else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006848 cat >conftest.$ac_ext <<_ACEOF
6849/* confdefs.h. */
6850_ACEOF
6851cat confdefs.h >>conftest.$ac_ext
6852cat >>conftest.$ac_ext <<_ACEOF
6853/* end confdefs.h. */
6854$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00006855typedef pid_t ac__type_new_;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006856int
6857main ()
6858{
Ronald Oussoren450d5612009-06-08 21:12:41 +00006859if ((ac__type_new_ *) 0)
6860 return 0;
6861if (sizeof (ac__type_new_))
6862 return 0;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006863 ;
6864 return 0;
6865}
6866_ACEOF
6867rm -f conftest.$ac_objext
6868if { (ac_try="$ac_compile"
6869case "(($ac_try" in
6870 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6871 *) ac_try_echo=$ac_try;;
6872esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006873eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006874 (eval "$ac_compile") 2>conftest.er1
6875 ac_status=$?
6876 grep -v '^ *+' conftest.er1 >conftest.err
6877 rm -f conftest.er1
6878 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006879 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006880 (exit $ac_status); } && {
6881 test -z "$ac_c_werror_flag" ||
6882 test ! -s conftest.err
6883 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006884 ac_cv_type_pid_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00006885else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006886 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006887sed 's/^/| /' conftest.$ac_ext >&5
6888
Ronald Oussoren450d5612009-06-08 21:12:41 +00006889 ac_cv_type_pid_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00006890fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006891
6892rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00006893fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006894{ echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
6895echo "${ECHO_T}$ac_cv_type_pid_t" >&6; }
6896if test $ac_cv_type_pid_t = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00006897 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006898else
Martin v. Löwis11437992002-04-12 09:54:03 +00006899
6900cat >>confdefs.h <<_ACEOF
6901#define pid_t int
6902_ACEOF
6903
6904fi
6905
Ronald Oussoren450d5612009-06-08 21:12:41 +00006906{ echo "$as_me:$LINENO: checking return type of signal handlers" >&5
6907echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006908if test "${ac_cv_type_signal+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006909 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00006910else
6911 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00006912/* confdefs.h. */
6913_ACEOF
6914cat confdefs.h >>conftest.$ac_ext
6915cat >>conftest.$ac_ext <<_ACEOF
6916/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +00006917#include <sys/types.h>
6918#include <signal.h>
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00006919
Martin v. Löwis11437992002-04-12 09:54:03 +00006920int
6921main ()
6922{
Martin v. Löwiseba40652007-08-30 20:10:57 +00006923return *(signal (0, 0)) (0) == 1;
Martin v. Löwis11437992002-04-12 09:54:03 +00006924 ;
6925 return 0;
6926}
6927_ACEOF
6928rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00006929if { (ac_try="$ac_compile"
6930case "(($ac_try" in
6931 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6932 *) ac_try_echo=$ac_try;;
6933esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006934eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006935 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00006936 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00006937 grep -v '^ *+' conftest.er1 >conftest.err
6938 rm -f conftest.er1
6939 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006940 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00006941 (exit $ac_status); } && {
6942 test -z "$ac_c_werror_flag" ||
6943 test ! -s conftest.err
6944 } && test -s conftest.$ac_objext; then
6945 ac_cv_type_signal=int
Guido van Rossum627b2d71993-12-24 10:39:16 +00006946else
Ronald Oussoren450d5612009-06-08 21:12:41 +00006947 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00006948sed 's/^/| /' conftest.$ac_ext >&5
6949
Martin v. Löwiseba40652007-08-30 20:10:57 +00006950 ac_cv_type_signal=void
Guido van Rossum627b2d71993-12-24 10:39:16 +00006951fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00006952
6953rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006954fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00006955{ echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
6956echo "${ECHO_T}$ac_cv_type_signal" >&6; }
Guido van Rossum48bdbfc1996-05-28 22:53:48 +00006957
Martin v. Löwis11437992002-04-12 09:54:03 +00006958cat >>confdefs.h <<_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006959#define RETSIGTYPE $ac_cv_type_signal
Martin v. Löwis11437992002-04-12 09:54:03 +00006960_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +00006961
Michael W. Hudson54241132001-12-07 15:38:26 +00006962
Ronald Oussoren450d5612009-06-08 21:12:41 +00006963{ echo "$as_me:$LINENO: checking for size_t" >&5
6964echo $ECHO_N "checking for size_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00006965if test "${ac_cv_type_size_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00006966 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +00006967else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006968 cat >conftest.$ac_ext <<_ACEOF
6969/* confdefs.h. */
6970_ACEOF
6971cat confdefs.h >>conftest.$ac_ext
6972cat >>conftest.$ac_ext <<_ACEOF
6973/* end confdefs.h. */
6974$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00006975typedef size_t ac__type_new_;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006976int
6977main ()
6978{
Ronald Oussoren450d5612009-06-08 21:12:41 +00006979if ((ac__type_new_ *) 0)
6980 return 0;
6981if (sizeof (ac__type_new_))
6982 return 0;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006983 ;
6984 return 0;
6985}
6986_ACEOF
6987rm -f conftest.$ac_objext
6988if { (ac_try="$ac_compile"
6989case "(($ac_try" in
6990 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6991 *) ac_try_echo=$ac_try;;
6992esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00006993eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00006994 (eval "$ac_compile") 2>conftest.er1
6995 ac_status=$?
6996 grep -v '^ *+' conftest.er1 >conftest.err
6997 rm -f conftest.er1
6998 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00006999 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007000 (exit $ac_status); } && {
7001 test -z "$ac_c_werror_flag" ||
7002 test ! -s conftest.err
7003 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007004 ac_cv_type_size_t=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +00007005else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007006 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007007sed 's/^/| /' conftest.$ac_ext >&5
7008
Ronald Oussoren450d5612009-06-08 21:12:41 +00007009 ac_cv_type_size_t=no
Guido van Rossum627b2d71993-12-24 10:39:16 +00007010fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007011
7012rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +00007013fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007014{ echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
7015echo "${ECHO_T}$ac_cv_type_size_t" >&6; }
7016if test $ac_cv_type_size_t = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007017 :
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007018else
Martin v. Löwis11437992002-04-12 09:54:03 +00007019
7020cat >>confdefs.h <<_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +00007021#define size_t unsigned int
Martin v. Löwis11437992002-04-12 09:54:03 +00007022_ACEOF
7023
7024fi
7025
Ronald Oussoren450d5612009-06-08 21:12:41 +00007026{ echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5
7027echo $ECHO_N "checking for uid_t in sys/types.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007028if test "${ac_cv_type_uid_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007029 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007030else
7031 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007032/* confdefs.h. */
7033_ACEOF
7034cat confdefs.h >>conftest.$ac_ext
7035cat >>conftest.$ac_ext <<_ACEOF
7036/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007037#include <sys/types.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007038
7039_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007040if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +00007041 $EGREP "uid_t" >/dev/null 2>&1; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007042 ac_cv_type_uid_t=yes
7043else
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007044 ac_cv_type_uid_t=no
7045fi
Guido van Rossum627b2d71993-12-24 10:39:16 +00007046rm -f conftest*
7047
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007048fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007049{ echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5
7050echo "${ECHO_T}$ac_cv_type_uid_t" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +00007051if test $ac_cv_type_uid_t = no; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007052
Martin v. Löwis11437992002-04-12 09:54:03 +00007053cat >>confdefs.h <<\_ACEOF
7054#define uid_t int
7055_ACEOF
7056
7057
7058cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007059#define gid_t int
Martin v. Löwis11437992002-04-12 09:54:03 +00007060_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +00007061
7062fi
7063
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007064
Ronald Oussoren450d5612009-06-08 21:12:41 +00007065 { echo "$as_me:$LINENO: checking for uint32_t" >&5
7066echo $ECHO_N "checking for uint32_t... $ECHO_C" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007067if test "${ac_cv_c_uint32_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007068 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007069else
7070 ac_cv_c_uint32_t=no
7071 for ac_type in 'uint32_t' 'unsigned int' 'unsigned long int' \
7072 'unsigned long long int' 'unsigned short int' 'unsigned char'; do
7073 cat >conftest.$ac_ext <<_ACEOF
7074/* confdefs.h. */
7075_ACEOF
7076cat confdefs.h >>conftest.$ac_ext
7077cat >>conftest.$ac_ext <<_ACEOF
7078/* end confdefs.h. */
7079$ac_includes_default
7080int
7081main ()
7082{
7083static int test_array [1 - 2 * !(($ac_type) -1 >> (32 - 1) == 1)];
7084test_array [0] = 0
7085
7086 ;
7087 return 0;
7088}
7089_ACEOF
7090rm -f conftest.$ac_objext
7091if { (ac_try="$ac_compile"
7092case "(($ac_try" in
7093 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7094 *) ac_try_echo=$ac_try;;
7095esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007096eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007097 (eval "$ac_compile") 2>conftest.er1
7098 ac_status=$?
7099 grep -v '^ *+' conftest.er1 >conftest.err
7100 rm -f conftest.er1
7101 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007102 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007103 (exit $ac_status); } && {
7104 test -z "$ac_c_werror_flag" ||
7105 test ! -s conftest.err
7106 } && test -s conftest.$ac_objext; then
7107 case $ac_type in
7108 uint32_t) ac_cv_c_uint32_t=yes ;;
7109 *) ac_cv_c_uint32_t=$ac_type ;;
7110esac
7111
7112else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007113 echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007114sed 's/^/| /' conftest.$ac_ext >&5
7115
7116
7117fi
7118
7119rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7120 test "$ac_cv_c_uint32_t" != no && break
7121 done
7122fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007123{ echo "$as_me:$LINENO: result: $ac_cv_c_uint32_t" >&5
7124echo "${ECHO_T}$ac_cv_c_uint32_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007125 case $ac_cv_c_uint32_t in #(
7126 no|yes) ;; #(
7127 *)
7128
7129cat >>confdefs.h <<\_ACEOF
7130#define _UINT32_T 1
7131_ACEOF
7132
7133
7134cat >>confdefs.h <<_ACEOF
7135#define uint32_t $ac_cv_c_uint32_t
7136_ACEOF
7137;;
7138 esac
7139
7140
Ronald Oussoren450d5612009-06-08 21:12:41 +00007141 { echo "$as_me:$LINENO: checking for uint64_t" >&5
7142echo $ECHO_N "checking for uint64_t... $ECHO_C" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007143if test "${ac_cv_c_uint64_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007144 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007145else
7146 ac_cv_c_uint64_t=no
7147 for ac_type in 'uint64_t' 'unsigned int' 'unsigned long int' \
7148 'unsigned long long int' 'unsigned short int' 'unsigned char'; do
7149 cat >conftest.$ac_ext <<_ACEOF
7150/* confdefs.h. */
7151_ACEOF
7152cat confdefs.h >>conftest.$ac_ext
7153cat >>conftest.$ac_ext <<_ACEOF
7154/* end confdefs.h. */
7155$ac_includes_default
7156int
7157main ()
7158{
7159static int test_array [1 - 2 * !(($ac_type) -1 >> (64 - 1) == 1)];
7160test_array [0] = 0
7161
7162 ;
7163 return 0;
7164}
7165_ACEOF
7166rm -f conftest.$ac_objext
7167if { (ac_try="$ac_compile"
7168case "(($ac_try" in
7169 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7170 *) ac_try_echo=$ac_try;;
7171esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007172eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007173 (eval "$ac_compile") 2>conftest.er1
7174 ac_status=$?
7175 grep -v '^ *+' conftest.er1 >conftest.err
7176 rm -f conftest.er1
7177 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007178 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007179 (exit $ac_status); } && {
7180 test -z "$ac_c_werror_flag" ||
7181 test ! -s conftest.err
7182 } && test -s conftest.$ac_objext; then
7183 case $ac_type in
7184 uint64_t) ac_cv_c_uint64_t=yes ;;
7185 *) ac_cv_c_uint64_t=$ac_type ;;
7186esac
7187
7188else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007189 echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007190sed 's/^/| /' conftest.$ac_ext >&5
7191
7192
7193fi
7194
7195rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7196 test "$ac_cv_c_uint64_t" != no && break
7197 done
7198fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007199{ echo "$as_me:$LINENO: result: $ac_cv_c_uint64_t" >&5
7200echo "${ECHO_T}$ac_cv_c_uint64_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007201 case $ac_cv_c_uint64_t in #(
7202 no|yes) ;; #(
7203 *)
7204
7205cat >>confdefs.h <<\_ACEOF
7206#define _UINT64_T 1
7207_ACEOF
7208
7209
7210cat >>confdefs.h <<_ACEOF
7211#define uint64_t $ac_cv_c_uint64_t
7212_ACEOF
7213;;
7214 esac
7215
7216
Ronald Oussoren450d5612009-06-08 21:12:41 +00007217 { echo "$as_me:$LINENO: checking for int32_t" >&5
7218echo $ECHO_N "checking for int32_t... $ECHO_C" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007219if test "${ac_cv_c_int32_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007220 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007221else
7222 ac_cv_c_int32_t=no
7223 for ac_type in 'int32_t' 'int' 'long int' \
7224 'long long int' 'short int' 'signed char'; do
7225 cat >conftest.$ac_ext <<_ACEOF
7226/* confdefs.h. */
7227_ACEOF
7228cat confdefs.h >>conftest.$ac_ext
7229cat >>conftest.$ac_ext <<_ACEOF
7230/* end confdefs.h. */
7231$ac_includes_default
7232int
7233main ()
7234{
7235static int test_array [1 - 2 * !(0 < ($ac_type) (((($ac_type) 1 << (32 - 2)) - 1) * 2 + 1))];
7236test_array [0] = 0
7237
7238 ;
7239 return 0;
7240}
7241_ACEOF
7242rm -f conftest.$ac_objext
7243if { (ac_try="$ac_compile"
7244case "(($ac_try" in
7245 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7246 *) ac_try_echo=$ac_try;;
7247esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007248eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007249 (eval "$ac_compile") 2>conftest.er1
7250 ac_status=$?
7251 grep -v '^ *+' conftest.er1 >conftest.err
7252 rm -f conftest.er1
7253 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007255 (exit $ac_status); } && {
7256 test -z "$ac_c_werror_flag" ||
7257 test ! -s conftest.err
7258 } && test -s conftest.$ac_objext; then
7259 cat >conftest.$ac_ext <<_ACEOF
7260/* confdefs.h. */
7261_ACEOF
7262cat confdefs.h >>conftest.$ac_ext
7263cat >>conftest.$ac_ext <<_ACEOF
7264/* end confdefs.h. */
7265$ac_includes_default
7266int
7267main ()
7268{
7269static int test_array [1 - 2 * !(($ac_type) (((($ac_type) 1 << (32 - 2)) - 1) * 2 + 1)
Ronald Oussoren450d5612009-06-08 21:12:41 +00007270 < ($ac_type) (((($ac_type) 1 << (32 - 2)) - 1) * 2 + 2))];
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007271test_array [0] = 0
7272
7273 ;
7274 return 0;
7275}
7276_ACEOF
7277rm -f conftest.$ac_objext
7278if { (ac_try="$ac_compile"
7279case "(($ac_try" in
7280 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7281 *) ac_try_echo=$ac_try;;
7282esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007283eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007284 (eval "$ac_compile") 2>conftest.er1
7285 ac_status=$?
7286 grep -v '^ *+' conftest.er1 >conftest.err
7287 rm -f conftest.er1
7288 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007289 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007290 (exit $ac_status); } && {
7291 test -z "$ac_c_werror_flag" ||
7292 test ! -s conftest.err
7293 } && test -s conftest.$ac_objext; then
7294 :
7295else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007296 echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007297sed 's/^/| /' conftest.$ac_ext >&5
7298
7299 case $ac_type in
7300 int32_t) ac_cv_c_int32_t=yes ;;
7301 *) ac_cv_c_int32_t=$ac_type ;;
7302esac
7303
7304fi
7305
7306rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7307else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007308 echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007309sed 's/^/| /' conftest.$ac_ext >&5
7310
7311
7312fi
7313
7314rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7315 test "$ac_cv_c_int32_t" != no && break
7316 done
7317fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007318{ echo "$as_me:$LINENO: result: $ac_cv_c_int32_t" >&5
7319echo "${ECHO_T}$ac_cv_c_int32_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007320 case $ac_cv_c_int32_t in #(
7321 no|yes) ;; #(
7322 *)
7323
7324cat >>confdefs.h <<_ACEOF
7325#define int32_t $ac_cv_c_int32_t
7326_ACEOF
7327;;
7328 esac
7329
7330
Ronald Oussoren450d5612009-06-08 21:12:41 +00007331 { echo "$as_me:$LINENO: checking for int64_t" >&5
7332echo $ECHO_N "checking for int64_t... $ECHO_C" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007333if test "${ac_cv_c_int64_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007334 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007335else
7336 ac_cv_c_int64_t=no
7337 for ac_type in 'int64_t' 'int' 'long int' \
7338 'long long int' 'short int' 'signed char'; do
7339 cat >conftest.$ac_ext <<_ACEOF
7340/* confdefs.h. */
7341_ACEOF
7342cat confdefs.h >>conftest.$ac_ext
7343cat >>conftest.$ac_ext <<_ACEOF
7344/* end confdefs.h. */
7345$ac_includes_default
7346int
7347main ()
7348{
7349static int test_array [1 - 2 * !(0 < ($ac_type) (((($ac_type) 1 << (64 - 2)) - 1) * 2 + 1))];
7350test_array [0] = 0
7351
7352 ;
7353 return 0;
7354}
7355_ACEOF
7356rm -f conftest.$ac_objext
7357if { (ac_try="$ac_compile"
7358case "(($ac_try" in
7359 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7360 *) ac_try_echo=$ac_try;;
7361esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007362eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007363 (eval "$ac_compile") 2>conftest.er1
7364 ac_status=$?
7365 grep -v '^ *+' conftest.er1 >conftest.err
7366 rm -f conftest.er1
7367 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007368 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007369 (exit $ac_status); } && {
7370 test -z "$ac_c_werror_flag" ||
7371 test ! -s conftest.err
7372 } && test -s conftest.$ac_objext; then
7373 cat >conftest.$ac_ext <<_ACEOF
7374/* confdefs.h. */
7375_ACEOF
7376cat confdefs.h >>conftest.$ac_ext
7377cat >>conftest.$ac_ext <<_ACEOF
7378/* end confdefs.h. */
7379$ac_includes_default
7380int
7381main ()
7382{
7383static int test_array [1 - 2 * !(($ac_type) (((($ac_type) 1 << (64 - 2)) - 1) * 2 + 1)
Ronald Oussoren450d5612009-06-08 21:12:41 +00007384 < ($ac_type) (((($ac_type) 1 << (64 - 2)) - 1) * 2 + 2))];
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007385test_array [0] = 0
7386
7387 ;
7388 return 0;
7389}
7390_ACEOF
7391rm -f conftest.$ac_objext
7392if { (ac_try="$ac_compile"
7393case "(($ac_try" in
7394 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7395 *) ac_try_echo=$ac_try;;
7396esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007397eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007398 (eval "$ac_compile") 2>conftest.er1
7399 ac_status=$?
7400 grep -v '^ *+' conftest.er1 >conftest.err
7401 rm -f conftest.er1
7402 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007403 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007404 (exit $ac_status); } && {
7405 test -z "$ac_c_werror_flag" ||
7406 test ! -s conftest.err
7407 } && test -s conftest.$ac_objext; then
7408 :
7409else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007410 echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007411sed 's/^/| /' conftest.$ac_ext >&5
7412
7413 case $ac_type in
7414 int64_t) ac_cv_c_int64_t=yes ;;
7415 *) ac_cv_c_int64_t=$ac_type ;;
7416esac
7417
7418fi
7419
7420rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7421else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007422 echo "$as_me: failed program was:" >&5
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007423sed 's/^/| /' conftest.$ac_ext >&5
7424
7425
7426fi
7427
7428rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7429 test "$ac_cv_c_int64_t" != no && break
7430 done
7431fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007432{ echo "$as_me:$LINENO: result: $ac_cv_c_int64_t" >&5
7433echo "${ECHO_T}$ac_cv_c_int64_t" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +00007434 case $ac_cv_c_int64_t in #(
7435 no|yes) ;; #(
7436 *)
7437
7438cat >>confdefs.h <<_ACEOF
7439#define int64_t $ac_cv_c_int64_t
7440_ACEOF
7441;;
7442 esac
7443
Ronald Oussoren450d5612009-06-08 21:12:41 +00007444{ echo "$as_me:$LINENO: checking for ssize_t" >&5
7445echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6; }
Martin v. Löwis18e16552006-02-15 17:27:45 +00007446if test "${ac_cv_type_ssize_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007447 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis18e16552006-02-15 17:27:45 +00007448else
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007449 cat >conftest.$ac_ext <<_ACEOF
7450/* confdefs.h. */
7451_ACEOF
7452cat confdefs.h >>conftest.$ac_ext
7453cat >>conftest.$ac_ext <<_ACEOF
7454/* end confdefs.h. */
7455$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007456typedef ssize_t ac__type_new_;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007457int
7458main ()
7459{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007460if ((ac__type_new_ *) 0)
7461 return 0;
7462if (sizeof (ac__type_new_))
7463 return 0;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007464 ;
7465 return 0;
7466}
7467_ACEOF
7468rm -f conftest.$ac_objext
7469if { (ac_try="$ac_compile"
7470case "(($ac_try" in
7471 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7472 *) ac_try_echo=$ac_try;;
7473esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007474eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007475 (eval "$ac_compile") 2>conftest.er1
7476 ac_status=$?
7477 grep -v '^ *+' conftest.er1 >conftest.err
7478 rm -f conftest.er1
7479 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Antoine Pitrouf2caeed2009-05-24 20:23:57 +00007481 (exit $ac_status); } && {
7482 test -z "$ac_c_werror_flag" ||
7483 test ! -s conftest.err
7484 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007485 ac_cv_type_ssize_t=yes
Martin v. Löwis18e16552006-02-15 17:27:45 +00007486else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007487 echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +00007488sed 's/^/| /' conftest.$ac_ext >&5
7489
Ronald Oussoren450d5612009-06-08 21:12:41 +00007490 ac_cv_type_ssize_t=no
Martin v. Löwis18e16552006-02-15 17:27:45 +00007491fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007492
7493rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +00007494fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007495{ echo "$as_me:$LINENO: result: $ac_cv_type_ssize_t" >&5
7496echo "${ECHO_T}$ac_cv_type_ssize_t" >&6; }
7497if test $ac_cv_type_ssize_t = yes; then
Martin v. Löwis18e16552006-02-15 17:27:45 +00007498
7499cat >>confdefs.h <<\_ACEOF
7500#define HAVE_SSIZE_T 1
7501_ACEOF
7502
7503fi
7504
Jack Jansendd19cf82001-12-06 22:36:17 +00007505
Michael W. Hudson54241132001-12-07 15:38:26 +00007506# Sizes of various common basic types
Skip Montanarob9820a32004-01-17 00:16:12 +00007507# ANSI C requires sizeof(char) == 1, so no need to check it
Ronald Oussoren450d5612009-06-08 21:12:41 +00007508{ echo "$as_me:$LINENO: checking for int" >&5
7509echo $ECHO_N "checking for int... $ECHO_C" >&6; }
7510if test "${ac_cv_type_int+set}" = set; then
7511 echo $ECHO_N "(cached) $ECHO_C" >&6
7512else
7513 cat >conftest.$ac_ext <<_ACEOF
7514/* confdefs.h. */
7515_ACEOF
7516cat confdefs.h >>conftest.$ac_ext
7517cat >>conftest.$ac_ext <<_ACEOF
7518/* end confdefs.h. */
7519$ac_includes_default
7520typedef int ac__type_new_;
7521int
7522main ()
7523{
7524if ((ac__type_new_ *) 0)
7525 return 0;
7526if (sizeof (ac__type_new_))
7527 return 0;
7528 ;
7529 return 0;
7530}
7531_ACEOF
7532rm -f conftest.$ac_objext
7533if { (ac_try="$ac_compile"
7534case "(($ac_try" in
7535 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7536 *) ac_try_echo=$ac_try;;
7537esac
7538eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7539 (eval "$ac_compile") 2>conftest.er1
7540 ac_status=$?
7541 grep -v '^ *+' conftest.er1 >conftest.err
7542 rm -f conftest.er1
7543 cat conftest.err >&5
7544 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7545 (exit $ac_status); } && {
7546 test -z "$ac_c_werror_flag" ||
7547 test ! -s conftest.err
7548 } && test -s conftest.$ac_objext; then
7549 ac_cv_type_int=yes
7550else
7551 echo "$as_me: failed program was:" >&5
7552sed 's/^/| /' conftest.$ac_ext >&5
7553
7554 ac_cv_type_int=no
7555fi
7556
7557rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7558fi
7559{ echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
7560echo "${ECHO_T}$ac_cv_type_int" >&6; }
7561
Martin v. Löwiseba40652007-08-30 20:10:57 +00007562# The cast to long int works around a bug in the HP C Compiler
7563# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7564# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7565# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00007566{ echo "$as_me:$LINENO: checking size of int" >&5
7567echo $ECHO_N "checking size of int... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007568if test "${ac_cv_sizeof_int+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007569 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007570else
Martin v. Löwis11437992002-04-12 09:54:03 +00007571 if test "$cross_compiling" = yes; then
7572 # Depending upon the size, compute the lo and hi bounds.
7573cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007574/* confdefs.h. */
7575_ACEOF
7576cat confdefs.h >>conftest.$ac_ext
7577cat >>conftest.$ac_ext <<_ACEOF
7578/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007579$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007580 typedef int ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00007581int
7582main ()
7583{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007584static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00007585test_array [0] = 0
7586
7587 ;
7588 return 0;
7589}
7590_ACEOF
7591rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007592if { (ac_try="$ac_compile"
7593case "(($ac_try" in
7594 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7595 *) ac_try_echo=$ac_try;;
7596esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007597eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007598 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007599 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007600 grep -v '^ *+' conftest.er1 >conftest.err
7601 rm -f conftest.er1
7602 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007603 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007604 (exit $ac_status); } && {
7605 test -z "$ac_c_werror_flag" ||
7606 test ! -s conftest.err
7607 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007608 ac_lo=0 ac_mid=0
7609 while :; do
7610 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007611/* confdefs.h. */
7612_ACEOF
7613cat confdefs.h >>conftest.$ac_ext
7614cat >>conftest.$ac_ext <<_ACEOF
7615/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007616$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007617 typedef int ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00007618int
7619main ()
7620{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007621static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00007622test_array [0] = 0
7623
7624 ;
7625 return 0;
7626}
7627_ACEOF
7628rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007629if { (ac_try="$ac_compile"
7630case "(($ac_try" in
7631 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7632 *) ac_try_echo=$ac_try;;
7633esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007634eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007635 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007636 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007637 grep -v '^ *+' conftest.er1 >conftest.err
7638 rm -f conftest.er1
7639 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007640 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007641 (exit $ac_status); } && {
7642 test -z "$ac_c_werror_flag" ||
7643 test ! -s conftest.err
7644 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007645 ac_hi=$ac_mid; break
7646else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007647 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007648sed 's/^/| /' conftest.$ac_ext >&5
7649
Martin v. Löwiseba40652007-08-30 20:10:57 +00007650 ac_lo=`expr $ac_mid + 1`
7651 if test $ac_lo -le $ac_mid; then
7652 ac_lo= ac_hi=
7653 break
7654 fi
7655 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00007656fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007657
7658rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007659 done
7660else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007661 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007662sed 's/^/| /' conftest.$ac_ext >&5
7663
Martin v. Löwiseba40652007-08-30 20:10:57 +00007664 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007665/* confdefs.h. */
7666_ACEOF
7667cat confdefs.h >>conftest.$ac_ext
7668cat >>conftest.$ac_ext <<_ACEOF
7669/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007670$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007671 typedef int ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00007672int
7673main ()
7674{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007675static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00007676test_array [0] = 0
7677
7678 ;
7679 return 0;
7680}
7681_ACEOF
7682rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007683if { (ac_try="$ac_compile"
7684case "(($ac_try" in
7685 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7686 *) ac_try_echo=$ac_try;;
7687esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007688eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007689 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007690 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007691 grep -v '^ *+' conftest.er1 >conftest.err
7692 rm -f conftest.er1
7693 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007695 (exit $ac_status); } && {
7696 test -z "$ac_c_werror_flag" ||
7697 test ! -s conftest.err
7698 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007699 ac_hi=-1 ac_mid=-1
7700 while :; do
7701 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007702/* confdefs.h. */
7703_ACEOF
7704cat confdefs.h >>conftest.$ac_ext
7705cat >>conftest.$ac_ext <<_ACEOF
7706/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007707$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007708 typedef int ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00007709int
7710main ()
7711{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007712static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00007713test_array [0] = 0
7714
7715 ;
7716 return 0;
7717}
7718_ACEOF
7719rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007720if { (ac_try="$ac_compile"
7721case "(($ac_try" in
7722 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7723 *) ac_try_echo=$ac_try;;
7724esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007725eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007726 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007727 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007728 grep -v '^ *+' conftest.er1 >conftest.err
7729 rm -f conftest.er1
7730 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007732 (exit $ac_status); } && {
7733 test -z "$ac_c_werror_flag" ||
7734 test ! -s conftest.err
7735 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007736 ac_lo=$ac_mid; break
7737else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007738 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007739sed 's/^/| /' conftest.$ac_ext >&5
7740
Martin v. Löwiseba40652007-08-30 20:10:57 +00007741 ac_hi=`expr '(' $ac_mid ')' - 1`
7742 if test $ac_mid -le $ac_hi; then
7743 ac_lo= ac_hi=
7744 break
7745 fi
7746 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00007747fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007748
7749rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007750 done
7751else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007752 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007753sed 's/^/| /' conftest.$ac_ext >&5
7754
Martin v. Löwiseba40652007-08-30 20:10:57 +00007755 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00007756fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007757
7758rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007759fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007760
7761rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007762# Binary search between lo and hi bounds.
7763while test "x$ac_lo" != "x$ac_hi"; do
7764 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
7765 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007766/* confdefs.h. */
7767_ACEOF
7768cat confdefs.h >>conftest.$ac_ext
7769cat >>conftest.$ac_ext <<_ACEOF
7770/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007771$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007772 typedef int ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00007773int
7774main ()
7775{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007776static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00007777test_array [0] = 0
7778
7779 ;
7780 return 0;
7781}
7782_ACEOF
7783rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007784if { (ac_try="$ac_compile"
7785case "(($ac_try" in
7786 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7787 *) ac_try_echo=$ac_try;;
7788esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007789eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007790 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00007791 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00007792 grep -v '^ *+' conftest.er1 >conftest.err
7793 rm -f conftest.er1
7794 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007795 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007796 (exit $ac_status); } && {
7797 test -z "$ac_c_werror_flag" ||
7798 test ! -s conftest.err
7799 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00007800 ac_hi=$ac_mid
7801else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007802 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007803sed 's/^/| /' conftest.$ac_ext >&5
7804
Martin v. Löwiseba40652007-08-30 20:10:57 +00007805 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00007806fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007807
7808rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007809done
7810case $ac_lo in
7811?*) ac_cv_sizeof_int=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00007812'') if test "$ac_cv_type_int" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007813 { { echo "$as_me:$LINENO: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00007814See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007815echo "$as_me: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00007816See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00007817 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00007818 else
7819 ac_cv_sizeof_int=0
7820 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00007821esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007822else
Martin v. Löwis11437992002-04-12 09:54:03 +00007823 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007824/* confdefs.h. */
7825_ACEOF
7826cat confdefs.h >>conftest.$ac_ext
7827cat >>conftest.$ac_ext <<_ACEOF
7828/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007829$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007830 typedef int ac__type_sizeof_;
7831static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
7832static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00007833#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007834#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00007835int
7836main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007837{
Martin v. Löwis11437992002-04-12 09:54:03 +00007838
7839 FILE *f = fopen ("conftest.val", "w");
7840 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00007841 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00007842 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00007843 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00007844 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00007845 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00007846 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00007847 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00007848 }
7849 else
7850 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00007851 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00007852 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00007853 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00007854 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00007855 }
Martin v. Löwiseba40652007-08-30 20:10:57 +00007856 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00007857
7858 ;
7859 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007860}
Martin v. Löwis11437992002-04-12 09:54:03 +00007861_ACEOF
7862rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007863if { (ac_try="$ac_link"
7864case "(($ac_try" in
7865 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7866 *) ac_try_echo=$ac_try;;
7867esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007868eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007869 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00007870 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00007871 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00007872 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00007873 { (case "(($ac_try" in
7874 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7875 *) ac_try_echo=$ac_try;;
7876esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00007877eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00007878 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00007879 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00007880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00007881 (exit $ac_status); }; }; then
7882 ac_cv_sizeof_int=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007883else
Ronald Oussoren450d5612009-06-08 21:12:41 +00007884 echo "$as_me: program exited with status $ac_status" >&5
7885echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00007886sed 's/^/| /' conftest.$ac_ext >&5
7887
Martin v. Löwis11437992002-04-12 09:54:03 +00007888( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00007889if test "$ac_cv_type_int" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007890 { { echo "$as_me:$LINENO: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00007891See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00007892echo "$as_me: error: cannot compute sizeof (int)
Skip Montanaro6dead952003-09-25 14:50:04 +00007893See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00007894 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00007895 else
7896 ac_cv_sizeof_int=0
7897 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00007898fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00007899rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00007900fi
7901rm -f conftest.val
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007902fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00007903{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
7904echo "${ECHO_T}$ac_cv_sizeof_int" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00007905
7906
7907
Martin v. Löwis11437992002-04-12 09:54:03 +00007908cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007909#define SIZEOF_INT $ac_cv_sizeof_int
Martin v. Löwis11437992002-04-12 09:54:03 +00007910_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00007911
7912
Ronald Oussoren450d5612009-06-08 21:12:41 +00007913{ echo "$as_me:$LINENO: checking for long" >&5
7914echo $ECHO_N "checking for long... $ECHO_C" >&6; }
7915if test "${ac_cv_type_long+set}" = set; then
7916 echo $ECHO_N "(cached) $ECHO_C" >&6
7917else
7918 cat >conftest.$ac_ext <<_ACEOF
7919/* confdefs.h. */
7920_ACEOF
7921cat confdefs.h >>conftest.$ac_ext
7922cat >>conftest.$ac_ext <<_ACEOF
7923/* end confdefs.h. */
7924$ac_includes_default
7925typedef long ac__type_new_;
7926int
7927main ()
7928{
7929if ((ac__type_new_ *) 0)
7930 return 0;
7931if (sizeof (ac__type_new_))
7932 return 0;
7933 ;
7934 return 0;
7935}
7936_ACEOF
7937rm -f conftest.$ac_objext
7938if { (ac_try="$ac_compile"
7939case "(($ac_try" in
7940 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7941 *) ac_try_echo=$ac_try;;
7942esac
7943eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7944 (eval "$ac_compile") 2>conftest.er1
7945 ac_status=$?
7946 grep -v '^ *+' conftest.er1 >conftest.err
7947 rm -f conftest.er1
7948 cat conftest.err >&5
7949 echo "$as_me:$LINENO: \$? = $ac_status" >&5
7950 (exit $ac_status); } && {
7951 test -z "$ac_c_werror_flag" ||
7952 test ! -s conftest.err
7953 } && test -s conftest.$ac_objext; then
7954 ac_cv_type_long=yes
7955else
7956 echo "$as_me: failed program was:" >&5
7957sed 's/^/| /' conftest.$ac_ext >&5
7958
7959 ac_cv_type_long=no
7960fi
7961
7962rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7963fi
7964{ echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
7965echo "${ECHO_T}$ac_cv_type_long" >&6; }
7966
Martin v. Löwiseba40652007-08-30 20:10:57 +00007967# The cast to long int works around a bug in the HP C Compiler
7968# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
7969# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
7970# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00007971{ echo "$as_me:$LINENO: checking size of long" >&5
7972echo $ECHO_N "checking size of long... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00007973if test "${ac_cv_sizeof_long+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00007974 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00007975else
Martin v. Löwis11437992002-04-12 09:54:03 +00007976 if test "$cross_compiling" = yes; then
7977 # Depending upon the size, compute the lo and hi bounds.
7978cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00007979/* confdefs.h. */
7980_ACEOF
7981cat confdefs.h >>conftest.$ac_ext
7982cat >>conftest.$ac_ext <<_ACEOF
7983/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00007984$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00007985 typedef long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00007986int
7987main ()
7988{
Ronald Oussoren450d5612009-06-08 21:12:41 +00007989static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00007990test_array [0] = 0
7991
7992 ;
7993 return 0;
7994}
7995_ACEOF
7996rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00007997if { (ac_try="$ac_compile"
7998case "(($ac_try" in
7999 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8000 *) ac_try_echo=$ac_try;;
8001esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008002eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008003 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008004 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008005 grep -v '^ *+' conftest.er1 >conftest.err
8006 rm -f conftest.er1
8007 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008008 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008009 (exit $ac_status); } && {
8010 test -z "$ac_c_werror_flag" ||
8011 test ! -s conftest.err
8012 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008013 ac_lo=0 ac_mid=0
8014 while :; do
8015 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008016/* confdefs.h. */
8017_ACEOF
8018cat confdefs.h >>conftest.$ac_ext
8019cat >>conftest.$ac_ext <<_ACEOF
8020/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008021$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008022 typedef long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008023int
8024main ()
8025{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008026static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008027test_array [0] = 0
8028
8029 ;
8030 return 0;
8031}
8032_ACEOF
8033rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008034if { (ac_try="$ac_compile"
8035case "(($ac_try" in
8036 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8037 *) ac_try_echo=$ac_try;;
8038esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008039eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008040 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008041 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008042 grep -v '^ *+' conftest.er1 >conftest.err
8043 rm -f conftest.er1
8044 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008045 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008046 (exit $ac_status); } && {
8047 test -z "$ac_c_werror_flag" ||
8048 test ! -s conftest.err
8049 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008050 ac_hi=$ac_mid; break
8051else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008052 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008053sed 's/^/| /' conftest.$ac_ext >&5
8054
Martin v. Löwiseba40652007-08-30 20:10:57 +00008055 ac_lo=`expr $ac_mid + 1`
8056 if test $ac_lo -le $ac_mid; then
8057 ac_lo= ac_hi=
8058 break
8059 fi
8060 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008061fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008062
8063rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008064 done
8065else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008066 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008067sed 's/^/| /' conftest.$ac_ext >&5
8068
Martin v. Löwiseba40652007-08-30 20:10:57 +00008069 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008070/* confdefs.h. */
8071_ACEOF
8072cat confdefs.h >>conftest.$ac_ext
8073cat >>conftest.$ac_ext <<_ACEOF
8074/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008075$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008076 typedef long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008077int
8078main ()
8079{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008080static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008081test_array [0] = 0
8082
8083 ;
8084 return 0;
8085}
8086_ACEOF
8087rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008088if { (ac_try="$ac_compile"
8089case "(($ac_try" in
8090 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8091 *) ac_try_echo=$ac_try;;
8092esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008093eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008094 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008095 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008096 grep -v '^ *+' conftest.er1 >conftest.err
8097 rm -f conftest.er1
8098 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008100 (exit $ac_status); } && {
8101 test -z "$ac_c_werror_flag" ||
8102 test ! -s conftest.err
8103 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008104 ac_hi=-1 ac_mid=-1
8105 while :; do
8106 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008107/* confdefs.h. */
8108_ACEOF
8109cat confdefs.h >>conftest.$ac_ext
8110cat >>conftest.$ac_ext <<_ACEOF
8111/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008112$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008113 typedef long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008114int
8115main ()
8116{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008117static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008118test_array [0] = 0
8119
8120 ;
8121 return 0;
8122}
8123_ACEOF
8124rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008125if { (ac_try="$ac_compile"
8126case "(($ac_try" in
8127 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8128 *) ac_try_echo=$ac_try;;
8129esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008130eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008131 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008132 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008133 grep -v '^ *+' conftest.er1 >conftest.err
8134 rm -f conftest.er1
8135 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008136 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008137 (exit $ac_status); } && {
8138 test -z "$ac_c_werror_flag" ||
8139 test ! -s conftest.err
8140 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008141 ac_lo=$ac_mid; break
8142else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008143 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008144sed 's/^/| /' conftest.$ac_ext >&5
8145
Martin v. Löwiseba40652007-08-30 20:10:57 +00008146 ac_hi=`expr '(' $ac_mid ')' - 1`
8147 if test $ac_mid -le $ac_hi; then
8148 ac_lo= ac_hi=
8149 break
8150 fi
8151 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00008152fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008153
8154rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008155 done
8156else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008157 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008158sed 's/^/| /' conftest.$ac_ext >&5
8159
Martin v. Löwiseba40652007-08-30 20:10:57 +00008160 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00008161fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008162
8163rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008164fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008165
8166rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008167# Binary search between lo and hi bounds.
8168while test "x$ac_lo" != "x$ac_hi"; do
8169 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8170 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008171/* confdefs.h. */
8172_ACEOF
8173cat confdefs.h >>conftest.$ac_ext
8174cat >>conftest.$ac_ext <<_ACEOF
8175/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008176$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008177 typedef long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008178int
8179main ()
8180{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008181static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008182test_array [0] = 0
8183
8184 ;
8185 return 0;
8186}
8187_ACEOF
8188rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008189if { (ac_try="$ac_compile"
8190case "(($ac_try" in
8191 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8192 *) ac_try_echo=$ac_try;;
8193esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008194eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008195 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008196 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008197 grep -v '^ *+' conftest.er1 >conftest.err
8198 rm -f conftest.er1
8199 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008200 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008201 (exit $ac_status); } && {
8202 test -z "$ac_c_werror_flag" ||
8203 test ! -s conftest.err
8204 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008205 ac_hi=$ac_mid
8206else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008207 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008208sed 's/^/| /' conftest.$ac_ext >&5
8209
Martin v. Löwiseba40652007-08-30 20:10:57 +00008210 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008211fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008212
8213rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008214done
8215case $ac_lo in
8216?*) ac_cv_sizeof_long=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00008217'') if test "$ac_cv_type_long" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00008218 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008219See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008220echo "$as_me: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008221See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00008222 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008223 else
8224 ac_cv_sizeof_long=0
8225 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00008226esac
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008227else
Martin v. Löwis11437992002-04-12 09:54:03 +00008228 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008229/* confdefs.h. */
8230_ACEOF
8231cat confdefs.h >>conftest.$ac_ext
8232cat >>conftest.$ac_ext <<_ACEOF
8233/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008234$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008235 typedef long ac__type_sizeof_;
8236static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
8237static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008238#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008239#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008240int
8241main ()
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008242{
Martin v. Löwis11437992002-04-12 09:54:03 +00008243
8244 FILE *f = fopen ("conftest.val", "w");
8245 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00008246 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00008247 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00008248 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008249 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00008250 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008251 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00008252 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008253 }
8254 else
8255 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008256 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00008257 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008258 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00008259 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008260 }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008261 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008262
8263 ;
8264 return 0;
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008265}
Martin v. Löwis11437992002-04-12 09:54:03 +00008266_ACEOF
8267rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008268if { (ac_try="$ac_link"
8269case "(($ac_try" in
8270 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8271 *) ac_try_echo=$ac_try;;
8272esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008273eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008274 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008275 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00008276 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008277 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00008278 { (case "(($ac_try" in
8279 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8280 *) ac_try_echo=$ac_try;;
8281esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008282eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008283 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008284 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00008285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008286 (exit $ac_status); }; }; then
8287 ac_cv_sizeof_long=`cat conftest.val`
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008288else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008289 echo "$as_me: program exited with status $ac_status" >&5
8290echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008291sed 's/^/| /' conftest.$ac_ext >&5
8292
Martin v. Löwis11437992002-04-12 09:54:03 +00008293( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00008294if test "$ac_cv_type_long" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00008295 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008296See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008297echo "$as_me: error: cannot compute sizeof (long)
Skip Montanaro6dead952003-09-25 14:50:04 +00008298See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00008299 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008300 else
8301 ac_cv_sizeof_long=0
8302 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008303fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008304rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008305fi
8306rm -f conftest.val
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008307fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00008308{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
8309echo "${ECHO_T}$ac_cv_sizeof_long" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008310
8311
8312
Martin v. Löwis11437992002-04-12 09:54:03 +00008313cat >>confdefs.h <<_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008314#define SIZEOF_LONG $ac_cv_sizeof_long
Martin v. Löwis11437992002-04-12 09:54:03 +00008315_ACEOF
Guido van Rossumccaf3b61996-12-06 21:19:16 +00008316
8317
Ronald Oussoren450d5612009-06-08 21:12:41 +00008318{ echo "$as_me:$LINENO: checking for void *" >&5
8319echo $ECHO_N "checking for void *... $ECHO_C" >&6; }
8320if test "${ac_cv_type_void_p+set}" = set; then
8321 echo $ECHO_N "(cached) $ECHO_C" >&6
8322else
8323 cat >conftest.$ac_ext <<_ACEOF
8324/* confdefs.h. */
8325_ACEOF
8326cat confdefs.h >>conftest.$ac_ext
8327cat >>conftest.$ac_ext <<_ACEOF
8328/* end confdefs.h. */
8329$ac_includes_default
8330typedef void * ac__type_new_;
8331int
8332main ()
8333{
8334if ((ac__type_new_ *) 0)
8335 return 0;
8336if (sizeof (ac__type_new_))
8337 return 0;
8338 ;
8339 return 0;
8340}
8341_ACEOF
8342rm -f conftest.$ac_objext
8343if { (ac_try="$ac_compile"
8344case "(($ac_try" in
8345 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8346 *) ac_try_echo=$ac_try;;
8347esac
8348eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8349 (eval "$ac_compile") 2>conftest.er1
8350 ac_status=$?
8351 grep -v '^ *+' conftest.er1 >conftest.err
8352 rm -f conftest.er1
8353 cat conftest.err >&5
8354 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8355 (exit $ac_status); } && {
8356 test -z "$ac_c_werror_flag" ||
8357 test ! -s conftest.err
8358 } && test -s conftest.$ac_objext; then
8359 ac_cv_type_void_p=yes
8360else
8361 echo "$as_me: failed program was:" >&5
8362sed 's/^/| /' conftest.$ac_ext >&5
8363
8364 ac_cv_type_void_p=no
8365fi
8366
8367rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8368fi
8369{ echo "$as_me:$LINENO: result: $ac_cv_type_void_p" >&5
8370echo "${ECHO_T}$ac_cv_type_void_p" >&6; }
8371
Martin v. Löwiseba40652007-08-30 20:10:57 +00008372# The cast to long int works around a bug in the HP C Compiler
8373# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8374# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8375# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00008376{ echo "$as_me:$LINENO: checking size of void *" >&5
8377echo $ECHO_N "checking size of void *... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00008378if test "${ac_cv_sizeof_void_p+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00008379 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00008380else
Martin v. Löwis11437992002-04-12 09:54:03 +00008381 if test "$cross_compiling" = yes; then
8382 # Depending upon the size, compute the lo and hi bounds.
8383cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008384/* confdefs.h. */
8385_ACEOF
8386cat confdefs.h >>conftest.$ac_ext
8387cat >>conftest.$ac_ext <<_ACEOF
8388/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008389$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008390 typedef void * ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008391int
8392main ()
8393{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008394static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008395test_array [0] = 0
8396
8397 ;
8398 return 0;
8399}
8400_ACEOF
8401rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008402if { (ac_try="$ac_compile"
8403case "(($ac_try" in
8404 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8405 *) ac_try_echo=$ac_try;;
8406esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008407eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008408 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008409 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008410 grep -v '^ *+' conftest.er1 >conftest.err
8411 rm -f conftest.er1
8412 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008413 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008414 (exit $ac_status); } && {
8415 test -z "$ac_c_werror_flag" ||
8416 test ! -s conftest.err
8417 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008418 ac_lo=0 ac_mid=0
8419 while :; do
8420 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008421/* confdefs.h. */
8422_ACEOF
8423cat confdefs.h >>conftest.$ac_ext
8424cat >>conftest.$ac_ext <<_ACEOF
8425/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008426$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008427 typedef void * ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008428int
8429main ()
8430{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008431static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008432test_array [0] = 0
8433
8434 ;
8435 return 0;
8436}
8437_ACEOF
8438rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008439if { (ac_try="$ac_compile"
8440case "(($ac_try" in
8441 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8442 *) ac_try_echo=$ac_try;;
8443esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008444eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008445 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008446 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008447 grep -v '^ *+' conftest.er1 >conftest.err
8448 rm -f conftest.er1
8449 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008450 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008451 (exit $ac_status); } && {
8452 test -z "$ac_c_werror_flag" ||
8453 test ! -s conftest.err
8454 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008455 ac_hi=$ac_mid; break
8456else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008457 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008458sed 's/^/| /' conftest.$ac_ext >&5
8459
Martin v. Löwiseba40652007-08-30 20:10:57 +00008460 ac_lo=`expr $ac_mid + 1`
8461 if test $ac_lo -le $ac_mid; then
8462 ac_lo= ac_hi=
8463 break
8464 fi
8465 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008466fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008467
8468rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008469 done
8470else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008471 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008472sed 's/^/| /' conftest.$ac_ext >&5
8473
Martin v. Löwiseba40652007-08-30 20:10:57 +00008474 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008475/* confdefs.h. */
8476_ACEOF
8477cat confdefs.h >>conftest.$ac_ext
8478cat >>conftest.$ac_ext <<_ACEOF
8479/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008480$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008481 typedef void * ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008482int
8483main ()
8484{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008485static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008486test_array [0] = 0
8487
8488 ;
8489 return 0;
8490}
8491_ACEOF
8492rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008493if { (ac_try="$ac_compile"
8494case "(($ac_try" in
8495 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8496 *) ac_try_echo=$ac_try;;
8497esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008498eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008499 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008500 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008501 grep -v '^ *+' conftest.er1 >conftest.err
8502 rm -f conftest.er1
8503 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008504 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008505 (exit $ac_status); } && {
8506 test -z "$ac_c_werror_flag" ||
8507 test ! -s conftest.err
8508 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008509 ac_hi=-1 ac_mid=-1
8510 while :; do
8511 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008512/* confdefs.h. */
8513_ACEOF
8514cat confdefs.h >>conftest.$ac_ext
8515cat >>conftest.$ac_ext <<_ACEOF
8516/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008517$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008518 typedef void * ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008519int
8520main ()
8521{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008522static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008523test_array [0] = 0
8524
8525 ;
8526 return 0;
8527}
8528_ACEOF
8529rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008530if { (ac_try="$ac_compile"
8531case "(($ac_try" in
8532 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8533 *) ac_try_echo=$ac_try;;
8534esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008535eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008536 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008537 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008538 grep -v '^ *+' conftest.er1 >conftest.err
8539 rm -f conftest.er1
8540 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008541 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008542 (exit $ac_status); } && {
8543 test -z "$ac_c_werror_flag" ||
8544 test ! -s conftest.err
8545 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008546 ac_lo=$ac_mid; break
8547else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008548 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008549sed 's/^/| /' conftest.$ac_ext >&5
8550
Martin v. Löwiseba40652007-08-30 20:10:57 +00008551 ac_hi=`expr '(' $ac_mid ')' - 1`
8552 if test $ac_mid -le $ac_hi; then
8553 ac_lo= ac_hi=
8554 break
8555 fi
8556 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00008557fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008558
8559rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008560 done
8561else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008562 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008563sed 's/^/| /' conftest.$ac_ext >&5
8564
Martin v. Löwiseba40652007-08-30 20:10:57 +00008565 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00008566fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008567
8568rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008569fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008570
8571rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008572# Binary search between lo and hi bounds.
8573while test "x$ac_lo" != "x$ac_hi"; do
8574 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8575 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008576/* confdefs.h. */
8577_ACEOF
8578cat confdefs.h >>conftest.$ac_ext
8579cat >>conftest.$ac_ext <<_ACEOF
8580/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008581$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008582 typedef void * ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008583int
8584main ()
8585{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008586static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008587test_array [0] = 0
8588
8589 ;
8590 return 0;
8591}
8592_ACEOF
8593rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008594if { (ac_try="$ac_compile"
8595case "(($ac_try" in
8596 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8597 *) ac_try_echo=$ac_try;;
8598esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008599eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008600 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008601 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008602 grep -v '^ *+' conftest.er1 >conftest.err
8603 rm -f conftest.er1
8604 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008605 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008606 (exit $ac_status); } && {
8607 test -z "$ac_c_werror_flag" ||
8608 test ! -s conftest.err
8609 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008610 ac_hi=$ac_mid
8611else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008612 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008613sed 's/^/| /' conftest.$ac_ext >&5
8614
Martin v. Löwiseba40652007-08-30 20:10:57 +00008615 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008616fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008617
8618rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008619done
8620case $ac_lo in
8621?*) ac_cv_sizeof_void_p=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00008622'') if test "$ac_cv_type_void_p" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00008623 { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00008624See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008625echo "$as_me: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00008626See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00008627 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008628 else
8629 ac_cv_sizeof_void_p=0
8630 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00008631esac
Guido van Rossumad678af1998-10-02 14:42:15 +00008632else
Martin v. Löwis11437992002-04-12 09:54:03 +00008633 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008634/* confdefs.h. */
8635_ACEOF
8636cat confdefs.h >>conftest.$ac_ext
8637cat >>conftest.$ac_ext <<_ACEOF
8638/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008639$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008640 typedef void * ac__type_sizeof_;
8641static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
8642static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00008643#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008644#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00008645int
8646main ()
Guido van Rossumad678af1998-10-02 14:42:15 +00008647{
Martin v. Löwis11437992002-04-12 09:54:03 +00008648
8649 FILE *f = fopen ("conftest.val", "w");
8650 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00008651 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00008652 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00008653 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008654 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00008655 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008656 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00008657 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008658 }
8659 else
8660 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00008661 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00008662 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00008663 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00008664 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00008665 }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008666 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00008667
8668 ;
8669 return 0;
Guido van Rossumad678af1998-10-02 14:42:15 +00008670}
Martin v. Löwis11437992002-04-12 09:54:03 +00008671_ACEOF
8672rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008673if { (ac_try="$ac_link"
8674case "(($ac_try" in
8675 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8676 *) ac_try_echo=$ac_try;;
8677esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008678eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008679 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008680 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00008681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008682 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00008683 { (case "(($ac_try" in
8684 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8685 *) ac_try_echo=$ac_try;;
8686esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008687eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008688 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008689 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00008690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00008691 (exit $ac_status); }; }; then
8692 ac_cv_sizeof_void_p=`cat conftest.val`
Guido van Rossumad678af1998-10-02 14:42:15 +00008693else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008694 echo "$as_me: program exited with status $ac_status" >&5
8695echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008696sed 's/^/| /' conftest.$ac_ext >&5
8697
Martin v. Löwis11437992002-04-12 09:54:03 +00008698( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00008699if test "$ac_cv_type_void_p" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00008700 { { echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00008701See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008702echo "$as_me: error: cannot compute sizeof (void *)
Skip Montanaro6dead952003-09-25 14:50:04 +00008703See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00008704 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008705 else
8706 ac_cv_sizeof_void_p=0
8707 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00008708fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008709rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008710fi
8711rm -f conftest.val
Guido van Rossumad678af1998-10-02 14:42:15 +00008712fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00008713{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
8714echo "${ECHO_T}$ac_cv_sizeof_void_p" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00008715
8716
8717
Martin v. Löwis11437992002-04-12 09:54:03 +00008718cat >>confdefs.h <<_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00008719#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
Martin v. Löwis11437992002-04-12 09:54:03 +00008720_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +00008721
8722
Ronald Oussoren450d5612009-06-08 21:12:41 +00008723{ echo "$as_me:$LINENO: checking for short" >&5
8724echo $ECHO_N "checking for short... $ECHO_C" >&6; }
8725if test "${ac_cv_type_short+set}" = set; then
8726 echo $ECHO_N "(cached) $ECHO_C" >&6
8727else
8728 cat >conftest.$ac_ext <<_ACEOF
8729/* confdefs.h. */
8730_ACEOF
8731cat confdefs.h >>conftest.$ac_ext
8732cat >>conftest.$ac_ext <<_ACEOF
8733/* end confdefs.h. */
8734$ac_includes_default
8735typedef short ac__type_new_;
8736int
8737main ()
8738{
8739if ((ac__type_new_ *) 0)
8740 return 0;
8741if (sizeof (ac__type_new_))
8742 return 0;
8743 ;
8744 return 0;
8745}
8746_ACEOF
8747rm -f conftest.$ac_objext
8748if { (ac_try="$ac_compile"
8749case "(($ac_try" in
8750 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8751 *) ac_try_echo=$ac_try;;
8752esac
8753eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8754 (eval "$ac_compile") 2>conftest.er1
8755 ac_status=$?
8756 grep -v '^ *+' conftest.er1 >conftest.err
8757 rm -f conftest.er1
8758 cat conftest.err >&5
8759 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8760 (exit $ac_status); } && {
8761 test -z "$ac_c_werror_flag" ||
8762 test ! -s conftest.err
8763 } && test -s conftest.$ac_objext; then
8764 ac_cv_type_short=yes
8765else
8766 echo "$as_me: failed program was:" >&5
8767sed 's/^/| /' conftest.$ac_ext >&5
8768
8769 ac_cv_type_short=no
8770fi
8771
8772rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8773fi
8774{ echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
8775echo "${ECHO_T}$ac_cv_type_short" >&6; }
8776
Martin v. Löwiseba40652007-08-30 20:10:57 +00008777# The cast to long int works around a bug in the HP C Compiler
8778# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
8779# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
8780# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00008781{ echo "$as_me:$LINENO: checking size of short" >&5
8782echo $ECHO_N "checking size of short... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00008783if test "${ac_cv_sizeof_short+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00008784 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00008785else
Martin v. Löwis11437992002-04-12 09:54:03 +00008786 if test "$cross_compiling" = yes; then
8787 # Depending upon the size, compute the lo and hi bounds.
8788cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008789/* confdefs.h. */
8790_ACEOF
8791cat confdefs.h >>conftest.$ac_ext
8792cat >>conftest.$ac_ext <<_ACEOF
8793/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008794$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008795 typedef short ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008796int
8797main ()
8798{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008799static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008800test_array [0] = 0
8801
8802 ;
8803 return 0;
8804}
8805_ACEOF
8806rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008807if { (ac_try="$ac_compile"
8808case "(($ac_try" in
8809 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8810 *) ac_try_echo=$ac_try;;
8811esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008812eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008813 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008814 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008815 grep -v '^ *+' conftest.er1 >conftest.err
8816 rm -f conftest.er1
8817 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008818 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008819 (exit $ac_status); } && {
8820 test -z "$ac_c_werror_flag" ||
8821 test ! -s conftest.err
8822 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008823 ac_lo=0 ac_mid=0
8824 while :; do
8825 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008826/* confdefs.h. */
8827_ACEOF
8828cat confdefs.h >>conftest.$ac_ext
8829cat >>conftest.$ac_ext <<_ACEOF
8830/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008831$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008832 typedef short ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008833int
8834main ()
8835{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008836static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008837test_array [0] = 0
8838
8839 ;
8840 return 0;
8841}
8842_ACEOF
8843rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008844if { (ac_try="$ac_compile"
8845case "(($ac_try" in
8846 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8847 *) ac_try_echo=$ac_try;;
8848esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008849eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008850 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008851 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008852 grep -v '^ *+' conftest.er1 >conftest.err
8853 rm -f conftest.er1
8854 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008856 (exit $ac_status); } && {
8857 test -z "$ac_c_werror_flag" ||
8858 test ! -s conftest.err
8859 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008860 ac_hi=$ac_mid; break
8861else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008862 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008863sed 's/^/| /' conftest.$ac_ext >&5
8864
Martin v. Löwiseba40652007-08-30 20:10:57 +00008865 ac_lo=`expr $ac_mid + 1`
8866 if test $ac_lo -le $ac_mid; then
8867 ac_lo= ac_hi=
8868 break
8869 fi
8870 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00008871fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008872
8873rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008874 done
8875else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008876 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008877sed 's/^/| /' conftest.$ac_ext >&5
8878
Martin v. Löwiseba40652007-08-30 20:10:57 +00008879 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008880/* confdefs.h. */
8881_ACEOF
8882cat confdefs.h >>conftest.$ac_ext
8883cat >>conftest.$ac_ext <<_ACEOF
8884/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008885$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008886 typedef short ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008887int
8888main ()
8889{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008890static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008891test_array [0] = 0
8892
8893 ;
8894 return 0;
8895}
8896_ACEOF
8897rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008898if { (ac_try="$ac_compile"
8899case "(($ac_try" in
8900 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8901 *) ac_try_echo=$ac_try;;
8902esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008903eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008904 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008905 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008906 grep -v '^ *+' conftest.er1 >conftest.err
8907 rm -f conftest.er1
8908 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008909 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008910 (exit $ac_status); } && {
8911 test -z "$ac_c_werror_flag" ||
8912 test ! -s conftest.err
8913 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008914 ac_hi=-1 ac_mid=-1
8915 while :; do
8916 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008917/* confdefs.h. */
8918_ACEOF
8919cat confdefs.h >>conftest.$ac_ext
8920cat >>conftest.$ac_ext <<_ACEOF
8921/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008922$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008923 typedef short ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008924int
8925main ()
8926{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008927static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008928test_array [0] = 0
8929
8930 ;
8931 return 0;
8932}
8933_ACEOF
8934rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008935if { (ac_try="$ac_compile"
8936case "(($ac_try" in
8937 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8938 *) ac_try_echo=$ac_try;;
8939esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00008940eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008941 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00008942 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00008943 grep -v '^ *+' conftest.er1 >conftest.err
8944 rm -f conftest.er1
8945 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00008946 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00008947 (exit $ac_status); } && {
8948 test -z "$ac_c_werror_flag" ||
8949 test ! -s conftest.err
8950 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00008951 ac_lo=$ac_mid; break
8952else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008953 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008954sed 's/^/| /' conftest.$ac_ext >&5
8955
Martin v. Löwiseba40652007-08-30 20:10:57 +00008956 ac_hi=`expr '(' $ac_mid ')' - 1`
8957 if test $ac_mid -le $ac_hi; then
8958 ac_lo= ac_hi=
8959 break
8960 fi
8961 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00008962fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008963
8964rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008965 done
8966else
Ronald Oussoren450d5612009-06-08 21:12:41 +00008967 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00008968sed 's/^/| /' conftest.$ac_ext >&5
8969
Martin v. Löwiseba40652007-08-30 20:10:57 +00008970 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00008971fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008972
8973rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008974fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00008975
8976rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00008977# Binary search between lo and hi bounds.
8978while test "x$ac_lo" != "x$ac_hi"; do
8979 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
8980 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00008981/* confdefs.h. */
8982_ACEOF
8983cat confdefs.h >>conftest.$ac_ext
8984cat >>conftest.$ac_ext <<_ACEOF
8985/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00008986$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00008987 typedef short ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00008988int
8989main ()
8990{
Ronald Oussoren450d5612009-06-08 21:12:41 +00008991static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00008992test_array [0] = 0
8993
8994 ;
8995 return 0;
8996}
8997_ACEOF
8998rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00008999if { (ac_try="$ac_compile"
9000case "(($ac_try" in
9001 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9002 *) ac_try_echo=$ac_try;;
9003esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009004eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009005 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009006 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009007 grep -v '^ *+' conftest.er1 >conftest.err
9008 rm -f conftest.er1
9009 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009011 (exit $ac_status); } && {
9012 test -z "$ac_c_werror_flag" ||
9013 test ! -s conftest.err
9014 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009015 ac_hi=$ac_mid
9016else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009017 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009018sed 's/^/| /' conftest.$ac_ext >&5
9019
Martin v. Löwiseba40652007-08-30 20:10:57 +00009020 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009021fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009022
9023rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009024done
9025case $ac_lo in
9026?*) ac_cv_sizeof_short=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00009027'') if test "$ac_cv_type_short" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009028 { { echo "$as_me:$LINENO: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009029See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009030echo "$as_me: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009031See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00009032 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009033 else
9034 ac_cv_sizeof_short=0
9035 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00009036esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00009037else
Martin v. Löwis11437992002-04-12 09:54:03 +00009038 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009039/* confdefs.h. */
9040_ACEOF
9041cat confdefs.h >>conftest.$ac_ext
9042cat >>conftest.$ac_ext <<_ACEOF
9043/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009044$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009045 typedef short ac__type_sizeof_;
9046static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
9047static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009048#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009049#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009050int
9051main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00009052{
Martin v. Löwis11437992002-04-12 09:54:03 +00009053
9054 FILE *f = fopen ("conftest.val", "w");
9055 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00009056 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009057 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00009058 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009059 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00009060 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009061 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009062 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009063 }
9064 else
9065 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009066 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00009067 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009068 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009069 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009070 }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009071 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009072
9073 ;
9074 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00009075}
Martin v. Löwis11437992002-04-12 09:54:03 +00009076_ACEOF
9077rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009078if { (ac_try="$ac_link"
9079case "(($ac_try" in
9080 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9081 *) ac_try_echo=$ac_try;;
9082esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009083eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009084 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009085 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00009086 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009087 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00009088 { (case "(($ac_try" in
9089 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9090 *) ac_try_echo=$ac_try;;
9091esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009092eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009093 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009094 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00009095 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009096 (exit $ac_status); }; }; then
9097 ac_cv_sizeof_short=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00009098else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009099 echo "$as_me: program exited with status $ac_status" >&5
9100echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009101sed 's/^/| /' conftest.$ac_ext >&5
9102
Martin v. Löwis11437992002-04-12 09:54:03 +00009103( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00009104if test "$ac_cv_type_short" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009105 { { echo "$as_me:$LINENO: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009106See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009107echo "$as_me: error: cannot compute sizeof (short)
Skip Montanaro6dead952003-09-25 14:50:04 +00009108See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00009109 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009110 else
9111 ac_cv_sizeof_short=0
9112 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009113fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009114rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009115fi
9116rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +00009117fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00009118{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_short" >&5
9119echo "${ECHO_T}$ac_cv_sizeof_short" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009120
9121
9122
Martin v. Löwis11437992002-04-12 09:54:03 +00009123cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009124#define SIZEOF_SHORT $ac_cv_sizeof_short
Martin v. Löwis11437992002-04-12 09:54:03 +00009125_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009126
9127
Ronald Oussoren450d5612009-06-08 21:12:41 +00009128{ echo "$as_me:$LINENO: checking for float" >&5
9129echo $ECHO_N "checking for float... $ECHO_C" >&6; }
9130if test "${ac_cv_type_float+set}" = set; then
9131 echo $ECHO_N "(cached) $ECHO_C" >&6
9132else
9133 cat >conftest.$ac_ext <<_ACEOF
9134/* confdefs.h. */
9135_ACEOF
9136cat confdefs.h >>conftest.$ac_ext
9137cat >>conftest.$ac_ext <<_ACEOF
9138/* end confdefs.h. */
9139$ac_includes_default
9140typedef float ac__type_new_;
9141int
9142main ()
9143{
9144if ((ac__type_new_ *) 0)
9145 return 0;
9146if (sizeof (ac__type_new_))
9147 return 0;
9148 ;
9149 return 0;
9150}
9151_ACEOF
9152rm -f conftest.$ac_objext
9153if { (ac_try="$ac_compile"
9154case "(($ac_try" in
9155 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9156 *) ac_try_echo=$ac_try;;
9157esac
9158eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9159 (eval "$ac_compile") 2>conftest.er1
9160 ac_status=$?
9161 grep -v '^ *+' conftest.er1 >conftest.err
9162 rm -f conftest.er1
9163 cat conftest.err >&5
9164 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9165 (exit $ac_status); } && {
9166 test -z "$ac_c_werror_flag" ||
9167 test ! -s conftest.err
9168 } && test -s conftest.$ac_objext; then
9169 ac_cv_type_float=yes
9170else
9171 echo "$as_me: failed program was:" >&5
9172sed 's/^/| /' conftest.$ac_ext >&5
9173
9174 ac_cv_type_float=no
9175fi
9176
9177rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9178fi
9179{ echo "$as_me:$LINENO: result: $ac_cv_type_float" >&5
9180echo "${ECHO_T}$ac_cv_type_float" >&6; }
9181
Martin v. Löwiseba40652007-08-30 20:10:57 +00009182# The cast to long int works around a bug in the HP C Compiler
9183# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9184# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9185# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00009186{ echo "$as_me:$LINENO: checking size of float" >&5
9187echo $ECHO_N "checking size of float... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00009188if test "${ac_cv_sizeof_float+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009189 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00009190else
Martin v. Löwis11437992002-04-12 09:54:03 +00009191 if test "$cross_compiling" = yes; then
9192 # Depending upon the size, compute the lo and hi bounds.
9193cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009194/* confdefs.h. */
9195_ACEOF
9196cat confdefs.h >>conftest.$ac_ext
9197cat >>conftest.$ac_ext <<_ACEOF
9198/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009199$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009200 typedef float ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009201int
9202main ()
9203{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009204static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009205test_array [0] = 0
9206
9207 ;
9208 return 0;
9209}
9210_ACEOF
9211rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009212if { (ac_try="$ac_compile"
9213case "(($ac_try" in
9214 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9215 *) ac_try_echo=$ac_try;;
9216esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009217eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009218 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009219 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009220 grep -v '^ *+' conftest.er1 >conftest.err
9221 rm -f conftest.er1
9222 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009223 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009224 (exit $ac_status); } && {
9225 test -z "$ac_c_werror_flag" ||
9226 test ! -s conftest.err
9227 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009228 ac_lo=0 ac_mid=0
9229 while :; do
9230 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009231/* confdefs.h. */
9232_ACEOF
9233cat confdefs.h >>conftest.$ac_ext
9234cat >>conftest.$ac_ext <<_ACEOF
9235/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009236$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009237 typedef float ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009238int
9239main ()
9240{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009241static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009242test_array [0] = 0
9243
9244 ;
9245 return 0;
9246}
9247_ACEOF
9248rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009249if { (ac_try="$ac_compile"
9250case "(($ac_try" in
9251 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9252 *) ac_try_echo=$ac_try;;
9253esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009254eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009255 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009256 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009257 grep -v '^ *+' conftest.er1 >conftest.err
9258 rm -f conftest.er1
9259 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009261 (exit $ac_status); } && {
9262 test -z "$ac_c_werror_flag" ||
9263 test ! -s conftest.err
9264 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009265 ac_hi=$ac_mid; break
9266else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009267 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009268sed 's/^/| /' conftest.$ac_ext >&5
9269
Martin v. Löwiseba40652007-08-30 20:10:57 +00009270 ac_lo=`expr $ac_mid + 1`
9271 if test $ac_lo -le $ac_mid; then
9272 ac_lo= ac_hi=
9273 break
9274 fi
9275 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009276fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009277
9278rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009279 done
9280else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009281 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009282sed 's/^/| /' conftest.$ac_ext >&5
9283
Martin v. Löwiseba40652007-08-30 20:10:57 +00009284 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009285/* confdefs.h. */
9286_ACEOF
9287cat confdefs.h >>conftest.$ac_ext
9288cat >>conftest.$ac_ext <<_ACEOF
9289/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009290$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009291 typedef float ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009292int
9293main ()
9294{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009295static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009296test_array [0] = 0
9297
9298 ;
9299 return 0;
9300}
9301_ACEOF
9302rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009303if { (ac_try="$ac_compile"
9304case "(($ac_try" in
9305 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9306 *) ac_try_echo=$ac_try;;
9307esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009308eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009309 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009310 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009311 grep -v '^ *+' conftest.er1 >conftest.err
9312 rm -f conftest.er1
9313 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009314 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009315 (exit $ac_status); } && {
9316 test -z "$ac_c_werror_flag" ||
9317 test ! -s conftest.err
9318 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009319 ac_hi=-1 ac_mid=-1
9320 while :; do
9321 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009322/* confdefs.h. */
9323_ACEOF
9324cat confdefs.h >>conftest.$ac_ext
9325cat >>conftest.$ac_ext <<_ACEOF
9326/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009327$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009328 typedef float ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009329int
9330main ()
9331{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009332static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009333test_array [0] = 0
9334
9335 ;
9336 return 0;
9337}
9338_ACEOF
9339rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009340if { (ac_try="$ac_compile"
9341case "(($ac_try" in
9342 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9343 *) ac_try_echo=$ac_try;;
9344esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009345eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009346 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009347 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009348 grep -v '^ *+' conftest.er1 >conftest.err
9349 rm -f conftest.er1
9350 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009351 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009352 (exit $ac_status); } && {
9353 test -z "$ac_c_werror_flag" ||
9354 test ! -s conftest.err
9355 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009356 ac_lo=$ac_mid; break
9357else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009358 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009359sed 's/^/| /' conftest.$ac_ext >&5
9360
Martin v. Löwiseba40652007-08-30 20:10:57 +00009361 ac_hi=`expr '(' $ac_mid ')' - 1`
9362 if test $ac_mid -le $ac_hi; then
9363 ac_lo= ac_hi=
9364 break
9365 fi
9366 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00009367fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009368
9369rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009370 done
9371else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009372 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009373sed 's/^/| /' conftest.$ac_ext >&5
9374
Martin v. Löwiseba40652007-08-30 20:10:57 +00009375 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00009376fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009377
9378rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009379fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009380
9381rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009382# Binary search between lo and hi bounds.
9383while test "x$ac_lo" != "x$ac_hi"; do
9384 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9385 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009386/* confdefs.h. */
9387_ACEOF
9388cat confdefs.h >>conftest.$ac_ext
9389cat >>conftest.$ac_ext <<_ACEOF
9390/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009391$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009392 typedef float ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009393int
9394main ()
9395{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009396static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009397test_array [0] = 0
9398
9399 ;
9400 return 0;
9401}
9402_ACEOF
9403rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009404if { (ac_try="$ac_compile"
9405case "(($ac_try" in
9406 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9407 *) ac_try_echo=$ac_try;;
9408esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009409eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009410 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009411 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009412 grep -v '^ *+' conftest.er1 >conftest.err
9413 rm -f conftest.er1
9414 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009415 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009416 (exit $ac_status); } && {
9417 test -z "$ac_c_werror_flag" ||
9418 test ! -s conftest.err
9419 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009420 ac_hi=$ac_mid
9421else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009422 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009423sed 's/^/| /' conftest.$ac_ext >&5
9424
Martin v. Löwiseba40652007-08-30 20:10:57 +00009425 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009426fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009427
9428rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009429done
9430case $ac_lo in
9431?*) ac_cv_sizeof_float=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00009432'') if test "$ac_cv_type_float" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009433 { { echo "$as_me:$LINENO: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +00009434See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009435echo "$as_me: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +00009436See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00009437 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009438 else
9439 ac_cv_sizeof_float=0
9440 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00009441esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00009442else
Martin v. Löwis11437992002-04-12 09:54:03 +00009443 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009444/* confdefs.h. */
9445_ACEOF
9446cat confdefs.h >>conftest.$ac_ext
9447cat >>conftest.$ac_ext <<_ACEOF
9448/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009449$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009450 typedef float ac__type_sizeof_;
9451static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
9452static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009453#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009454#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009455int
9456main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00009457{
Martin v. Löwis11437992002-04-12 09:54:03 +00009458
9459 FILE *f = fopen ("conftest.val", "w");
9460 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00009461 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009462 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00009463 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009464 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00009465 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009466 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009467 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009468 }
9469 else
9470 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009471 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00009472 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009473 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009474 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009475 }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009476 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009477
9478 ;
9479 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00009480}
Martin v. Löwis11437992002-04-12 09:54:03 +00009481_ACEOF
9482rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009483if { (ac_try="$ac_link"
9484case "(($ac_try" in
9485 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9486 *) ac_try_echo=$ac_try;;
9487esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009488eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009489 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009490 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00009491 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009492 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00009493 { (case "(($ac_try" in
9494 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9495 *) ac_try_echo=$ac_try;;
9496esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009497eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009498 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009499 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00009500 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009501 (exit $ac_status); }; }; then
9502 ac_cv_sizeof_float=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00009503else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009504 echo "$as_me: program exited with status $ac_status" >&5
9505echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009506sed 's/^/| /' conftest.$ac_ext >&5
9507
Martin v. Löwis11437992002-04-12 09:54:03 +00009508( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00009509if test "$ac_cv_type_float" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009510 { { echo "$as_me:$LINENO: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +00009511See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009512echo "$as_me: error: cannot compute sizeof (float)
Skip Montanaro6dead952003-09-25 14:50:04 +00009513See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00009514 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009515 else
9516 ac_cv_sizeof_float=0
9517 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009518fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009519rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009520fi
9521rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +00009522fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00009523{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_float" >&5
9524echo "${ECHO_T}$ac_cv_sizeof_float" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009525
9526
9527
Martin v. Löwis11437992002-04-12 09:54:03 +00009528cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009529#define SIZEOF_FLOAT $ac_cv_sizeof_float
Martin v. Löwis11437992002-04-12 09:54:03 +00009530_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009531
9532
Ronald Oussoren450d5612009-06-08 21:12:41 +00009533{ echo "$as_me:$LINENO: checking for double" >&5
9534echo $ECHO_N "checking for double... $ECHO_C" >&6; }
9535if test "${ac_cv_type_double+set}" = set; then
9536 echo $ECHO_N "(cached) $ECHO_C" >&6
9537else
9538 cat >conftest.$ac_ext <<_ACEOF
9539/* confdefs.h. */
9540_ACEOF
9541cat confdefs.h >>conftest.$ac_ext
9542cat >>conftest.$ac_ext <<_ACEOF
9543/* end confdefs.h. */
9544$ac_includes_default
9545typedef double ac__type_new_;
9546int
9547main ()
9548{
9549if ((ac__type_new_ *) 0)
9550 return 0;
9551if (sizeof (ac__type_new_))
9552 return 0;
9553 ;
9554 return 0;
9555}
9556_ACEOF
9557rm -f conftest.$ac_objext
9558if { (ac_try="$ac_compile"
9559case "(($ac_try" in
9560 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9561 *) ac_try_echo=$ac_try;;
9562esac
9563eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9564 (eval "$ac_compile") 2>conftest.er1
9565 ac_status=$?
9566 grep -v '^ *+' conftest.er1 >conftest.err
9567 rm -f conftest.er1
9568 cat conftest.err >&5
9569 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9570 (exit $ac_status); } && {
9571 test -z "$ac_c_werror_flag" ||
9572 test ! -s conftest.err
9573 } && test -s conftest.$ac_objext; then
9574 ac_cv_type_double=yes
9575else
9576 echo "$as_me: failed program was:" >&5
9577sed 's/^/| /' conftest.$ac_ext >&5
9578
9579 ac_cv_type_double=no
9580fi
9581
9582rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9583fi
9584{ echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
9585echo "${ECHO_T}$ac_cv_type_double" >&6; }
9586
Martin v. Löwiseba40652007-08-30 20:10:57 +00009587# The cast to long int works around a bug in the HP C Compiler
9588# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9589# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9590# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00009591{ echo "$as_me:$LINENO: checking size of double" >&5
9592echo $ECHO_N "checking size of double... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00009593if test "${ac_cv_sizeof_double+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009594 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +00009595else
Martin v. Löwis11437992002-04-12 09:54:03 +00009596 if test "$cross_compiling" = yes; then
9597 # Depending upon the size, compute the lo and hi bounds.
9598cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009599/* confdefs.h. */
9600_ACEOF
9601cat confdefs.h >>conftest.$ac_ext
9602cat >>conftest.$ac_ext <<_ACEOF
9603/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009604$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009605 typedef double ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009606int
9607main ()
9608{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009609static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009610test_array [0] = 0
9611
9612 ;
9613 return 0;
9614}
9615_ACEOF
9616rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009617if { (ac_try="$ac_compile"
9618case "(($ac_try" in
9619 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9620 *) ac_try_echo=$ac_try;;
9621esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009622eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009623 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009624 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009625 grep -v '^ *+' conftest.er1 >conftest.err
9626 rm -f conftest.er1
9627 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009629 (exit $ac_status); } && {
9630 test -z "$ac_c_werror_flag" ||
9631 test ! -s conftest.err
9632 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009633 ac_lo=0 ac_mid=0
9634 while :; do
9635 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009636/* confdefs.h. */
9637_ACEOF
9638cat confdefs.h >>conftest.$ac_ext
9639cat >>conftest.$ac_ext <<_ACEOF
9640/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009641$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009642 typedef double ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009643int
9644main ()
9645{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009646static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009647test_array [0] = 0
9648
9649 ;
9650 return 0;
9651}
9652_ACEOF
9653rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009654if { (ac_try="$ac_compile"
9655case "(($ac_try" in
9656 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9657 *) ac_try_echo=$ac_try;;
9658esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009659eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009660 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009661 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009662 grep -v '^ *+' conftest.er1 >conftest.err
9663 rm -f conftest.er1
9664 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009665 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009666 (exit $ac_status); } && {
9667 test -z "$ac_c_werror_flag" ||
9668 test ! -s conftest.err
9669 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009670 ac_hi=$ac_mid; break
9671else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009672 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009673sed 's/^/| /' conftest.$ac_ext >&5
9674
Martin v. Löwiseba40652007-08-30 20:10:57 +00009675 ac_lo=`expr $ac_mid + 1`
9676 if test $ac_lo -le $ac_mid; then
9677 ac_lo= ac_hi=
9678 break
9679 fi
9680 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009681fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009682
9683rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009684 done
9685else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009686 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009687sed 's/^/| /' conftest.$ac_ext >&5
9688
Martin v. Löwiseba40652007-08-30 20:10:57 +00009689 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009690/* confdefs.h. */
9691_ACEOF
9692cat confdefs.h >>conftest.$ac_ext
9693cat >>conftest.$ac_ext <<_ACEOF
9694/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009695$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009696 typedef double ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009697int
9698main ()
9699{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009700static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009701test_array [0] = 0
9702
9703 ;
9704 return 0;
9705}
9706_ACEOF
9707rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009708if { (ac_try="$ac_compile"
9709case "(($ac_try" in
9710 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9711 *) ac_try_echo=$ac_try;;
9712esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009713eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009714 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009715 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009716 grep -v '^ *+' conftest.er1 >conftest.err
9717 rm -f conftest.er1
9718 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009719 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009720 (exit $ac_status); } && {
9721 test -z "$ac_c_werror_flag" ||
9722 test ! -s conftest.err
9723 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009724 ac_hi=-1 ac_mid=-1
9725 while :; do
9726 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009727/* confdefs.h. */
9728_ACEOF
9729cat confdefs.h >>conftest.$ac_ext
9730cat >>conftest.$ac_ext <<_ACEOF
9731/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009732$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009733 typedef double ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009734int
9735main ()
9736{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009737static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009738test_array [0] = 0
9739
9740 ;
9741 return 0;
9742}
9743_ACEOF
9744rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009745if { (ac_try="$ac_compile"
9746case "(($ac_try" in
9747 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9748 *) ac_try_echo=$ac_try;;
9749esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009750eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009751 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009752 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009753 grep -v '^ *+' conftest.er1 >conftest.err
9754 rm -f conftest.er1
9755 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009756 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009757 (exit $ac_status); } && {
9758 test -z "$ac_c_werror_flag" ||
9759 test ! -s conftest.err
9760 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009761 ac_lo=$ac_mid; break
9762else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009763 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009764sed 's/^/| /' conftest.$ac_ext >&5
9765
Martin v. Löwiseba40652007-08-30 20:10:57 +00009766 ac_hi=`expr '(' $ac_mid ')' - 1`
9767 if test $ac_mid -le $ac_hi; then
9768 ac_lo= ac_hi=
9769 break
9770 fi
9771 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +00009772fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009773
9774rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009775 done
9776else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009777 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009778sed 's/^/| /' conftest.$ac_ext >&5
9779
Martin v. Löwiseba40652007-08-30 20:10:57 +00009780 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +00009781fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009782
9783rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009784fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009785
9786rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009787# Binary search between lo and hi bounds.
9788while test "x$ac_lo" != "x$ac_hi"; do
9789 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
9790 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009791/* confdefs.h. */
9792_ACEOF
9793cat confdefs.h >>conftest.$ac_ext
9794cat >>conftest.$ac_ext <<_ACEOF
9795/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009796$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009797 typedef double ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +00009798int
9799main ()
9800{
Ronald Oussoren450d5612009-06-08 21:12:41 +00009801static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +00009802test_array [0] = 0
9803
9804 ;
9805 return 0;
9806}
9807_ACEOF
9808rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009809if { (ac_try="$ac_compile"
9810case "(($ac_try" in
9811 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9812 *) ac_try_echo=$ac_try;;
9813esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009814eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009815 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +00009816 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +00009817 grep -v '^ *+' conftest.er1 >conftest.err
9818 rm -f conftest.er1
9819 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009820 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009821 (exit $ac_status); } && {
9822 test -z "$ac_c_werror_flag" ||
9823 test ! -s conftest.err
9824 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +00009825 ac_hi=$ac_mid
9826else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009827 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009828sed 's/^/| /' conftest.$ac_ext >&5
9829
Martin v. Löwiseba40652007-08-30 20:10:57 +00009830 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +00009831fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009832
9833rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009834done
9835case $ac_lo in
9836?*) ac_cv_sizeof_double=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +00009837'') if test "$ac_cv_type_double" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009838 { { echo "$as_me:$LINENO: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +00009839See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009840echo "$as_me: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +00009841See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00009842 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009843 else
9844 ac_cv_sizeof_double=0
9845 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +00009846esac
Guido van Rossumef2255b2000-03-10 22:30:29 +00009847else
Martin v. Löwis11437992002-04-12 09:54:03 +00009848 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +00009849/* confdefs.h. */
9850_ACEOF
9851cat confdefs.h >>conftest.$ac_ext
9852cat >>conftest.$ac_ext <<_ACEOF
9853/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +00009854$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +00009855 typedef double ac__type_sizeof_;
9856static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
9857static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +00009858#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009859#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +00009860int
9861main ()
Guido van Rossumef2255b2000-03-10 22:30:29 +00009862{
Martin v. Löwis11437992002-04-12 09:54:03 +00009863
9864 FILE *f = fopen ("conftest.val", "w");
9865 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +00009866 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009867 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +00009868 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009869 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00009870 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009871 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009872 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009873 }
9874 else
9875 {
Martin v. Löwiseba40652007-08-30 20:10:57 +00009876 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +00009877 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +00009878 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +00009879 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +00009880 }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009881 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +00009882
9883 ;
9884 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +00009885}
Martin v. Löwis11437992002-04-12 09:54:03 +00009886_ACEOF
9887rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +00009888if { (ac_try="$ac_link"
9889case "(($ac_try" in
9890 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9891 *) ac_try_echo=$ac_try;;
9892esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009893eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009894 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009895 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00009896 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009897 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +00009898 { (case "(($ac_try" in
9899 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9900 *) ac_try_echo=$ac_try;;
9901esac
Ronald Oussoren450d5612009-06-08 21:12:41 +00009902eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +00009903 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009904 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +00009905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +00009906 (exit $ac_status); }; }; then
9907 ac_cv_sizeof_double=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +00009908else
Ronald Oussoren450d5612009-06-08 21:12:41 +00009909 echo "$as_me: program exited with status $ac_status" >&5
9910echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +00009911sed 's/^/| /' conftest.$ac_ext >&5
9912
Martin v. Löwis11437992002-04-12 09:54:03 +00009913( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +00009914if test "$ac_cv_type_double" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009915 { { echo "$as_me:$LINENO: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +00009916See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +00009917echo "$as_me: error: cannot compute sizeof (double)
Skip Montanaro6dead952003-09-25 14:50:04 +00009918See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +00009919 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009920 else
9921 ac_cv_sizeof_double=0
9922 fi
Martin v. Löwis11437992002-04-12 09:54:03 +00009923fi
Martin v. Löwiseba40652007-08-30 20:10:57 +00009924rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +00009925fi
9926rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +00009927fi
Ronald Oussoren450d5612009-06-08 21:12:41 +00009928{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_double" >&5
9929echo "${ECHO_T}$ac_cv_sizeof_double" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +00009930
9931
9932
Martin v. Löwis11437992002-04-12 09:54:03 +00009933cat >>confdefs.h <<_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009934#define SIZEOF_DOUBLE $ac_cv_sizeof_double
Martin v. Löwis11437992002-04-12 09:54:03 +00009935_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +00009936
9937
Ronald Oussoren450d5612009-06-08 21:12:41 +00009938{ echo "$as_me:$LINENO: checking for fpos_t" >&5
9939echo $ECHO_N "checking for fpos_t... $ECHO_C" >&6; }
9940if test "${ac_cv_type_fpos_t+set}" = set; then
9941 echo $ECHO_N "(cached) $ECHO_C" >&6
9942else
9943 cat >conftest.$ac_ext <<_ACEOF
9944/* confdefs.h. */
9945_ACEOF
9946cat confdefs.h >>conftest.$ac_ext
9947cat >>conftest.$ac_ext <<_ACEOF
9948/* end confdefs.h. */
9949$ac_includes_default
9950typedef fpos_t ac__type_new_;
9951int
9952main ()
9953{
9954if ((ac__type_new_ *) 0)
9955 return 0;
9956if (sizeof (ac__type_new_))
9957 return 0;
9958 ;
9959 return 0;
9960}
9961_ACEOF
9962rm -f conftest.$ac_objext
9963if { (ac_try="$ac_compile"
9964case "(($ac_try" in
9965 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9966 *) ac_try_echo=$ac_try;;
9967esac
9968eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9969 (eval "$ac_compile") 2>conftest.er1
9970 ac_status=$?
9971 grep -v '^ *+' conftest.er1 >conftest.err
9972 rm -f conftest.er1
9973 cat conftest.err >&5
9974 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9975 (exit $ac_status); } && {
9976 test -z "$ac_c_werror_flag" ||
9977 test ! -s conftest.err
9978 } && test -s conftest.$ac_objext; then
9979 ac_cv_type_fpos_t=yes
9980else
9981 echo "$as_me: failed program was:" >&5
9982sed 's/^/| /' conftest.$ac_ext >&5
9983
9984 ac_cv_type_fpos_t=no
9985fi
9986
9987rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9988fi
9989{ echo "$as_me:$LINENO: result: $ac_cv_type_fpos_t" >&5
9990echo "${ECHO_T}$ac_cv_type_fpos_t" >&6; }
9991
Martin v. Löwiseba40652007-08-30 20:10:57 +00009992# The cast to long int works around a bug in the HP C Compiler
9993# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9994# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9995# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +00009996{ echo "$as_me:$LINENO: checking size of fpos_t" >&5
9997echo $ECHO_N "checking size of fpos_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +00009998if test "${ac_cv_sizeof_fpos_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +00009999 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000010000else
Martin v. Löwis11437992002-04-12 09:54:03 +000010001 if test "$cross_compiling" = yes; then
10002 # Depending upon the size, compute the lo and hi bounds.
10003cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010004/* confdefs.h. */
10005_ACEOF
10006cat confdefs.h >>conftest.$ac_ext
10007cat >>conftest.$ac_ext <<_ACEOF
10008/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010009$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010010 typedef fpos_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000010011int
10012main ()
10013{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010014static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010015test_array [0] = 0
10016
10017 ;
10018 return 0;
10019}
10020_ACEOF
10021rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010022if { (ac_try="$ac_compile"
10023case "(($ac_try" in
10024 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10025 *) ac_try_echo=$ac_try;;
10026esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010027eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010028 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010029 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010030 grep -v '^ *+' conftest.er1 >conftest.err
10031 rm -f conftest.er1
10032 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010034 (exit $ac_status); } && {
10035 test -z "$ac_c_werror_flag" ||
10036 test ! -s conftest.err
10037 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010038 ac_lo=0 ac_mid=0
10039 while :; do
10040 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010041/* confdefs.h. */
10042_ACEOF
10043cat confdefs.h >>conftest.$ac_ext
10044cat >>conftest.$ac_ext <<_ACEOF
10045/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010046$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010047 typedef fpos_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000010048int
10049main ()
10050{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010051static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010052test_array [0] = 0
10053
10054 ;
10055 return 0;
10056}
10057_ACEOF
10058rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010059if { (ac_try="$ac_compile"
10060case "(($ac_try" in
10061 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10062 *) ac_try_echo=$ac_try;;
10063esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010064eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010065 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010066 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010067 grep -v '^ *+' conftest.er1 >conftest.err
10068 rm -f conftest.er1
10069 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010070 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010071 (exit $ac_status); } && {
10072 test -z "$ac_c_werror_flag" ||
10073 test ! -s conftest.err
10074 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010075 ac_hi=$ac_mid; break
10076else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010077 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010078sed 's/^/| /' conftest.$ac_ext >&5
10079
Martin v. Löwiseba40652007-08-30 20:10:57 +000010080 ac_lo=`expr $ac_mid + 1`
10081 if test $ac_lo -le $ac_mid; then
10082 ac_lo= ac_hi=
10083 break
10084 fi
10085 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000010086fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010087
10088rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010089 done
10090else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010091 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010092sed 's/^/| /' conftest.$ac_ext >&5
10093
Martin v. Löwiseba40652007-08-30 20:10:57 +000010094 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010095/* confdefs.h. */
10096_ACEOF
10097cat confdefs.h >>conftest.$ac_ext
10098cat >>conftest.$ac_ext <<_ACEOF
10099/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010100$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010101 typedef fpos_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000010102int
10103main ()
10104{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010105static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010106test_array [0] = 0
10107
10108 ;
10109 return 0;
10110}
10111_ACEOF
10112rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010113if { (ac_try="$ac_compile"
10114case "(($ac_try" in
10115 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10116 *) ac_try_echo=$ac_try;;
10117esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010118eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010119 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010120 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010121 grep -v '^ *+' conftest.er1 >conftest.err
10122 rm -f conftest.er1
10123 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010124 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010125 (exit $ac_status); } && {
10126 test -z "$ac_c_werror_flag" ||
10127 test ! -s conftest.err
10128 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010129 ac_hi=-1 ac_mid=-1
10130 while :; do
10131 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010132/* confdefs.h. */
10133_ACEOF
10134cat confdefs.h >>conftest.$ac_ext
10135cat >>conftest.$ac_ext <<_ACEOF
10136/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010137$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010138 typedef fpos_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000010139int
10140main ()
10141{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010142static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010143test_array [0] = 0
10144
10145 ;
10146 return 0;
10147}
10148_ACEOF
10149rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010150if { (ac_try="$ac_compile"
10151case "(($ac_try" in
10152 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10153 *) ac_try_echo=$ac_try;;
10154esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010155eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010156 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010157 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010158 grep -v '^ *+' conftest.er1 >conftest.err
10159 rm -f conftest.er1
10160 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010161 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010162 (exit $ac_status); } && {
10163 test -z "$ac_c_werror_flag" ||
10164 test ! -s conftest.err
10165 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010166 ac_lo=$ac_mid; break
10167else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010168 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010169sed 's/^/| /' conftest.$ac_ext >&5
10170
Martin v. Löwiseba40652007-08-30 20:10:57 +000010171 ac_hi=`expr '(' $ac_mid ')' - 1`
10172 if test $ac_mid -le $ac_hi; then
10173 ac_lo= ac_hi=
10174 break
10175 fi
10176 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000010177fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010178
10179rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010180 done
10181else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010182 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010183sed 's/^/| /' conftest.$ac_ext >&5
10184
Martin v. Löwiseba40652007-08-30 20:10:57 +000010185 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000010186fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010187
10188rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010189fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010190
10191rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010192# Binary search between lo and hi bounds.
10193while test "x$ac_lo" != "x$ac_hi"; do
10194 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
10195 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010196/* confdefs.h. */
10197_ACEOF
10198cat confdefs.h >>conftest.$ac_ext
10199cat >>conftest.$ac_ext <<_ACEOF
10200/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010201$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010202 typedef fpos_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000010203int
10204main ()
10205{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010206static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000010207test_array [0] = 0
10208
10209 ;
10210 return 0;
10211}
10212_ACEOF
10213rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010214if { (ac_try="$ac_compile"
10215case "(($ac_try" in
10216 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10217 *) ac_try_echo=$ac_try;;
10218esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010219eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010220 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000010221 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000010222 grep -v '^ *+' conftest.er1 >conftest.err
10223 rm -f conftest.er1
10224 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010226 (exit $ac_status); } && {
10227 test -z "$ac_c_werror_flag" ||
10228 test ! -s conftest.err
10229 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000010230 ac_hi=$ac_mid
10231else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010232 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010233sed 's/^/| /' conftest.$ac_ext >&5
10234
Martin v. Löwiseba40652007-08-30 20:10:57 +000010235 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000010236fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010237
10238rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010239done
10240case $ac_lo in
10241?*) ac_cv_sizeof_fpos_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000010242'') if test "$ac_cv_type_fpos_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000010243 { { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010244See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010245echo "$as_me: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010246See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000010247 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010248 else
10249 ac_cv_sizeof_fpos_t=0
10250 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000010251esac
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010252else
Martin v. Löwis11437992002-04-12 09:54:03 +000010253 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000010254/* confdefs.h. */
10255_ACEOF
10256cat confdefs.h >>conftest.$ac_ext
10257cat >>conftest.$ac_ext <<_ACEOF
10258/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000010259$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010260 typedef fpos_t ac__type_sizeof_;
10261static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
10262static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000010263#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010264#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000010265int
10266main ()
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010267{
Martin v. Löwis11437992002-04-12 09:54:03 +000010268
10269 FILE *f = fopen ("conftest.val", "w");
10270 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000010271 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000010272 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000010273 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010274 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000010275 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010276 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000010277 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010278 }
10279 else
10280 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010281 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000010282 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010283 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000010284 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000010285 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010286 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000010287
10288 ;
10289 return 0;
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010290}
Martin v. Löwis11437992002-04-12 09:54:03 +000010291_ACEOF
10292rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010293if { (ac_try="$ac_link"
10294case "(($ac_try" in
10295 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10296 *) ac_try_echo=$ac_try;;
10297esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010298eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010299 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010300 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000010301 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010302 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000010303 { (case "(($ac_try" in
10304 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10305 *) ac_try_echo=$ac_try;;
10306esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010307eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010308 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010309 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000010310 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000010311 (exit $ac_status); }; }; then
10312 ac_cv_sizeof_fpos_t=`cat conftest.val`
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010313else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010314 echo "$as_me: program exited with status $ac_status" >&5
10315echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000010316sed 's/^/| /' conftest.$ac_ext >&5
10317
Martin v. Löwis11437992002-04-12 09:54:03 +000010318( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000010319if test "$ac_cv_type_fpos_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000010320 { { echo "$as_me:$LINENO: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010321See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010322echo "$as_me: error: cannot compute sizeof (fpos_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000010323See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000010324 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010325 else
10326 ac_cv_sizeof_fpos_t=0
10327 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000010328fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010329rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000010330fi
10331rm -f conftest.val
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010332fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000010333{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_fpos_t" >&5
10334echo "${ECHO_T}$ac_cv_sizeof_fpos_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010335
10336
10337
Martin v. Löwis11437992002-04-12 09:54:03 +000010338cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010339#define SIZEOF_FPOS_T $ac_cv_sizeof_fpos_t
Martin v. Löwis11437992002-04-12 09:54:03 +000010340_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000010341
Michael W. Hudson54241132001-12-07 15:38:26 +000010342
Ronald Oussoren450d5612009-06-08 21:12:41 +000010343{ echo "$as_me:$LINENO: checking for size_t" >&5
10344echo $ECHO_N "checking for size_t... $ECHO_C" >&6; }
10345if test "${ac_cv_type_size_t+set}" = set; then
10346 echo $ECHO_N "(cached) $ECHO_C" >&6
10347else
10348 cat >conftest.$ac_ext <<_ACEOF
10349/* confdefs.h. */
10350_ACEOF
10351cat confdefs.h >>conftest.$ac_ext
10352cat >>conftest.$ac_ext <<_ACEOF
10353/* end confdefs.h. */
10354$ac_includes_default
10355typedef size_t ac__type_new_;
10356int
10357main ()
10358{
10359if ((ac__type_new_ *) 0)
10360 return 0;
10361if (sizeof (ac__type_new_))
10362 return 0;
10363 ;
10364 return 0;
10365}
10366_ACEOF
10367rm -f conftest.$ac_objext
10368if { (ac_try="$ac_compile"
10369case "(($ac_try" in
10370 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10371 *) ac_try_echo=$ac_try;;
10372esac
10373eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10374 (eval "$ac_compile") 2>conftest.er1
10375 ac_status=$?
10376 grep -v '^ *+' conftest.er1 >conftest.err
10377 rm -f conftest.er1
10378 cat conftest.err >&5
10379 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10380 (exit $ac_status); } && {
10381 test -z "$ac_c_werror_flag" ||
10382 test ! -s conftest.err
10383 } && test -s conftest.$ac_objext; then
10384 ac_cv_type_size_t=yes
10385else
10386 echo "$as_me: failed program was:" >&5
10387sed 's/^/| /' conftest.$ac_ext >&5
10388
10389 ac_cv_type_size_t=no
10390fi
10391
10392rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10393fi
10394{ echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
10395echo "${ECHO_T}$ac_cv_type_size_t" >&6; }
10396
Martin v. Löwiseba40652007-08-30 20:10:57 +000010397# The cast to long int works around a bug in the HP C Compiler
10398# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10399# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10400# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000010401{ echo "$as_me:$LINENO: checking size of size_t" >&5
10402echo $ECHO_N "checking size of size_t... $ECHO_C" >&6; }
Martin v. Löwis18e16552006-02-15 17:27:45 +000010403if test "${ac_cv_sizeof_size_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000010404 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis18e16552006-02-15 17:27:45 +000010405else
Martin v. Löwis18e16552006-02-15 17:27:45 +000010406 if test "$cross_compiling" = yes; then
10407 # Depending upon the size, compute the lo and hi bounds.
10408cat >conftest.$ac_ext <<_ACEOF
10409/* confdefs.h. */
10410_ACEOF
10411cat confdefs.h >>conftest.$ac_ext
10412cat >>conftest.$ac_ext <<_ACEOF
10413/* end confdefs.h. */
10414$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010415 typedef size_t ac__type_sizeof_;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010416int
10417main ()
10418{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010419static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010420test_array [0] = 0
10421
10422 ;
10423 return 0;
10424}
10425_ACEOF
10426rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010427if { (ac_try="$ac_compile"
10428case "(($ac_try" in
10429 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10430 *) ac_try_echo=$ac_try;;
10431esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010432eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010433 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010434 ac_status=$?
10435 grep -v '^ *+' conftest.er1 >conftest.err
10436 rm -f conftest.er1
10437 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010438 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010439 (exit $ac_status); } && {
10440 test -z "$ac_c_werror_flag" ||
10441 test ! -s conftest.err
10442 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010443 ac_lo=0 ac_mid=0
10444 while :; do
10445 cat >conftest.$ac_ext <<_ACEOF
10446/* confdefs.h. */
10447_ACEOF
10448cat confdefs.h >>conftest.$ac_ext
10449cat >>conftest.$ac_ext <<_ACEOF
10450/* end confdefs.h. */
10451$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010452 typedef size_t ac__type_sizeof_;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010453int
10454main ()
10455{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010456static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010457test_array [0] = 0
10458
10459 ;
10460 return 0;
10461}
10462_ACEOF
10463rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010464if { (ac_try="$ac_compile"
10465case "(($ac_try" in
10466 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10467 *) ac_try_echo=$ac_try;;
10468esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010469eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010470 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010471 ac_status=$?
10472 grep -v '^ *+' conftest.er1 >conftest.err
10473 rm -f conftest.er1
10474 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010476 (exit $ac_status); } && {
10477 test -z "$ac_c_werror_flag" ||
10478 test ! -s conftest.err
10479 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010480 ac_hi=$ac_mid; break
10481else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010482 echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010483sed 's/^/| /' conftest.$ac_ext >&5
10484
Martin v. Löwiseba40652007-08-30 20:10:57 +000010485 ac_lo=`expr $ac_mid + 1`
10486 if test $ac_lo -le $ac_mid; then
10487 ac_lo= ac_hi=
10488 break
10489 fi
10490 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis18e16552006-02-15 17:27:45 +000010491fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010492
10493rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010494 done
10495else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010496 echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010497sed 's/^/| /' conftest.$ac_ext >&5
10498
Martin v. Löwiseba40652007-08-30 20:10:57 +000010499 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwis18e16552006-02-15 17:27:45 +000010500/* confdefs.h. */
10501_ACEOF
10502cat confdefs.h >>conftest.$ac_ext
10503cat >>conftest.$ac_ext <<_ACEOF
10504/* end confdefs.h. */
10505$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010506 typedef size_t ac__type_sizeof_;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010507int
10508main ()
10509{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010510static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010511test_array [0] = 0
10512
10513 ;
10514 return 0;
10515}
10516_ACEOF
10517rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010518if { (ac_try="$ac_compile"
10519case "(($ac_try" in
10520 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10521 *) ac_try_echo=$ac_try;;
10522esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010523eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010524 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010525 ac_status=$?
10526 grep -v '^ *+' conftest.er1 >conftest.err
10527 rm -f conftest.er1
10528 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010529 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010530 (exit $ac_status); } && {
10531 test -z "$ac_c_werror_flag" ||
10532 test ! -s conftest.err
10533 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010534 ac_hi=-1 ac_mid=-1
10535 while :; do
10536 cat >conftest.$ac_ext <<_ACEOF
10537/* confdefs.h. */
10538_ACEOF
10539cat confdefs.h >>conftest.$ac_ext
10540cat >>conftest.$ac_ext <<_ACEOF
10541/* end confdefs.h. */
10542$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010543 typedef size_t ac__type_sizeof_;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010544int
10545main ()
10546{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010547static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010548test_array [0] = 0
10549
10550 ;
10551 return 0;
10552}
10553_ACEOF
10554rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010555if { (ac_try="$ac_compile"
10556case "(($ac_try" in
10557 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10558 *) ac_try_echo=$ac_try;;
10559esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010560eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010561 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010562 ac_status=$?
10563 grep -v '^ *+' conftest.er1 >conftest.err
10564 rm -f conftest.er1
10565 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010566 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010567 (exit $ac_status); } && {
10568 test -z "$ac_c_werror_flag" ||
10569 test ! -s conftest.err
10570 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010571 ac_lo=$ac_mid; break
10572else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010573 echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010574sed 's/^/| /' conftest.$ac_ext >&5
10575
Martin v. Löwiseba40652007-08-30 20:10:57 +000010576 ac_hi=`expr '(' $ac_mid ')' - 1`
10577 if test $ac_mid -le $ac_hi; then
10578 ac_lo= ac_hi=
10579 break
10580 fi
10581 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis18e16552006-02-15 17:27:45 +000010582fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010583
10584rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010585 done
10586else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010587 echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010588sed 's/^/| /' conftest.$ac_ext >&5
10589
Martin v. Löwiseba40652007-08-30 20:10:57 +000010590 ac_lo= ac_hi=
Martin v. Löwis18e16552006-02-15 17:27:45 +000010591fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010592
10593rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010594fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010595
10596rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010597# Binary search between lo and hi bounds.
10598while test "x$ac_lo" != "x$ac_hi"; do
10599 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
10600 cat >conftest.$ac_ext <<_ACEOF
10601/* confdefs.h. */
10602_ACEOF
10603cat confdefs.h >>conftest.$ac_ext
10604cat >>conftest.$ac_ext <<_ACEOF
10605/* end confdefs.h. */
10606$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010607 typedef size_t ac__type_sizeof_;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010608int
10609main ()
10610{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010611static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis18e16552006-02-15 17:27:45 +000010612test_array [0] = 0
10613
10614 ;
10615 return 0;
10616}
10617_ACEOF
10618rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010619if { (ac_try="$ac_compile"
10620case "(($ac_try" in
10621 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10622 *) ac_try_echo=$ac_try;;
10623esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010624eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010625 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis18e16552006-02-15 17:27:45 +000010626 ac_status=$?
10627 grep -v '^ *+' conftest.er1 >conftest.err
10628 rm -f conftest.er1
10629 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010631 (exit $ac_status); } && {
10632 test -z "$ac_c_werror_flag" ||
10633 test ! -s conftest.err
10634 } && test -s conftest.$ac_objext; then
Martin v. Löwis18e16552006-02-15 17:27:45 +000010635 ac_hi=$ac_mid
10636else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010637 echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010638sed 's/^/| /' conftest.$ac_ext >&5
10639
Martin v. Löwiseba40652007-08-30 20:10:57 +000010640 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis18e16552006-02-15 17:27:45 +000010641fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010642
10643rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010644done
10645case $ac_lo in
10646?*) ac_cv_sizeof_size_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000010647'') if test "$ac_cv_type_size_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000010648 { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000010649See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010650echo "$as_me: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000010651See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000010652 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010653 else
10654 ac_cv_sizeof_size_t=0
10655 fi ;;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010656esac
10657else
Martin v. Löwis18e16552006-02-15 17:27:45 +000010658 cat >conftest.$ac_ext <<_ACEOF
10659/* confdefs.h. */
10660_ACEOF
10661cat confdefs.h >>conftest.$ac_ext
10662cat >>conftest.$ac_ext <<_ACEOF
10663/* end confdefs.h. */
10664$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010665 typedef size_t ac__type_sizeof_;
10666static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
10667static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Martin v. Löwis18e16552006-02-15 17:27:45 +000010668#include <stdio.h>
10669#include <stdlib.h>
10670int
10671main ()
10672{
10673
10674 FILE *f = fopen ("conftest.val", "w");
10675 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000010676 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000010677 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis18e16552006-02-15 17:27:45 +000010678 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010679 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000010680 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010681 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000010682 fprintf (f, "%ld\n", i);
Martin v. Löwis18e16552006-02-15 17:27:45 +000010683 }
10684 else
10685 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000010686 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000010687 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000010688 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000010689 fprintf (f, "%lu\n", i);
Martin v. Löwis18e16552006-02-15 17:27:45 +000010690 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010691 return ferror (f) || fclose (f) != 0;
Martin v. Löwis18e16552006-02-15 17:27:45 +000010692
10693 ;
10694 return 0;
10695}
10696_ACEOF
10697rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000010698if { (ac_try="$ac_link"
10699case "(($ac_try" in
10700 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10701 *) ac_try_echo=$ac_try;;
10702esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010703eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010704 (eval "$ac_link") 2>&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010705 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000010706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010707 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000010708 { (case "(($ac_try" in
10709 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10710 *) ac_try_echo=$ac_try;;
10711esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010712eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000010713 (eval "$ac_try") 2>&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010714 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000010715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010716 (exit $ac_status); }; }; then
10717 ac_cv_sizeof_size_t=`cat conftest.val`
10718else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010719 echo "$as_me: program exited with status $ac_status" >&5
10720echo "$as_me: failed program was:" >&5
Martin v. Löwis18e16552006-02-15 17:27:45 +000010721sed 's/^/| /' conftest.$ac_ext >&5
10722
10723( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000010724if test "$ac_cv_type_size_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000010725 { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000010726See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010727echo "$as_me: error: cannot compute sizeof (size_t)
Martin v. Löwis18e16552006-02-15 17:27:45 +000010728See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000010729 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010730 else
10731 ac_cv_sizeof_size_t=0
10732 fi
Martin v. Löwis18e16552006-02-15 17:27:45 +000010733fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000010734rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis18e16552006-02-15 17:27:45 +000010735fi
10736rm -f conftest.val
Martin v. Löwis18e16552006-02-15 17:27:45 +000010737fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000010738{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
10739echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000010740
10741
10742
Martin v. Löwis18e16552006-02-15 17:27:45 +000010743cat >>confdefs.h <<_ACEOF
10744#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
10745_ACEOF
10746
10747
Ronald Oussoren450d5612009-06-08 21:12:41 +000010748{ echo "$as_me:$LINENO: checking for pid_t" >&5
10749echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; }
10750if test "${ac_cv_type_pid_t+set}" = set; then
10751 echo $ECHO_N "(cached) $ECHO_C" >&6
10752else
10753 cat >conftest.$ac_ext <<_ACEOF
10754/* confdefs.h. */
10755_ACEOF
10756cat confdefs.h >>conftest.$ac_ext
10757cat >>conftest.$ac_ext <<_ACEOF
10758/* end confdefs.h. */
10759$ac_includes_default
10760typedef pid_t ac__type_new_;
10761int
10762main ()
10763{
10764if ((ac__type_new_ *) 0)
10765 return 0;
10766if (sizeof (ac__type_new_))
10767 return 0;
10768 ;
10769 return 0;
10770}
10771_ACEOF
10772rm -f conftest.$ac_objext
10773if { (ac_try="$ac_compile"
10774case "(($ac_try" in
10775 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10776 *) ac_try_echo=$ac_try;;
10777esac
10778eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10779 (eval "$ac_compile") 2>conftest.er1
10780 ac_status=$?
10781 grep -v '^ *+' conftest.er1 >conftest.err
10782 rm -f conftest.er1
10783 cat conftest.err >&5
10784 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10785 (exit $ac_status); } && {
10786 test -z "$ac_c_werror_flag" ||
10787 test ! -s conftest.err
10788 } && test -s conftest.$ac_objext; then
10789 ac_cv_type_pid_t=yes
10790else
10791 echo "$as_me: failed program was:" >&5
10792sed 's/^/| /' conftest.$ac_ext >&5
10793
10794 ac_cv_type_pid_t=no
10795fi
10796
10797rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10798fi
10799{ echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
10800echo "${ECHO_T}$ac_cv_type_pid_t" >&6; }
10801
Christian Heimes951cc0f2008-01-31 23:08:23 +000010802# The cast to long int works around a bug in the HP C Compiler
10803# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10804# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10805# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000010806{ echo "$as_me:$LINENO: checking size of pid_t" >&5
10807echo $ECHO_N "checking size of pid_t... $ECHO_C" >&6; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000010808if test "${ac_cv_sizeof_pid_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000010809 echo $ECHO_N "(cached) $ECHO_C" >&6
Christian Heimes951cc0f2008-01-31 23:08:23 +000010810else
10811 if test "$cross_compiling" = yes; then
10812 # Depending upon the size, compute the lo and hi bounds.
10813cat >conftest.$ac_ext <<_ACEOF
10814/* confdefs.h. */
10815_ACEOF
10816cat confdefs.h >>conftest.$ac_ext
10817cat >>conftest.$ac_ext <<_ACEOF
10818/* end confdefs.h. */
10819$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010820 typedef pid_t ac__type_sizeof_;
Christian Heimes951cc0f2008-01-31 23:08:23 +000010821int
10822main ()
10823{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010824static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000010825test_array [0] = 0
10826
10827 ;
10828 return 0;
10829}
10830_ACEOF
10831rm -f conftest.$ac_objext
10832if { (ac_try="$ac_compile"
10833case "(($ac_try" in
10834 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10835 *) ac_try_echo=$ac_try;;
10836esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010837eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010838 (eval "$ac_compile") 2>conftest.er1
10839 ac_status=$?
10840 grep -v '^ *+' conftest.er1 >conftest.err
10841 rm -f conftest.er1
10842 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010843 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010844 (exit $ac_status); } && {
10845 test -z "$ac_c_werror_flag" ||
10846 test ! -s conftest.err
10847 } && test -s conftest.$ac_objext; then
10848 ac_lo=0 ac_mid=0
10849 while :; do
10850 cat >conftest.$ac_ext <<_ACEOF
10851/* confdefs.h. */
10852_ACEOF
10853cat confdefs.h >>conftest.$ac_ext
10854cat >>conftest.$ac_ext <<_ACEOF
10855/* end confdefs.h. */
10856$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010857 typedef pid_t ac__type_sizeof_;
Christian Heimes951cc0f2008-01-31 23:08:23 +000010858int
10859main ()
10860{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010861static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000010862test_array [0] = 0
10863
10864 ;
10865 return 0;
10866}
10867_ACEOF
10868rm -f conftest.$ac_objext
10869if { (ac_try="$ac_compile"
10870case "(($ac_try" in
10871 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10872 *) ac_try_echo=$ac_try;;
10873esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010874eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010875 (eval "$ac_compile") 2>conftest.er1
10876 ac_status=$?
10877 grep -v '^ *+' conftest.er1 >conftest.err
10878 rm -f conftest.er1
10879 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010880 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010881 (exit $ac_status); } && {
10882 test -z "$ac_c_werror_flag" ||
10883 test ! -s conftest.err
10884 } && test -s conftest.$ac_objext; then
10885 ac_hi=$ac_mid; break
10886else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010887 echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010888sed 's/^/| /' conftest.$ac_ext >&5
10889
10890 ac_lo=`expr $ac_mid + 1`
10891 if test $ac_lo -le $ac_mid; then
10892 ac_lo= ac_hi=
10893 break
10894 fi
10895 ac_mid=`expr 2 '*' $ac_mid + 1`
10896fi
10897
10898rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10899 done
10900else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010901 echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010902sed 's/^/| /' conftest.$ac_ext >&5
10903
10904 cat >conftest.$ac_ext <<_ACEOF
10905/* confdefs.h. */
10906_ACEOF
10907cat confdefs.h >>conftest.$ac_ext
10908cat >>conftest.$ac_ext <<_ACEOF
10909/* end confdefs.h. */
10910$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010911 typedef pid_t ac__type_sizeof_;
Christian Heimes951cc0f2008-01-31 23:08:23 +000010912int
10913main ()
10914{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010915static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000010916test_array [0] = 0
10917
10918 ;
10919 return 0;
10920}
10921_ACEOF
10922rm -f conftest.$ac_objext
10923if { (ac_try="$ac_compile"
10924case "(($ac_try" in
10925 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10926 *) ac_try_echo=$ac_try;;
10927esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010928eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010929 (eval "$ac_compile") 2>conftest.er1
10930 ac_status=$?
10931 grep -v '^ *+' conftest.er1 >conftest.err
10932 rm -f conftest.er1
10933 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010934 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010935 (exit $ac_status); } && {
10936 test -z "$ac_c_werror_flag" ||
10937 test ! -s conftest.err
10938 } && test -s conftest.$ac_objext; then
10939 ac_hi=-1 ac_mid=-1
10940 while :; do
10941 cat >conftest.$ac_ext <<_ACEOF
10942/* confdefs.h. */
10943_ACEOF
10944cat confdefs.h >>conftest.$ac_ext
10945cat >>conftest.$ac_ext <<_ACEOF
10946/* end confdefs.h. */
10947$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000010948 typedef pid_t ac__type_sizeof_;
Christian Heimes951cc0f2008-01-31 23:08:23 +000010949int
10950main ()
10951{
Ronald Oussoren450d5612009-06-08 21:12:41 +000010952static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000010953test_array [0] = 0
10954
10955 ;
10956 return 0;
10957}
10958_ACEOF
10959rm -f conftest.$ac_objext
10960if { (ac_try="$ac_compile"
10961case "(($ac_try" in
10962 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10963 *) ac_try_echo=$ac_try;;
10964esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000010965eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010966 (eval "$ac_compile") 2>conftest.er1
10967 ac_status=$?
10968 grep -v '^ *+' conftest.er1 >conftest.err
10969 rm -f conftest.er1
10970 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000010971 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010972 (exit $ac_status); } && {
10973 test -z "$ac_c_werror_flag" ||
10974 test ! -s conftest.err
10975 } && test -s conftest.$ac_objext; then
10976 ac_lo=$ac_mid; break
10977else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010978 echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010979sed 's/^/| /' conftest.$ac_ext >&5
10980
10981 ac_hi=`expr '(' $ac_mid ')' - 1`
10982 if test $ac_mid -le $ac_hi; then
10983 ac_lo= ac_hi=
10984 break
10985 fi
10986 ac_mid=`expr 2 '*' $ac_mid`
10987fi
10988
10989rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10990 done
10991else
Ronald Oussoren450d5612009-06-08 21:12:41 +000010992 echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000010993sed 's/^/| /' conftest.$ac_ext >&5
10994
10995 ac_lo= ac_hi=
10996fi
10997
10998rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10999fi
11000
11001rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11002# Binary search between lo and hi bounds.
11003while test "x$ac_lo" != "x$ac_hi"; do
11004 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
11005 cat >conftest.$ac_ext <<_ACEOF
11006/* confdefs.h. */
11007_ACEOF
11008cat confdefs.h >>conftest.$ac_ext
11009cat >>conftest.$ac_ext <<_ACEOF
11010/* end confdefs.h. */
11011$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011012 typedef pid_t ac__type_sizeof_;
Christian Heimes951cc0f2008-01-31 23:08:23 +000011013int
11014main ()
11015{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011016static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Christian Heimes951cc0f2008-01-31 23:08:23 +000011017test_array [0] = 0
11018
11019 ;
11020 return 0;
11021}
11022_ACEOF
11023rm -f conftest.$ac_objext
11024if { (ac_try="$ac_compile"
11025case "(($ac_try" in
11026 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11027 *) ac_try_echo=$ac_try;;
11028esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011029eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011030 (eval "$ac_compile") 2>conftest.er1
11031 ac_status=$?
11032 grep -v '^ *+' conftest.er1 >conftest.err
11033 rm -f conftest.er1
11034 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011035 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011036 (exit $ac_status); } && {
11037 test -z "$ac_c_werror_flag" ||
11038 test ! -s conftest.err
11039 } && test -s conftest.$ac_objext; then
11040 ac_hi=$ac_mid
11041else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011042 echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011043sed 's/^/| /' conftest.$ac_ext >&5
11044
11045 ac_lo=`expr '(' $ac_mid ')' + 1`
11046fi
11047
11048rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11049done
11050case $ac_lo in
11051?*) ac_cv_sizeof_pid_t=$ac_lo;;
11052'') if test "$ac_cv_type_pid_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011053 { { echo "$as_me:$LINENO: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011054See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011055echo "$as_me: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011056See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000011057 { (exit 77); exit 77; }; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011058 else
11059 ac_cv_sizeof_pid_t=0
11060 fi ;;
11061esac
11062else
11063 cat >conftest.$ac_ext <<_ACEOF
11064/* confdefs.h. */
11065_ACEOF
11066cat confdefs.h >>conftest.$ac_ext
11067cat >>conftest.$ac_ext <<_ACEOF
11068/* end confdefs.h. */
11069$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011070 typedef pid_t ac__type_sizeof_;
11071static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
11072static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011073#include <stdio.h>
11074#include <stdlib.h>
11075int
11076main ()
11077{
11078
11079 FILE *f = fopen ("conftest.val", "w");
11080 if (! f)
11081 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000011082 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011083 {
11084 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000011085 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Christian Heimes951cc0f2008-01-31 23:08:23 +000011086 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000011087 fprintf (f, "%ld\n", i);
Christian Heimes951cc0f2008-01-31 23:08:23 +000011088 }
11089 else
11090 {
11091 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000011092 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Christian Heimes951cc0f2008-01-31 23:08:23 +000011093 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000011094 fprintf (f, "%lu\n", i);
Christian Heimes951cc0f2008-01-31 23:08:23 +000011095 }
11096 return ferror (f) || fclose (f) != 0;
11097
11098 ;
11099 return 0;
11100}
11101_ACEOF
11102rm -f conftest$ac_exeext
11103if { (ac_try="$ac_link"
11104case "(($ac_try" in
11105 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11106 *) ac_try_echo=$ac_try;;
11107esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011108eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011109 (eval "$ac_link") 2>&5
11110 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000011111 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011112 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11113 { (case "(($ac_try" in
11114 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11115 *) ac_try_echo=$ac_try;;
11116esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011117eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011118 (eval "$ac_try") 2>&5
11119 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000011120 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011121 (exit $ac_status); }; }; then
11122 ac_cv_sizeof_pid_t=`cat conftest.val`
11123else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011124 echo "$as_me: program exited with status $ac_status" >&5
11125echo "$as_me: failed program was:" >&5
Christian Heimes951cc0f2008-01-31 23:08:23 +000011126sed 's/^/| /' conftest.$ac_ext >&5
11127
11128( exit $ac_status )
11129if test "$ac_cv_type_pid_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011130 { { echo "$as_me:$LINENO: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011131See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011132echo "$as_me: error: cannot compute sizeof (pid_t)
Christian Heimes951cc0f2008-01-31 23:08:23 +000011133See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000011134 { (exit 77); exit 77; }; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011135 else
11136 ac_cv_sizeof_pid_t=0
11137 fi
11138fi
11139rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11140fi
11141rm -f conftest.val
11142fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000011143{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_pid_t" >&5
11144echo "${ECHO_T}$ac_cv_sizeof_pid_t" >&6; }
Christian Heimes951cc0f2008-01-31 23:08:23 +000011145
11146
11147
11148cat >>confdefs.h <<_ACEOF
11149#define SIZEOF_PID_T $ac_cv_sizeof_pid_t
11150_ACEOF
11151
11152
Michael W. Hudson54241132001-12-07 15:38:26 +000011153
Ronald Oussoren450d5612009-06-08 21:12:41 +000011154{ echo "$as_me:$LINENO: checking for long long support" >&5
11155echo $ECHO_N "checking for long long support... $ECHO_C" >&6; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011156have_long_long=no
Martin v. Löwis11437992002-04-12 09:54:03 +000011157cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011158/* confdefs.h. */
11159_ACEOF
11160cat confdefs.h >>conftest.$ac_ext
11161cat >>conftest.$ac_ext <<_ACEOF
11162/* end confdefs.h. */
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011163
Martin v. Löwis11437992002-04-12 09:54:03 +000011164int
11165main ()
11166{
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011167long long x; x = (long long)0;
Martin v. Löwis11437992002-04-12 09:54:03 +000011168 ;
11169 return 0;
11170}
11171_ACEOF
11172rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011173if { (ac_try="$ac_compile"
11174case "(($ac_try" in
11175 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11176 *) ac_try_echo=$ac_try;;
11177esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011178eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011179 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011180 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011181 grep -v '^ *+' conftest.er1 >conftest.err
11182 rm -f conftest.er1
11183 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011184 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011185 (exit $ac_status); } && {
11186 test -z "$ac_c_werror_flag" ||
11187 test ! -s conftest.err
11188 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011189
11190
11191cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011192#define HAVE_LONG_LONG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000011193_ACEOF
11194
Martin v. Löwisc45929e2002-04-06 10:10:49 +000011195 have_long_long=yes
11196
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011197else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011198 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011199sed 's/^/| /' conftest.$ac_ext >&5
11200
Martin v. Löwiseba40652007-08-30 20:10:57 +000011201
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011202fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011203
11204rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000011205{ echo "$as_me:$LINENO: result: $have_long_long" >&5
11206echo "${ECHO_T}$have_long_long" >&6; }
Guido van Rossum96f2eb91999-04-10 16:02:18 +000011207if test "$have_long_long" = yes ; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011208{ echo "$as_me:$LINENO: checking for long long" >&5
11209echo $ECHO_N "checking for long long... $ECHO_C" >&6; }
11210if test "${ac_cv_type_long_long+set}" = set; then
11211 echo $ECHO_N "(cached) $ECHO_C" >&6
11212else
11213 cat >conftest.$ac_ext <<_ACEOF
11214/* confdefs.h. */
11215_ACEOF
11216cat confdefs.h >>conftest.$ac_ext
11217cat >>conftest.$ac_ext <<_ACEOF
11218/* end confdefs.h. */
11219$ac_includes_default
11220typedef long long ac__type_new_;
11221int
11222main ()
11223{
11224if ((ac__type_new_ *) 0)
11225 return 0;
11226if (sizeof (ac__type_new_))
11227 return 0;
11228 ;
11229 return 0;
11230}
11231_ACEOF
11232rm -f conftest.$ac_objext
11233if { (ac_try="$ac_compile"
11234case "(($ac_try" in
11235 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11236 *) ac_try_echo=$ac_try;;
11237esac
11238eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11239 (eval "$ac_compile") 2>conftest.er1
11240 ac_status=$?
11241 grep -v '^ *+' conftest.er1 >conftest.err
11242 rm -f conftest.er1
11243 cat conftest.err >&5
11244 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11245 (exit $ac_status); } && {
11246 test -z "$ac_c_werror_flag" ||
11247 test ! -s conftest.err
11248 } && test -s conftest.$ac_objext; then
11249 ac_cv_type_long_long=yes
11250else
11251 echo "$as_me: failed program was:" >&5
11252sed 's/^/| /' conftest.$ac_ext >&5
11253
11254 ac_cv_type_long_long=no
11255fi
11256
11257rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11258fi
11259{ echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
11260echo "${ECHO_T}$ac_cv_type_long_long" >&6; }
11261
Martin v. Löwiseba40652007-08-30 20:10:57 +000011262# The cast to long int works around a bug in the HP C Compiler
11263# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11264# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11265# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000011266{ echo "$as_me:$LINENO: checking size of long long" >&5
11267echo $ECHO_N "checking size of long long... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000011268if test "${ac_cv_sizeof_long_long+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011269 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000011270else
Martin v. Löwis11437992002-04-12 09:54:03 +000011271 if test "$cross_compiling" = yes; then
11272 # Depending upon the size, compute the lo and hi bounds.
11273cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011274/* confdefs.h. */
11275_ACEOF
11276cat confdefs.h >>conftest.$ac_ext
11277cat >>conftest.$ac_ext <<_ACEOF
11278/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011279$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011280 typedef long long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000011281int
11282main ()
11283{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011284static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011285test_array [0] = 0
11286
11287 ;
11288 return 0;
11289}
11290_ACEOF
11291rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011292if { (ac_try="$ac_compile"
11293case "(($ac_try" in
11294 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11295 *) ac_try_echo=$ac_try;;
11296esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011297eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011298 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011299 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011300 grep -v '^ *+' conftest.er1 >conftest.err
11301 rm -f conftest.er1
11302 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011303 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011304 (exit $ac_status); } && {
11305 test -z "$ac_c_werror_flag" ||
11306 test ! -s conftest.err
11307 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011308 ac_lo=0 ac_mid=0
11309 while :; do
11310 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011311/* confdefs.h. */
11312_ACEOF
11313cat confdefs.h >>conftest.$ac_ext
11314cat >>conftest.$ac_ext <<_ACEOF
11315/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011316$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011317 typedef long long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000011318int
11319main ()
11320{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011321static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011322test_array [0] = 0
11323
11324 ;
11325 return 0;
11326}
11327_ACEOF
11328rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011329if { (ac_try="$ac_compile"
11330case "(($ac_try" in
11331 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11332 *) ac_try_echo=$ac_try;;
11333esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011334eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011335 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011336 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011337 grep -v '^ *+' conftest.er1 >conftest.err
11338 rm -f conftest.er1
11339 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011340 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011341 (exit $ac_status); } && {
11342 test -z "$ac_c_werror_flag" ||
11343 test ! -s conftest.err
11344 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011345 ac_hi=$ac_mid; break
11346else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011347 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011348sed 's/^/| /' conftest.$ac_ext >&5
11349
Martin v. Löwiseba40652007-08-30 20:10:57 +000011350 ac_lo=`expr $ac_mid + 1`
11351 if test $ac_lo -le $ac_mid; then
11352 ac_lo= ac_hi=
11353 break
11354 fi
11355 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000011356fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011357
11358rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011359 done
11360else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011361 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011362sed 's/^/| /' conftest.$ac_ext >&5
11363
Martin v. Löwiseba40652007-08-30 20:10:57 +000011364 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011365/* confdefs.h. */
11366_ACEOF
11367cat confdefs.h >>conftest.$ac_ext
11368cat >>conftest.$ac_ext <<_ACEOF
11369/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011370$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011371 typedef long long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000011372int
11373main ()
11374{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011375static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011376test_array [0] = 0
11377
11378 ;
11379 return 0;
11380}
11381_ACEOF
11382rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011383if { (ac_try="$ac_compile"
11384case "(($ac_try" in
11385 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11386 *) ac_try_echo=$ac_try;;
11387esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011388eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011389 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011390 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011391 grep -v '^ *+' conftest.er1 >conftest.err
11392 rm -f conftest.er1
11393 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011395 (exit $ac_status); } && {
11396 test -z "$ac_c_werror_flag" ||
11397 test ! -s conftest.err
11398 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011399 ac_hi=-1 ac_mid=-1
11400 while :; do
11401 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011402/* confdefs.h. */
11403_ACEOF
11404cat confdefs.h >>conftest.$ac_ext
11405cat >>conftest.$ac_ext <<_ACEOF
11406/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011407$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011408 typedef long long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000011409int
11410main ()
11411{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011412static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011413test_array [0] = 0
11414
11415 ;
11416 return 0;
11417}
11418_ACEOF
11419rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011420if { (ac_try="$ac_compile"
11421case "(($ac_try" in
11422 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11423 *) ac_try_echo=$ac_try;;
11424esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011425eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011426 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011427 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011428 grep -v '^ *+' conftest.er1 >conftest.err
11429 rm -f conftest.er1
11430 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011431 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011432 (exit $ac_status); } && {
11433 test -z "$ac_c_werror_flag" ||
11434 test ! -s conftest.err
11435 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011436 ac_lo=$ac_mid; break
11437else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011438 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011439sed 's/^/| /' conftest.$ac_ext >&5
11440
Martin v. Löwiseba40652007-08-30 20:10:57 +000011441 ac_hi=`expr '(' $ac_mid ')' - 1`
11442 if test $ac_mid -le $ac_hi; then
11443 ac_lo= ac_hi=
11444 break
11445 fi
11446 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000011447fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011448
11449rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011450 done
11451else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011452 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011453sed 's/^/| /' conftest.$ac_ext >&5
11454
Martin v. Löwiseba40652007-08-30 20:10:57 +000011455 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000011456fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011457
11458rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011459fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011460
11461rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011462# Binary search between lo and hi bounds.
11463while test "x$ac_lo" != "x$ac_hi"; do
11464 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
11465 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011466/* confdefs.h. */
11467_ACEOF
11468cat confdefs.h >>conftest.$ac_ext
11469cat >>conftest.$ac_ext <<_ACEOF
11470/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011471$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011472 typedef long long ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000011473int
11474main ()
11475{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011476static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000011477test_array [0] = 0
11478
11479 ;
11480 return 0;
11481}
11482_ACEOF
11483rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011484if { (ac_try="$ac_compile"
11485case "(($ac_try" in
11486 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11487 *) ac_try_echo=$ac_try;;
11488esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011489eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011490 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000011491 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000011492 grep -v '^ *+' conftest.er1 >conftest.err
11493 rm -f conftest.er1
11494 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011495 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011496 (exit $ac_status); } && {
11497 test -z "$ac_c_werror_flag" ||
11498 test ! -s conftest.err
11499 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000011500 ac_hi=$ac_mid
11501else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011502 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011503sed 's/^/| /' conftest.$ac_ext >&5
11504
Martin v. Löwiseba40652007-08-30 20:10:57 +000011505 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000011506fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011507
11508rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011509done
11510case $ac_lo in
11511?*) ac_cv_sizeof_long_long=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000011512'') if test "$ac_cv_type_long_long" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011513 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011514See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011515echo "$as_me: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011516See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000011517 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011518 else
11519 ac_cv_sizeof_long_long=0
11520 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000011521esac
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011522else
Martin v. Löwis11437992002-04-12 09:54:03 +000011523 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000011524/* confdefs.h. */
11525_ACEOF
11526cat confdefs.h >>conftest.$ac_ext
11527cat >>conftest.$ac_ext <<_ACEOF
11528/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000011529$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011530 typedef long long ac__type_sizeof_;
11531static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
11532static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000011533#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011534#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000011535int
11536main ()
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011537{
Martin v. Löwis11437992002-04-12 09:54:03 +000011538
11539 FILE *f = fopen ("conftest.val", "w");
11540 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000011541 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000011542 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000011543 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000011544 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000011545 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000011546 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000011547 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000011548 }
11549 else
11550 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000011551 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000011552 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000011553 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000011554 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000011555 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011556 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000011557
11558 ;
11559 return 0;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011560}
Martin v. Löwis11437992002-04-12 09:54:03 +000011561_ACEOF
11562rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000011563if { (ac_try="$ac_link"
11564case "(($ac_try" in
11565 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11566 *) ac_try_echo=$ac_try;;
11567esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011568eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011569 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011570 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000011571 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011572 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000011573 { (case "(($ac_try" in
11574 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11575 *) ac_try_echo=$ac_try;;
11576esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011577eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000011578 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011579 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000011580 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000011581 (exit $ac_status); }; }; then
11582 ac_cv_sizeof_long_long=`cat conftest.val`
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011583else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011584 echo "$as_me: program exited with status $ac_status" >&5
11585echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000011586sed 's/^/| /' conftest.$ac_ext >&5
11587
Martin v. Löwis11437992002-04-12 09:54:03 +000011588( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000011589if test "$ac_cv_type_long_long" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011590 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011591See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011592echo "$as_me: error: cannot compute sizeof (long long)
Skip Montanaro6dead952003-09-25 14:50:04 +000011593See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000011594 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011595 else
11596 ac_cv_sizeof_long_long=0
11597 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000011598fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000011599rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000011600fi
11601rm -f conftest.val
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011602fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000011603{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5
11604echo "${ECHO_T}$ac_cv_sizeof_long_long" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000011605
11606
11607
Martin v. Löwis11437992002-04-12 09:54:03 +000011608cat >>confdefs.h <<_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011609#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
Martin v. Löwis11437992002-04-12 09:54:03 +000011610_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011611
Michael W. Hudson54241132001-12-07 15:38:26 +000011612
Guido van Rossumec95c7b1998-08-04 17:59:56 +000011613fi
11614
Ronald Oussoren450d5612009-06-08 21:12:41 +000011615{ echo "$as_me:$LINENO: checking for long double support" >&5
11616echo $ECHO_N "checking for long double support... $ECHO_C" >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011617have_long_double=no
11618cat >conftest.$ac_ext <<_ACEOF
11619/* confdefs.h. */
11620_ACEOF
11621cat confdefs.h >>conftest.$ac_ext
11622cat >>conftest.$ac_ext <<_ACEOF
11623/* end confdefs.h. */
11624
11625int
11626main ()
11627{
11628long double x; x = (long double)0.;
11629 ;
11630 return 0;
11631}
11632_ACEOF
11633rm -f conftest.$ac_objext
11634if { (ac_try="$ac_compile"
11635case "(($ac_try" in
11636 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11637 *) ac_try_echo=$ac_try;;
11638esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011639eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011640 (eval "$ac_compile") 2>conftest.er1
11641 ac_status=$?
11642 grep -v '^ *+' conftest.er1 >conftest.err
11643 rm -f conftest.er1
11644 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011645 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011646 (exit $ac_status); } && {
11647 test -z "$ac_c_werror_flag" ||
11648 test ! -s conftest.err
11649 } && test -s conftest.$ac_objext; then
11650
11651
11652cat >>confdefs.h <<\_ACEOF
11653#define HAVE_LONG_DOUBLE 1
11654_ACEOF
11655
11656 have_long_double=yes
11657
11658else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011659 echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011660sed 's/^/| /' conftest.$ac_ext >&5
11661
11662
11663fi
11664
11665rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000011666{ echo "$as_me:$LINENO: result: $have_long_double" >&5
11667echo "${ECHO_T}$have_long_double" >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011668if test "$have_long_double" = yes ; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011669{ echo "$as_me:$LINENO: checking for long double" >&5
11670echo $ECHO_N "checking for long double... $ECHO_C" >&6; }
11671if test "${ac_cv_type_long_double+set}" = set; then
11672 echo $ECHO_N "(cached) $ECHO_C" >&6
11673else
11674 cat >conftest.$ac_ext <<_ACEOF
11675/* confdefs.h. */
11676_ACEOF
11677cat confdefs.h >>conftest.$ac_ext
11678cat >>conftest.$ac_ext <<_ACEOF
11679/* end confdefs.h. */
11680$ac_includes_default
11681typedef long double ac__type_new_;
11682int
11683main ()
11684{
11685if ((ac__type_new_ *) 0)
11686 return 0;
11687if (sizeof (ac__type_new_))
11688 return 0;
11689 ;
11690 return 0;
11691}
11692_ACEOF
11693rm -f conftest.$ac_objext
11694if { (ac_try="$ac_compile"
11695case "(($ac_try" in
11696 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11697 *) ac_try_echo=$ac_try;;
11698esac
11699eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11700 (eval "$ac_compile") 2>conftest.er1
11701 ac_status=$?
11702 grep -v '^ *+' conftest.er1 >conftest.err
11703 rm -f conftest.er1
11704 cat conftest.err >&5
11705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11706 (exit $ac_status); } && {
11707 test -z "$ac_c_werror_flag" ||
11708 test ! -s conftest.err
11709 } && test -s conftest.$ac_objext; then
11710 ac_cv_type_long_double=yes
11711else
11712 echo "$as_me: failed program was:" >&5
11713sed 's/^/| /' conftest.$ac_ext >&5
11714
11715 ac_cv_type_long_double=no
11716fi
11717
11718rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11719fi
11720{ echo "$as_me:$LINENO: result: $ac_cv_type_long_double" >&5
11721echo "${ECHO_T}$ac_cv_type_long_double" >&6; }
11722
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011723# The cast to long int works around a bug in the HP C Compiler
11724# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11725# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11726# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000011727{ echo "$as_me:$LINENO: checking size of long double" >&5
11728echo $ECHO_N "checking size of long double... $ECHO_C" >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011729if test "${ac_cv_sizeof_long_double+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011730 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011731else
11732 if test "$cross_compiling" = yes; then
11733 # Depending upon the size, compute the lo and hi bounds.
11734cat >conftest.$ac_ext <<_ACEOF
11735/* confdefs.h. */
11736_ACEOF
11737cat confdefs.h >>conftest.$ac_ext
11738cat >>conftest.$ac_ext <<_ACEOF
11739/* end confdefs.h. */
11740$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011741 typedef long double ac__type_sizeof_;
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011742int
11743main ()
11744{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011745static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011746test_array [0] = 0
11747
11748 ;
11749 return 0;
11750}
11751_ACEOF
11752rm -f conftest.$ac_objext
11753if { (ac_try="$ac_compile"
11754case "(($ac_try" in
11755 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11756 *) ac_try_echo=$ac_try;;
11757esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011758eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011759 (eval "$ac_compile") 2>conftest.er1
11760 ac_status=$?
11761 grep -v '^ *+' conftest.er1 >conftest.err
11762 rm -f conftest.er1
11763 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011764 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011765 (exit $ac_status); } && {
11766 test -z "$ac_c_werror_flag" ||
11767 test ! -s conftest.err
11768 } && test -s conftest.$ac_objext; then
11769 ac_lo=0 ac_mid=0
11770 while :; do
11771 cat >conftest.$ac_ext <<_ACEOF
11772/* confdefs.h. */
11773_ACEOF
11774cat confdefs.h >>conftest.$ac_ext
11775cat >>conftest.$ac_ext <<_ACEOF
11776/* end confdefs.h. */
11777$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011778 typedef long double ac__type_sizeof_;
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011779int
11780main ()
11781{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011782static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011783test_array [0] = 0
11784
11785 ;
11786 return 0;
11787}
11788_ACEOF
11789rm -f conftest.$ac_objext
11790if { (ac_try="$ac_compile"
11791case "(($ac_try" in
11792 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11793 *) ac_try_echo=$ac_try;;
11794esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011795eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011796 (eval "$ac_compile") 2>conftest.er1
11797 ac_status=$?
11798 grep -v '^ *+' conftest.er1 >conftest.err
11799 rm -f conftest.er1
11800 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011802 (exit $ac_status); } && {
11803 test -z "$ac_c_werror_flag" ||
11804 test ! -s conftest.err
11805 } && test -s conftest.$ac_objext; then
11806 ac_hi=$ac_mid; break
11807else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011808 echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011809sed 's/^/| /' conftest.$ac_ext >&5
11810
11811 ac_lo=`expr $ac_mid + 1`
11812 if test $ac_lo -le $ac_mid; then
11813 ac_lo= ac_hi=
11814 break
11815 fi
11816 ac_mid=`expr 2 '*' $ac_mid + 1`
11817fi
11818
11819rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11820 done
11821else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011822 echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011823sed 's/^/| /' conftest.$ac_ext >&5
11824
11825 cat >conftest.$ac_ext <<_ACEOF
11826/* confdefs.h. */
11827_ACEOF
11828cat confdefs.h >>conftest.$ac_ext
11829cat >>conftest.$ac_ext <<_ACEOF
11830/* end confdefs.h. */
11831$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011832 typedef long double ac__type_sizeof_;
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011833int
11834main ()
11835{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011836static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011837test_array [0] = 0
11838
11839 ;
11840 return 0;
11841}
11842_ACEOF
11843rm -f conftest.$ac_objext
11844if { (ac_try="$ac_compile"
11845case "(($ac_try" in
11846 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11847 *) ac_try_echo=$ac_try;;
11848esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011849eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011850 (eval "$ac_compile") 2>conftest.er1
11851 ac_status=$?
11852 grep -v '^ *+' conftest.er1 >conftest.err
11853 rm -f conftest.er1
11854 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011856 (exit $ac_status); } && {
11857 test -z "$ac_c_werror_flag" ||
11858 test ! -s conftest.err
11859 } && test -s conftest.$ac_objext; then
11860 ac_hi=-1 ac_mid=-1
11861 while :; do
11862 cat >conftest.$ac_ext <<_ACEOF
11863/* confdefs.h. */
11864_ACEOF
11865cat confdefs.h >>conftest.$ac_ext
11866cat >>conftest.$ac_ext <<_ACEOF
11867/* end confdefs.h. */
11868$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011869 typedef long double ac__type_sizeof_;
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011870int
11871main ()
11872{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011873static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011874test_array [0] = 0
11875
11876 ;
11877 return 0;
11878}
11879_ACEOF
11880rm -f conftest.$ac_objext
11881if { (ac_try="$ac_compile"
11882case "(($ac_try" in
11883 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11884 *) ac_try_echo=$ac_try;;
11885esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011886eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011887 (eval "$ac_compile") 2>conftest.er1
11888 ac_status=$?
11889 grep -v '^ *+' conftest.er1 >conftest.err
11890 rm -f conftest.er1
11891 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011892 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011893 (exit $ac_status); } && {
11894 test -z "$ac_c_werror_flag" ||
11895 test ! -s conftest.err
11896 } && test -s conftest.$ac_objext; then
11897 ac_lo=$ac_mid; break
11898else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011899 echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011900sed 's/^/| /' conftest.$ac_ext >&5
11901
11902 ac_hi=`expr '(' $ac_mid ')' - 1`
11903 if test $ac_mid -le $ac_hi; then
11904 ac_lo= ac_hi=
11905 break
11906 fi
11907 ac_mid=`expr 2 '*' $ac_mid`
11908fi
11909
11910rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11911 done
11912else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011913 echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011914sed 's/^/| /' conftest.$ac_ext >&5
11915
11916 ac_lo= ac_hi=
11917fi
11918
11919rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11920fi
11921
11922rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11923# Binary search between lo and hi bounds.
11924while test "x$ac_lo" != "x$ac_hi"; do
11925 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
11926 cat >conftest.$ac_ext <<_ACEOF
11927/* confdefs.h. */
11928_ACEOF
11929cat confdefs.h >>conftest.$ac_ext
11930cat >>conftest.$ac_ext <<_ACEOF
11931/* end confdefs.h. */
11932$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011933 typedef long double ac__type_sizeof_;
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011934int
11935main ()
11936{
Ronald Oussoren450d5612009-06-08 21:12:41 +000011937static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011938test_array [0] = 0
11939
11940 ;
11941 return 0;
11942}
11943_ACEOF
11944rm -f conftest.$ac_objext
11945if { (ac_try="$ac_compile"
11946case "(($ac_try" in
11947 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11948 *) ac_try_echo=$ac_try;;
11949esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000011950eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011951 (eval "$ac_compile") 2>conftest.er1
11952 ac_status=$?
11953 grep -v '^ *+' conftest.er1 >conftest.err
11954 rm -f conftest.er1
11955 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011956 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011957 (exit $ac_status); } && {
11958 test -z "$ac_c_werror_flag" ||
11959 test ! -s conftest.err
11960 } && test -s conftest.$ac_objext; then
11961 ac_hi=$ac_mid
11962else
Ronald Oussoren450d5612009-06-08 21:12:41 +000011963 echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011964sed 's/^/| /' conftest.$ac_ext >&5
11965
11966 ac_lo=`expr '(' $ac_mid ')' + 1`
11967fi
11968
11969rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11970done
11971case $ac_lo in
11972?*) ac_cv_sizeof_long_double=$ac_lo;;
11973'') if test "$ac_cv_type_long_double" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000011974 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011975See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000011976echo "$as_me: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011977See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000011978 { (exit 77); exit 77; }; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011979 else
11980 ac_cv_sizeof_long_double=0
11981 fi ;;
11982esac
11983else
11984 cat >conftest.$ac_ext <<_ACEOF
11985/* confdefs.h. */
11986_ACEOF
11987cat confdefs.h >>conftest.$ac_ext
11988cat >>conftest.$ac_ext <<_ACEOF
11989/* end confdefs.h. */
11990$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000011991 typedef long double ac__type_sizeof_;
11992static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
11993static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000011994#include <stdio.h>
11995#include <stdlib.h>
11996int
11997main ()
11998{
11999
12000 FILE *f = fopen ("conftest.val", "w");
12001 if (! f)
12002 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012003 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012004 {
12005 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000012006 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012007 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012008 fprintf (f, "%ld\n", i);
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012009 }
12010 else
12011 {
12012 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000012013 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012014 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012015 fprintf (f, "%lu\n", i);
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012016 }
12017 return ferror (f) || fclose (f) != 0;
12018
12019 ;
12020 return 0;
12021}
12022_ACEOF
12023rm -f conftest$ac_exeext
12024if { (ac_try="$ac_link"
12025case "(($ac_try" in
12026 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12027 *) ac_try_echo=$ac_try;;
12028esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012029eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012030 (eval "$ac_link") 2>&5
12031 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000012032 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012033 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12034 { (case "(($ac_try" in
12035 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12036 *) ac_try_echo=$ac_try;;
12037esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012038eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012039 (eval "$ac_try") 2>&5
12040 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000012041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012042 (exit $ac_status); }; }; then
12043 ac_cv_sizeof_long_double=`cat conftest.val`
12044else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012045 echo "$as_me: program exited with status $ac_status" >&5
12046echo "$as_me: failed program was:" >&5
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012047sed 's/^/| /' conftest.$ac_ext >&5
12048
12049( exit $ac_status )
12050if test "$ac_cv_type_long_double" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012051 { { echo "$as_me:$LINENO: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012052See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012053echo "$as_me: error: cannot compute sizeof (long double)
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012054See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000012055 { (exit 77); exit 77; }; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012056 else
12057 ac_cv_sizeof_long_double=0
12058 fi
12059fi
12060rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12061fi
12062rm -f conftest.val
12063fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000012064{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_double" >&5
12065echo "${ECHO_T}$ac_cv_sizeof_long_double" >&6; }
Mark Dickinsondc1688a2008-06-27 22:20:14 +000012066
12067
12068
12069cat >>confdefs.h <<_ACEOF
12070#define SIZEOF_LONG_DOUBLE $ac_cv_sizeof_long_double
12071_ACEOF
12072
12073
12074fi
12075
Ronald Oussoren450d5612009-06-08 21:12:41 +000012076{ echo "$as_me:$LINENO: checking for _Bool support" >&5
12077echo $ECHO_N "checking for _Bool support... $ECHO_C" >&6; }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012078have_c99_bool=no
12079cat >conftest.$ac_ext <<_ACEOF
12080/* confdefs.h. */
12081_ACEOF
12082cat confdefs.h >>conftest.$ac_ext
12083cat >>conftest.$ac_ext <<_ACEOF
12084/* end confdefs.h. */
12085
12086int
12087main ()
12088{
12089_Bool x; x = (_Bool)0;
12090 ;
12091 return 0;
12092}
12093_ACEOF
12094rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012095if { (ac_try="$ac_compile"
12096case "(($ac_try" in
12097 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12098 *) ac_try_echo=$ac_try;;
12099esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012100eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012101 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012102 ac_status=$?
12103 grep -v '^ *+' conftest.er1 >conftest.err
12104 rm -f conftest.er1
12105 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012106 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012107 (exit $ac_status); } && {
12108 test -z "$ac_c_werror_flag" ||
12109 test ! -s conftest.err
12110 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012111
12112
12113cat >>confdefs.h <<\_ACEOF
12114#define HAVE_C99_BOOL 1
12115_ACEOF
12116
12117 have_c99_bool=yes
12118
12119else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012120 echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012121sed 's/^/| /' conftest.$ac_ext >&5
12122
Martin v. Löwiseba40652007-08-30 20:10:57 +000012123
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012124fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012125
12126rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000012127{ echo "$as_me:$LINENO: result: $have_c99_bool" >&5
12128echo "${ECHO_T}$have_c99_bool" >&6; }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012129if test "$have_c99_bool" = yes ; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012130{ echo "$as_me:$LINENO: checking for _Bool" >&5
12131echo $ECHO_N "checking for _Bool... $ECHO_C" >&6; }
12132if test "${ac_cv_type__Bool+set}" = set; then
12133 echo $ECHO_N "(cached) $ECHO_C" >&6
12134else
12135 cat >conftest.$ac_ext <<_ACEOF
12136/* confdefs.h. */
12137_ACEOF
12138cat confdefs.h >>conftest.$ac_ext
12139cat >>conftest.$ac_ext <<_ACEOF
12140/* end confdefs.h. */
12141$ac_includes_default
12142typedef _Bool ac__type_new_;
12143int
12144main ()
12145{
12146if ((ac__type_new_ *) 0)
12147 return 0;
12148if (sizeof (ac__type_new_))
12149 return 0;
12150 ;
12151 return 0;
12152}
12153_ACEOF
12154rm -f conftest.$ac_objext
12155if { (ac_try="$ac_compile"
12156case "(($ac_try" in
12157 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12158 *) ac_try_echo=$ac_try;;
12159esac
12160eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12161 (eval "$ac_compile") 2>conftest.er1
12162 ac_status=$?
12163 grep -v '^ *+' conftest.er1 >conftest.err
12164 rm -f conftest.er1
12165 cat conftest.err >&5
12166 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12167 (exit $ac_status); } && {
12168 test -z "$ac_c_werror_flag" ||
12169 test ! -s conftest.err
12170 } && test -s conftest.$ac_objext; then
12171 ac_cv_type__Bool=yes
12172else
12173 echo "$as_me: failed program was:" >&5
12174sed 's/^/| /' conftest.$ac_ext >&5
12175
12176 ac_cv_type__Bool=no
12177fi
12178
12179rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12180fi
12181{ echo "$as_me:$LINENO: result: $ac_cv_type__Bool" >&5
12182echo "${ECHO_T}$ac_cv_type__Bool" >&6; }
12183
Martin v. Löwiseba40652007-08-30 20:10:57 +000012184# The cast to long int works around a bug in the HP C Compiler
12185# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12186# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12187# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000012188{ echo "$as_me:$LINENO: checking size of _Bool" >&5
12189echo $ECHO_N "checking size of _Bool... $ECHO_C" >&6; }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012190if test "${ac_cv_sizeof__Bool+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012191 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012192else
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012193 if test "$cross_compiling" = yes; then
12194 # Depending upon the size, compute the lo and hi bounds.
12195cat >conftest.$ac_ext <<_ACEOF
12196/* confdefs.h. */
12197_ACEOF
12198cat confdefs.h >>conftest.$ac_ext
12199cat >>conftest.$ac_ext <<_ACEOF
12200/* end confdefs.h. */
12201$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012202 typedef _Bool ac__type_sizeof_;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012203int
12204main ()
12205{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012206static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012207test_array [0] = 0
12208
12209 ;
12210 return 0;
12211}
12212_ACEOF
12213rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012214if { (ac_try="$ac_compile"
12215case "(($ac_try" in
12216 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12217 *) ac_try_echo=$ac_try;;
12218esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012219eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012220 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012221 ac_status=$?
12222 grep -v '^ *+' conftest.er1 >conftest.err
12223 rm -f conftest.er1
12224 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012226 (exit $ac_status); } && {
12227 test -z "$ac_c_werror_flag" ||
12228 test ! -s conftest.err
12229 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012230 ac_lo=0 ac_mid=0
12231 while :; do
12232 cat >conftest.$ac_ext <<_ACEOF
12233/* confdefs.h. */
12234_ACEOF
12235cat confdefs.h >>conftest.$ac_ext
12236cat >>conftest.$ac_ext <<_ACEOF
12237/* end confdefs.h. */
12238$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012239 typedef _Bool ac__type_sizeof_;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012240int
12241main ()
12242{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012243static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012244test_array [0] = 0
12245
12246 ;
12247 return 0;
12248}
12249_ACEOF
12250rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012251if { (ac_try="$ac_compile"
12252case "(($ac_try" in
12253 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12254 *) ac_try_echo=$ac_try;;
12255esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012256eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012257 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012258 ac_status=$?
12259 grep -v '^ *+' conftest.er1 >conftest.err
12260 rm -f conftest.er1
12261 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012262 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012263 (exit $ac_status); } && {
12264 test -z "$ac_c_werror_flag" ||
12265 test ! -s conftest.err
12266 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012267 ac_hi=$ac_mid; break
12268else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012269 echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012270sed 's/^/| /' conftest.$ac_ext >&5
12271
Martin v. Löwiseba40652007-08-30 20:10:57 +000012272 ac_lo=`expr $ac_mid + 1`
12273 if test $ac_lo -le $ac_mid; then
12274 ac_lo= ac_hi=
12275 break
12276 fi
12277 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012278fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012279
12280rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012281 done
12282else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012283 echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012284sed 's/^/| /' conftest.$ac_ext >&5
12285
Martin v. Löwiseba40652007-08-30 20:10:57 +000012286 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012287/* confdefs.h. */
12288_ACEOF
12289cat confdefs.h >>conftest.$ac_ext
12290cat >>conftest.$ac_ext <<_ACEOF
12291/* end confdefs.h. */
12292$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012293 typedef _Bool ac__type_sizeof_;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012294int
12295main ()
12296{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012297static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012298test_array [0] = 0
12299
12300 ;
12301 return 0;
12302}
12303_ACEOF
12304rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012305if { (ac_try="$ac_compile"
12306case "(($ac_try" in
12307 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12308 *) ac_try_echo=$ac_try;;
12309esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012310eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012311 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012312 ac_status=$?
12313 grep -v '^ *+' conftest.er1 >conftest.err
12314 rm -f conftest.er1
12315 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012316 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012317 (exit $ac_status); } && {
12318 test -z "$ac_c_werror_flag" ||
12319 test ! -s conftest.err
12320 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012321 ac_hi=-1 ac_mid=-1
12322 while :; do
12323 cat >conftest.$ac_ext <<_ACEOF
12324/* confdefs.h. */
12325_ACEOF
12326cat confdefs.h >>conftest.$ac_ext
12327cat >>conftest.$ac_ext <<_ACEOF
12328/* end confdefs.h. */
12329$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012330 typedef _Bool ac__type_sizeof_;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012331int
12332main ()
12333{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012334static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012335test_array [0] = 0
12336
12337 ;
12338 return 0;
12339}
12340_ACEOF
12341rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012342if { (ac_try="$ac_compile"
12343case "(($ac_try" in
12344 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12345 *) ac_try_echo=$ac_try;;
12346esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012347eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012348 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012349 ac_status=$?
12350 grep -v '^ *+' conftest.er1 >conftest.err
12351 rm -f conftest.er1
12352 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012353 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012354 (exit $ac_status); } && {
12355 test -z "$ac_c_werror_flag" ||
12356 test ! -s conftest.err
12357 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012358 ac_lo=$ac_mid; break
12359else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012360 echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012361sed 's/^/| /' conftest.$ac_ext >&5
12362
Martin v. Löwiseba40652007-08-30 20:10:57 +000012363 ac_hi=`expr '(' $ac_mid ')' - 1`
12364 if test $ac_mid -le $ac_hi; then
12365 ac_lo= ac_hi=
12366 break
12367 fi
12368 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012369fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012370
12371rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012372 done
12373else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012374 echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012375sed 's/^/| /' conftest.$ac_ext >&5
12376
Martin v. Löwiseba40652007-08-30 20:10:57 +000012377 ac_lo= ac_hi=
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012378fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012379
12380rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012381fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012382
12383rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012384# Binary search between lo and hi bounds.
12385while test "x$ac_lo" != "x$ac_hi"; do
12386 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
12387 cat >conftest.$ac_ext <<_ACEOF
12388/* confdefs.h. */
12389_ACEOF
12390cat confdefs.h >>conftest.$ac_ext
12391cat >>conftest.$ac_ext <<_ACEOF
12392/* end confdefs.h. */
12393$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012394 typedef _Bool ac__type_sizeof_;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012395int
12396main ()
12397{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012398static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012399test_array [0] = 0
12400
12401 ;
12402 return 0;
12403}
12404_ACEOF
12405rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012406if { (ac_try="$ac_compile"
12407case "(($ac_try" in
12408 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12409 *) ac_try_echo=$ac_try;;
12410esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012411eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012412 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012413 ac_status=$?
12414 grep -v '^ *+' conftest.er1 >conftest.err
12415 rm -f conftest.er1
12416 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012417 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012418 (exit $ac_status); } && {
12419 test -z "$ac_c_werror_flag" ||
12420 test ! -s conftest.err
12421 } && test -s conftest.$ac_objext; then
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012422 ac_hi=$ac_mid
12423else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012424 echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012425sed 's/^/| /' conftest.$ac_ext >&5
12426
Martin v. Löwiseba40652007-08-30 20:10:57 +000012427 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012428fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012429
12430rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012431done
12432case $ac_lo in
12433?*) ac_cv_sizeof__Bool=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000012434'') if test "$ac_cv_type__Bool" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012435 { { echo "$as_me:$LINENO: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012436See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012437echo "$as_me: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012438See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000012439 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012440 else
12441 ac_cv_sizeof__Bool=0
12442 fi ;;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012443esac
12444else
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012445 cat >conftest.$ac_ext <<_ACEOF
12446/* confdefs.h. */
12447_ACEOF
12448cat confdefs.h >>conftest.$ac_ext
12449cat >>conftest.$ac_ext <<_ACEOF
12450/* end confdefs.h. */
12451$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012452 typedef _Bool ac__type_sizeof_;
12453static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
12454static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012455#include <stdio.h>
12456#include <stdlib.h>
12457int
12458main ()
12459{
12460
12461 FILE *f = fopen ("conftest.val", "w");
12462 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000012463 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012464 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012465 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000012466 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000012467 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000012468 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012469 fprintf (f, "%ld\n", i);
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012470 }
12471 else
12472 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000012473 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000012474 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000012475 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012476 fprintf (f, "%lu\n", i);
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012477 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012478 return ferror (f) || fclose (f) != 0;
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012479
12480 ;
12481 return 0;
12482}
12483_ACEOF
12484rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012485if { (ac_try="$ac_link"
12486case "(($ac_try" in
12487 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12488 *) ac_try_echo=$ac_try;;
12489esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012490eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012491 (eval "$ac_link") 2>&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012492 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000012493 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012494 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000012495 { (case "(($ac_try" in
12496 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12497 *) ac_try_echo=$ac_try;;
12498esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012499eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012500 (eval "$ac_try") 2>&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012501 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000012502 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012503 (exit $ac_status); }; }; then
12504 ac_cv_sizeof__Bool=`cat conftest.val`
12505else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012506 echo "$as_me: program exited with status $ac_status" >&5
12507echo "$as_me: failed program was:" >&5
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012508sed 's/^/| /' conftest.$ac_ext >&5
12509
12510( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000012511if test "$ac_cv_type__Bool" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012512 { { echo "$as_me:$LINENO: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012513See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012514echo "$as_me: error: cannot compute sizeof (_Bool)
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012515See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000012516 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012517 else
12518 ac_cv_sizeof__Bool=0
12519 fi
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012520fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012521rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012522fi
12523rm -f conftest.val
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012524fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000012525{ echo "$as_me:$LINENO: result: $ac_cv_sizeof__Bool" >&5
12526echo "${ECHO_T}$ac_cv_sizeof__Bool" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012527
12528
12529
Martin v. Löwisaef4c6b2007-01-21 09:33:07 +000012530cat >>confdefs.h <<_ACEOF
12531#define SIZEOF__BOOL $ac_cv_sizeof__Bool
12532_ACEOF
12533
12534
12535fi
12536
Ronald Oussoren450d5612009-06-08 21:12:41 +000012537{ echo "$as_me:$LINENO: checking for uintptr_t" >&5
12538echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6; }
Martin v. Löwisebe26702006-10-02 14:55:51 +000012539if test "${ac_cv_type_uintptr_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012540 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisebe26702006-10-02 14:55:51 +000012541else
12542 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012543/* confdefs.h. */
12544_ACEOF
12545cat confdefs.h >>conftest.$ac_ext
12546cat >>conftest.$ac_ext <<_ACEOF
12547/* end confdefs.h. */
Martin v. Löwis40e9aed2006-10-02 15:20:37 +000012548#ifdef HAVE_STDINT_H
12549 #include <stdint.h>
12550 #endif
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012551
Ronald Oussoren450d5612009-06-08 21:12:41 +000012552typedef uintptr_t ac__type_new_;
Martin v. Löwis11437992002-04-12 09:54:03 +000012553int
12554main ()
12555{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012556if ((ac__type_new_ *) 0)
12557 return 0;
12558if (sizeof (ac__type_new_))
12559 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000012560 ;
12561 return 0;
12562}
12563_ACEOF
12564rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012565if { (ac_try="$ac_compile"
12566case "(($ac_try" in
12567 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12568 *) ac_try_echo=$ac_try;;
12569esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012570eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012571 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012572 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012573 grep -v '^ *+' conftest.er1 >conftest.err
12574 rm -f conftest.er1
12575 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012576 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012577 (exit $ac_status); } && {
12578 test -z "$ac_c_werror_flag" ||
12579 test ! -s conftest.err
12580 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012581 ac_cv_type_uintptr_t=yes
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012582else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012583 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012584sed 's/^/| /' conftest.$ac_ext >&5
12585
Ronald Oussoren450d5612009-06-08 21:12:41 +000012586 ac_cv_type_uintptr_t=no
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012587fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012588
12589rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebe26702006-10-02 14:55:51 +000012590fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000012591{ echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
12592echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6; }
12593if test $ac_cv_type_uintptr_t = yes; then
Martin v. Löwisebe26702006-10-02 14:55:51 +000012594
12595cat >>confdefs.h <<_ACEOF
12596#define HAVE_UINTPTR_T 1
12597_ACEOF
12598
Ronald Oussoren450d5612009-06-08 21:12:41 +000012599{ echo "$as_me:$LINENO: checking for uintptr_t" >&5
12600echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6; }
12601if test "${ac_cv_type_uintptr_t+set}" = set; then
12602 echo $ECHO_N "(cached) $ECHO_C" >&6
12603else
12604 cat >conftest.$ac_ext <<_ACEOF
12605/* confdefs.h. */
12606_ACEOF
12607cat confdefs.h >>conftest.$ac_ext
12608cat >>conftest.$ac_ext <<_ACEOF
12609/* end confdefs.h. */
12610$ac_includes_default
12611typedef uintptr_t ac__type_new_;
12612int
12613main ()
12614{
12615if ((ac__type_new_ *) 0)
12616 return 0;
12617if (sizeof (ac__type_new_))
12618 return 0;
12619 ;
12620 return 0;
12621}
12622_ACEOF
12623rm -f conftest.$ac_objext
12624if { (ac_try="$ac_compile"
12625case "(($ac_try" in
12626 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12627 *) ac_try_echo=$ac_try;;
12628esac
12629eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12630 (eval "$ac_compile") 2>conftest.er1
12631 ac_status=$?
12632 grep -v '^ *+' conftest.er1 >conftest.err
12633 rm -f conftest.er1
12634 cat conftest.err >&5
12635 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12636 (exit $ac_status); } && {
12637 test -z "$ac_c_werror_flag" ||
12638 test ! -s conftest.err
12639 } && test -s conftest.$ac_objext; then
12640 ac_cv_type_uintptr_t=yes
12641else
12642 echo "$as_me: failed program was:" >&5
12643sed 's/^/| /' conftest.$ac_ext >&5
12644
12645 ac_cv_type_uintptr_t=no
12646fi
12647
12648rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12649fi
12650{ echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
12651echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6; }
12652
Martin v. Löwiseba40652007-08-30 20:10:57 +000012653# The cast to long int works around a bug in the HP C Compiler
12654# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
12655# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
12656# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000012657{ echo "$as_me:$LINENO: checking size of uintptr_t" >&5
12658echo $ECHO_N "checking size of uintptr_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000012659if test "${ac_cv_sizeof_uintptr_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012660 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000012661else
Martin v. Löwis11437992002-04-12 09:54:03 +000012662 if test "$cross_compiling" = yes; then
12663 # Depending upon the size, compute the lo and hi bounds.
12664cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012665/* confdefs.h. */
12666_ACEOF
12667cat confdefs.h >>conftest.$ac_ext
12668cat >>conftest.$ac_ext <<_ACEOF
12669/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012670$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012671 typedef uintptr_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000012672int
12673main ()
12674{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012675static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012676test_array [0] = 0
12677
12678 ;
12679 return 0;
12680}
12681_ACEOF
12682rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012683if { (ac_try="$ac_compile"
12684case "(($ac_try" in
12685 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12686 *) ac_try_echo=$ac_try;;
12687esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012688eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012689 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012690 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012691 grep -v '^ *+' conftest.er1 >conftest.err
12692 rm -f conftest.er1
12693 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012694 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012695 (exit $ac_status); } && {
12696 test -z "$ac_c_werror_flag" ||
12697 test ! -s conftest.err
12698 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012699 ac_lo=0 ac_mid=0
12700 while :; do
12701 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012702/* confdefs.h. */
12703_ACEOF
12704cat confdefs.h >>conftest.$ac_ext
12705cat >>conftest.$ac_ext <<_ACEOF
12706/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012707$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012708 typedef uintptr_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000012709int
12710main ()
12711{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012712static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012713test_array [0] = 0
12714
12715 ;
12716 return 0;
12717}
12718_ACEOF
12719rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012720if { (ac_try="$ac_compile"
12721case "(($ac_try" in
12722 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12723 *) ac_try_echo=$ac_try;;
12724esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012725eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012726 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012727 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012728 grep -v '^ *+' conftest.er1 >conftest.err
12729 rm -f conftest.er1
12730 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012731 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012732 (exit $ac_status); } && {
12733 test -z "$ac_c_werror_flag" ||
12734 test ! -s conftest.err
12735 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012736 ac_hi=$ac_mid; break
12737else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012738 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012739sed 's/^/| /' conftest.$ac_ext >&5
12740
Martin v. Löwiseba40652007-08-30 20:10:57 +000012741 ac_lo=`expr $ac_mid + 1`
12742 if test $ac_lo -le $ac_mid; then
12743 ac_lo= ac_hi=
12744 break
12745 fi
12746 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000012747fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012748
12749rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012750 done
12751else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012752 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012753sed 's/^/| /' conftest.$ac_ext >&5
12754
Martin v. Löwiseba40652007-08-30 20:10:57 +000012755 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012756/* confdefs.h. */
12757_ACEOF
12758cat confdefs.h >>conftest.$ac_ext
12759cat >>conftest.$ac_ext <<_ACEOF
12760/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012761$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012762 typedef uintptr_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000012763int
12764main ()
12765{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012766static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012767test_array [0] = 0
12768
12769 ;
12770 return 0;
12771}
12772_ACEOF
12773rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012774if { (ac_try="$ac_compile"
12775case "(($ac_try" in
12776 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12777 *) ac_try_echo=$ac_try;;
12778esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012779eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012780 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012781 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012782 grep -v '^ *+' conftest.er1 >conftest.err
12783 rm -f conftest.er1
12784 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012785 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012786 (exit $ac_status); } && {
12787 test -z "$ac_c_werror_flag" ||
12788 test ! -s conftest.err
12789 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012790 ac_hi=-1 ac_mid=-1
12791 while :; do
12792 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012793/* confdefs.h. */
12794_ACEOF
12795cat confdefs.h >>conftest.$ac_ext
12796cat >>conftest.$ac_ext <<_ACEOF
12797/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012798$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012799 typedef uintptr_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000012800int
12801main ()
12802{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012803static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012804test_array [0] = 0
12805
12806 ;
12807 return 0;
12808}
12809_ACEOF
12810rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012811if { (ac_try="$ac_compile"
12812case "(($ac_try" in
12813 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12814 *) ac_try_echo=$ac_try;;
12815esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012816eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012817 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012818 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012819 grep -v '^ *+' conftest.er1 >conftest.err
12820 rm -f conftest.er1
12821 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012822 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012823 (exit $ac_status); } && {
12824 test -z "$ac_c_werror_flag" ||
12825 test ! -s conftest.err
12826 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012827 ac_lo=$ac_mid; break
12828else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012829 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012830sed 's/^/| /' conftest.$ac_ext >&5
12831
Martin v. Löwiseba40652007-08-30 20:10:57 +000012832 ac_hi=`expr '(' $ac_mid ')' - 1`
12833 if test $ac_mid -le $ac_hi; then
12834 ac_lo= ac_hi=
12835 break
12836 fi
12837 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000012838fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012839
12840rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012841 done
12842else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012843 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012844sed 's/^/| /' conftest.$ac_ext >&5
12845
Martin v. Löwiseba40652007-08-30 20:10:57 +000012846 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000012847fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012848
12849rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012850fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012851
12852rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012853# Binary search between lo and hi bounds.
12854while test "x$ac_lo" != "x$ac_hi"; do
12855 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
12856 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012857/* confdefs.h. */
12858_ACEOF
12859cat confdefs.h >>conftest.$ac_ext
12860cat >>conftest.$ac_ext <<_ACEOF
12861/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012862$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012863 typedef uintptr_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000012864int
12865main ()
12866{
Ronald Oussoren450d5612009-06-08 21:12:41 +000012867static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000012868test_array [0] = 0
12869
12870 ;
12871 return 0;
12872}
12873_ACEOF
12874rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012875if { (ac_try="$ac_compile"
12876case "(($ac_try" in
12877 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12878 *) ac_try_echo=$ac_try;;
12879esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012880eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012881 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000012882 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000012883 grep -v '^ *+' conftest.er1 >conftest.err
12884 rm -f conftest.er1
12885 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012886 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012887 (exit $ac_status); } && {
12888 test -z "$ac_c_werror_flag" ||
12889 test ! -s conftest.err
12890 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000012891 ac_hi=$ac_mid
12892else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012893 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012894sed 's/^/| /' conftest.$ac_ext >&5
12895
Martin v. Löwiseba40652007-08-30 20:10:57 +000012896 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000012897fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012898
12899rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012900done
12901case $ac_lo in
12902?*) ac_cv_sizeof_uintptr_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000012903'') if test "$ac_cv_type_uintptr_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012904 { { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000012905See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012906echo "$as_me: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000012907See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000012908 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012909 else
12910 ac_cv_sizeof_uintptr_t=0
12911 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000012912esac
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012913else
Martin v. Löwis11437992002-04-12 09:54:03 +000012914 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000012915/* confdefs.h. */
12916_ACEOF
12917cat confdefs.h >>conftest.$ac_ext
12918cat >>conftest.$ac_ext <<_ACEOF
12919/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000012920$ac_includes_default
Ronald Oussoren450d5612009-06-08 21:12:41 +000012921 typedef uintptr_t ac__type_sizeof_;
12922static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
12923static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000012924#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012925#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000012926int
12927main ()
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012928{
Martin v. Löwis11437992002-04-12 09:54:03 +000012929
12930 FILE *f = fopen ("conftest.val", "w");
12931 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000012932 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012933 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000012934 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000012935 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000012936 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000012937 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012938 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000012939 }
12940 else
12941 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000012942 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000012943 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000012944 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000012945 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000012946 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012947 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000012948
12949 ;
12950 return 0;
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012951}
Martin v. Löwis11437992002-04-12 09:54:03 +000012952_ACEOF
12953rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000012954if { (ac_try="$ac_link"
12955case "(($ac_try" in
12956 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12957 *) ac_try_echo=$ac_try;;
12958esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012959eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012960 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012961 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000012962 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012963 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000012964 { (case "(($ac_try" in
12965 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12966 *) ac_try_echo=$ac_try;;
12967esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000012968eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000012969 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012970 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000012971 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000012972 (exit $ac_status); }; }; then
12973 ac_cv_sizeof_uintptr_t=`cat conftest.val`
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012974else
Ronald Oussoren450d5612009-06-08 21:12:41 +000012975 echo "$as_me: program exited with status $ac_status" >&5
12976echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000012977sed 's/^/| /' conftest.$ac_ext >&5
12978
Martin v. Löwis11437992002-04-12 09:54:03 +000012979( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000012980if test "$ac_cv_type_uintptr_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000012981 { { echo "$as_me:$LINENO: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000012982See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000012983echo "$as_me: error: cannot compute sizeof (uintptr_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000012984See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000012985 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012986 else
12987 ac_cv_sizeof_uintptr_t=0
12988 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000012989fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000012990rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000012991fi
12992rm -f conftest.val
Barry Warsawbc7c7f92000-08-18 04:53:33 +000012993fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000012994{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_uintptr_t" >&5
12995echo "${ECHO_T}$ac_cv_sizeof_uintptr_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000012996
12997
12998
Martin v. Löwis11437992002-04-12 09:54:03 +000012999cat >>confdefs.h <<_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013000#define SIZEOF_UINTPTR_T $ac_cv_sizeof_uintptr_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013001_ACEOF
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013002
Michael W. Hudson54241132001-12-07 15:38:26 +000013003
Barry Warsawbc7c7f92000-08-18 04:53:33 +000013004fi
13005
Martin v. Löwisebe26702006-10-02 14:55:51 +000013006
13007
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013008# Hmph. AC_CHECK_SIZEOF() doesn't include <sys/types.h>.
Ronald Oussoren450d5612009-06-08 21:12:41 +000013009{ echo "$as_me:$LINENO: checking size of off_t" >&5
13010echo $ECHO_N "checking size of off_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013011if test "${ac_cv_sizeof_off_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013012 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013013else
13014 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000013015 ac_cv_sizeof_off_t=4
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013016else
Martin v. Löwis11437992002-04-12 09:54:03 +000013017 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013018/* confdefs.h. */
13019_ACEOF
13020cat confdefs.h >>conftest.$ac_ext
13021cat >>conftest.$ac_ext <<_ACEOF
13022/* end confdefs.h. */
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013023#include <stdio.h>
13024#include <sys/types.h>
13025main()
13026{
13027 FILE *f=fopen("conftestval", "w");
13028 if (!f) exit(1);
13029 fprintf(f, "%d\n", sizeof(off_t));
13030 exit(0);
13031}
Martin v. Löwis11437992002-04-12 09:54:03 +000013032_ACEOF
13033rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013034if { (ac_try="$ac_link"
13035case "(($ac_try" in
13036 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13037 *) ac_try_echo=$ac_try;;
13038esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013039eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013040 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013041 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000013042 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013043 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013044 { (case "(($ac_try" in
13045 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13046 *) ac_try_echo=$ac_try;;
13047esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013048eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013049 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013050 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000013051 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013052 (exit $ac_status); }; }; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013053 ac_cv_sizeof_off_t=`cat conftestval`
13054else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013055 echo "$as_me: program exited with status $ac_status" >&5
13056echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013057sed 's/^/| /' conftest.$ac_ext >&5
13058
Martin v. Löwis11437992002-04-12 09:54:03 +000013059( exit $ac_status )
13060ac_cv_sizeof_off_t=0
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013061fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013062rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013063fi
13064
Martin v. Löwiseba40652007-08-30 20:10:57 +000013065
13066
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013067fi
13068
Ronald Oussoren450d5612009-06-08 21:12:41 +000013069{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
13070echo "${ECHO_T}$ac_cv_sizeof_off_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013071
13072cat >>confdefs.h <<_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013073#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013074_ACEOF
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013075
Michael W. Hudson54241132001-12-07 15:38:26 +000013076
Ronald Oussoren450d5612009-06-08 21:12:41 +000013077{ echo "$as_me:$LINENO: checking whether to enable large file support" >&5
13078echo $ECHO_N "checking whether to enable large file support... $ECHO_C" >&6; }
Guido van Rossum96f2eb91999-04-10 16:02:18 +000013079if test "$have_long_long" = yes -a \
13080 "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
13081 "$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013082
Martin v. Löwis11437992002-04-12 09:54:03 +000013083cat >>confdefs.h <<\_ACEOF
13084#define HAVE_LARGEFILE_SUPPORT 1
13085_ACEOF
13086
Ronald Oussoren450d5612009-06-08 21:12:41 +000013087 { echo "$as_me:$LINENO: result: yes" >&5
13088echo "${ECHO_T}yes" >&6; }
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013089else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013090 { echo "$as_me:$LINENO: result: no" >&5
13091echo "${ECHO_T}no" >&6; }
Guido van Rossumf98e2a71999-01-06 18:53:34 +000013092fi
13093
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013094# AC_CHECK_SIZEOF() doesn't include <time.h>.
Ronald Oussoren450d5612009-06-08 21:12:41 +000013095{ echo "$as_me:$LINENO: checking size of time_t" >&5
13096echo $ECHO_N "checking size of time_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013097if test "${ac_cv_sizeof_time_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013098 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013099else
13100 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000013101 ac_cv_sizeof_time_t=4
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013102else
Martin v. Löwis11437992002-04-12 09:54:03 +000013103 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013104/* confdefs.h. */
13105_ACEOF
13106cat confdefs.h >>conftest.$ac_ext
13107cat >>conftest.$ac_ext <<_ACEOF
13108/* end confdefs.h. */
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013109#include <stdio.h>
13110#include <time.h>
13111main()
13112{
13113 FILE *f=fopen("conftestval", "w");
13114 if (!f) exit(1);
13115 fprintf(f, "%d\n", sizeof(time_t));
13116 exit(0);
13117}
Martin v. Löwis11437992002-04-12 09:54:03 +000013118_ACEOF
13119rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013120if { (ac_try="$ac_link"
13121case "(($ac_try" in
13122 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13123 *) ac_try_echo=$ac_try;;
13124esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013125eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013126 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013127 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000013128 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013129 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013130 { (case "(($ac_try" in
13131 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13132 *) ac_try_echo=$ac_try;;
13133esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013134eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013135 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013136 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000013137 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013138 (exit $ac_status); }; }; then
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013139 ac_cv_sizeof_time_t=`cat conftestval`
13140else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013141 echo "$as_me: program exited with status $ac_status" >&5
13142echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013143sed 's/^/| /' conftest.$ac_ext >&5
13144
Martin v. Löwis11437992002-04-12 09:54:03 +000013145( exit $ac_status )
13146ac_cv_sizeof_time_t=0
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013147fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013148rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013149fi
13150
Martin v. Löwiseba40652007-08-30 20:10:57 +000013151
13152
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013153fi
13154
Ronald Oussoren450d5612009-06-08 21:12:41 +000013155{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5
13156echo "${ECHO_T}$ac_cv_sizeof_time_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013157
13158cat >>confdefs.h <<_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013159#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013160_ACEOF
Guido van Rossumb9a22a12000-06-30 02:48:53 +000013161
Michael W. Hudson54241132001-12-07 15:38:26 +000013162
13163
Trent Mick635f6fb2000-08-23 21:33:05 +000013164# if have pthread_t then define SIZEOF_PTHREAD_T
Martin v. Löwis123cbd22001-07-19 14:21:10 +000013165ac_save_cc="$CC"
13166if test "$ac_cv_kpthread" = "yes"
13167then CC="$CC -Kpthread"
Martin v. Löwis5f433f02003-05-05 05:05:30 +000013168elif test "$ac_cv_kthread" = "yes"
13169then CC="$CC -Kthread"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000013170elif test "$ac_cv_pthread" = "yes"
13171then CC="$CC -pthread"
Martin v. Löwis123cbd22001-07-19 14:21:10 +000013172fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013173{ echo "$as_me:$LINENO: checking for pthread_t" >&5
13174echo $ECHO_N "checking for pthread_t... $ECHO_C" >&6; }
Trent Mick635f6fb2000-08-23 21:33:05 +000013175have_pthread_t=no
Martin v. Löwis11437992002-04-12 09:54:03 +000013176cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013177/* confdefs.h. */
13178_ACEOF
13179cat confdefs.h >>conftest.$ac_ext
13180cat >>conftest.$ac_ext <<_ACEOF
13181/* end confdefs.h. */
Trent Mick635f6fb2000-08-23 21:33:05 +000013182#include <pthread.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000013183int
13184main ()
13185{
Guido van Rossum12580492000-09-24 16:47:19 +000013186pthread_t x; x = *(pthread_t*)0;
Martin v. Löwis11437992002-04-12 09:54:03 +000013187 ;
13188 return 0;
13189}
13190_ACEOF
13191rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013192if { (ac_try="$ac_compile"
13193case "(($ac_try" in
13194 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13195 *) ac_try_echo=$ac_try;;
13196esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013197eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013198 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013199 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013200 grep -v '^ *+' conftest.er1 >conftest.err
13201 rm -f conftest.er1
13202 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000013203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013204 (exit $ac_status); } && {
13205 test -z "$ac_c_werror_flag" ||
13206 test ! -s conftest.err
13207 } && test -s conftest.$ac_objext; then
Trent Mick635f6fb2000-08-23 21:33:05 +000013208 have_pthread_t=yes
13209else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013210 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013211sed 's/^/| /' conftest.$ac_ext >&5
13212
Martin v. Löwiseba40652007-08-30 20:10:57 +000013213
Trent Mick635f6fb2000-08-23 21:33:05 +000013214fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013215
13216rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000013217{ echo "$as_me:$LINENO: result: $have_pthread_t" >&5
13218echo "${ECHO_T}$have_pthread_t" >&6; }
Trent Mick635f6fb2000-08-23 21:33:05 +000013219if test "$have_pthread_t" = yes ; then
13220 # AC_CHECK_SIZEOF() doesn't include <pthread.h>.
Ronald Oussoren450d5612009-06-08 21:12:41 +000013221 { echo "$as_me:$LINENO: checking size of pthread_t" >&5
13222echo $ECHO_N "checking size of pthread_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013223 if test "${ac_cv_sizeof_pthread_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013224 echo $ECHO_N "(cached) $ECHO_C" >&6
Trent Mick635f6fb2000-08-23 21:33:05 +000013225else
13226 if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000013227 ac_cv_sizeof_pthread_t=4
Trent Mick635f6fb2000-08-23 21:33:05 +000013228else
Martin v. Löwis11437992002-04-12 09:54:03 +000013229 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013230/* confdefs.h. */
13231_ACEOF
13232cat confdefs.h >>conftest.$ac_ext
13233cat >>conftest.$ac_ext <<_ACEOF
13234/* end confdefs.h. */
Trent Mick635f6fb2000-08-23 21:33:05 +000013235#include <stdio.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +000013236#include <pthread.h>
Trent Mick635f6fb2000-08-23 21:33:05 +000013237 main()
13238 {
13239 FILE *f=fopen("conftestval", "w");
13240 if (!f) exit(1);
13241 fprintf(f, "%d\n", sizeof(pthread_t));
13242 exit(0);
13243 }
Martin v. Löwis11437992002-04-12 09:54:03 +000013244_ACEOF
13245rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013246if { (ac_try="$ac_link"
13247case "(($ac_try" in
13248 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13249 *) ac_try_echo=$ac_try;;
13250esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013251eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013252 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013253 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000013254 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013255 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000013256 { (case "(($ac_try" in
13257 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13258 *) ac_try_echo=$ac_try;;
13259esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013260eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013261 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013262 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000013263 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000013264 (exit $ac_status); }; }; then
Trent Mick635f6fb2000-08-23 21:33:05 +000013265 ac_cv_sizeof_pthread_t=`cat conftestval`
13266else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013267 echo "$as_me: program exited with status $ac_status" >&5
13268echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013269sed 's/^/| /' conftest.$ac_ext >&5
13270
Martin v. Löwis11437992002-04-12 09:54:03 +000013271( exit $ac_status )
13272ac_cv_sizeof_pthread_t=0
Trent Mick635f6fb2000-08-23 21:33:05 +000013273fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013274rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Trent Mick635f6fb2000-08-23 21:33:05 +000013275fi
13276
Martin v. Löwiseba40652007-08-30 20:10:57 +000013277
13278
Trent Mick635f6fb2000-08-23 21:33:05 +000013279fi
13280
Ronald Oussoren450d5612009-06-08 21:12:41 +000013281 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_pthread_t" >&5
13282echo "${ECHO_T}$ac_cv_sizeof_pthread_t" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013283
13284cat >>confdefs.h <<_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +000013285#define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
Martin v. Löwis11437992002-04-12 09:54:03 +000013286_ACEOF
Trent Mick635f6fb2000-08-23 21:33:05 +000013287
13288fi
Martin v. Löwis123cbd22001-07-19 14:21:10 +000013289CC="$ac_save_cc"
Trent Mick635f6fb2000-08-23 21:33:05 +000013290
Ronald Oussoren450d5612009-06-08 21:12:41 +000013291{ echo "$as_me:$LINENO: checking for --enable-toolbox-glue" >&5
13292echo $ECHO_N "checking for --enable-toolbox-glue... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000013293# Check whether --enable-toolbox-glue was given.
Jack Jansene578a632001-08-15 01:27:14 +000013294if test "${enable_toolbox_glue+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000013295 enableval=$enable_toolbox_glue;
13296fi
Jack Jansene578a632001-08-15 01:27:14 +000013297
13298
13299if test -z "$enable_toolbox_glue"
Martin v. Löwis11437992002-04-12 09:54:03 +000013300then
Jack Jansene578a632001-08-15 01:27:14 +000013301 case $ac_sys_system/$ac_sys_release in
13302 Darwin/*)
13303 enable_toolbox_glue="yes";;
13304 *)
13305 enable_toolbox_glue="no";;
13306 esac
13307fi
13308case "$enable_toolbox_glue" in
13309yes)
Jack Jansene578a632001-08-15 01:27:14 +000013310 extra_machdep_objs="Python/mactoolboxglue.o"
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013311 extra_undefs="-u _PyMac_Error"
Martin v. Löwis11437992002-04-12 09:54:03 +000013312
13313cat >>confdefs.h <<\_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +000013314#define USE_TOOLBOX_OBJECT_GLUE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000013315_ACEOF
Jack Jansene578a632001-08-15 01:27:14 +000013316
13317 ;;
13318*)
Jack Jansene578a632001-08-15 01:27:14 +000013319 extra_machdep_objs=""
Jack Jansen591cbed2001-08-15 13:55:15 +000013320 extra_undefs=""
Jack Jansene578a632001-08-15 01:27:14 +000013321 ;;
13322esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013323{ echo "$as_me:$LINENO: result: $enable_toolbox_glue" >&5
13324echo "${ECHO_T}$enable_toolbox_glue" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000013325
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013326
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000013327
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013328case $ac_sys_system/$ac_sys_release in
Anthony Baxter82201742006-04-09 15:07:40 +000013329 Darwin/[01567]\..*)
Bob Ippolito7026a0a2005-03-28 23:23:47 +000013330 OTHER_LIBTOOL_OPT="-prebind -seg1addr 0x10000000"
13331 ;;
13332 Darwin/*)
13333 OTHER_LIBTOOL_OPT=""
13334 ;;
13335esac
13336
13337
13338case $ac_sys_system/$ac_sys_release in
Anthony Baxter82201742006-04-09 15:07:40 +000013339 Darwin/[01567]\..*)
Ronald Oussoren988117f2006-04-29 11:31:35 +000013340 LIBTOOL_CRUFT="-framework System -lcc_dynamic"
13341 if test "${enable_universalsdk}"; then
13342 :
13343 else
13344 LIBTOOL_CRUFT="${LIBTOOL_CRUFT} -arch_only `arch`"
13345 fi
Jack Jansenb36687a2004-07-16 08:43:47 +000013346 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansena3891ea2001-09-07 14:25:12 +000013347 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum5839e582000-10-09 19:52:35 +000013348 Darwin/*)
Bob Ippolito7026a0a2005-03-28 23:23:47 +000013349 gcc_version=`gcc -v 2>&1 | grep version | cut -d\ -f3`
13350 if test ${gcc_version} '<' 4.0
13351 then
13352 LIBTOOL_CRUFT="-lcc_dynamic"
13353 else
13354 LIBTOOL_CRUFT=""
13355 fi
Jack Jansen39fd2312006-02-23 15:12:19 +000013356 LIBTOOL_CRUFT=$LIBTOOL_CRUFT" -lSystem -lSystemStubs -arch_only `arch`"
Jack Jansenb36687a2004-07-16 08:43:47 +000013357 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -install_name $(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000013358 LIBTOOL_CRUFT=$LIBTOOL_CRUFT' -compatibility_version $(VERSION) -current_version $(VERSION)';;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013359esac
13360
Ronald Oussoren450d5612009-06-08 21:12:41 +000013361{ echo "$as_me:$LINENO: checking for --enable-framework" >&5
13362echo $ECHO_N "checking for --enable-framework... $ECHO_C" >&6; }
Jack Jansene578a632001-08-15 01:27:14 +000013363if test "$enable_framework"
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013364then
Skip Montanarodecc6a42003-01-01 20:07:49 +000013365 BASECFLAGS="$BASECFLAGS -fno-common -dynamic"
Martin v. Löwis11437992002-04-12 09:54:03 +000013366 # -F. is needed to allow linking to the framework while
Jack Jansene578a632001-08-15 01:27:14 +000013367 # in the build location.
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013368
Martin v. Löwis11437992002-04-12 09:54:03 +000013369cat >>confdefs.h <<\_ACEOF
13370#define WITH_NEXT_FRAMEWORK 1
13371_ACEOF
13372
Ronald Oussoren450d5612009-06-08 21:12:41 +000013373 { echo "$as_me:$LINENO: result: yes" >&5
13374echo "${ECHO_T}yes" >&6; }
13375 if test $enable_shared = "yes"
13376 then
13377 { { echo "$as_me:$LINENO: error: Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead" >&5
13378echo "$as_me: error: Specifying both --enable-shared and --enable-framework is not supported, use only --enable-framework instead" >&2;}
13379 { (exit 1); exit 1; }; }
13380 fi
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013381else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013382 { echo "$as_me:$LINENO: result: no" >&5
13383echo "${ECHO_T}no" >&6; }
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013384fi
13385
Ronald Oussoren450d5612009-06-08 21:12:41 +000013386{ echo "$as_me:$LINENO: checking for dyld" >&5
13387echo $ECHO_N "checking for dyld... $ECHO_C" >&6; }
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013388case $ac_sys_system/$ac_sys_release in
13389 Darwin/*)
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013390
Martin v. Löwis11437992002-04-12 09:54:03 +000013391cat >>confdefs.h <<\_ACEOF
13392#define WITH_DYLD 1
13393_ACEOF
13394
Ronald Oussoren450d5612009-06-08 21:12:41 +000013395 { echo "$as_me:$LINENO: result: always on for Darwin" >&5
13396echo "${ECHO_T}always on for Darwin" >&6; }
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013397 ;;
13398 *)
Ronald Oussoren450d5612009-06-08 21:12:41 +000013399 { echo "$as_me:$LINENO: result: no" >&5
13400echo "${ECHO_T}no" >&6; }
Jack Jansene578a632001-08-15 01:27:14 +000013401 ;;
Jack Jansen9a66b6d2001-08-08 13:56:14 +000013402esac
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013403
Guido van Rossum0a516c91994-09-12 10:58:40 +000013404# Set info about shared libraries.
Guido van Rossum0a516c91994-09-12 10:58:40 +000013405
Michael W. Hudson54241132001-12-07 15:38:26 +000013406
13407
13408
13409
Guido van Rossum0a516c91994-09-12 10:58:40 +000013410# SO is the extension of shared libraries `(including the dot!)
Guido van Rossumaef734b2001-01-10 21:09:12 +000013411# -- usually .so, .sl on HP-UX, .dll on Cygwin
Ronald Oussoren450d5612009-06-08 21:12:41 +000013412{ echo "$as_me:$LINENO: checking SO" >&5
13413echo $ECHO_N "checking SO... $ECHO_C" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013414if test -z "$SO"
13415then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013416 case $ac_sys_system in
Neal Norwitz58e28882006-05-19 07:00:58 +000013417 hp*|HP*)
13418 case `uname -m` in
13419 ia64) SO=.so;;
13420 *) SO=.sl;;
13421 esac
13422 ;;
Guido van Rossumaef734b2001-01-10 21:09:12 +000013423 CYGWIN*) SO=.dll;;
Guido van Rossum563e7081996-09-10 18:20:48 +000013424 *) SO=.so;;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013425 esac
Martin v. Löwis368de8f2003-06-14 14:46:38 +000013426else
13427 # this might also be a termcap variable, see #610332
13428 echo
13429 echo '====================================================================='
13430 echo '+ +'
13431 echo '+ WARNING: You have set SO in your environment. +'
13432 echo '+ Do you really mean to change the extension for shared libraries? +'
13433 echo '+ Continuing in 10 seconds to let you to ponder. +'
13434 echo '+ +'
13435 echo '====================================================================='
13436 sleep 10
Guido van Rossum0a516c91994-09-12 10:58:40 +000013437fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013438{ echo "$as_me:$LINENO: result: $SO" >&5
13439echo "${ECHO_T}$SO" >&6; }
Neal Norwitz58e28882006-05-19 07:00:58 +000013440
Ronald Oussoren79f90492009-01-02 10:44:46 +000013441
Neal Norwitz58e28882006-05-19 07:00:58 +000013442cat >>confdefs.h <<_ACEOF
13443#define SHLIB_EXT "$SO"
13444_ACEOF
13445
Guido van Rossum0a516c91994-09-12 10:58:40 +000013446# LDSHARED is the ld *command* used to create shared library
Martin v. Löwis12af0482004-01-31 12:34:17 +000013447# -- "cc -G" on SunOS 5.x, "ld -shared" on IRIX 5
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013448# (Shared libraries in this instance are shared modules to be loaded into
13449# Python, as opposed to building Python itself as a shared library.)
Ronald Oussoren450d5612009-06-08 21:12:41 +000013450{ echo "$as_me:$LINENO: checking LDSHARED" >&5
13451echo $ECHO_N "checking LDSHARED... $ECHO_C" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013452if test -z "$LDSHARED"
13453then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013454 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013455 AIX*)
13456 BLDSHARED="\$(srcdir)/Modules/ld_so_aix \$(CC) -bI:Modules/python.exp"
Guido van Rossumce608b02001-09-28 15:59:38 +000013457 LDSHARED="\$(BINLIBDEST)/config/ld_so_aix \$(CC) -bI:\$(BINLIBDEST)/config/python.exp"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013458 ;;
13459 BeOS*)
13460 BLDSHARED="\$(srcdir)/Modules/ld_so_beos $LDLIBRARY"
Guido van Rossumce608b02001-09-28 15:59:38 +000013461 LDSHARED="\$(BINLIBDEST)/config/ld_so_beos \$(LIBDIR)/$LDLIBRARY"
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013462 ;;
Guido van Rossum07397971997-04-29 21:49:50 +000013463 IRIX/5*) LDSHARED="ld -shared";;
Guido van Rossum91922671997-10-09 20:24:13 +000013464 IRIX*/6*) LDSHARED="ld ${SGI_ABI} -shared -all";;
Martin v. Löwis11437992002-04-12 09:54:03 +000013465 SunOS/5*)
Greg Ward57c9a662000-05-26 12:22:54 +000013466 if test "$GCC" = "yes"
Neil Schemenauer8ba94452001-02-19 18:18:48 +000013467 then LDSHARED='$(CC) -shared'
Martin v. Löwisaa5afe12002-10-07 06:21:41 +000013468 else LDSHARED='$(CC) -G';
Greg Ward57c9a662000-05-26 12:22:54 +000013469 fi ;;
Thomas Hellerdc96a772008-04-04 10:07:55 +000013470 hp*|HP*)
13471 if test "$GCC" = "yes"
13472 then LDSHARED='$(CC) -shared'
13473 else LDSHARED='ld -b';
13474 fi ;;
Guido van Rossumda88dad1995-01-26 00:46:29 +000013475 OSF*) LDSHARED="ld -shared -expect_unresolved \"*\"";;
Jack Jansen418c3b12001-11-14 10:59:57 +000013476 Darwin/1.3*)
Jack Jansena3891ea2001-09-07 14:25:12 +000013477 LDSHARED='$(CC) $(LDFLAGS) -bundle'
13478 if test "$enable_framework" ; then
13479 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000013480 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
13481 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansena3891ea2001-09-07 14:25:12 +000013482 else
13483 # No framework. Ignore undefined symbols, assuming they come from Python
Jack Jansen418c3b12001-11-14 10:59:57 +000013484 LDSHARED="$LDSHARED -undefined suppress"
Jack Jansena3891ea2001-09-07 14:25:12 +000013485 fi ;;
Jack Jansen6b08a402004-06-03 12:41:45 +000013486 Darwin/1.4*|Darwin/5.*|Darwin/6.*)
Jack Jansene578a632001-08-15 01:27:14 +000013487 LDSHARED='$(CC) $(LDFLAGS) -bundle'
13488 if test "$enable_framework" ; then
13489 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000013490 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
13491 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000013492 else
Michael W. Hudson594bc802002-03-07 09:59:15 +000013493 # No framework, use the Python app as bundle-loader
13494 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
Jack Jansenc28fc372003-02-25 13:14:43 +000013495 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013496 fi ;;
Jack Jansen6b08a402004-06-03 12:41:45 +000013497 Darwin/*)
13498 # Use -undefined dynamic_lookup whenever possible (10.3 and later).
13499 # This allows an extension to be used in any Python
Ronald Oussoren38f1b982007-09-02 09:46:07 +000013500
Ronald Oussoren5640ce22008-06-05 12:58:24 +000013501 if test ${MACOSX_DEPLOYMENT_TARGET} '>' 10.2
Jack Jansen6b08a402004-06-03 12:41:45 +000013502 then
Ronald Oussoren988117f2006-04-29 11:31:35 +000013503 if test "${enable_universalsdk}"; then
Ronald Oussoren5640ce22008-06-05 12:58:24 +000013504 LDFLAGS="${UNIVERSAL_ARCH_FLAGS} -isysroot ${UNIVERSALSDK} ${LDFLAGS}"
Ronald Oussoren988117f2006-04-29 11:31:35 +000013505 fi
Jack Jansen6b08a402004-06-03 12:41:45 +000013506 LDSHARED='$(CC) $(LDFLAGS) -bundle -undefined dynamic_lookup'
13507 BLDSHARED="$LDSHARED"
Jack Jansen6b08a402004-06-03 12:41:45 +000013508 else
13509 LDSHARED='$(CC) $(LDFLAGS) -bundle'
13510 if test "$enable_framework" ; then
13511 # Link against the framework. All externals should be defined.
Jack Jansenda49e192005-01-07 13:08:22 +000013512 BLDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
13513 LDSHARED="$LDSHARED "'$(PYTHONFRAMEWORKPREFIX)/$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansen6b08a402004-06-03 12:41:45 +000013514 else
13515 # No framework, use the Python app as bundle-loader
13516 BLDSHARED="$LDSHARED "'-bundle_loader $(BUILDPYTHON)'
13517 LDSHARED="$LDSHARED "'-bundle_loader $(BINDIR)/python$(VERSION)$(EXE)'
13518 fi
13519 fi
13520 ;;
Martin v. Löwis8c255e42008-05-23 15:06:50 +000013521 Linux*|GNU*|QNX*) LDSHARED='$(CC) -shared';;
Guido van Rossum458e7fa1999-09-17 15:40:40 +000013522 BSD/OS*/4*) LDSHARED="gcc -shared";;
Martin v. Löwis222c5152006-06-03 07:37:13 +000013523 FreeBSD*)
Jeremy Hylton4bcc7c52000-08-31 17:45:35 +000013524 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
Guido van Rossum0286ae82000-08-29 15:06:49 +000013525 then
Hye-Shik Chang33761492004-10-26 09:53:46 +000013526 LDSHARED="$CC -shared ${LDFLAGS}"
Guido van Rossum0286ae82000-08-29 15:06:49 +000013527 else
13528 LDSHARED="ld -Bshareable ${LDFLAGS}"
13529 fi;;
Martin v. Löwis222c5152006-06-03 07:37:13 +000013530 OpenBSD*)
13531 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
13532 then
13533 LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}'
13534 else
13535 case `uname -r` in
13536 [01].* | 2.[0-7] | 2.[0-7].*)
13537 LDSHARED="ld -Bshareable ${LDFLAGS}"
13538 ;;
13539 *)
13540 LDSHARED='$(CC) -shared $(CCSHARED) ${LDFLAGS}'
13541 ;;
13542 esac
13543 fi;;
Martin v. Löwis86d66262006-02-17 08:40:11 +000013544 NetBSD*|DragonFly*) LDSHARED="cc -shared ${LDFLAGS}";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000013545 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000013546 if test "$GCC" = "yes"
Martin v. Löwis79f3c532002-12-11 12:51:58 +000013547 then LDSHARED='$(CC) -shared'
13548 else LDSHARED='$(CC) -G'
Martin v. Löwisbec19582001-03-21 15:57:54 +000013549 fi;;
Martin v. Löwis79f3c532002-12-11 12:51:58 +000013550 SCO_SV*) LDSHARED='$(CC) -Wl,-G,-Bexport';;
Trent Mick635f6fb2000-08-23 21:33:05 +000013551 Monterey*) LDSHARED="cc -G -dy -Bdynamic -Bexport -L/usr/lib/ia64l64";;
Guido van Rossumaef734b2001-01-10 21:09:12 +000013552 CYGWIN*) LDSHARED="gcc -shared -Wl,--enable-auto-image-base";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013553 atheos*) LDSHARED="gcc -shared";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013554 *) LDSHARED="ld";;
13555 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000013556fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013557{ echo "$as_me:$LINENO: result: $LDSHARED" >&5
13558echo "${ECHO_T}$LDSHARED" >&6; }
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013559BLDSHARED=${BLDSHARED-$LDSHARED}
Guido van Rossum0a516c91994-09-12 10:58:40 +000013560# CCSHARED are the C *flags* used to create objects to go into a shared
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013561# library (module) -- this is only needed for a few systems
Ronald Oussoren450d5612009-06-08 21:12:41 +000013562{ echo "$as_me:$LINENO: checking CCSHARED" >&5
13563echo $ECHO_N "checking CCSHARED... $ECHO_C" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013564if test -z "$CCSHARED"
13565then
Guido van Rossum07397971997-04-29 21:49:50 +000013566 case $ac_sys_system/$ac_sys_release in
Neil Schemenauerc761fc82001-02-19 04:50:49 +000013567 SunOS*) if test "$GCC" = yes;
Martin v. Löwiseb623572007-03-12 10:50:39 +000013568 then CCSHARED="-fPIC";
13569 elif test `uname -p` = sparc;
13570 then CCSHARED="-xcode=pic32";
13571 else CCSHARED="-Kpic";
13572 fi;;
Guido van Rossumaf07a441995-02-13 19:45:27 +000013573 hp*|HP*) if test "$GCC" = yes;
Martin v. Löwis703ad702001-09-05 08:36:52 +000013574 then CCSHARED="-fPIC";
Guido van Rossumaf07a441995-02-13 19:45:27 +000013575 else CCSHARED="+z";
13576 fi;;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000013577 Linux*|GNU*) CCSHARED="-fPIC";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +000013578 BSD/OS*/4*) CCSHARED="-fpic";;
Martin v. Löwis86d66262006-02-17 08:40:11 +000013579 FreeBSD*|NetBSD*|OpenBSD*|DragonFly*) CCSHARED="-fPIC";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000013580 OpenUNIX*|UnixWare*)
Martin v. Löwisbec19582001-03-21 15:57:54 +000013581 if test "$GCC" = "yes"
13582 then CCSHARED="-fPIC"
Martin v. Löwis130fb172001-07-19 11:00:41 +000013583 else CCSHARED="-KPIC"
Martin v. Löwisbec19582001-03-21 15:57:54 +000013584 fi;;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000013585 SCO_SV*)
13586 if test "$GCC" = "yes"
13587 then CCSHARED="-fPIC"
13588 else CCSHARED="-Kpic -belf"
13589 fi;;
Trent Mick635f6fb2000-08-23 21:33:05 +000013590 Monterey*) CCSHARED="-G";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013591 IRIX*/6*) case $CC in
13592 *gcc*) CCSHARED="-shared";;
Guido van Rossumee21f411998-04-20 18:51:54 +000013593 *) CCSHARED="";;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013594 esac;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013595 atheos*) CCSHARED="-fPIC";;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013596 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000013597fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013598{ echo "$as_me:$LINENO: result: $CCSHARED" >&5
13599echo "${ECHO_T}$CCSHARED" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013600# LINKFORSHARED are the flags passed to the $(CC) command that links
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013601# the python executable -- this is only needed for a few systems
Ronald Oussoren450d5612009-06-08 21:12:41 +000013602{ echo "$as_me:$LINENO: checking LINKFORSHARED" >&5
13603echo $ECHO_N "checking LINKFORSHARED... $ECHO_C" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013604if test -z "$LINKFORSHARED"
13605then
Guido van Rossum07397971997-04-29 21:49:50 +000013606 case $ac_sys_system/$ac_sys_release in
Neil Schemenauer4a7bbcb2001-02-16 03:37:54 +000013607 AIX*) LINKFORSHARED='-Wl,-bE:Modules/python.exp -lld';;
Guido van Rossumccaf3b61996-12-06 21:19:16 +000013608 hp*|HP*)
Martin v. Löwis1142de32002-03-29 16:28:31 +000013609 LINKFORSHARED="-Wl,-E -Wl,+s";;
13610# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Guido van Rossumf5957ea1999-10-05 21:59:33 +000013611 BSD/OS/4*) LINKFORSHARED="-Xlinker -export-dynamic";;
Martin v. Löwisa6e97582002-01-01 18:41:33 +000013612 Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
Guido van Rossum54ecc3d1999-01-27 17:53:11 +000013613 # -u libsys_s pulls in all symbols in libsys
Martin v. Löwis11437992002-04-12 09:54:03 +000013614 Darwin/*)
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013615 # -u _PyMac_Error is needed to pull in the mac toolbox glue,
13616 # which is
Jack Jansene578a632001-08-15 01:27:14 +000013617 # not used by the core itself but which needs to be in the core so
13618 # that dynamically loaded extension modules have access to it.
Jack Jansen97e3f002003-02-23 22:59:01 +000013619 # -prebind is no longer used, because it actually seems to give a
13620 # slowdown in stead of a speedup, maybe due to the large number of
13621 # dynamic loads Python does.
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013622
13623 LINKFORSHARED="$extra_undefs"
Jack Jansene578a632001-08-15 01:27:14 +000013624 if test "$enable_framework"
13625 then
Jack Jansenda49e192005-01-07 13:08:22 +000013626 LINKFORSHARED="$LINKFORSHARED "'$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK)'
Jack Jansene578a632001-08-15 01:27:14 +000013627 fi
Anthony Baxtereef2d3b2004-11-06 04:45:33 +000013628 LINKFORSHARED="$LINKFORSHARED";;
Martin v. Löwis25ae43b2001-10-07 08:39:18 +000013629 OpenUNIX*|UnixWare*) LINKFORSHARED="-Wl,-Bexport";;
Martin v. Löwis21ee4092002-09-30 16:19:48 +000013630 SCO_SV*) LINKFORSHARED="-Wl,-Bexport";;
Fred Drake02706f52000-09-25 15:08:46 +000013631 ReliantUNIX*) LINKFORSHARED="-W1 -Blargedynsym";;
Martin v. Löwis86d66262006-02-17 08:40:11 +000013632 FreeBSD*|NetBSD*|OpenBSD*|DragonFly*)
Guido van Rossumdf693651999-01-07 21:50:41 +000013633 if [ "`$CC -dM -E - </dev/null | grep __ELF__`" != "" ]
13634 then
13635 LINKFORSHARED="-Wl,--export-dynamic"
13636 fi;;
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013637 SunOS/5*) case $CC in
13638 *gcc*)
Martin v. Löwisa4548572002-04-18 14:51:36 +000013639 if $CC -Xlinker --help 2>&1 | grep export-dynamic >/dev/null
Guido van Rossum8f4ceb11997-12-18 23:42:19 +000013640 then
13641 LINKFORSHARED="-Xlinker --export-dynamic"
Guido van Rossum2b5ca001998-03-05 15:41:09 +000013642 fi;;
13643 esac;;
Jason Tishler30765592003-09-04 11:04:06 +000013644 CYGWIN*)
13645 if test $enable_shared = "no"
13646 then
13647 LINKFORSHARED='-Wl,--out-implib=$(LDLIBRARY)'
13648 fi;;
Martin v. Löwis8c255e42008-05-23 15:06:50 +000013649 QNX*)
13650 # -Wl,-E causes the symbols to be added to the dynamic
13651 # symbol table so that they can be found when a module
13652 # is loaded. -N 2048K causes the stack size to be set
13653 # to 2048 kilobytes so that the stack doesn't overflow
13654 # when running test_compile.py.
13655 LINKFORSHARED='-Wl,-E -N 2048K';;
Guido van Rossum0a516c91994-09-12 10:58:40 +000013656 esac
Guido van Rossum0a516c91994-09-12 10:58:40 +000013657fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013658{ echo "$as_me:$LINENO: result: $LINKFORSHARED" >&5
13659echo "${ECHO_T}$LINKFORSHARED" >&6; }
Guido van Rossum0a516c91994-09-12 10:58:40 +000013660
Michael W. Hudson54241132001-12-07 15:38:26 +000013661
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000013662
Ronald Oussoren450d5612009-06-08 21:12:41 +000013663{ echo "$as_me:$LINENO: checking CFLAGSFORSHARED" >&5
13664echo $ECHO_N "checking CFLAGSFORSHARED... $ECHO_C" >&6; }
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000013665if test ! "$LIBRARY" = "$LDLIBRARY"
13666then
Neil Schemenauer0c6141f2001-01-27 21:40:54 +000013667 case $ac_sys_system in
13668 CYGWIN*)
13669 # Cygwin needs CCSHARED when building extension DLLs
13670 # but not when building the interpreter DLL.
13671 CFLAGSFORSHARED='';;
13672 *)
13673 CFLAGSFORSHARED='$(CCSHARED)'
13674 esac
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000013675fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013676{ echo "$as_me:$LINENO: result: $CFLAGSFORSHARED" >&5
13677echo "${ECHO_T}$CFLAGSFORSHARED" >&6; }
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000013678
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013679# SHLIBS are libraries (except -lc and -lm) to link to the python shared
13680# library (with --enable-shared).
13681# For platforms on which shared libraries are not allowed to have unresolved
Martin v. Löwisd6359c52002-08-04 12:38:50 +000013682# symbols, this must be set to $(LIBS) (expanded by make). We do this even
13683# if it is not required, since it creates a dependency of the shared library
13684# to LIBS. This, in turn, means that applications linking the shared libpython
13685# don't need to link LIBS explicitly. The default should be only changed
13686# on systems where this approach causes problems.
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013687
Ronald Oussoren450d5612009-06-08 21:12:41 +000013688{ echo "$as_me:$LINENO: checking SHLIBS" >&5
13689echo $ECHO_N "checking SHLIBS... $ECHO_C" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013690case "$ac_sys_system" in
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013691 *)
Martin v. Löwisd6359c52002-08-04 12:38:50 +000013692 SHLIBS='$(LIBS)';;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013693esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013694{ echo "$as_me:$LINENO: result: $SHLIBS" >&5
13695echo "${ECHO_T}$SHLIBS" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000013696
13697
Guido van Rossum627b2d71993-12-24 10:39:16 +000013698# checks for libraries
Martin v. Löwis11437992002-04-12 09:54:03 +000013699
Ronald Oussoren450d5612009-06-08 21:12:41 +000013700{ echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
13701echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013702if test "${ac_cv_lib_dl_dlopen+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013703 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013704else
Martin v. Löwis11437992002-04-12 09:54:03 +000013705 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013706LIBS="-ldl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000013707cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013708/* confdefs.h. */
13709_ACEOF
13710cat confdefs.h >>conftest.$ac_ext
13711cat >>conftest.$ac_ext <<_ACEOF
13712/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013713
Martin v. Löwiseba40652007-08-30 20:10:57 +000013714/* Override any GCC internal prototype to avoid an error.
13715 Use char because int might match the return type of a GCC
13716 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013717#ifdef __cplusplus
13718extern "C"
13719#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013720char dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013721int
13722main ()
13723{
Martin v. Löwiseba40652007-08-30 20:10:57 +000013724return dlopen ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013725 ;
13726 return 0;
13727}
13728_ACEOF
13729rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013730if { (ac_try="$ac_link"
13731case "(($ac_try" in
13732 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13733 *) ac_try_echo=$ac_try;;
13734esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013735eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013736 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013737 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013738 grep -v '^ *+' conftest.er1 >conftest.err
13739 rm -f conftest.er1
13740 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000013741 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013742 (exit $ac_status); } && {
13743 test -z "$ac_c_werror_flag" ||
13744 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000013745 } && test -s conftest$ac_exeext &&
13746 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013747 ac_cv_lib_dl_dlopen=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013748else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013749 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013750sed 's/^/| /' conftest.$ac_ext >&5
13751
Martin v. Löwiseba40652007-08-30 20:10:57 +000013752 ac_cv_lib_dl_dlopen=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013753fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013754
13755rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000013756 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000013757LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000013758fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013759{ echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
13760echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; }
13761if test $ac_cv_lib_dl_dlopen = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013762 cat >>confdefs.h <<_ACEOF
13763#define HAVE_LIBDL 1
13764_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013765
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013766 LIBS="-ldl $LIBS"
Guido van Rossum7f43da71994-08-01 12:15:30 +000013767
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013768fi
13769 # Dynamic linking for SunOS/Solaris and SYSV
Martin v. Löwis11437992002-04-12 09:54:03 +000013770
Ronald Oussoren450d5612009-06-08 21:12:41 +000013771{ echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
13772echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000013773if test "${ac_cv_lib_dld_shl_load+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013774 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013775else
Martin v. Löwis11437992002-04-12 09:54:03 +000013776 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013777LIBS="-ldld $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000013778cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013779/* confdefs.h. */
13780_ACEOF
13781cat confdefs.h >>conftest.$ac_ext
13782cat >>conftest.$ac_ext <<_ACEOF
13783/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013784
Martin v. Löwiseba40652007-08-30 20:10:57 +000013785/* Override any GCC internal prototype to avoid an error.
13786 Use char because int might match the return type of a GCC
13787 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013788#ifdef __cplusplus
13789extern "C"
13790#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013791char shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013792int
13793main ()
13794{
Martin v. Löwiseba40652007-08-30 20:10:57 +000013795return shl_load ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013796 ;
13797 return 0;
13798}
13799_ACEOF
13800rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013801if { (ac_try="$ac_link"
13802case "(($ac_try" in
13803 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13804 *) ac_try_echo=$ac_try;;
13805esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013806eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013807 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000013808 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013809 grep -v '^ *+' conftest.er1 >conftest.err
13810 rm -f conftest.er1
13811 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000013812 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013813 (exit $ac_status); } && {
13814 test -z "$ac_c_werror_flag" ||
13815 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000013816 } && test -s conftest$ac_exeext &&
13817 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013818 ac_cv_lib_dld_shl_load=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013819else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013820 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013821sed 's/^/| /' conftest.$ac_ext >&5
13822
Martin v. Löwiseba40652007-08-30 20:10:57 +000013823 ac_cv_lib_dld_shl_load=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000013824fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013825
13826rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000013827 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000013828LIBS=$ac_check_lib_save_LIBS
Guido van Rossum627b2d71993-12-24 10:39:16 +000013829fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013830{ echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
13831echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; }
13832if test $ac_cv_lib_dld_shl_load = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000013833 cat >>confdefs.h <<_ACEOF
13834#define HAVE_LIBDLD 1
13835_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000013836
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000013837 LIBS="-ldld $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013838
Guido van Rossum76be6ed1995-01-02 18:33:54 +000013839fi
13840 # Dynamic linking for HP-UX
Martin v. Löwis519adae2003-09-20 10:47:47 +000013841
Ronald Oussoren79f90492009-01-02 10:44:46 +000013842# only check for sem_init if thread support is requested
Martin v. Löwis519adae2003-09-20 10:47:47 +000013843if test "$with_threads" = "yes" -o -z "$with_threads"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013844 { echo "$as_me:$LINENO: checking for library containing sem_init" >&5
13845echo $ECHO_N "checking for library containing sem_init... $ECHO_C" >&6; }
Martin v. Löwis82c19a72002-10-06 11:48:09 +000013846if test "${ac_cv_search_sem_init+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013847 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis41933dd2002-03-21 15:10:58 +000013848else
Martin v. Löwis82c19a72002-10-06 11:48:09 +000013849 ac_func_search_save_LIBS=$LIBS
Martin v. Löwis11437992002-04-12 09:54:03 +000013850cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013851/* confdefs.h. */
13852_ACEOF
13853cat confdefs.h >>conftest.$ac_ext
13854cat >>conftest.$ac_ext <<_ACEOF
13855/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013856
Martin v. Löwiseba40652007-08-30 20:10:57 +000013857/* Override any GCC internal prototype to avoid an error.
13858 Use char because int might match the return type of a GCC
13859 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000013860#ifdef __cplusplus
13861extern "C"
13862#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000013863char sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013864int
13865main ()
13866{
Martin v. Löwiseba40652007-08-30 20:10:57 +000013867return sem_init ();
Martin v. Löwis11437992002-04-12 09:54:03 +000013868 ;
13869 return 0;
13870}
13871_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000013872for ac_lib in '' pthread rt posix4; do
13873 if test -z "$ac_lib"; then
13874 ac_res="none required"
13875 else
13876 ac_res=-l$ac_lib
Skip Montanaro89e975f2007-08-22 19:05:21 +000013877 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
Martin v. Löwiseba40652007-08-30 20:10:57 +000013878 fi
13879 rm -f conftest.$ac_objext conftest$ac_exeext
13880if { (ac_try="$ac_link"
13881case "(($ac_try" in
13882 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13883 *) ac_try_echo=$ac_try;;
13884esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013885eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013886 (eval "$ac_link") 2>conftest.er1
Skip Montanaro89e975f2007-08-22 19:05:21 +000013887 ac_status=$?
13888 grep -v '^ *+' conftest.er1 >conftest.err
13889 rm -f conftest.er1
13890 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000013891 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013892 (exit $ac_status); } && {
13893 test -z "$ac_c_werror_flag" ||
13894 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000013895 } && test -s conftest$ac_exeext &&
13896 $as_test_x conftest$ac_exeext; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000013897 ac_cv_search_sem_init=$ac_res
Brett Cannon19fab762007-06-02 03:02:29 +000013898else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013899 echo "$as_me: failed program was:" >&5
Skip Montanaro89e975f2007-08-22 19:05:21 +000013900sed 's/^/| /' conftest.$ac_ext >&5
13901
Martin v. Löwiseba40652007-08-30 20:10:57 +000013902
Brett Cannon19fab762007-06-02 03:02:29 +000013903fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013904
13905rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13906 conftest$ac_exeext
13907 if test "${ac_cv_search_sem_init+set}" = set; then
13908 break
Skip Montanaro89e975f2007-08-22 19:05:21 +000013909fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013910done
13911if test "${ac_cv_search_sem_init+set}" = set; then
13912 :
13913else
13914 ac_cv_search_sem_init=no
13915fi
13916rm conftest.$ac_ext
Martin v. Löwis82c19a72002-10-06 11:48:09 +000013917LIBS=$ac_func_search_save_LIBS
13918fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013919{ echo "$as_me:$LINENO: result: $ac_cv_search_sem_init" >&5
13920echo "${ECHO_T}$ac_cv_search_sem_init" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000013921ac_res=$ac_cv_search_sem_init
13922if test "$ac_res" != no; then
13923 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Martin v. Löwis41933dd2002-03-21 15:10:58 +000013924
Martin v. Löwis41933dd2002-03-21 15:10:58 +000013925fi
Martin v. Löwisd3545ec2003-05-03 11:25:43 +000013926 # 'Real Time' functions on Solaris
Martin v. Löwis519adae2003-09-20 10:47:47 +000013927 # posix4 on Solaris 2.6
13928 # pthread (first!) on Linux
13929fi
13930
Martin v. Löwis19d17342003-06-14 21:03:05 +000013931# check if we need libintl for locale functions
Ronald Oussoren450d5612009-06-08 21:12:41 +000013932{ echo "$as_me:$LINENO: checking for textdomain in -lintl" >&5
13933echo $ECHO_N "checking for textdomain in -lintl... $ECHO_C" >&6; }
Martin v. Löwis19d17342003-06-14 21:03:05 +000013934if test "${ac_cv_lib_intl_textdomain+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000013935 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis19d17342003-06-14 21:03:05 +000013936else
13937 ac_check_lib_save_LIBS=$LIBS
13938LIBS="-lintl $LIBS"
13939cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000013940/* confdefs.h. */
13941_ACEOF
13942cat confdefs.h >>conftest.$ac_ext
13943cat >>conftest.$ac_ext <<_ACEOF
13944/* end confdefs.h. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000013945
Martin v. Löwiseba40652007-08-30 20:10:57 +000013946/* Override any GCC internal prototype to avoid an error.
13947 Use char because int might match the return type of a GCC
13948 builtin and then its argument prototype would still apply. */
Martin v. Löwis19d17342003-06-14 21:03:05 +000013949#ifdef __cplusplus
13950extern "C"
13951#endif
Martin v. Löwis19d17342003-06-14 21:03:05 +000013952char textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000013953int
13954main ()
13955{
Martin v. Löwiseba40652007-08-30 20:10:57 +000013956return textdomain ();
Martin v. Löwis19d17342003-06-14 21:03:05 +000013957 ;
13958 return 0;
13959}
13960_ACEOF
13961rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000013962if { (ac_try="$ac_link"
13963case "(($ac_try" in
13964 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13965 *) ac_try_echo=$ac_try;;
13966esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000013967eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013968 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis19d17342003-06-14 21:03:05 +000013969 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000013970 grep -v '^ *+' conftest.er1 >conftest.err
13971 rm -f conftest.er1
13972 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000013973 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000013974 (exit $ac_status); } && {
13975 test -z "$ac_c_werror_flag" ||
13976 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000013977 } && test -s conftest$ac_exeext &&
13978 $as_test_x conftest$ac_exeext; then
Martin v. Löwis19d17342003-06-14 21:03:05 +000013979 ac_cv_lib_intl_textdomain=yes
13980else
Ronald Oussoren450d5612009-06-08 21:12:41 +000013981 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000013982sed 's/^/| /' conftest.$ac_ext >&5
13983
Martin v. Löwiseba40652007-08-30 20:10:57 +000013984 ac_cv_lib_intl_textdomain=no
Martin v. Löwis19d17342003-06-14 21:03:05 +000013985fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000013986
13987rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000013988 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis19d17342003-06-14 21:03:05 +000013989LIBS=$ac_check_lib_save_LIBS
13990fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000013991{ echo "$as_me:$LINENO: result: $ac_cv_lib_intl_textdomain" >&5
13992echo "${ECHO_T}$ac_cv_lib_intl_textdomain" >&6; }
13993if test $ac_cv_lib_intl_textdomain = yes; then
Martin v. Löwis19d17342003-06-14 21:03:05 +000013994
13995cat >>confdefs.h <<\_ACEOF
13996#define WITH_LIBINTL 1
13997_ACEOF
13998
13999fi
14000
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014001
14002# checks for system dependent C++ extensions support
14003case "$ac_sys_system" in
Ronald Oussoren450d5612009-06-08 21:12:41 +000014004 AIX*) { echo "$as_me:$LINENO: checking for genuine AIX C++ extensions support" >&5
14005echo $ECHO_N "checking for genuine AIX C++ extensions support... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014006 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014007/* confdefs.h. */
14008_ACEOF
14009cat confdefs.h >>conftest.$ac_ext
14010cat >>conftest.$ac_ext <<_ACEOF
14011/* end confdefs.h. */
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014012#include "/usr/lpp/xlC/include/load.h"
Martin v. Löwis11437992002-04-12 09:54:03 +000014013int
14014main ()
14015{
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014016loadAndInit("", 0, "")
Martin v. Löwis11437992002-04-12 09:54:03 +000014017 ;
14018 return 0;
14019}
14020_ACEOF
14021rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014022if { (ac_try="$ac_link"
14023case "(($ac_try" in
14024 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14025 *) ac_try_echo=$ac_try;;
14026esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014027eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014028 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014029 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014030 grep -v '^ *+' conftest.er1 >conftest.err
14031 rm -f conftest.er1
14032 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014033 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014034 (exit $ac_status); } && {
14035 test -z "$ac_c_werror_flag" ||
14036 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000014037 } && test -s conftest$ac_exeext &&
14038 $as_test_x conftest$ac_exeext; then
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014039
Martin v. Löwis11437992002-04-12 09:54:03 +000014040cat >>confdefs.h <<\_ACEOF
14041#define AIX_GENUINE_CPLUSPLUS 1
14042_ACEOF
14043
Ronald Oussoren450d5612009-06-08 21:12:41 +000014044 { echo "$as_me:$LINENO: result: yes" >&5
14045echo "${ECHO_T}yes" >&6; }
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014046else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014047 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014048sed 's/^/| /' conftest.$ac_ext >&5
14049
Ronald Oussoren450d5612009-06-08 21:12:41 +000014050 { echo "$as_me:$LINENO: result: no" >&5
14051echo "${ECHO_T}no" >&6; }
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014052fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014053
14054rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014055 conftest$ac_exeext conftest.$ac_ext;;
Guido van Rossum0eefa3f1999-11-16 15:57:37 +000014056 *) ;;
14057esac
14058
Guido van Rossum70c7f481998-03-26 18:44:10 +000014059# Most SVR4 platforms (e.g. Solaris) need -lsocket and -lnsl.
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014060# BeOS' sockets are stashed in libnet.
Ronald Oussoren450d5612009-06-08 21:12:41 +000014061{ echo "$as_me:$LINENO: checking for t_open in -lnsl" >&5
14062echo $ECHO_N "checking for t_open in -lnsl... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014063if test "${ac_cv_lib_nsl_t_open+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014064 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014065else
Martin v. Löwis11437992002-04-12 09:54:03 +000014066 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014067LIBS="-lnsl $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014068cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014069/* confdefs.h. */
14070_ACEOF
14071cat confdefs.h >>conftest.$ac_ext
14072cat >>conftest.$ac_ext <<_ACEOF
14073/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014074
Martin v. Löwiseba40652007-08-30 20:10:57 +000014075/* Override any GCC internal prototype to avoid an error.
14076 Use char because int might match the return type of a GCC
14077 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014078#ifdef __cplusplus
14079extern "C"
14080#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014081char t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014082int
14083main ()
14084{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014085return t_open ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014086 ;
14087 return 0;
14088}
14089_ACEOF
14090rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014091if { (ac_try="$ac_link"
14092case "(($ac_try" in
14093 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14094 *) ac_try_echo=$ac_try;;
14095esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014096eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014097 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014098 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014099 grep -v '^ *+' conftest.er1 >conftest.err
14100 rm -f conftest.er1
14101 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014102 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014103 (exit $ac_status); } && {
14104 test -z "$ac_c_werror_flag" ||
14105 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000014106 } && test -s conftest$ac_exeext &&
14107 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014108 ac_cv_lib_nsl_t_open=yes
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014109else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014110 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014111sed 's/^/| /' conftest.$ac_ext >&5
14112
Martin v. Löwiseba40652007-08-30 20:10:57 +000014113 ac_cv_lib_nsl_t_open=no
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014114fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014115
14116rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014117 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014118LIBS=$ac_check_lib_save_LIBS
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014119fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014120{ echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_t_open" >&5
14121echo "${ECHO_T}$ac_cv_lib_nsl_t_open" >&6; }
14122if test $ac_cv_lib_nsl_t_open = yes; then
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014123 LIBS="-lnsl $LIBS"
Guido van Rossum79dddcb1995-01-12 12:25:42 +000014124fi
Guido van Rossum0ddb0281995-01-17 16:46:14 +000014125 # SVR4
Ronald Oussoren450d5612009-06-08 21:12:41 +000014126{ echo "$as_me:$LINENO: checking for socket in -lsocket" >&5
14127echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014128if test "${ac_cv_lib_socket_socket+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014129 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000014130else
Martin v. Löwis11437992002-04-12 09:54:03 +000014131 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000014132LIBS="-lsocket $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014133cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014134/* confdefs.h. */
14135_ACEOF
14136cat confdefs.h >>conftest.$ac_ext
14137cat >>conftest.$ac_ext <<_ACEOF
14138/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014139
Martin v. Löwiseba40652007-08-30 20:10:57 +000014140/* Override any GCC internal prototype to avoid an error.
14141 Use char because int might match the return type of a GCC
14142 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014143#ifdef __cplusplus
14144extern "C"
14145#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014146char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014147int
14148main ()
14149{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014150return socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014151 ;
14152 return 0;
14153}
14154_ACEOF
14155rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014156if { (ac_try="$ac_link"
14157case "(($ac_try" in
14158 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14159 *) ac_try_echo=$ac_try;;
14160esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014161eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014162 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014163 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014164 grep -v '^ *+' conftest.er1 >conftest.err
14165 rm -f conftest.er1
14166 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014167 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014168 (exit $ac_status); } && {
14169 test -z "$ac_c_werror_flag" ||
14170 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000014171 } && test -s conftest$ac_exeext &&
14172 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014173 ac_cv_lib_socket_socket=yes
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014174else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014175 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014176sed 's/^/| /' conftest.$ac_ext >&5
14177
Martin v. Löwiseba40652007-08-30 20:10:57 +000014178 ac_cv_lib_socket_socket=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014179fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014180
14181rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014182 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014183LIBS=$ac_check_lib_save_LIBS
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014184fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014185{ echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5
14186echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6; }
14187if test $ac_cv_lib_socket_socket = yes; then
Guido van Rossumad678af1998-10-02 14:42:15 +000014188 LIBS="-lsocket $LIBS"
Guido van Rossumad678af1998-10-02 14:42:15 +000014189fi
14190 # SVR4 sockets
Skip Montanarob9949db2004-01-17 04:04:13 +000014191
Jeremy Hyltoncb25d5e2000-07-27 21:23:28 +000014192case "$ac_sys_system" in
14193BeOS*)
Ronald Oussoren450d5612009-06-08 21:12:41 +000014194{ echo "$as_me:$LINENO: checking for socket in -lnet" >&5
14195echo $ECHO_N "checking for socket in -lnet... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014196if test "${ac_cv_lib_net_socket+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014197 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000014198else
Martin v. Löwis11437992002-04-12 09:54:03 +000014199 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +000014200LIBS="-lnet $LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000014201cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014202/* confdefs.h. */
14203_ACEOF
14204cat confdefs.h >>conftest.$ac_ext
14205cat >>conftest.$ac_ext <<_ACEOF
14206/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014207
Martin v. Löwiseba40652007-08-30 20:10:57 +000014208/* Override any GCC internal prototype to avoid an error.
14209 Use char because int might match the return type of a GCC
14210 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014211#ifdef __cplusplus
14212extern "C"
14213#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014214char socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014215int
14216main ()
14217{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014218return socket ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014219 ;
14220 return 0;
14221}
14222_ACEOF
14223rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014224if { (ac_try="$ac_link"
14225case "(($ac_try" in
14226 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14227 *) ac_try_echo=$ac_try;;
14228esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014229eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014230 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014231 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014232 grep -v '^ *+' conftest.er1 >conftest.err
14233 rm -f conftest.er1
14234 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014235 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014236 (exit $ac_status); } && {
14237 test -z "$ac_c_werror_flag" ||
14238 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000014239 } && test -s conftest$ac_exeext &&
14240 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014241 ac_cv_lib_net_socket=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000014242else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014243 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014244sed 's/^/| /' conftest.$ac_ext >&5
14245
Martin v. Löwiseba40652007-08-30 20:10:57 +000014246 ac_cv_lib_net_socket=no
Guido van Rossumad678af1998-10-02 14:42:15 +000014247fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014248
14249rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014250 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000014251LIBS=$ac_check_lib_save_LIBS
Guido van Rossumad678af1998-10-02 14:42:15 +000014252fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014253{ echo "$as_me:$LINENO: result: $ac_cv_lib_net_socket" >&5
14254echo "${ECHO_T}$ac_cv_lib_net_socket" >&6; }
14255if test $ac_cv_lib_net_socket = yes; then
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014256 LIBS="-lnet $LIBS"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000014257fi
14258 # BeOS
14259;;
14260esac
Guido van Rossum70c7f481998-03-26 18:44:10 +000014261
Ronald Oussoren450d5612009-06-08 21:12:41 +000014262{ echo "$as_me:$LINENO: checking for --with-libs" >&5
14263echo $ECHO_N "checking for --with-libs... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014264
Martin v. Löwiseba40652007-08-30 20:10:57 +000014265# Check whether --with-libs was given.
Guido van Rossuma68acba1996-07-31 17:36:39 +000014266if test "${with_libs+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014267 withval=$with_libs;
Ronald Oussoren450d5612009-06-08 21:12:41 +000014268{ echo "$as_me:$LINENO: result: $withval" >&5
14269echo "${ECHO_T}$withval" >&6; }
Guido van Rossuma68acba1996-07-31 17:36:39 +000014270LIBS="$withval $LIBS"
14271
14272else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014273 { echo "$as_me:$LINENO: result: no" >&5
14274echo "${ECHO_T}no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000014275fi
14276
Guido van Rossum7f43da71994-08-01 12:15:30 +000014277
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014278# Check for use of the system libffi library
Ronald Oussoren450d5612009-06-08 21:12:41 +000014279{ echo "$as_me:$LINENO: checking for --with-system-ffi" >&5
14280echo $ECHO_N "checking for --with-system-ffi... $ECHO_C" >&6; }
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014281
Martin v. Löwiseba40652007-08-30 20:10:57 +000014282# Check whether --with-system_ffi was given.
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014283if test "${with_system_ffi+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014284 withval=$with_system_ffi;
14285fi
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014286
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014287
Ronald Oussoren450d5612009-06-08 21:12:41 +000014288{ echo "$as_me:$LINENO: result: $with_system_ffi" >&5
14289echo "${ECHO_T}$with_system_ffi" >&6; }
Martin v. Löwis9176fc12006-04-11 11:12:43 +000014290
Benjamin Peterson867475c2009-04-29 20:36:25 +000014291# Check for --with-dbmliborder
Ronald Oussoren450d5612009-06-08 21:12:41 +000014292{ echo "$as_me:$LINENO: checking for --with-dbmliborder" >&5
14293echo $ECHO_N "checking for --with-dbmliborder... $ECHO_C" >&6; }
Benjamin Peterson867475c2009-04-29 20:36:25 +000014294
14295# Check whether --with-dbmliborder was given.
14296if test "${with_dbmliborder+set}" = set; then
14297 withval=$with_dbmliborder;
14298if test x$with_dbmliborder = xyes
14299then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014300{ { echo "$as_me:$LINENO: error: proper usage is --with-dbmliborder=db1:db2:..." >&5
14301echo "$as_me: error: proper usage is --with-dbmliborder=db1:db2:..." >&2;}
Benjamin Peterson867475c2009-04-29 20:36:25 +000014302 { (exit 1); exit 1; }; }
14303else
14304 for db in `echo $with_dbmliborder | sed 's/:/ /g'`; do
14305 if test x$db != xndbm && test x$db != xgdbm && test x$db != xbdb
14306 then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014307 { { echo "$as_me:$LINENO: error: proper usage is --with-dbmliborder=db1:db2:..." >&5
14308echo "$as_me: error: proper usage is --with-dbmliborder=db1:db2:..." >&2;}
Benjamin Peterson867475c2009-04-29 20:36:25 +000014309 { (exit 1); exit 1; }; }
14310 fi
14311 done
14312fi
14313fi
14314
Ronald Oussoren450d5612009-06-08 21:12:41 +000014315{ echo "$as_me:$LINENO: result: $with_dbmliborder" >&5
14316echo "${ECHO_T}$with_dbmliborder" >&6; }
Benjamin Peterson867475c2009-04-29 20:36:25 +000014317
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000014318# Determine if signalmodule should be used.
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014319
14320
Ronald Oussoren450d5612009-06-08 21:12:41 +000014321{ echo "$as_me:$LINENO: checking for --with-signal-module" >&5
14322echo $ECHO_N "checking for --with-signal-module... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014323
Martin v. Löwiseba40652007-08-30 20:10:57 +000014324# Check whether --with-signal-module was given.
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014325if test "${with_signal_module+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014326 withval=$with_signal_module;
14327fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014328
14329
14330if test -z "$with_signal_module"
14331then with_signal_module="yes"
14332fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014333{ echo "$as_me:$LINENO: result: $with_signal_module" >&5
14334echo "${ECHO_T}$with_signal_module" >&6; }
Neil Schemenauerd32c2492001-01-24 17:25:28 +000014335
14336if test "${with_signal_module}" = "yes"; then
14337 USE_SIGNAL_MODULE=""
14338 SIGNAL_OBJS=""
14339else
14340 USE_SIGNAL_MODULE="#"
14341 SIGNAL_OBJS="Parser/intrcheck.o Python/sigcheck.o"
14342fi
14343
Guido van Rossum3d15bd82001-01-10 18:53:48 +000014344# This is used to generate Setup.config
Guido van Rossum009f7871997-12-04 00:51:42 +000014345
Barry Warsawc0d24d82000-06-29 16:12:00 +000014346USE_THREAD_MODULE=""
Guido van Rossum009f7871997-12-04 00:51:42 +000014347
Ronald Oussoren450d5612009-06-08 21:12:41 +000014348{ echo "$as_me:$LINENO: checking for --with-dec-threads" >&5
14349echo $ECHO_N "checking for --with-dec-threads... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014350
Guido van Rossumec2f0731997-01-22 20:54:01 +000014351
Martin v. Löwiseba40652007-08-30 20:10:57 +000014352# Check whether --with-dec-threads was given.
Guido van Rossumec2f0731997-01-22 20:54:01 +000014353if test "${with_dec_threads+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014354 withval=$with_dec_threads;
Ronald Oussoren450d5612009-06-08 21:12:41 +000014355{ echo "$as_me:$LINENO: result: $withval" >&5
14356echo "${ECHO_T}$withval" >&6; }
Guido van Rossumec2f0731997-01-22 20:54:01 +000014357LDLAST=-threads
Guido van Rossumf78abae1997-01-21 22:02:36 +000014358if test "${with_thread+set}" != set; then
Guido van Rossumec2f0731997-01-22 20:54:01 +000014359 with_thread="$withval";
Guido van Rossumf78abae1997-01-21 22:02:36 +000014360fi
Guido van Rossumec2f0731997-01-22 20:54:01 +000014361else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014362 { echo "$as_me:$LINENO: result: no" >&5
14363echo "${ECHO_T}no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000014364fi
14365
Martin v. Löwis11437992002-04-12 09:54:03 +000014366
14367# Templates for things AC_DEFINEd more than once.
14368# For a single AC_DEFINE, no template is needed.
Guido van Rossumec2f0731997-01-22 20:54:01 +000014369
14370
Martin v. Löwis11437992002-04-12 09:54:03 +000014371
14372
14373
14374
14375
Ronald Oussoren450d5612009-06-08 21:12:41 +000014376{ echo "$as_me:$LINENO: checking for --with-threads" >&5
14377echo $ECHO_N "checking for --with-threads... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014378
Martin v. Löwiseba40652007-08-30 20:10:57 +000014379# Check whether --with-threads was given.
Guido van Rossumec2f0731997-01-22 20:54:01 +000014380if test "${with_threads+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014381 withval=$with_threads;
14382fi
Guido van Rossumec2f0731997-01-22 20:54:01 +000014383
14384
Barry Warsawc0d24d82000-06-29 16:12:00 +000014385# --with-thread is deprecated, but check for it anyway
Martin v. Löwis11437992002-04-12 09:54:03 +000014386
Martin v. Löwiseba40652007-08-30 20:10:57 +000014387# Check whether --with-thread was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000014388if test "${with_thread+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000014389 withval=$with_thread; with_threads=$with_thread
14390fi
14391
Barry Warsawc0d24d82000-06-29 16:12:00 +000014392
14393if test -z "$with_threads"
14394then with_threads="yes"
14395fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014396{ echo "$as_me:$LINENO: result: $with_threads" >&5
14397echo "${ECHO_T}$with_threads" >&6; }
Barry Warsawc0d24d82000-06-29 16:12:00 +000014398
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014399
Barry Warsawc0d24d82000-06-29 16:12:00 +000014400if test "$with_threads" = "no"
14401then
14402 USE_THREAD_MODULE="#"
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014403elif test "$ac_cv_pthread_is_default" = yes
14404then
Martin v. Löwis11437992002-04-12 09:54:03 +000014405 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014406#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014407_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014408
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014409 # Defining _REENTRANT on system with POSIX threads should not hurt.
Martin v. Löwis11437992002-04-12 09:54:03 +000014410 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014411#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014412_ACEOF
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000014413
14414 posix_threads=yes
Martin v. Löwis11437992002-04-12 09:54:03 +000014415 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000014416elif test "$ac_cv_kpthread" = "yes"
14417then
14418 CC="$CC -Kpthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000014419 if test "$ac_cv_cxx_thread" = "yes"; then
14420 CXX="$CXX -Kpthread"
14421 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000014422 cat >>confdefs.h <<\_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000014423#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014424_ACEOF
Guido van Rossum2242f2f2001-04-11 20:58:20 +000014425
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000014426 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014427 THREADOBJ="Python/thread.o"
Martin v. Löwis5f433f02003-05-05 05:05:30 +000014428elif test "$ac_cv_kthread" = "yes"
14429then
14430 CC="$CC -Kthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000014431 if test "$ac_cv_cxx_thread" = "yes"; then
14432 CXX="$CXX -Kthread"
14433 fi
Martin v. Löwis5f433f02003-05-05 05:05:30 +000014434 cat >>confdefs.h <<\_ACEOF
14435#define WITH_THREAD 1
14436_ACEOF
14437
14438 posix_threads=yes
14439 THREADOBJ="Python/thread.o"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014440elif test "$ac_cv_pthread" = "yes"
14441then
14442 CC="$CC -pthread"
Martin v. Löwis519adae2003-09-20 10:47:47 +000014443 if test "$ac_cv_cxx_thread" = "yes"; then
14444 CXX="$CXX -pthread"
14445 fi
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000014446 cat >>confdefs.h <<\_ACEOF
14447#define WITH_THREAD 1
14448_ACEOF
14449
14450 posix_threads=yes
14451 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000014452else
14453 if test ! -z "$with_threads" -a -d "$with_threads"
14454 then LDFLAGS="$LDFLAGS -L$with_threads"
14455 fi
14456 if test ! -z "$withval" -a -d "$withval"
14457 then LDFLAGS="$LDFLAGS -L$withval"
14458 fi
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014459
14460 # According to the POSIX spec, a pthreads implementation must
Matthias Klosea2542be2004-08-16 11:35:51 +000014461 # define _POSIX_THREADS in unistd.h. Some apparently don't
14462 # (e.g. gnu pth with pthread emulation)
Ronald Oussoren450d5612009-06-08 21:12:41 +000014463 { echo "$as_me:$LINENO: checking for _POSIX_THREADS in unistd.h" >&5
14464echo $ECHO_N "checking for _POSIX_THREADS in unistd.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014465 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014466/* confdefs.h. */
14467_ACEOF
14468cat confdefs.h >>conftest.$ac_ext
14469cat >>conftest.$ac_ext <<_ACEOF
14470/* end confdefs.h. */
Neal Norwitz6eb37f02003-02-23 23:28:15 +000014471
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014472#include <unistd.h>
Neal Norwitz6eb37f02003-02-23 23:28:15 +000014473#ifdef _POSIX_THREADS
14474yes
14475#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014476
14477_ACEOF
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014478if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000014479 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014480 unistd_defines_pthreads=yes
14481else
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014482 unistd_defines_pthreads=no
14483fi
14484rm -f conftest*
14485
Ronald Oussoren450d5612009-06-08 21:12:41 +000014486 { echo "$as_me:$LINENO: result: $unistd_defines_pthreads" >&5
14487echo "${ECHO_T}$unistd_defines_pthreads" >&6; }
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014488
Martin v. Löwis11437992002-04-12 09:54:03 +000014489 cat >>confdefs.h <<\_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000014490#define _REENTRANT 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014491_ACEOF
Guido van Rossum9caf77a1996-08-01 00:52:26 +000014492
Martin v. Löwis11437992002-04-12 09:54:03 +000014493 if test "${ac_cv_header_cthreads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014494 { echo "$as_me:$LINENO: checking for cthreads.h" >&5
14495echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014496if test "${ac_cv_header_cthreads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014497 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014498fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014499{ echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
14500echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6; }
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014501else
Martin v. Löwis11437992002-04-12 09:54:03 +000014502 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +000014503{ echo "$as_me:$LINENO: checking cthreads.h usability" >&5
14504echo $ECHO_N "checking cthreads.h usability... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014505cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014506/* confdefs.h. */
14507_ACEOF
14508cat confdefs.h >>conftest.$ac_ext
14509cat >>conftest.$ac_ext <<_ACEOF
14510/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014511$ac_includes_default
14512#include <cthreads.h>
14513_ACEOF
14514rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014515if { (ac_try="$ac_compile"
14516case "(($ac_try" in
14517 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14518 *) ac_try_echo=$ac_try;;
14519esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014520eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014521 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014522 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014523 grep -v '^ *+' conftest.er1 >conftest.err
14524 rm -f conftest.er1
14525 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014526 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014527 (exit $ac_status); } && {
14528 test -z "$ac_c_werror_flag" ||
14529 test ! -s conftest.err
14530 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014531 ac_header_compiler=yes
14532else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014533 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014534sed 's/^/| /' conftest.$ac_ext >&5
14535
Martin v. Löwiseba40652007-08-30 20:10:57 +000014536 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014537fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014538
14539rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000014540{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14541echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014542
14543# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +000014544{ echo "$as_me:$LINENO: checking cthreads.h presence" >&5
14545echo $ECHO_N "checking cthreads.h presence... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014546cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014547/* confdefs.h. */
14548_ACEOF
14549cat confdefs.h >>conftest.$ac_ext
14550cat >>conftest.$ac_ext <<_ACEOF
14551/* end confdefs.h. */
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014552#include <cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014553_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000014554if { (ac_try="$ac_cpp conftest.$ac_ext"
14555case "(($ac_try" in
14556 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14557 *) ac_try_echo=$ac_try;;
14558esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014559eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014560 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014561 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000014562 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000014563 rm -f conftest.er1
14564 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014565 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014566 (exit $ac_status); } >/dev/null && {
14567 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14568 test ! -s conftest.err
14569 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014570 ac_header_preproc=yes
14571else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014572 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014573sed 's/^/| /' conftest.$ac_ext >&5
14574
Martin v. Löwis11437992002-04-12 09:54:03 +000014575 ac_header_preproc=no
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014576fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014577
Martin v. Löwis11437992002-04-12 09:54:03 +000014578rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000014579{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14580echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014581
14582# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014583case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14584 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +000014585 { echo "$as_me:$LINENO: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
14586echo "$as_me: WARNING: cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14587 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the compiler's result" >&5
14588echo "$as_me: WARNING: cthreads.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000014589 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000014590 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000014591 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +000014592 { echo "$as_me:$LINENO: WARNING: cthreads.h: present but cannot be compiled" >&5
14593echo "$as_me: WARNING: cthreads.h: present but cannot be compiled" >&2;}
14594 { echo "$as_me:$LINENO: WARNING: cthreads.h: check for missing prerequisite headers?" >&5
14595echo "$as_me: WARNING: cthreads.h: check for missing prerequisite headers?" >&2;}
14596 { echo "$as_me:$LINENO: WARNING: cthreads.h: see the Autoconf documentation" >&5
14597echo "$as_me: WARNING: cthreads.h: see the Autoconf documentation" >&2;}
14598 { echo "$as_me:$LINENO: WARNING: cthreads.h: section \"Present But Cannot Be Compiled\"" >&5
14599echo "$as_me: WARNING: cthreads.h: section \"Present But Cannot Be Compiled\"" >&2;}
14600 { echo "$as_me:$LINENO: WARNING: cthreads.h: proceeding with the preprocessor's result" >&5
14601echo "$as_me: WARNING: cthreads.h: proceeding with the preprocessor's result" >&2;}
14602 { echo "$as_me:$LINENO: WARNING: cthreads.h: in the future, the compiler will take precedence" >&5
14603echo "$as_me: WARNING: cthreads.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000014604 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000014605## -------------------------------------- ##
14606## Report this to http://bugs.python.org/ ##
14607## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000014608_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000014609 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000014610 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000014611esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014612{ echo "$as_me:$LINENO: checking for cthreads.h" >&5
14613echo $ECHO_N "checking for cthreads.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014614if test "${ac_cv_header_cthreads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014615 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014616else
14617 ac_cv_header_cthreads_h=$ac_header_preproc
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014618fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014619{ echo "$as_me:$LINENO: result: $ac_cv_header_cthreads_h" >&5
14620echo "${ECHO_T}$ac_cv_header_cthreads_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014621
14622fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014623if test $ac_cv_header_cthreads_h = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014624 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014625#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014626_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014627
Martin v. Löwis11437992002-04-12 09:54:03 +000014628 cat >>confdefs.h <<\_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014629#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014630_ACEOF
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014631
Martin v. Löwis11437992002-04-12 09:54:03 +000014632
14633cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014634#define HURD_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014635_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014636
14637 LIBS="$LIBS -lthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014638 THREADOBJ="Python/thread.o"
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014639else
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014640
Martin v. Löwis11437992002-04-12 09:54:03 +000014641 if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014642 { echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
14643echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014644if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014645 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014646fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014647{ echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
14648echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6; }
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014649else
Martin v. Löwis11437992002-04-12 09:54:03 +000014650 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +000014651{ echo "$as_me:$LINENO: checking mach/cthreads.h usability" >&5
14652echo $ECHO_N "checking mach/cthreads.h usability... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014653cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014654/* confdefs.h. */
14655_ACEOF
14656cat confdefs.h >>conftest.$ac_ext
14657cat >>conftest.$ac_ext <<_ACEOF
14658/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014659$ac_includes_default
14660#include <mach/cthreads.h>
14661_ACEOF
14662rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014663if { (ac_try="$ac_compile"
14664case "(($ac_try" in
14665 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14666 *) ac_try_echo=$ac_try;;
14667esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014668eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014669 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014670 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014671 grep -v '^ *+' conftest.er1 >conftest.err
14672 rm -f conftest.er1
14673 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014674 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014675 (exit $ac_status); } && {
14676 test -z "$ac_c_werror_flag" ||
14677 test ! -s conftest.err
14678 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014679 ac_header_compiler=yes
14680else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014681 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014682sed 's/^/| /' conftest.$ac_ext >&5
14683
Martin v. Löwiseba40652007-08-30 20:10:57 +000014684 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000014685fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014686
14687rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000014688{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14689echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014690
14691# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +000014692{ echo "$as_me:$LINENO: checking mach/cthreads.h presence" >&5
14693echo $ECHO_N "checking mach/cthreads.h presence... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014694cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014695/* confdefs.h. */
14696_ACEOF
14697cat confdefs.h >>conftest.$ac_ext
14698cat >>conftest.$ac_ext <<_ACEOF
14699/* end confdefs.h. */
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014700#include <mach/cthreads.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000014701_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000014702if { (ac_try="$ac_cpp conftest.$ac_ext"
14703case "(($ac_try" in
14704 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14705 *) ac_try_echo=$ac_try;;
14706esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014707eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014708 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014709 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000014710 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000014711 rm -f conftest.er1
14712 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014713 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014714 (exit $ac_status); } >/dev/null && {
14715 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14716 test ! -s conftest.err
14717 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014718 ac_header_preproc=yes
14719else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014720 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014721sed 's/^/| /' conftest.$ac_ext >&5
14722
Martin v. Löwis11437992002-04-12 09:54:03 +000014723 ac_header_preproc=no
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014724fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014725
Martin v. Löwis11437992002-04-12 09:54:03 +000014726rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000014727{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14728echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014729
14730# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014731case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14732 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +000014733 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&5
14734echo "$as_me: WARNING: mach/cthreads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14735 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the compiler's result" >&5
14736echo "$as_me: WARNING: mach/cthreads.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000014737 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000014738 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000014739 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +000014740 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: present but cannot be compiled" >&5
14741echo "$as_me: WARNING: mach/cthreads.h: present but cannot be compiled" >&2;}
14742 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&5
14743echo "$as_me: WARNING: mach/cthreads.h: check for missing prerequisite headers?" >&2;}
14744 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: see the Autoconf documentation" >&5
14745echo "$as_me: WARNING: mach/cthreads.h: see the Autoconf documentation" >&2;}
14746 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: section \"Present But Cannot Be Compiled\"" >&5
14747echo "$as_me: WARNING: mach/cthreads.h: section \"Present But Cannot Be Compiled\"" >&2;}
14748 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&5
14749echo "$as_me: WARNING: mach/cthreads.h: proceeding with the preprocessor's result" >&2;}
14750 { echo "$as_me:$LINENO: WARNING: mach/cthreads.h: in the future, the compiler will take precedence" >&5
14751echo "$as_me: WARNING: mach/cthreads.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000014752 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000014753## -------------------------------------- ##
14754## Report this to http://bugs.python.org/ ##
14755## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000014756_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000014757 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000014758 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000014759esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014760{ echo "$as_me:$LINENO: checking for mach/cthreads.h" >&5
14761echo $ECHO_N "checking for mach/cthreads.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014762if test "${ac_cv_header_mach_cthreads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014763 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000014764else
14765 ac_cv_header_mach_cthreads_h=$ac_header_preproc
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014766fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014767{ echo "$as_me:$LINENO: result: $ac_cv_header_mach_cthreads_h" >&5
14768echo "${ECHO_T}$ac_cv_header_mach_cthreads_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014769
14770fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014771if test $ac_cv_header_mach_cthreads_h = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014772 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014773#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014774_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014775
Martin v. Löwis11437992002-04-12 09:54:03 +000014776 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014777#define C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014778_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014779
Martin v. Löwis11437992002-04-12 09:54:03 +000014780
14781cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014782#define MACH_C_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014783_ACEOF
Martin v. Löwisa6e97582002-01-01 18:41:33 +000014784
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014785 THREADOBJ="Python/thread.o"
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014786else
Guido van Rossum7b3853f1996-07-30 18:09:35 +000014787
Ronald Oussoren450d5612009-06-08 21:12:41 +000014788 { echo "$as_me:$LINENO: checking for --with-pth" >&5
14789echo $ECHO_N "checking for --with-pth... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014790
Martin v. Löwiseba40652007-08-30 20:10:57 +000014791# Check whether --with-pth was given.
Guido van Rossum9e8181b2000-09-19 00:46:46 +000014792if test "${with_pth+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014793 withval=$with_pth; { echo "$as_me:$LINENO: result: $withval" >&5
14794echo "${ECHO_T}$withval" >&6; }
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000014795 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000014796#define WITH_THREAD 1
14797_ACEOF
14798
14799
14800cat >>confdefs.h <<\_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000014801#define HAVE_PTH 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014802_ACEOF
Guido van Rossum9e8181b2000-09-19 00:46:46 +000014803
Martin v. Löwis3e2c6322002-10-29 10:07:43 +000014804 LIBS="-lpth $LIBS"
14805 THREADOBJ="Python/thread.o"
Guido van Rossum9e8181b2000-09-19 00:46:46 +000014806else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014807 { echo "$as_me:$LINENO: result: no" >&5
14808echo "${ECHO_T}no" >&6; }
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000014809
14810 # Just looking for pthread_create in libpthread is not enough:
14811 # on HP/UX, pthread.h renames pthread_create to a different symbol name.
14812 # So we really have to include pthread.h, and then link.
14813 _libs=$LIBS
14814 LIBS="$LIBS -lpthread"
Ronald Oussoren450d5612009-06-08 21:12:41 +000014815 { echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
14816echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014817 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014818/* confdefs.h. */
14819_ACEOF
14820cat confdefs.h >>conftest.$ac_ext
14821cat >>conftest.$ac_ext <<_ACEOF
14822/* end confdefs.h. */
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000014823#include <pthread.h>
Guido van Rossum02a1c402000-02-25 19:26:31 +000014824
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000014825void * start_routine (void *arg) { exit (0); }
Martin v. Löwis11437992002-04-12 09:54:03 +000014826int
14827main ()
14828{
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000014829
14830pthread_create (NULL, NULL, start_routine, NULL)
Martin v. Löwis11437992002-04-12 09:54:03 +000014831 ;
14832 return 0;
14833}
14834_ACEOF
14835rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014836if { (ac_try="$ac_link"
14837case "(($ac_try" in
14838 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14839 *) ac_try_echo=$ac_try;;
14840esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014841eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014842 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014843 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014844 grep -v '^ *+' conftest.er1 >conftest.err
14845 rm -f conftest.er1
14846 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014848 (exit $ac_status); } && {
14849 test -z "$ac_c_werror_flag" ||
14850 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000014851 } && test -s conftest$ac_exeext &&
14852 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014853
Ronald Oussoren450d5612009-06-08 21:12:41 +000014854 { echo "$as_me:$LINENO: result: yes" >&5
14855echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014856 cat >>confdefs.h <<\_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000014857#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014858_ACEOF
Guido van Rossum02a1c402000-02-25 19:26:31 +000014859
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014860 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014861 THREADOBJ="Python/thread.o"
Guido van Rossum02a1c402000-02-25 19:26:31 +000014862else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014863 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014864sed 's/^/| /' conftest.$ac_ext >&5
14865
Martin v. Löwis11437992002-04-12 09:54:03 +000014866
Martin v. Löwis8158b5a2001-10-08 13:17:28 +000014867 LIBS=$_libs
Ronald Oussoren450d5612009-06-08 21:12:41 +000014868 { echo "$as_me:$LINENO: checking for pthread_detach" >&5
14869echo $ECHO_N "checking for pthread_detach... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000014870if test "${ac_cv_func_pthread_detach+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014871 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumad678af1998-10-02 14:42:15 +000014872else
Martin v. Löwis11437992002-04-12 09:54:03 +000014873 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014874/* confdefs.h. */
14875_ACEOF
14876cat confdefs.h >>conftest.$ac_ext
14877cat >>conftest.$ac_ext <<_ACEOF
14878/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000014879/* Define pthread_detach to an innocuous variant, in case <limits.h> declares pthread_detach.
14880 For example, HP-UX 11i <limits.h> declares gettimeofday. */
14881#define pthread_detach innocuous_pthread_detach
14882
Guido van Rossumad678af1998-10-02 14:42:15 +000014883/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000014884 which can conflict with char pthread_detach (); below.
14885 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000014886 <limits.h> exists even on freestanding compilers. */
14887
14888#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000014889# include <limits.h>
14890#else
14891# include <assert.h>
14892#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000014893
14894#undef pthread_detach
14895
Martin v. Löwiseba40652007-08-30 20:10:57 +000014896/* Override any GCC internal prototype to avoid an error.
14897 Use char because int might match the return type of a GCC
14898 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000014899#ifdef __cplusplus
14900extern "C"
14901#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000014902char pthread_detach ();
Guido van Rossumad678af1998-10-02 14:42:15 +000014903/* The GNU C library defines this for functions which it implements
14904 to always fail with ENOSYS. Some functions are actually named
14905 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000014906#if defined __stub_pthread_detach || defined __stub___pthread_detach
Guido van Rossumad678af1998-10-02 14:42:15 +000014907choke me
Guido van Rossumad678af1998-10-02 14:42:15 +000014908#endif
14909
Skip Montanaro6dead952003-09-25 14:50:04 +000014910int
14911main ()
14912{
Martin v. Löwiseba40652007-08-30 20:10:57 +000014913return pthread_detach ();
Martin v. Löwis11437992002-04-12 09:54:03 +000014914 ;
14915 return 0;
14916}
14917_ACEOF
14918rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014919if { (ac_try="$ac_link"
14920case "(($ac_try" in
14921 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14922 *) ac_try_echo=$ac_try;;
14923esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014924eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014925 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000014926 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014927 grep -v '^ *+' conftest.er1 >conftest.err
14928 rm -f conftest.er1
14929 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014930 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014931 (exit $ac_status); } && {
14932 test -z "$ac_c_werror_flag" ||
14933 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000014934 } && test -s conftest$ac_exeext &&
14935 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014936 ac_cv_func_pthread_detach=yes
Guido van Rossumad678af1998-10-02 14:42:15 +000014937else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014938 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014939sed 's/^/| /' conftest.$ac_ext >&5
14940
Martin v. Löwiseba40652007-08-30 20:10:57 +000014941 ac_cv_func_pthread_detach=no
Guido van Rossumad678af1998-10-02 14:42:15 +000014942fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000014943
14944rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000014945 conftest$ac_exeext conftest.$ac_ext
Guido van Rossumad678af1998-10-02 14:42:15 +000014946fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014947{ echo "$as_me:$LINENO: result: $ac_cv_func_pthread_detach" >&5
14948echo "${ECHO_T}$ac_cv_func_pthread_detach" >&6; }
14949if test $ac_cv_func_pthread_detach = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000014950 cat >>confdefs.h <<\_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000014951#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000014952_ACEOF
Guido van Rossumad678af1998-10-02 14:42:15 +000014953
Martin v. Löwis69c0ff32001-10-15 14:34:42 +000014954 posix_threads=yes
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000014955 THREADOBJ="Python/thread.o"
Guido van Rossumad678af1998-10-02 14:42:15 +000014956else
Guido van Rossumad678af1998-10-02 14:42:15 +000014957
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014958 if test "${ac_cv_header_atheos_threads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014959 { echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
14960echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014961if test "${ac_cv_header_atheos_threads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000014962 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014963fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000014964{ echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
14965echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014966else
14967 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +000014968{ echo "$as_me:$LINENO: checking atheos/threads.h usability" >&5
14969echo $ECHO_N "checking atheos/threads.h usability... $ECHO_C" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014970cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000014971/* confdefs.h. */
14972_ACEOF
14973cat confdefs.h >>conftest.$ac_ext
14974cat >>conftest.$ac_ext <<_ACEOF
14975/* end confdefs.h. */
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014976$ac_includes_default
14977#include <atheos/threads.h>
14978_ACEOF
14979rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000014980if { (ac_try="$ac_compile"
14981case "(($ac_try" in
14982 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14983 *) ac_try_echo=$ac_try;;
14984esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000014985eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014986 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014987 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000014988 grep -v '^ *+' conftest.er1 >conftest.err
14989 rm -f conftest.er1
14990 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000014991 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000014992 (exit $ac_status); } && {
14993 test -z "$ac_c_werror_flag" ||
14994 test ! -s conftest.err
14995 } && test -s conftest.$ac_objext; then
Martin v. Löwisf90ae202002-06-11 06:22:31 +000014996 ac_header_compiler=yes
14997else
Ronald Oussoren450d5612009-06-08 21:12:41 +000014998 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000014999sed 's/^/| /' conftest.$ac_ext >&5
15000
Martin v. Löwiseba40652007-08-30 20:10:57 +000015001 ac_header_compiler=no
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015002fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015003
15004rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000015005{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15006echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015007
15008# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015009{ echo "$as_me:$LINENO: checking atheos/threads.h presence" >&5
15010echo $ECHO_N "checking atheos/threads.h presence... $ECHO_C" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015011cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015012/* confdefs.h. */
15013_ACEOF
15014cat confdefs.h >>conftest.$ac_ext
15015cat >>conftest.$ac_ext <<_ACEOF
15016/* end confdefs.h. */
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015017#include <atheos/threads.h>
15018_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000015019if { (ac_try="$ac_cpp conftest.$ac_ext"
15020case "(($ac_try" in
15021 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15022 *) ac_try_echo=$ac_try;;
15023esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015024eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015025 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015026 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000015027 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015028 rm -f conftest.er1
15029 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015030 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015031 (exit $ac_status); } >/dev/null && {
15032 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15033 test ! -s conftest.err
15034 }; then
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015035 ac_header_preproc=yes
15036else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015037 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015038sed 's/^/| /' conftest.$ac_ext >&5
15039
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015040 ac_header_preproc=no
15041fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015042
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015043rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000015044{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15045echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015046
15047# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015048case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15049 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +000015050 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&5
15051echo "$as_me: WARNING: atheos/threads.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15052 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the compiler's result" >&5
15053echo "$as_me: WARNING: atheos/threads.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000015054 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000015055 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000015056 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +000015057 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: present but cannot be compiled" >&5
15058echo "$as_me: WARNING: atheos/threads.h: present but cannot be compiled" >&2;}
15059 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&5
15060echo "$as_me: WARNING: atheos/threads.h: check for missing prerequisite headers?" >&2;}
15061 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: see the Autoconf documentation" >&5
15062echo "$as_me: WARNING: atheos/threads.h: see the Autoconf documentation" >&2;}
15063 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: section \"Present But Cannot Be Compiled\"" >&5
15064echo "$as_me: WARNING: atheos/threads.h: section \"Present But Cannot Be Compiled\"" >&2;}
15065 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&5
15066echo "$as_me: WARNING: atheos/threads.h: proceeding with the preprocessor's result" >&2;}
15067 { echo "$as_me:$LINENO: WARNING: atheos/threads.h: in the future, the compiler will take precedence" >&5
15068echo "$as_me: WARNING: atheos/threads.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000015069 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000015070## -------------------------------------- ##
15071## Report this to http://bugs.python.org/ ##
15072## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000015073_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000015074 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000015075 ;;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015076esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015077{ echo "$as_me:$LINENO: checking for atheos/threads.h" >&5
15078echo $ECHO_N "checking for atheos/threads.h... $ECHO_C" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015079if test "${ac_cv_header_atheos_threads_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015080 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015081else
15082 ac_cv_header_atheos_threads_h=$ac_header_preproc
15083fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015084{ echo "$as_me:$LINENO: result: $ac_cv_header_atheos_threads_h" >&5
15085echo "${ECHO_T}$ac_cv_header_atheos_threads_h" >&6; }
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015086
15087fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015088if test $ac_cv_header_atheos_threads_h = yes; then
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015089 cat >>confdefs.h <<\_ACEOF
15090#define WITH_THREAD 1
15091_ACEOF
15092
15093
15094cat >>confdefs.h <<\_ACEOF
15095#define ATHEOS_THREADS 1
15096_ACEOF
15097
15098 THREADOBJ="Python/thread.o"
15099else
15100
Martin v. Löwis11437992002-04-12 09:54:03 +000015101 if test "${ac_cv_header_kernel_OS_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015102 { echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
15103echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015104if test "${ac_cv_header_kernel_OS_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015105 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000015106fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015107{ echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
15108echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015109else
Martin v. Löwis11437992002-04-12 09:54:03 +000015110 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015111{ echo "$as_me:$LINENO: checking kernel/OS.h usability" >&5
15112echo $ECHO_N "checking kernel/OS.h usability... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015113cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015114/* confdefs.h. */
15115_ACEOF
15116cat confdefs.h >>conftest.$ac_ext
15117cat >>conftest.$ac_ext <<_ACEOF
15118/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015119$ac_includes_default
15120#include <kernel/OS.h>
15121_ACEOF
15122rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015123if { (ac_try="$ac_compile"
15124case "(($ac_try" in
15125 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15126 *) ac_try_echo=$ac_try;;
15127esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015128eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015129 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015130 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015131 grep -v '^ *+' conftest.er1 >conftest.err
15132 rm -f conftest.er1
15133 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015134 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015135 (exit $ac_status); } && {
15136 test -z "$ac_c_werror_flag" ||
15137 test ! -s conftest.err
15138 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015139 ac_header_compiler=yes
15140else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015141 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015142sed 's/^/| /' conftest.$ac_ext >&5
15143
Martin v. Löwiseba40652007-08-30 20:10:57 +000015144 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000015145fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015146
15147rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000015148{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15149echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015150
15151# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015152{ echo "$as_me:$LINENO: checking kernel/OS.h presence" >&5
15153echo $ECHO_N "checking kernel/OS.h presence... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015154cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015155/* confdefs.h. */
15156_ACEOF
15157cat confdefs.h >>conftest.$ac_ext
15158cat >>conftest.$ac_ext <<_ACEOF
15159/* end confdefs.h. */
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015160#include <kernel/OS.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000015161_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000015162if { (ac_try="$ac_cpp conftest.$ac_ext"
15163case "(($ac_try" in
15164 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15165 *) ac_try_echo=$ac_try;;
15166esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015167eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015168 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015169 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000015170 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000015171 rm -f conftest.er1
15172 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015173 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015174 (exit $ac_status); } >/dev/null && {
15175 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
15176 test ! -s conftest.err
15177 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015178 ac_header_preproc=yes
15179else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015180 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015181sed 's/^/| /' conftest.$ac_ext >&5
15182
Martin v. Löwis11437992002-04-12 09:54:03 +000015183 ac_header_preproc=no
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015184fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015185
Martin v. Löwis11437992002-04-12 09:54:03 +000015186rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000015187{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15188echo "${ECHO_T}$ac_header_preproc" >&6; }
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015189
Martin v. Löwis11437992002-04-12 09:54:03 +000015190# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015191case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15192 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +000015193 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&5
15194echo "$as_me: WARNING: kernel/OS.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15195 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the compiler's result" >&5
15196echo "$as_me: WARNING: kernel/OS.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000015197 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000015198 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000015199 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +000015200 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: present but cannot be compiled" >&5
15201echo "$as_me: WARNING: kernel/OS.h: present but cannot be compiled" >&2;}
15202 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&5
15203echo "$as_me: WARNING: kernel/OS.h: check for missing prerequisite headers?" >&2;}
15204 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: see the Autoconf documentation" >&5
15205echo "$as_me: WARNING: kernel/OS.h: see the Autoconf documentation" >&2;}
15206 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: section \"Present But Cannot Be Compiled\"" >&5
15207echo "$as_me: WARNING: kernel/OS.h: section \"Present But Cannot Be Compiled\"" >&2;}
15208 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&5
15209echo "$as_me: WARNING: kernel/OS.h: proceeding with the preprocessor's result" >&2;}
15210 { echo "$as_me:$LINENO: WARNING: kernel/OS.h: in the future, the compiler will take precedence" >&5
15211echo "$as_me: WARNING: kernel/OS.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000015212 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000015213## -------------------------------------- ##
15214## Report this to http://bugs.python.org/ ##
15215## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000015216_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000015217 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000015218 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000015219esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015220{ echo "$as_me:$LINENO: checking for kernel/OS.h" >&5
15221echo $ECHO_N "checking for kernel/OS.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015222if test "${ac_cv_header_kernel_OS_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015223 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000015224else
15225 ac_cv_header_kernel_OS_h=$ac_header_preproc
15226fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015227{ echo "$as_me:$LINENO: result: $ac_cv_header_kernel_OS_h" >&5
15228echo "${ECHO_T}$ac_cv_header_kernel_OS_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015229
15230fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015231if test $ac_cv_header_kernel_OS_h = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015232 cat >>confdefs.h <<\_ACEOF
15233#define WITH_THREAD 1
15234_ACEOF
15235
15236
15237cat >>confdefs.h <<\_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015238#define BEOS_THREADS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015239_ACEOF
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015240
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015241 THREADOBJ="Python/thread.o"
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015242else
Guido van Rossumec95c7b1998-08-04 17:59:56 +000015243
Ronald Oussoren450d5612009-06-08 21:12:41 +000015244 { echo "$as_me:$LINENO: checking for pthread_create in -lpthreads" >&5
15245echo $ECHO_N "checking for pthread_create in -lpthreads... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015246if test "${ac_cv_lib_pthreads_pthread_create+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015247 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015248else
Martin v. Löwis11437992002-04-12 09:54:03 +000015249 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015250LIBS="-lpthreads $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015251cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015252/* confdefs.h. */
15253_ACEOF
15254cat confdefs.h >>conftest.$ac_ext
15255cat >>conftest.$ac_ext <<_ACEOF
15256/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015257
Martin v. Löwiseba40652007-08-30 20:10:57 +000015258/* Override any GCC internal prototype to avoid an error.
15259 Use char because int might match the return type of a GCC
15260 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015261#ifdef __cplusplus
15262extern "C"
15263#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015264char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015265int
15266main ()
15267{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015268return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015269 ;
15270 return 0;
15271}
15272_ACEOF
15273rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015274if { (ac_try="$ac_link"
15275case "(($ac_try" in
15276 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15277 *) ac_try_echo=$ac_try;;
15278esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015279eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015280 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015281 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015282 grep -v '^ *+' conftest.er1 >conftest.err
15283 rm -f conftest.er1
15284 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015285 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015286 (exit $ac_status); } && {
15287 test -z "$ac_c_werror_flag" ||
15288 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015289 } && test -s conftest$ac_exeext &&
15290 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015291 ac_cv_lib_pthreads_pthread_create=yes
Greg Steinadf63d62000-07-05 10:38:09 +000015292else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015293 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015294sed 's/^/| /' conftest.$ac_ext >&5
15295
Martin v. Löwiseba40652007-08-30 20:10:57 +000015296 ac_cv_lib_pthreads_pthread_create=no
Greg Steinadf63d62000-07-05 10:38:09 +000015297fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015298
15299rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015300 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015301LIBS=$ac_check_lib_save_LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000015302fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015303{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthreads_pthread_create" >&5
15304echo "${ECHO_T}$ac_cv_lib_pthreads_pthread_create" >&6; }
15305if test $ac_cv_lib_pthreads_pthread_create = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015306 cat >>confdefs.h <<\_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000015307#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015308_ACEOF
Greg Steinadf63d62000-07-05 10:38:09 +000015309
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015310 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015311 LIBS="$LIBS -lpthreads"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015312 THREADOBJ="Python/thread.o"
Greg Steinadf63d62000-07-05 10:38:09 +000015313else
Greg Steinadf63d62000-07-05 10:38:09 +000015314
Ronald Oussoren450d5612009-06-08 21:12:41 +000015315 { echo "$as_me:$LINENO: checking for pthread_create in -lc_r" >&5
15316echo $ECHO_N "checking for pthread_create in -lc_r... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015317if test "${ac_cv_lib_c_r_pthread_create+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015318 echo $ECHO_N "(cached) $ECHO_C" >&6
Greg Steinadf63d62000-07-05 10:38:09 +000015319else
Martin v. Löwis11437992002-04-12 09:54:03 +000015320 ac_check_lib_save_LIBS=$LIBS
Greg Steinadf63d62000-07-05 10:38:09 +000015321LIBS="-lc_r $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015322cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015323/* confdefs.h. */
15324_ACEOF
15325cat confdefs.h >>conftest.$ac_ext
15326cat >>conftest.$ac_ext <<_ACEOF
15327/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015328
Martin v. Löwiseba40652007-08-30 20:10:57 +000015329/* Override any GCC internal prototype to avoid an error.
15330 Use char because int might match the return type of a GCC
15331 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015332#ifdef __cplusplus
15333extern "C"
15334#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015335char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015336int
15337main ()
15338{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015339return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015340 ;
15341 return 0;
15342}
15343_ACEOF
15344rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015345if { (ac_try="$ac_link"
15346case "(($ac_try" in
15347 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15348 *) ac_try_echo=$ac_try;;
15349esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015350eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015351 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015352 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015353 grep -v '^ *+' conftest.er1 >conftest.err
15354 rm -f conftest.er1
15355 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015356 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015357 (exit $ac_status); } && {
15358 test -z "$ac_c_werror_flag" ||
15359 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015360 } && test -s conftest$ac_exeext &&
15361 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015362 ac_cv_lib_c_r_pthread_create=yes
Guido van Rossum49545951997-12-02 19:28:29 +000015363else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015364 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015365sed 's/^/| /' conftest.$ac_ext >&5
15366
Martin v. Löwiseba40652007-08-30 20:10:57 +000015367 ac_cv_lib_c_r_pthread_create=no
Guido van Rossum49545951997-12-02 19:28:29 +000015368fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015369
15370rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015371 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015372LIBS=$ac_check_lib_save_LIBS
Guido van Rossum49545951997-12-02 19:28:29 +000015373fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015374{ echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_create" >&5
15375echo "${ECHO_T}$ac_cv_lib_c_r_pthread_create" >&6; }
15376if test $ac_cv_lib_c_r_pthread_create = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015377 cat >>confdefs.h <<\_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000015378#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015379_ACEOF
Guido van Rossum49545951997-12-02 19:28:29 +000015380
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015381 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015382 LIBS="$LIBS -lc_r"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015383 THREADOBJ="Python/thread.o"
Guido van Rossum07bd90e2000-05-08 13:41:38 +000015384else
Guido van Rossum07bd90e2000-05-08 13:41:38 +000015385
Ronald Oussoren450d5612009-06-08 21:12:41 +000015386 { echo "$as_me:$LINENO: checking for __pthread_create_system in -lpthread" >&5
15387echo $ECHO_N "checking for __pthread_create_system in -lpthread... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015388if test "${ac_cv_lib_pthread___pthread_create_system+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015389 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015390else
Martin v. Löwis11437992002-04-12 09:54:03 +000015391 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015392LIBS="-lpthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015393cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015394/* confdefs.h. */
15395_ACEOF
15396cat confdefs.h >>conftest.$ac_ext
15397cat >>conftest.$ac_ext <<_ACEOF
15398/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015399
Martin v. Löwiseba40652007-08-30 20:10:57 +000015400/* Override any GCC internal prototype to avoid an error.
15401 Use char because int might match the return type of a GCC
15402 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015403#ifdef __cplusplus
15404extern "C"
15405#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015406char __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015407int
15408main ()
15409{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015410return __pthread_create_system ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015411 ;
15412 return 0;
15413}
15414_ACEOF
15415rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015416if { (ac_try="$ac_link"
15417case "(($ac_try" in
15418 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15419 *) ac_try_echo=$ac_try;;
15420esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015421eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015422 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015423 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015424 grep -v '^ *+' conftest.er1 >conftest.err
15425 rm -f conftest.er1
15426 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015428 (exit $ac_status); } && {
15429 test -z "$ac_c_werror_flag" ||
15430 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015431 } && test -s conftest$ac_exeext &&
15432 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015433 ac_cv_lib_pthread___pthread_create_system=yes
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015434else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015435 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015436sed 's/^/| /' conftest.$ac_ext >&5
15437
Martin v. Löwiseba40652007-08-30 20:10:57 +000015438 ac_cv_lib_pthread___pthread_create_system=no
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015439fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015440
15441rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015442 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015443LIBS=$ac_check_lib_save_LIBS
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015444fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015445{ echo "$as_me:$LINENO: result: $ac_cv_lib_pthread___pthread_create_system" >&5
15446echo "${ECHO_T}$ac_cv_lib_pthread___pthread_create_system" >&6; }
15447if test $ac_cv_lib_pthread___pthread_create_system = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015448 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015449#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015450_ACEOF
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015451
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015452 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015453 LIBS="$LIBS -lpthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015454 THREADOBJ="Python/thread.o"
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015455else
Guido van Rossum8d6e8af2000-10-30 17:45:07 +000015456
Ronald Oussoren450d5612009-06-08 21:12:41 +000015457 { echo "$as_me:$LINENO: checking for pthread_create in -lcma" >&5
15458echo $ECHO_N "checking for pthread_create in -lcma... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015459if test "${ac_cv_lib_cma_pthread_create+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015460 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumb93a8621998-05-07 13:27:32 +000015461else
Martin v. Löwis11437992002-04-12 09:54:03 +000015462 ac_check_lib_save_LIBS=$LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000015463LIBS="-lcma $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015464cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015465/* confdefs.h. */
15466_ACEOF
15467cat confdefs.h >>conftest.$ac_ext
15468cat >>conftest.$ac_ext <<_ACEOF
15469/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015470
Martin v. Löwiseba40652007-08-30 20:10:57 +000015471/* Override any GCC internal prototype to avoid an error.
15472 Use char because int might match the return type of a GCC
15473 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015474#ifdef __cplusplus
15475extern "C"
15476#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015477char pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015478int
15479main ()
15480{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015481return pthread_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015482 ;
15483 return 0;
15484}
15485_ACEOF
15486rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015487if { (ac_try="$ac_link"
15488case "(($ac_try" in
15489 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15490 *) ac_try_echo=$ac_try;;
15491esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015492eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015493 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015494 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015495 grep -v '^ *+' conftest.er1 >conftest.err
15496 rm -f conftest.er1
15497 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015498 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015499 (exit $ac_status); } && {
15500 test -z "$ac_c_werror_flag" ||
15501 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015502 } && test -s conftest$ac_exeext &&
15503 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015504 ac_cv_lib_cma_pthread_create=yes
Guido van Rossumb93a8621998-05-07 13:27:32 +000015505else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015506 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015507sed 's/^/| /' conftest.$ac_ext >&5
15508
Martin v. Löwiseba40652007-08-30 20:10:57 +000015509 ac_cv_lib_cma_pthread_create=no
Guido van Rossumb93a8621998-05-07 13:27:32 +000015510fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015511
15512rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015513 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015514LIBS=$ac_check_lib_save_LIBS
Guido van Rossumb93a8621998-05-07 13:27:32 +000015515fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015516{ echo "$as_me:$LINENO: result: $ac_cv_lib_cma_pthread_create" >&5
15517echo "${ECHO_T}$ac_cv_lib_cma_pthread_create" >&6; }
15518if test $ac_cv_lib_cma_pthread_create = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015519 cat >>confdefs.h <<\_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000015520#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015521_ACEOF
Guido van Rossumb93a8621998-05-07 13:27:32 +000015522
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000015523 posix_threads=yes
Martin v. Löwis130fb172001-07-19 11:00:41 +000015524 LIBS="$LIBS -lcma"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015525 THREADOBJ="Python/thread.o"
Guido van Rossumb93a8621998-05-07 13:27:32 +000015526else
Thomas Wouters0db2b2b2000-08-26 11:33:43 +000015527
Martin v. Löwis130fb172001-07-19 11:00:41 +000015528 USE_THREAD_MODULE="#"
Guido van Rossum2d38f911996-06-26 19:47:01 +000015529fi
15530
Guido van Rossum627b2d71993-12-24 10:39:16 +000015531
Guido van Rossum7b3853f1996-07-30 18:09:35 +000015532fi
15533
Guido van Rossum0be3e491997-05-22 20:33:33 +000015534fi
15535
Guido van Rossum49545951997-12-02 19:28:29 +000015536fi
15537
Guido van Rossumb93a8621998-05-07 13:27:32 +000015538fi
15539
Guido van Rossum07bd90e2000-05-08 13:41:38 +000015540
Michael W. Hudson54241132001-12-07 15:38:26 +000015541fi
15542
Martin v. Löwisf90ae202002-06-11 06:22:31 +000015543
15544fi
15545
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015546fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015547
15548rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015549 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015550fi
15551
Martin v. Löwis11437992002-04-12 09:54:03 +000015552fi
15553
15554
15555fi
15556
Martin v. Löwisa6e97582002-01-01 18:41:33 +000015557
Michael W. Hudson54241132001-12-07 15:38:26 +000015558
Ronald Oussoren450d5612009-06-08 21:12:41 +000015559 { echo "$as_me:$LINENO: checking for usconfig in -lmpc" >&5
15560echo $ECHO_N "checking for usconfig in -lmpc... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015561if test "${ac_cv_lib_mpc_usconfig+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015562 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015563else
Martin v. Löwis11437992002-04-12 09:54:03 +000015564 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015565LIBS="-lmpc $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015566cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015567/* confdefs.h. */
15568_ACEOF
15569cat confdefs.h >>conftest.$ac_ext
15570cat >>conftest.$ac_ext <<_ACEOF
15571/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015572
Martin v. Löwiseba40652007-08-30 20:10:57 +000015573/* Override any GCC internal prototype to avoid an error.
15574 Use char because int might match the return type of a GCC
15575 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015576#ifdef __cplusplus
15577extern "C"
15578#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015579char usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015580int
15581main ()
15582{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015583return usconfig ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015584 ;
15585 return 0;
15586}
15587_ACEOF
15588rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015589if { (ac_try="$ac_link"
15590case "(($ac_try" in
15591 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15592 *) ac_try_echo=$ac_try;;
15593esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015594eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015595 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015596 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015597 grep -v '^ *+' conftest.er1 >conftest.err
15598 rm -f conftest.er1
15599 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015600 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015601 (exit $ac_status); } && {
15602 test -z "$ac_c_werror_flag" ||
15603 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015604 } && test -s conftest$ac_exeext &&
15605 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015606 ac_cv_lib_mpc_usconfig=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015607else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015608 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015609sed 's/^/| /' conftest.$ac_ext >&5
15610
Martin v. Löwiseba40652007-08-30 20:10:57 +000015611 ac_cv_lib_mpc_usconfig=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015612fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015613
15614rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015615 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015616LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015617fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015618{ echo "$as_me:$LINENO: result: $ac_cv_lib_mpc_usconfig" >&5
15619echo "${ECHO_T}$ac_cv_lib_mpc_usconfig" >&6; }
15620if test $ac_cv_lib_mpc_usconfig = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015621 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015622#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015623_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000015624
Martin v. Löwis130fb172001-07-19 11:00:41 +000015625 LIBS="$LIBS -lmpc"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015626 THREADOBJ="Python/thread.o"
Martin v. Löwis130fb172001-07-19 11:00:41 +000015627 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000015628fi
15629
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000015630
Neal Norwitza978ab02002-11-02 16:58:05 +000015631 if test "$posix_threads" != "yes"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015632 { echo "$as_me:$LINENO: checking for thr_create in -lthread" >&5
15633echo $ECHO_N "checking for thr_create in -lthread... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015634if test "${ac_cv_lib_thread_thr_create+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015635 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015636else
Martin v. Löwis11437992002-04-12 09:54:03 +000015637 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000015638LIBS="-lthread $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000015639cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015640/* confdefs.h. */
15641_ACEOF
15642cat confdefs.h >>conftest.$ac_ext
15643cat >>conftest.$ac_ext <<_ACEOF
15644/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015645
Martin v. Löwiseba40652007-08-30 20:10:57 +000015646/* Override any GCC internal prototype to avoid an error.
15647 Use char because int might match the return type of a GCC
15648 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000015649#ifdef __cplusplus
15650extern "C"
15651#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000015652char thr_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015653int
15654main ()
15655{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015656return thr_create ();
Martin v. Löwis11437992002-04-12 09:54:03 +000015657 ;
15658 return 0;
15659}
15660_ACEOF
15661rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015662if { (ac_try="$ac_link"
15663case "(($ac_try" in
15664 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15665 *) ac_try_echo=$ac_try;;
15666esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015667eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015668 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000015669 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015670 grep -v '^ *+' conftest.er1 >conftest.err
15671 rm -f conftest.er1
15672 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015673 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015674 (exit $ac_status); } && {
15675 test -z "$ac_c_werror_flag" ||
15676 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015677 } && test -s conftest$ac_exeext &&
15678 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015679 ac_cv_lib_thread_thr_create=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015680else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015681 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015682sed 's/^/| /' conftest.$ac_ext >&5
15683
Martin v. Löwiseba40652007-08-30 20:10:57 +000015684 ac_cv_lib_thread_thr_create=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000015685fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015686
15687rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015688 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000015689LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015690fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015691{ echo "$as_me:$LINENO: result: $ac_cv_lib_thread_thr_create" >&5
15692echo "${ECHO_T}$ac_cv_lib_thread_thr_create" >&6; }
15693if test $ac_cv_lib_thread_thr_create = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000015694 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000015695#define WITH_THREAD 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015696_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000015697
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000015698 LIBS="$LIBS -lthread"
Martin v. Löwis2d7e2642002-04-05 16:50:53 +000015699 THREADOBJ="Python/thread.o"
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000015700 USE_THREAD_MODULE=""
Guido van Rossum627b2d71993-12-24 10:39:16 +000015701fi
15702
Martin v. Löwis3d2b5492002-03-15 13:48:21 +000015703 fi
Michael W. Hudson54241132001-12-07 15:38:26 +000015704
Martin v. Löwis130fb172001-07-19 11:00:41 +000015705 if test "$USE_THREAD_MODULE" != "#"
15706 then
15707 # If the above checks didn't disable threads, (at least) OSF1
15708 # needs this '-threads' argument during linking.
15709 case $ac_sys_system in
15710 OSF1) LDLAST=-threads;;
15711 esac
Jeremy Hylton1a2ca862000-10-16 16:59:12 +000015712 fi
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015713fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000015714
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015715if test "$posix_threads" = "yes"; then
15716 if test "$unistd_defines_pthreads" = "no"; then
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000015717
15718cat >>confdefs.h <<\_ACEOF
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015719#define _POSIX_THREADS 1
15720_ACEOF
15721
15722 fi
15723
15724 # Bug 662787: Using semaphores causes unexplicable hangs on Solaris 8.
15725 case $ac_sys_system/$ac_sys_release in
15726 SunOS/5.6)
15727cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000015728#define HAVE_PTHREAD_DESTRUCTOR 1
15729_ACEOF
15730
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015731 ;;
15732 SunOS/5.8)
15733cat >>confdefs.h <<\_ACEOF
15734#define HAVE_BROKEN_POSIX_SEMAPHORES 1
15735_ACEOF
15736
15737 ;;
Christian Heimescba36bb2008-01-30 22:54:18 +000015738 AIX/5)
15739cat >>confdefs.h <<\_ACEOF
15740#define HAVE_BROKEN_POSIX_SEMAPHORES 1
15741_ACEOF
15742
15743 ;;
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015744 esac
15745
Ronald Oussoren450d5612009-06-08 21:12:41 +000015746 { echo "$as_me:$LINENO: checking if PTHREAD_SCOPE_SYSTEM is supported" >&5
15747echo $ECHO_N "checking if PTHREAD_SCOPE_SYSTEM is supported... $ECHO_C" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015748 if test "${ac_cv_pthread_system_supported+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015749 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015750else
15751 if test "$cross_compiling" = yes; then
15752 ac_cv_pthread_system_supported=no
15753else
15754 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015755/* confdefs.h. */
15756_ACEOF
15757cat confdefs.h >>conftest.$ac_ext
15758cat >>conftest.$ac_ext <<_ACEOF
15759/* end confdefs.h. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015760#include <pthread.h>
15761 void *foo(void *parm) {
15762 return NULL;
15763 }
15764 main() {
15765 pthread_attr_t attr;
15766 pthread_t id;
15767 if (pthread_attr_init(&attr)) exit(-1);
15768 if (pthread_attr_setscope(&attr, PTHREAD_SCOPE_SYSTEM)) exit(-1);
15769 if (pthread_create(&id, &attr, foo, NULL)) exit(-1);
15770 exit(0);
15771 }
15772_ACEOF
15773rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015774if { (ac_try="$ac_link"
15775case "(($ac_try" in
15776 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15777 *) ac_try_echo=$ac_try;;
15778esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015779eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015780 (eval "$ac_link") 2>&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015781 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015782 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015783 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000015784 { (case "(($ac_try" in
15785 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15786 *) ac_try_echo=$ac_try;;
15787esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015788eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015789 (eval "$ac_try") 2>&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015790 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015791 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015792 (exit $ac_status); }; }; then
15793 ac_cv_pthread_system_supported=yes
15794else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015795 echo "$as_me: program exited with status $ac_status" >&5
15796echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015797sed 's/^/| /' conftest.$ac_ext >&5
15798
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015799( exit $ac_status )
15800ac_cv_pthread_system_supported=no
15801fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015802rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015803fi
Martin v. Löwisa7a76d32002-10-04 07:21:24 +000015804
Martin v. Löwiseba40652007-08-30 20:10:57 +000015805
15806
Guido van Rossum627b2d71993-12-24 10:39:16 +000015807fi
15808
Ronald Oussoren450d5612009-06-08 21:12:41 +000015809 { echo "$as_me:$LINENO: result: $ac_cv_pthread_system_supported" >&5
15810echo "${ECHO_T}$ac_cv_pthread_system_supported" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015811 if test "$ac_cv_pthread_system_supported" = "yes"; then
15812
15813cat >>confdefs.h <<\_ACEOF
15814#define PTHREAD_SYSTEM_SCHED_SUPPORTED 1
15815_ACEOF
15816
15817 fi
15818
15819for ac_func in pthread_sigmask
15820do
Ronald Oussoren450d5612009-06-08 21:12:41 +000015821as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15822{ echo "$as_me:$LINENO: checking for $ac_func" >&5
15823echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000015824if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015825 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015826else
15827 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015828/* confdefs.h. */
15829_ACEOF
15830cat confdefs.h >>conftest.$ac_ext
15831cat >>conftest.$ac_ext <<_ACEOF
15832/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000015833/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15834 For example, HP-UX 11i <limits.h> declares gettimeofday. */
15835#define $ac_func innocuous_$ac_func
15836
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015837/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000015838 which can conflict with char $ac_func (); below.
15839 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000015840 <limits.h> exists even on freestanding compilers. */
15841
15842#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000015843# include <limits.h>
15844#else
15845# include <assert.h>
15846#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000015847
15848#undef $ac_func
15849
Martin v. Löwiseba40652007-08-30 20:10:57 +000015850/* Override any GCC internal prototype to avoid an error.
15851 Use char because int might match the return type of a GCC
15852 builtin and then its argument prototype would still apply. */
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015853#ifdef __cplusplus
15854extern "C"
15855#endif
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015856char $ac_func ();
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015857/* The GNU C library defines this for functions which it implements
15858 to always fail with ENOSYS. Some functions are actually named
15859 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000015860#if defined __stub_$ac_func || defined __stub___$ac_func
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015861choke me
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015862#endif
15863
Skip Montanaro6dead952003-09-25 14:50:04 +000015864int
15865main ()
15866{
Martin v. Löwiseba40652007-08-30 20:10:57 +000015867return $ac_func ();
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015868 ;
15869 return 0;
15870}
15871_ACEOF
15872rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015873if { (ac_try="$ac_link"
15874case "(($ac_try" in
15875 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15876 *) ac_try_echo=$ac_try;;
15877esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015878eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015879 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015880 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000015881 grep -v '^ *+' conftest.er1 >conftest.err
15882 rm -f conftest.er1
15883 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000015884 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015885 (exit $ac_status); } && {
15886 test -z "$ac_c_werror_flag" ||
15887 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000015888 } && test -s conftest$ac_exeext &&
15889 $as_test_x conftest$ac_exeext; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015890 eval "$as_ac_var=yes"
15891else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015892 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015893sed 's/^/| /' conftest.$ac_ext >&5
15894
Martin v. Löwiseba40652007-08-30 20:10:57 +000015895 eval "$as_ac_var=no"
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015896fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000015897
15898rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000015899 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015900fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000015901ac_res=`eval echo '${'$as_ac_var'}'`
15902 { echo "$as_me:$LINENO: result: $ac_res" >&5
15903echo "${ECHO_T}$ac_res" >&6; }
15904if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015905 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000015906#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015907_ACEOF
Jason Tishlerfac083d2003-07-22 15:20:49 +000015908 case $ac_sys_system in
15909 CYGWIN*)
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015910
Jason Tishlerfac083d2003-07-22 15:20:49 +000015911cat >>confdefs.h <<\_ACEOF
15912#define HAVE_BROKEN_PTHREAD_SIGMASK 1
15913_ACEOF
15914
15915 ;;
15916 esac
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000015917fi
15918done
15919
15920fi
15921
15922
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015923# Check for enable-ipv6
Martin v. Löwis11437992002-04-12 09:54:03 +000015924
15925
Ronald Oussoren450d5612009-06-08 21:12:41 +000015926{ echo "$as_me:$LINENO: checking if --enable-ipv6 is specified" >&5
15927echo $ECHO_N "checking if --enable-ipv6 is specified... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000015928# Check whether --enable-ipv6 was given.
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015929if test "${enable_ipv6+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000015930 enableval=$enable_ipv6; case "$enableval" in
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015931 no)
Ronald Oussoren450d5612009-06-08 21:12:41 +000015932 { echo "$as_me:$LINENO: result: no" >&5
15933echo "${ECHO_T}no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015934 ipv6=no
15935 ;;
Ronald Oussoren450d5612009-06-08 21:12:41 +000015936 *) { echo "$as_me:$LINENO: result: yes" >&5
15937echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000015938 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015939#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000015940_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015941
15942 ipv6=yes
15943 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000015944 esac
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015945else
Martin v. Löwis11437992002-04-12 09:54:03 +000015946
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015947 if test "$cross_compiling" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015948 { echo "$as_me:$LINENO: result: no" >&5
15949echo "${ECHO_T}no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015950 ipv6=no
15951
15952else
Martin v. Löwis11437992002-04-12 09:54:03 +000015953 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000015954/* confdefs.h. */
15955_ACEOF
15956cat confdefs.h >>conftest.$ac_ext
15957cat >>conftest.$ac_ext <<_ACEOF
15958/* end confdefs.h. */
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015959 /* AF_INET6 available check */
15960#include <sys/types.h>
15961#include <sys/socket.h>
15962main()
15963{
15964 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
15965 exit(1);
15966 else
15967 exit(0);
15968}
15969
Martin v. Löwis11437992002-04-12 09:54:03 +000015970_ACEOF
15971rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000015972if { (ac_try="$ac_link"
15973case "(($ac_try" in
15974 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15975 *) ac_try_echo=$ac_try;;
15976esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015977eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015978 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015979 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015980 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015981 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000015982 { (case "(($ac_try" in
15983 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15984 *) ac_try_echo=$ac_try;;
15985esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000015986eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000015987 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015988 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000015989 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000015990 (exit $ac_status); }; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000015991 { echo "$as_me:$LINENO: result: yes" >&5
15992echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000015993 ipv6=yes
15994else
Ronald Oussoren450d5612009-06-08 21:12:41 +000015995 echo "$as_me: program exited with status $ac_status" >&5
15996echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000015997sed 's/^/| /' conftest.$ac_ext >&5
15998
Martin v. Löwis11437992002-04-12 09:54:03 +000015999( exit $ac_status )
Ronald Oussoren450d5612009-06-08 21:12:41 +000016000{ echo "$as_me:$LINENO: result: no" >&5
16001echo "${ECHO_T}no" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016002 ipv6=no
16003fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016004rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016005fi
16006
Martin v. Löwiseba40652007-08-30 20:10:57 +000016007
16008
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016009if test "$ipv6" = "yes"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000016010 { echo "$as_me:$LINENO: checking if RFC2553 API is available" >&5
16011echo $ECHO_N "checking if RFC2553 API is available... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016012 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016013/* confdefs.h. */
16014_ACEOF
16015cat confdefs.h >>conftest.$ac_ext
16016cat >>conftest.$ac_ext <<_ACEOF
16017/* end confdefs.h. */
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016018#include <sys/types.h>
16019#include <netinet/in.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000016020int
16021main ()
16022{
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016023struct sockaddr_in6 x;
16024x.sin6_scope_id;
Martin v. Löwis11437992002-04-12 09:54:03 +000016025 ;
16026 return 0;
16027}
16028_ACEOF
16029rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016030if { (ac_try="$ac_compile"
16031case "(($ac_try" in
16032 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16033 *) ac_try_echo=$ac_try;;
16034esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016035eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016036 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000016037 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016038 grep -v '^ *+' conftest.er1 >conftest.err
16039 rm -f conftest.er1
16040 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016042 (exit $ac_status); } && {
16043 test -z "$ac_c_werror_flag" ||
16044 test ! -s conftest.err
16045 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000016046 { echo "$as_me:$LINENO: result: yes" >&5
16047echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016048 ipv6=yes
16049else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016050 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016051sed 's/^/| /' conftest.$ac_ext >&5
16052
Ronald Oussoren450d5612009-06-08 21:12:41 +000016053 { echo "$as_me:$LINENO: result: no" >&5
16054echo "${ECHO_T}no" >&6; }
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016055 ipv6=no
16056fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016057
16058rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016059fi
16060
16061if test "$ipv6" = "yes"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016062 cat >>confdefs.h <<\_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016063#define ENABLE_IPV6 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016064_ACEOF
Martin v. Löwisa5f8bb52001-09-05 08:22:34 +000016065
16066fi
16067
Martin v. Löwiseba40652007-08-30 20:10:57 +000016068fi
16069
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016070
16071ipv6type=unknown
16072ipv6lib=none
16073ipv6trylibc=no
16074
16075if test "$ipv6" = "yes"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000016076 { echo "$as_me:$LINENO: checking ipv6 stack type" >&5
16077echo $ECHO_N "checking ipv6 stack type... $ECHO_C" >&6; }
Guido van Rossumb8552162001-09-05 14:58:11 +000016078 for i in inria kame linux-glibc linux-inet6 solaris toshiba v6d zeta;
16079 do
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016080 case $i in
16081 inria)
Martin v. Löwis11437992002-04-12 09:54:03 +000016082 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016083/* confdefs.h. */
16084_ACEOF
16085cat confdefs.h >>conftest.$ac_ext
16086cat >>conftest.$ac_ext <<_ACEOF
16087/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016088
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016089#include <netinet/in.h>
16090#ifdef IPV6_INRIA_VERSION
16091yes
16092#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016093_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016094if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016095 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000016096 ipv6type=$i
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016097fi
16098rm -f conftest*
16099
16100 ;;
16101 kame)
Martin v. Löwis11437992002-04-12 09:54:03 +000016102 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016103/* confdefs.h. */
16104_ACEOF
16105cat confdefs.h >>conftest.$ac_ext
16106cat >>conftest.$ac_ext <<_ACEOF
16107/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016108
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016109#include <netinet/in.h>
16110#ifdef __KAME__
16111yes
16112#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016113_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016114if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016115 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016116 ipv6type=$i;
16117 ipv6lib=inet6
16118 ipv6libdir=/usr/local/v6/lib
16119 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016120fi
16121rm -f conftest*
16122
16123 ;;
16124 linux-glibc)
Martin v. Löwis11437992002-04-12 09:54:03 +000016125 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016126/* confdefs.h. */
16127_ACEOF
16128cat confdefs.h >>conftest.$ac_ext
16129cat >>conftest.$ac_ext <<_ACEOF
16130/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016131
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016132#include <features.h>
16133#if defined(__GLIBC__) && ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2))
16134yes
16135#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016136_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016137if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016138 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016139 ipv6type=$i;
16140 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016141fi
16142rm -f conftest*
16143
16144 ;;
16145 linux-inet6)
16146 if test -d /usr/inet6; then
16147 ipv6type=$i
16148 ipv6lib=inet6
16149 ipv6libdir=/usr/inet6/lib
Skip Montanarodecc6a42003-01-01 20:07:49 +000016150 BASECFLAGS="-I/usr/inet6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016151 fi
16152 ;;
16153 solaris)
16154 if test -f /etc/netconfig; then
16155 if /usr/xpg4/bin/grep -q tcp6 /etc/netconfig; then
16156 ipv6type=$i
16157 ipv6trylibc=yes
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016158 fi
16159 fi
16160 ;;
16161 toshiba)
Martin v. Löwis11437992002-04-12 09:54:03 +000016162 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016163/* confdefs.h. */
16164_ACEOF
16165cat confdefs.h >>conftest.$ac_ext
16166cat >>conftest.$ac_ext <<_ACEOF
16167/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016168
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016169#include <sys/param.h>
16170#ifdef _TOSHIBA_INET6
16171yes
16172#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016173_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016174if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016175 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016176 ipv6type=$i;
16177 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000016178 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016179fi
16180rm -f conftest*
16181
16182 ;;
16183 v6d)
Martin v. Löwis11437992002-04-12 09:54:03 +000016184 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016185/* confdefs.h. */
16186_ACEOF
16187cat confdefs.h >>conftest.$ac_ext
16188cat >>conftest.$ac_ext <<_ACEOF
16189/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016190
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016191#include </usr/local/v6/include/sys/v6config.h>
16192#ifdef __V6D__
16193yes
16194#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016195_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016196if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016197 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016198 ipv6type=$i;
16199 ipv6lib=v6;
16200 ipv6libdir=/usr/local/v6/lib;
Skip Montanarodecc6a42003-01-01 20:07:49 +000016201 BASECFLAGS="-I/usr/local/v6/include $BASECFLAGS"
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016202fi
16203rm -f conftest*
16204
16205 ;;
16206 zeta)
Martin v. Löwis11437992002-04-12 09:54:03 +000016207 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016208/* confdefs.h. */
16209_ACEOF
16210cat confdefs.h >>conftest.$ac_ext
16211cat >>conftest.$ac_ext <<_ACEOF
16212/* end confdefs.h. */
Martin v. Löwisa5f73f92001-10-15 08:06:29 +000016213
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016214#include <sys/param.h>
16215#ifdef _ZETA_MINAMI_INET6
16216yes
16217#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016218_ACEOF
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016219if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000016220 $EGREP "yes" >/dev/null 2>&1; then
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016221 ipv6type=$i;
16222 ipv6lib=inet6;
Martin v. Löwis44ddbde2001-12-02 10:15:37 +000016223 ipv6libdir=/usr/local/v6/lib
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016224fi
16225rm -f conftest*
16226
16227 ;;
16228 esac
16229 if test "$ipv6type" != "unknown"; then
16230 break
16231 fi
16232 done
Ronald Oussoren450d5612009-06-08 21:12:41 +000016233 { echo "$as_me:$LINENO: result: $ipv6type" >&5
16234echo "${ECHO_T}$ipv6type" >&6; }
Martin v. Löwisa2ac6022001-08-09 11:40:14 +000016235fi
16236
16237if test "$ipv6" = "yes" -a "$ipv6lib" != "none"; then
16238 if test -d $ipv6libdir -a -f $ipv6libdir/lib$ipv6lib.a; then
16239 LIBS="-L$ipv6libdir -l$ipv6lib $LIBS"
16240 echo "using lib$ipv6lib"
16241 else
16242 if test $ipv6trylibc = "yes"; then
16243 echo "using libc"
16244 else
16245 echo 'Fatal: no $ipv6lib library found. cannot continue.'
16246 echo "You need to fetch lib$ipv6lib.a from appropriate"
16247 echo 'ipv6 kit and compile beforehand.'
16248 exit 1
16249 fi
16250 fi
16251fi
16252
Ronald Oussoren450d5612009-06-08 21:12:41 +000016253{ echo "$as_me:$LINENO: checking for OSX 10.5 SDK or later" >&5
16254echo $ECHO_N "checking for OSX 10.5 SDK or later... $ECHO_C" >&6; }
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016255cat >conftest.$ac_ext <<_ACEOF
16256/* confdefs.h. */
16257_ACEOF
16258cat confdefs.h >>conftest.$ac_ext
16259cat >>conftest.$ac_ext <<_ACEOF
16260/* end confdefs.h. */
16261#include <Carbon/Carbon.h>
16262int
16263main ()
16264{
16265FSIORefNum fRef = 0
16266 ;
16267 return 0;
16268}
16269_ACEOF
16270rm -f conftest.$ac_objext
16271if { (ac_try="$ac_compile"
16272case "(($ac_try" in
16273 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16274 *) ac_try_echo=$ac_try;;
16275esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016276eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016277 (eval "$ac_compile") 2>conftest.er1
16278 ac_status=$?
16279 grep -v '^ *+' conftest.er1 >conftest.err
16280 rm -f conftest.er1
16281 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016282 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016283 (exit $ac_status); } && {
16284 test -z "$ac_c_werror_flag" ||
16285 test ! -s conftest.err
16286 } && test -s conftest.$ac_objext; then
16287
16288cat >>confdefs.h <<\_ACEOF
16289#define HAVE_OSX105_SDK 1
16290_ACEOF
16291
Ronald Oussoren450d5612009-06-08 21:12:41 +000016292 { echo "$as_me:$LINENO: result: yes" >&5
16293echo "${ECHO_T}yes" >&6; }
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016294else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016295 echo "$as_me: failed program was:" >&5
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016296sed 's/^/| /' conftest.$ac_ext >&5
16297
Ronald Oussoren450d5612009-06-08 21:12:41 +000016298 { echo "$as_me:$LINENO: result: no" >&5
16299echo "${ECHO_T}no" >&6; }
Ronald Oussoren0d236eb2008-06-06 21:31:33 +000016300
16301fi
16302
16303rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16304
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016305# Check for --with-doc-strings
Ronald Oussoren450d5612009-06-08 21:12:41 +000016306{ echo "$as_me:$LINENO: checking for --with-doc-strings" >&5
16307echo $ECHO_N "checking for --with-doc-strings... $ECHO_C" >&6; }
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016308
Martin v. Löwiseba40652007-08-30 20:10:57 +000016309# Check whether --with-doc-strings was given.
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016310if test "${with_doc_strings+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016311 withval=$with_doc_strings;
16312fi
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016313
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016314
16315if test -z "$with_doc_strings"
16316then with_doc_strings="yes"
16317fi
16318if test "$with_doc_strings" != "no"
16319then
16320
16321cat >>confdefs.h <<\_ACEOF
16322#define WITH_DOC_STRINGS 1
16323_ACEOF
16324
16325fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000016326{ echo "$as_me:$LINENO: result: $with_doc_strings" >&5
16327echo "${ECHO_T}$with_doc_strings" >&6; }
Martin v. Löwisa3fb4f72002-06-09 13:33:54 +000016328
Neil Schemenauera35c6882001-02-27 04:45:05 +000016329# Check for Python-specific malloc support
Ronald Oussoren450d5612009-06-08 21:12:41 +000016330{ echo "$as_me:$LINENO: checking for --with-tsc" >&5
16331echo $ECHO_N "checking for --with-tsc... $ECHO_C" >&6; }
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016332
Martin v. Löwiseba40652007-08-30 20:10:57 +000016333# Check whether --with-tsc was given.
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016334if test "${with_tsc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016335 withval=$with_tsc;
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016336if test "$withval" != no
16337then
16338
16339cat >>confdefs.h <<\_ACEOF
16340#define WITH_TSC 1
16341_ACEOF
16342
Ronald Oussoren450d5612009-06-08 21:12:41 +000016343 { echo "$as_me:$LINENO: result: yes" >&5
16344echo "${ECHO_T}yes" >&6; }
16345else { echo "$as_me:$LINENO: result: no" >&5
16346echo "${ECHO_T}no" >&6; }
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016347fi
16348else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016349 { echo "$as_me:$LINENO: result: no" >&5
16350echo "${ECHO_T}no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016351fi
16352
Martin v. Löwisf30d60e2004-06-08 08:17:44 +000016353
16354# Check for Python-specific malloc support
Ronald Oussoren450d5612009-06-08 21:12:41 +000016355{ echo "$as_me:$LINENO: checking for --with-pymalloc" >&5
16356echo $ECHO_N "checking for --with-pymalloc... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016357
Martin v. Löwiseba40652007-08-30 20:10:57 +000016358# Check whether --with-pymalloc was given.
Neil Schemenauera35c6882001-02-27 04:45:05 +000016359if test "${with_pymalloc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016360 withval=$with_pymalloc;
16361fi
Michael W. Hudson54241132001-12-07 15:38:26 +000016362
Neil Schemenauera35c6882001-02-27 04:45:05 +000016363
Neil Schemenauer16c22972002-03-22 15:34:49 +000016364if test -z "$with_pymalloc"
16365then with_pymalloc="yes"
16366fi
16367if test "$with_pymalloc" != "no"
16368then
Martin v. Löwis11437992002-04-12 09:54:03 +000016369
16370cat >>confdefs.h <<\_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000016371#define WITH_PYMALLOC 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016372_ACEOF
Neil Schemenauer16c22972002-03-22 15:34:49 +000016373
16374fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000016375{ echo "$as_me:$LINENO: result: $with_pymalloc" >&5
16376echo "${ECHO_T}$with_pymalloc" >&6; }
Neil Schemenauer16c22972002-03-22 15:34:49 +000016377
Barry Warsawef82cd72000-06-30 16:21:01 +000016378# Check for --with-wctype-functions
Ronald Oussoren450d5612009-06-08 21:12:41 +000016379{ echo "$as_me:$LINENO: checking for --with-wctype-functions" >&5
16380echo $ECHO_N "checking for --with-wctype-functions... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000016381
Martin v. Löwiseba40652007-08-30 20:10:57 +000016382# Check whether --with-wctype-functions was given.
Barry Warsawef82cd72000-06-30 16:21:01 +000016383if test "${with_wctype_functions+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000016384 withval=$with_wctype_functions;
Barry Warsawef82cd72000-06-30 16:21:01 +000016385if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000016386then
16387
16388cat >>confdefs.h <<\_ACEOF
Barry Warsawef82cd72000-06-30 16:21:01 +000016389#define WANT_WCTYPE_FUNCTIONS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016390_ACEOF
16391
Ronald Oussoren450d5612009-06-08 21:12:41 +000016392 { echo "$as_me:$LINENO: result: yes" >&5
16393echo "${ECHO_T}yes" >&6; }
16394else { echo "$as_me:$LINENO: result: no" >&5
16395echo "${ECHO_T}no" >&6; }
Barry Warsawef82cd72000-06-30 16:21:01 +000016396fi
16397else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016398 { echo "$as_me:$LINENO: result: no" >&5
16399echo "${ECHO_T}no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016400fi
16401
Barry Warsawef82cd72000-06-30 16:21:01 +000016402
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000016403# -I${DLINCLDIR} is added to the compile rule for importdl.o
Guido van Rossum7f43da71994-08-01 12:15:30 +000016404
Guido van Rossum98935bf2001-09-05 19:13:16 +000016405DLINCLDIR=.
Guido van Rossum7f43da71994-08-01 12:15:30 +000016406
Guido van Rossume97ee181999-12-20 21:27:22 +000016407# the dlopen() function means we might want to use dynload_shlib.o. some
16408# platforms, such as AIX, have dlopen(), but don't want to use it.
Martin v. Löwis11437992002-04-12 09:54:03 +000016409
Thomas Wouters3a584202000-08-05 23:28:51 +000016410for ac_func in dlopen
16411do
Ronald Oussoren450d5612009-06-08 21:12:41 +000016412as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16413{ echo "$as_me:$LINENO: checking for $ac_func" >&5
16414echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016415if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000016416 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossume97ee181999-12-20 21:27:22 +000016417else
Martin v. Löwis11437992002-04-12 09:54:03 +000016418 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016419/* confdefs.h. */
16420_ACEOF
16421cat confdefs.h >>conftest.$ac_ext
16422cat >>conftest.$ac_ext <<_ACEOF
16423/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016424/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16425 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16426#define $ac_func innocuous_$ac_func
16427
Guido van Rossume97ee181999-12-20 21:27:22 +000016428/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000016429 which can conflict with char $ac_func (); below.
16430 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016431 <limits.h> exists even on freestanding compilers. */
16432
16433#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000016434# include <limits.h>
16435#else
16436# include <assert.h>
16437#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016438
16439#undef $ac_func
16440
Martin v. Löwiseba40652007-08-30 20:10:57 +000016441/* Override any GCC internal prototype to avoid an error.
16442 Use char because int might match the return type of a GCC
16443 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016444#ifdef __cplusplus
16445extern "C"
16446#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016447char $ac_func ();
Guido van Rossume97ee181999-12-20 21:27:22 +000016448/* The GNU C library defines this for functions which it implements
16449 to always fail with ENOSYS. Some functions are actually named
16450 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000016451#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossume97ee181999-12-20 21:27:22 +000016452choke me
Guido van Rossume97ee181999-12-20 21:27:22 +000016453#endif
16454
Skip Montanaro6dead952003-09-25 14:50:04 +000016455int
16456main ()
16457{
Martin v. Löwiseba40652007-08-30 20:10:57 +000016458return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000016459 ;
16460 return 0;
16461}
16462_ACEOF
16463rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016464if { (ac_try="$ac_link"
16465case "(($ac_try" in
16466 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16467 *) ac_try_echo=$ac_try;;
16468esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016469eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016470 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000016471 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016472 grep -v '^ *+' conftest.er1 >conftest.err
16473 rm -f conftest.er1
16474 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016475 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016476 (exit $ac_status); } && {
16477 test -z "$ac_c_werror_flag" ||
16478 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000016479 } && test -s conftest$ac_exeext &&
16480 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016481 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000016482else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016483 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016484sed 's/^/| /' conftest.$ac_ext >&5
16485
Martin v. Löwiseba40652007-08-30 20:10:57 +000016486 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000016487fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016488
16489rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000016490 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000016491fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000016492ac_res=`eval echo '${'$as_ac_var'}'`
16493 { echo "$as_me:$LINENO: result: $ac_res" >&5
16494echo "${ECHO_T}$ac_res" >&6; }
16495if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016496 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000016497#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016498_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000016499
Guido van Rossume97ee181999-12-20 21:27:22 +000016500fi
Thomas Wouters3a584202000-08-05 23:28:51 +000016501done
Guido van Rossume97ee181999-12-20 21:27:22 +000016502
Michael W. Hudson54241132001-12-07 15:38:26 +000016503
Guido van Rossume97ee181999-12-20 21:27:22 +000016504# DYNLOADFILE specifies which dynload_*.o file we will use for dynamic
16505# loading of modules.
16506
Ronald Oussoren450d5612009-06-08 21:12:41 +000016507{ echo "$as_me:$LINENO: checking DYNLOADFILE" >&5
16508echo $ECHO_N "checking DYNLOADFILE... $ECHO_C" >&6; }
Guido van Rossume97ee181999-12-20 21:27:22 +000016509if test -z "$DYNLOADFILE"
16510then
16511 case $ac_sys_system/$ac_sys_release in
Martin v. Löwisc19c5a62003-11-18 20:00:44 +000016512 AIX*) # Use dynload_shlib.c and dlopen() if we have it; otherwise dynload_aix.c
16513 if test "$ac_cv_func_dlopen" = yes
16514 then DYNLOADFILE="dynload_shlib.o"
16515 else DYNLOADFILE="dynload_aix.o"
16516 fi
16517 ;;
Guido van Rossume97ee181999-12-20 21:27:22 +000016518 BeOS*) DYNLOADFILE="dynload_beos.o";;
16519 hp*|HP*) DYNLOADFILE="dynload_hpux.o";;
Anthony Baxter82201742006-04-09 15:07:40 +000016520 # Use dynload_next.c only on 10.2 and below, which don't have native dlopen()
16521 Darwin/[0156]\..*) DYNLOADFILE="dynload_next.o";;
Martin v. Löwisf90ae202002-06-11 06:22:31 +000016522 atheos*) DYNLOADFILE="dynload_atheos.o";;
Guido van Rossume97ee181999-12-20 21:27:22 +000016523 *)
16524 # use dynload_shlib.c and dlopen() if we have it; otherwise stub
16525 # out any dynamic loading
16526 if test "$ac_cv_func_dlopen" = yes
16527 then DYNLOADFILE="dynload_shlib.o"
16528 else DYNLOADFILE="dynload_stub.o"
16529 fi
16530 ;;
16531 esac
16532fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000016533{ echo "$as_me:$LINENO: result: $DYNLOADFILE" >&5
16534echo "${ECHO_T}$DYNLOADFILE" >&6; }
Guido van Rossume97ee181999-12-20 21:27:22 +000016535if test "$DYNLOADFILE" != "dynload_stub.o"
16536then
Martin v. Löwis11437992002-04-12 09:54:03 +000016537
16538cat >>confdefs.h <<\_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000016539#define HAVE_DYNAMIC_LOADING 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016540_ACEOF
Guido van Rossume97ee181999-12-20 21:27:22 +000016541
16542fi
16543
Neil Schemenauer4e425612001-06-19 15:44:15 +000016544# MACHDEP_OBJS can be set to platform-specific object files needed by Python
16545
Michael W. Hudson54241132001-12-07 15:38:26 +000016546
Ronald Oussoren450d5612009-06-08 21:12:41 +000016547{ echo "$as_me:$LINENO: checking MACHDEP_OBJS" >&5
16548echo $ECHO_N "checking MACHDEP_OBJS... $ECHO_C" >&6; }
Neil Schemenauer4e425612001-06-19 15:44:15 +000016549if test -z "$MACHDEP_OBJS"
16550then
Jack Jansene578a632001-08-15 01:27:14 +000016551 MACHDEP_OBJS=$extra_machdep_objs
16552else
16553 MACHDEP_OBJS="$MACHDEP_OBJS $extra_machdep_objs"
Neil Schemenauer4e425612001-06-19 15:44:15 +000016554fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000016555{ echo "$as_me:$LINENO: result: MACHDEP_OBJS" >&5
16556echo "${ECHO_T}MACHDEP_OBJS" >&6; }
Neil Schemenauer4e425612001-06-19 15:44:15 +000016557
Guido van Rossum627b2d71993-12-24 10:39:16 +000016558# checks for library functions
Martin v. Löwis11437992002-04-12 09:54:03 +000016559
16560
16561
16562
16563
16564
16565
16566
16567
16568
16569
16570
16571
16572
16573
16574
16575
16576
16577
16578
16579
16580
16581
16582
16583
16584
16585
16586
16587
16588
16589
16590
16591
16592
16593
16594
16595
16596
16597
16598
16599
16600
16601
16602
16603
16604
16605
16606
16607
16608
16609
16610
16611
16612
16613
16614
16615
16616
16617
16618
16619
16620
16621
16622
16623
16624
16625
16626
16627
16628
16629
Martin v. Löwisd6320502004-08-12 13:45:08 +000016630
Martin v. Löwisc3001752005-01-23 09:27:24 +000016631
16632
Neal Norwitz05a45592006-03-20 06:30:08 +000016633
16634
Martin v. Löwis382abef2007-02-19 10:55:19 +000016635
16636
Christian Heimes36281872007-11-30 21:11:28 +000016637
Martin v. Löwisaef18b12008-03-24 13:31:16 +000016638
16639
Jesse Noller355b1262009-04-02 00:03:28 +000016640
16641
16642
16643
Martin v. Löwisaef18b12008-03-24 13:31:16 +000016644for ac_func in alarm setitimer getitimer bind_textdomain_codeset chown \
16645 clock confstr ctermid execv fchmod fchown fork fpathconf ftime ftruncate \
Martin v. Löwis438b5342002-12-27 10:16:42 +000016646 gai_strerror getgroups getlogin getloadavg getpeername getpgid getpid \
Martin v. Löwisc3001752005-01-23 09:27:24 +000016647 getpriority getpwent getspnam getspent getsid getwd \
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000016648 kill killpg lchmod lchown lstat mkfifo mknod mktime \
Martin v. Löwisa5f09072002-10-11 05:37:59 +000016649 mremap nice pathconf pause plock poll pthread_init \
Guido van Rossum162e38c2003-02-19 15:25:10 +000016650 putenv readlink realpath \
Jesse Noller355b1262009-04-02 00:03:28 +000016651 select sem_open sem_timedwait sem_getvalue sem_unlink setegid seteuid \
16652 setgid \
Martin v. Löwis4daacb12003-03-28 18:37:01 +000016653 setlocale setregid setreuid setsid setpgid setpgrp setuid setvbuf snprintf \
Skip Montanaro7e11a012004-02-07 12:55:46 +000016654 sigaction siginterrupt sigrelse strftime \
Michael W. Hudson34f20ea2002-05-27 15:08:24 +000016655 sysconf tcgetpgrp tcsetpgrp tempnam timegm times tmpfile tmpnam tmpnam_r \
Neal Norwitz05a45592006-03-20 06:30:08 +000016656 truncate uname unsetenv utimes waitpid wait3 wait4 wcscoll _getpty
Guido van Rossum627b2d71993-12-24 10:39:16 +000016657do
Ronald Oussoren450d5612009-06-08 21:12:41 +000016658as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16659{ echo "$as_me:$LINENO: checking for $ac_func" >&5
16660echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000016661if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000016662 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016663else
Martin v. Löwis11437992002-04-12 09:54:03 +000016664 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016665/* confdefs.h. */
16666_ACEOF
16667cat confdefs.h >>conftest.$ac_ext
16668cat >>conftest.$ac_ext <<_ACEOF
16669/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016670/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16671 For example, HP-UX 11i <limits.h> declares gettimeofday. */
16672#define $ac_func innocuous_$ac_func
16673
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000016674/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000016675 which can conflict with char $ac_func (); below.
16676 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016677 <limits.h> exists even on freestanding compilers. */
16678
16679#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000016680# include <limits.h>
16681#else
16682# include <assert.h>
16683#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000016684
16685#undef $ac_func
16686
Martin v. Löwiseba40652007-08-30 20:10:57 +000016687/* Override any GCC internal prototype to avoid an error.
16688 Use char because int might match the return type of a GCC
16689 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000016690#ifdef __cplusplus
16691extern "C"
16692#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000016693char $ac_func ();
Guido van Rossum627b2d71993-12-24 10:39:16 +000016694/* The GNU C library defines this for functions which it implements
16695 to always fail with ENOSYS. Some functions are actually named
16696 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000016697#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossum627b2d71993-12-24 10:39:16 +000016698choke me
Guido van Rossum627b2d71993-12-24 10:39:16 +000016699#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000016700
Skip Montanaro6dead952003-09-25 14:50:04 +000016701int
16702main ()
16703{
Martin v. Löwiseba40652007-08-30 20:10:57 +000016704return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000016705 ;
16706 return 0;
16707}
16708_ACEOF
16709rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016710if { (ac_try="$ac_link"
16711case "(($ac_try" in
16712 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16713 *) ac_try_echo=$ac_try;;
16714esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016715eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016716 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000016717 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016718 grep -v '^ *+' conftest.er1 >conftest.err
16719 rm -f conftest.er1
16720 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016721 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016722 (exit $ac_status); } && {
16723 test -z "$ac_c_werror_flag" ||
16724 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000016725 } && test -s conftest$ac_exeext &&
16726 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016727 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000016728else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016729 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016730sed 's/^/| /' conftest.$ac_ext >&5
16731
Martin v. Löwiseba40652007-08-30 20:10:57 +000016732 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000016733fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016734
16735rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000016736 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000016737fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000016738ac_res=`eval echo '${'$as_ac_var'}'`
16739 { echo "$as_me:$LINENO: result: $ac_res" >&5
16740echo "${ECHO_T}$ac_res" >&6; }
16741if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000016742 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000016743#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000016744_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000016745
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000016746fi
16747done
16748
Michael W. Hudson54241132001-12-07 15:38:26 +000016749
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016750# For some functions, having a definition is not sufficient, since
16751# we want to take their address.
Ronald Oussoren450d5612009-06-08 21:12:41 +000016752{ echo "$as_me:$LINENO: checking for chroot" >&5
16753echo $ECHO_N "checking for chroot... $ECHO_C" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016754cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016755/* confdefs.h. */
16756_ACEOF
16757cat confdefs.h >>conftest.$ac_ext
16758cat >>conftest.$ac_ext <<_ACEOF
16759/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016760#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016761int
16762main ()
16763{
16764void *x=chroot
16765 ;
16766 return 0;
16767}
16768_ACEOF
16769rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016770if { (ac_try="$ac_compile"
16771case "(($ac_try" in
16772 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16773 *) ac_try_echo=$ac_try;;
16774esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016775eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016776 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016777 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016778 grep -v '^ *+' conftest.er1 >conftest.err
16779 rm -f conftest.er1
16780 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016781 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016782 (exit $ac_status); } && {
16783 test -z "$ac_c_werror_flag" ||
16784 test ! -s conftest.err
16785 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016786
16787cat >>confdefs.h <<\_ACEOF
16788#define HAVE_CHROOT 1
16789_ACEOF
16790
Ronald Oussoren450d5612009-06-08 21:12:41 +000016791 { echo "$as_me:$LINENO: result: yes" >&5
16792echo "${ECHO_T}yes" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016793else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016794 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016795sed 's/^/| /' conftest.$ac_ext >&5
16796
Ronald Oussoren450d5612009-06-08 21:12:41 +000016797 { echo "$as_me:$LINENO: result: no" >&5
16798echo "${ECHO_T}no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016799
16800fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016801
16802rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000016803{ echo "$as_me:$LINENO: checking for link" >&5
16804echo $ECHO_N "checking for link... $ECHO_C" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016805cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016806/* confdefs.h. */
16807_ACEOF
16808cat confdefs.h >>conftest.$ac_ext
16809cat >>conftest.$ac_ext <<_ACEOF
16810/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016811#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016812int
16813main ()
16814{
16815void *x=link
16816 ;
16817 return 0;
16818}
16819_ACEOF
16820rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016821if { (ac_try="$ac_compile"
16822case "(($ac_try" in
16823 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16824 *) ac_try_echo=$ac_try;;
16825esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016826eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016827 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016828 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016829 grep -v '^ *+' conftest.er1 >conftest.err
16830 rm -f conftest.er1
16831 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016832 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016833 (exit $ac_status); } && {
16834 test -z "$ac_c_werror_flag" ||
16835 test ! -s conftest.err
16836 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016837
16838cat >>confdefs.h <<\_ACEOF
16839#define HAVE_LINK 1
16840_ACEOF
16841
Ronald Oussoren450d5612009-06-08 21:12:41 +000016842 { echo "$as_me:$LINENO: result: yes" >&5
16843echo "${ECHO_T}yes" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016844else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016845 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016846sed 's/^/| /' conftest.$ac_ext >&5
16847
Ronald Oussoren450d5612009-06-08 21:12:41 +000016848 { echo "$as_me:$LINENO: result: no" >&5
16849echo "${ECHO_T}no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016850
16851fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016852
16853rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000016854{ echo "$as_me:$LINENO: checking for symlink" >&5
16855echo $ECHO_N "checking for symlink... $ECHO_C" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016856cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016857/* confdefs.h. */
16858_ACEOF
16859cat confdefs.h >>conftest.$ac_ext
16860cat >>conftest.$ac_ext <<_ACEOF
16861/* end confdefs.h. */
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016862#include <unistd.h>
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016863int
16864main ()
16865{
16866void *x=symlink
16867 ;
16868 return 0;
16869}
16870_ACEOF
16871rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016872if { (ac_try="$ac_compile"
16873case "(($ac_try" in
16874 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16875 *) ac_try_echo=$ac_try;;
16876esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016877eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016878 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016879 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016880 grep -v '^ *+' conftest.er1 >conftest.err
16881 rm -f conftest.er1
16882 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016883 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016884 (exit $ac_status); } && {
16885 test -z "$ac_c_werror_flag" ||
16886 test ! -s conftest.err
16887 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016888
16889cat >>confdefs.h <<\_ACEOF
16890#define HAVE_SYMLINK 1
16891_ACEOF
16892
Ronald Oussoren450d5612009-06-08 21:12:41 +000016893 { echo "$as_me:$LINENO: result: yes" >&5
16894echo "${ECHO_T}yes" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016895else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016896 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016897sed 's/^/| /' conftest.$ac_ext >&5
16898
Ronald Oussoren450d5612009-06-08 21:12:41 +000016899 { echo "$as_me:$LINENO: result: no" >&5
16900echo "${ECHO_T}no" >&6; }
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000016901
16902fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016903
16904rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000016905{ echo "$as_me:$LINENO: checking for fchdir" >&5
16906echo $ECHO_N "checking for fchdir... $ECHO_C" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016907cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016908/* confdefs.h. */
16909_ACEOF
16910cat confdefs.h >>conftest.$ac_ext
16911cat >>conftest.$ac_ext <<_ACEOF
16912/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016913#include <unistd.h>
16914int
16915main ()
16916{
16917void *x=fchdir
16918 ;
16919 return 0;
16920}
16921_ACEOF
16922rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016923if { (ac_try="$ac_compile"
16924case "(($ac_try" in
16925 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16926 *) ac_try_echo=$ac_try;;
16927esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016928eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016929 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016930 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016931 grep -v '^ *+' conftest.er1 >conftest.err
16932 rm -f conftest.er1
16933 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016934 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016935 (exit $ac_status); } && {
16936 test -z "$ac_c_werror_flag" ||
16937 test ! -s conftest.err
16938 } && test -s conftest.$ac_objext; then
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016939
16940cat >>confdefs.h <<\_ACEOF
16941#define HAVE_FCHDIR 1
16942_ACEOF
16943
Ronald Oussoren450d5612009-06-08 21:12:41 +000016944 { echo "$as_me:$LINENO: result: yes" >&5
16945echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016946else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016947 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016948sed 's/^/| /' conftest.$ac_ext >&5
16949
Ronald Oussoren450d5612009-06-08 21:12:41 +000016950 { echo "$as_me:$LINENO: result: no" >&5
16951echo "${ECHO_T}no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016952
16953fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000016954
16955rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000016956{ echo "$as_me:$LINENO: checking for fsync" >&5
16957echo $ECHO_N "checking for fsync... $ECHO_C" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016958cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016959/* confdefs.h. */
16960_ACEOF
16961cat confdefs.h >>conftest.$ac_ext
16962cat >>conftest.$ac_ext <<_ACEOF
16963/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016964#include <unistd.h>
16965int
16966main ()
16967{
16968void *x=fsync
16969 ;
16970 return 0;
16971}
16972_ACEOF
16973rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000016974if { (ac_try="$ac_compile"
16975case "(($ac_try" in
16976 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16977 *) ac_try_echo=$ac_try;;
16978esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000016979eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016980 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016981 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000016982 grep -v '^ *+' conftest.er1 >conftest.err
16983 rm -f conftest.er1
16984 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000016985 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000016986 (exit $ac_status); } && {
16987 test -z "$ac_c_werror_flag" ||
16988 test ! -s conftest.err
16989 } && test -s conftest.$ac_objext; then
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016990
16991cat >>confdefs.h <<\_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000016992#define HAVE_FSYNC 1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016993_ACEOF
16994
Ronald Oussoren450d5612009-06-08 21:12:41 +000016995 { echo "$as_me:$LINENO: result: yes" >&5
16996echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000016997else
Ronald Oussoren450d5612009-06-08 21:12:41 +000016998 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000016999sed 's/^/| /' conftest.$ac_ext >&5
17000
Ronald Oussoren450d5612009-06-08 21:12:41 +000017001 { echo "$as_me:$LINENO: result: no" >&5
17002echo "${ECHO_T}no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017003
17004fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017005
17006rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000017007{ echo "$as_me:$LINENO: checking for fdatasync" >&5
17008echo $ECHO_N "checking for fdatasync... $ECHO_C" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017009cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017010/* confdefs.h. */
17011_ACEOF
17012cat confdefs.h >>conftest.$ac_ext
17013cat >>conftest.$ac_ext <<_ACEOF
17014/* end confdefs.h. */
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017015#include <unistd.h>
17016int
17017main ()
17018{
17019void *x=fdatasync
17020 ;
17021 return 0;
17022}
17023_ACEOF
17024rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017025if { (ac_try="$ac_compile"
17026case "(($ac_try" in
17027 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17028 *) ac_try_echo=$ac_try;;
17029esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017030eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017031 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017032 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017033 grep -v '^ *+' conftest.er1 >conftest.err
17034 rm -f conftest.er1
17035 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017036 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017037 (exit $ac_status); } && {
17038 test -z "$ac_c_werror_flag" ||
17039 test ! -s conftest.err
17040 } && test -s conftest.$ac_objext; then
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017041
17042cat >>confdefs.h <<\_ACEOF
17043#define HAVE_FDATASYNC 1
17044_ACEOF
17045
Ronald Oussoren450d5612009-06-08 21:12:41 +000017046 { echo "$as_me:$LINENO: result: yes" >&5
17047echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017048else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017049 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017050sed 's/^/| /' conftest.$ac_ext >&5
17051
Ronald Oussoren450d5612009-06-08 21:12:41 +000017052 { echo "$as_me:$LINENO: result: no" >&5
17053echo "${ECHO_T}no" >&6; }
Martin v. Löwisa64988c2003-09-20 15:30:20 +000017054
17055fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017056
17057rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000017058{ echo "$as_me:$LINENO: checking for epoll" >&5
17059echo $ECHO_N "checking for epoll... $ECHO_C" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017060cat >conftest.$ac_ext <<_ACEOF
17061/* confdefs.h. */
17062_ACEOF
17063cat confdefs.h >>conftest.$ac_ext
17064cat >>conftest.$ac_ext <<_ACEOF
17065/* end confdefs.h. */
17066#include <sys/epoll.h>
17067int
17068main ()
17069{
17070void *x=epoll_create
17071 ;
17072 return 0;
17073}
17074_ACEOF
17075rm -f conftest.$ac_objext
17076if { (ac_try="$ac_compile"
17077case "(($ac_try" in
17078 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17079 *) ac_try_echo=$ac_try;;
17080esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017081eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017082 (eval "$ac_compile") 2>conftest.er1
17083 ac_status=$?
17084 grep -v '^ *+' conftest.er1 >conftest.err
17085 rm -f conftest.er1
17086 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017087 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017088 (exit $ac_status); } && {
17089 test -z "$ac_c_werror_flag" ||
17090 test ! -s conftest.err
17091 } && test -s conftest.$ac_objext; then
Martin v. Löwisc8ad7cc2002-11-11 13:23:45 +000017092
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017093cat >>confdefs.h <<\_ACEOF
17094#define HAVE_EPOLL 1
17095_ACEOF
17096
Ronald Oussoren450d5612009-06-08 21:12:41 +000017097 { echo "$as_me:$LINENO: result: yes" >&5
17098echo "${ECHO_T}yes" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017099else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017100 echo "$as_me: failed program was:" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017101sed 's/^/| /' conftest.$ac_ext >&5
17102
Ronald Oussoren450d5612009-06-08 21:12:41 +000017103 { echo "$as_me:$LINENO: result: no" >&5
17104echo "${ECHO_T}no" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017105
17106fi
17107
17108rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000017109{ echo "$as_me:$LINENO: checking for kqueue" >&5
17110echo $ECHO_N "checking for kqueue... $ECHO_C" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017111cat >conftest.$ac_ext <<_ACEOF
17112/* confdefs.h. */
17113_ACEOF
17114cat confdefs.h >>conftest.$ac_ext
17115cat >>conftest.$ac_ext <<_ACEOF
17116/* end confdefs.h. */
17117
17118#include <sys/types.h>
17119#include <sys/event.h>
17120
17121int
17122main ()
17123{
17124int x=kqueue()
17125 ;
17126 return 0;
17127}
17128_ACEOF
17129rm -f conftest.$ac_objext
17130if { (ac_try="$ac_compile"
17131case "(($ac_try" in
17132 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17133 *) ac_try_echo=$ac_try;;
17134esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017135eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017136 (eval "$ac_compile") 2>conftest.er1
17137 ac_status=$?
17138 grep -v '^ *+' conftest.er1 >conftest.err
17139 rm -f conftest.er1
17140 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017141 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017142 (exit $ac_status); } && {
17143 test -z "$ac_c_werror_flag" ||
17144 test ! -s conftest.err
17145 } && test -s conftest.$ac_objext; then
17146
17147cat >>confdefs.h <<\_ACEOF
17148#define HAVE_KQUEUE 1
17149_ACEOF
17150
Ronald Oussoren450d5612009-06-08 21:12:41 +000017151 { echo "$as_me:$LINENO: result: yes" >&5
17152echo "${ECHO_T}yes" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017153else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017154 echo "$as_me: failed program was:" >&5
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017155sed 's/^/| /' conftest.$ac_ext >&5
17156
Ronald Oussoren450d5612009-06-08 21:12:41 +000017157 { echo "$as_me:$LINENO: result: no" >&5
17158echo "${ECHO_T}no" >&6; }
Christian Heimes0e9ab5f2008-03-21 23:49:44 +000017159
17160fi
17161
17162rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisd5843682002-11-21 20:41:28 +000017163# On some systems (eg. FreeBSD 5), we would find a definition of the
17164# functions ctermid_r, setgroups in the library, but no prototype
17165# (e.g. because we use _XOPEN_SOURCE). See whether we can take their
17166# address to avoid compiler warnings and potential miscompilations
17167# because of the missing prototypes.
17168
Ronald Oussoren450d5612009-06-08 21:12:41 +000017169{ echo "$as_me:$LINENO: checking for ctermid_r" >&5
17170echo $ECHO_N "checking for ctermid_r... $ECHO_C" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017171cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017172/* confdefs.h. */
17173_ACEOF
17174cat confdefs.h >>conftest.$ac_ext
17175cat >>conftest.$ac_ext <<_ACEOF
17176/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000017177
17178#include "confdefs.h"
17179#include <stdio.h>
17180
Martin v. Löwisd5843682002-11-21 20:41:28 +000017181int
17182main ()
17183{
17184void* p = ctermid_r
17185 ;
17186 return 0;
17187}
17188_ACEOF
17189rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017190if { (ac_try="$ac_compile"
17191case "(($ac_try" in
17192 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17193 *) ac_try_echo=$ac_try;;
17194esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017195eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017196 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisd5843682002-11-21 20:41:28 +000017197 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017198 grep -v '^ *+' conftest.er1 >conftest.err
17199 rm -f conftest.er1
17200 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017201 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017202 (exit $ac_status); } && {
17203 test -z "$ac_c_werror_flag" ||
17204 test ! -s conftest.err
17205 } && test -s conftest.$ac_objext; then
Martin v. Löwisd5843682002-11-21 20:41:28 +000017206
17207cat >>confdefs.h <<\_ACEOF
17208#define HAVE_CTERMID_R 1
17209_ACEOF
17210
Ronald Oussoren450d5612009-06-08 21:12:41 +000017211 { echo "$as_me:$LINENO: result: yes" >&5
17212echo "${ECHO_T}yes" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017213else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017214 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017215sed 's/^/| /' conftest.$ac_ext >&5
17216
Ronald Oussoren450d5612009-06-08 21:12:41 +000017217 { echo "$as_me:$LINENO: result: no" >&5
17218echo "${ECHO_T}no" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017219
17220fi
Martin v. Löwisd5843682002-11-21 20:41:28 +000017221
Martin v. Löwiseba40652007-08-30 20:10:57 +000017222rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17223
Ronald Oussoren450d5612009-06-08 21:12:41 +000017224{ echo "$as_me:$LINENO: checking for flock" >&5
17225echo $ECHO_N "checking for flock... $ECHO_C" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017226cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017227/* confdefs.h. */
17228_ACEOF
17229cat confdefs.h >>conftest.$ac_ext
17230cat >>conftest.$ac_ext <<_ACEOF
17231/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017232
17233#include "confdefs.h"
17234#include <sys/file.h>
17235
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017236int
17237main ()
17238{
17239void* p = flock
17240 ;
17241 return 0;
17242}
17243_ACEOF
17244rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017245if { (ac_try="$ac_compile"
17246case "(($ac_try" in
17247 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17248 *) ac_try_echo=$ac_try;;
17249esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017250eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017251 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017252 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017253 grep -v '^ *+' conftest.er1 >conftest.err
17254 rm -f conftest.er1
17255 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017256 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017257 (exit $ac_status); } && {
17258 test -z "$ac_c_werror_flag" ||
17259 test ! -s conftest.err
17260 } && test -s conftest.$ac_objext; then
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017261
17262cat >>confdefs.h <<\_ACEOF
17263#define HAVE_FLOCK 1
17264_ACEOF
17265
Ronald Oussoren450d5612009-06-08 21:12:41 +000017266 { echo "$as_me:$LINENO: result: yes" >&5
17267echo "${ECHO_T}yes" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017268else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017269 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017270sed 's/^/| /' conftest.$ac_ext >&5
17271
Ronald Oussoren450d5612009-06-08 21:12:41 +000017272 { echo "$as_me:$LINENO: result: no" >&5
17273echo "${ECHO_T}no" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017274
17275fi
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017276
Martin v. Löwiseba40652007-08-30 20:10:57 +000017277rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17278
Ronald Oussoren450d5612009-06-08 21:12:41 +000017279{ echo "$as_me:$LINENO: checking for getpagesize" >&5
17280echo $ECHO_N "checking for getpagesize... $ECHO_C" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017281cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017282/* confdefs.h. */
17283_ACEOF
17284cat confdefs.h >>conftest.$ac_ext
17285cat >>conftest.$ac_ext <<_ACEOF
17286/* end confdefs.h. */
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017287
17288#include "confdefs.h"
17289#include <unistd.h>
17290
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017291int
17292main ()
17293{
17294void* p = getpagesize
17295 ;
17296 return 0;
17297}
17298_ACEOF
17299rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017300if { (ac_try="$ac_compile"
17301case "(($ac_try" in
17302 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17303 *) ac_try_echo=$ac_try;;
17304esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017305eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017306 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017307 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017308 grep -v '^ *+' conftest.er1 >conftest.err
17309 rm -f conftest.er1
17310 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017311 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017312 (exit $ac_status); } && {
17313 test -z "$ac_c_werror_flag" ||
17314 test ! -s conftest.err
17315 } && test -s conftest.$ac_objext; then
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017316
17317cat >>confdefs.h <<\_ACEOF
17318#define HAVE_GETPAGESIZE 1
17319_ACEOF
17320
Ronald Oussoren450d5612009-06-08 21:12:41 +000017321 { echo "$as_me:$LINENO: result: yes" >&5
17322echo "${ECHO_T}yes" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017323else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017324 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017325sed 's/^/| /' conftest.$ac_ext >&5
17326
Ronald Oussoren450d5612009-06-08 21:12:41 +000017327 { echo "$as_me:$LINENO: result: no" >&5
17328echo "${ECHO_T}no" >&6; }
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017329
17330fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017331
17332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisf26d63b2003-03-30 17:23:49 +000017333
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017334for ac_prog in true
17335do
17336 # Extract the first word of "$ac_prog", so it can be a program name with args.
17337set dummy $ac_prog; ac_word=$2
Ronald Oussoren450d5612009-06-08 21:12:41 +000017338{ echo "$as_me:$LINENO: checking for $ac_word" >&5
17339echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017340if test "${ac_cv_prog_TRUE+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017341 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017342else
17343 if test -n "$TRUE"; then
17344 ac_cv_prog_TRUE="$TRUE" # Let the user override the test.
17345else
17346as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17347for as_dir in $PATH
17348do
17349 IFS=$as_save_IFS
17350 test -z "$as_dir" && as_dir=.
17351 for ac_exec_ext in '' $ac_executable_extensions; do
Martin v. Löwiseba40652007-08-30 20:10:57 +000017352 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017353 ac_cv_prog_TRUE="$ac_prog"
Ronald Oussoren450d5612009-06-08 21:12:41 +000017354 echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017355 break 2
17356 fi
17357done
17358done
Martin v. Löwiseba40652007-08-30 20:10:57 +000017359IFS=$as_save_IFS
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017360
17361fi
17362fi
17363TRUE=$ac_cv_prog_TRUE
17364if test -n "$TRUE"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017365 { echo "$as_me:$LINENO: result: $TRUE" >&5
17366echo "${ECHO_T}$TRUE" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017367else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017368 { echo "$as_me:$LINENO: result: no" >&5
17369echo "${ECHO_T}no" >&6; }
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017370fi
17371
Martin v. Löwiseba40652007-08-30 20:10:57 +000017372
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017373 test -n "$TRUE" && break
17374done
17375test -n "$TRUE" || TRUE="/bin/true"
17376
17377
Ronald Oussoren450d5612009-06-08 21:12:41 +000017378{ echo "$as_me:$LINENO: checking for inet_aton in -lc" >&5
17379echo $ECHO_N "checking for inet_aton in -lc... $ECHO_C" >&6; }
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017380if test "${ac_cv_lib_c_inet_aton+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017381 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017382else
17383 ac_check_lib_save_LIBS=$LIBS
17384LIBS="-lc $LIBS"
17385cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017386/* confdefs.h. */
17387_ACEOF
17388cat confdefs.h >>conftest.$ac_ext
17389cat >>conftest.$ac_ext <<_ACEOF
17390/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017391
Martin v. Löwiseba40652007-08-30 20:10:57 +000017392/* Override any GCC internal prototype to avoid an error.
17393 Use char because int might match the return type of a GCC
17394 builtin and then its argument prototype would still apply. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017395#ifdef __cplusplus
17396extern "C"
17397#endif
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017398char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017399int
17400main ()
17401{
Martin v. Löwiseba40652007-08-30 20:10:57 +000017402return inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017403 ;
17404 return 0;
17405}
17406_ACEOF
17407rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017408if { (ac_try="$ac_link"
17409case "(($ac_try" in
17410 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17411 *) ac_try_echo=$ac_try;;
17412esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017413eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017414 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017415 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017416 grep -v '^ *+' conftest.er1 >conftest.err
17417 rm -f conftest.er1
17418 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017419 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017420 (exit $ac_status); } && {
17421 test -z "$ac_c_werror_flag" ||
17422 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000017423 } && test -s conftest$ac_exeext &&
17424 $as_test_x conftest$ac_exeext; then
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017425 ac_cv_lib_c_inet_aton=yes
17426else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017427 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017428sed 's/^/| /' conftest.$ac_ext >&5
17429
Martin v. Löwiseba40652007-08-30 20:10:57 +000017430 ac_cv_lib_c_inet_aton=no
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017431fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017432
17433rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017434 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017435LIBS=$ac_check_lib_save_LIBS
17436fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000017437{ echo "$as_me:$LINENO: result: $ac_cv_lib_c_inet_aton" >&5
17438echo "${ECHO_T}$ac_cv_lib_c_inet_aton" >&6; }
17439if test $ac_cv_lib_c_inet_aton = yes; then
Martin v. Löwis4ee6eef2003-05-26 05:37:51 +000017440 $ac_cv_prog_TRUE
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017441else
17442
Ronald Oussoren450d5612009-06-08 21:12:41 +000017443{ echo "$as_me:$LINENO: checking for inet_aton in -lresolv" >&5
17444echo $ECHO_N "checking for inet_aton in -lresolv... $ECHO_C" >&6; }
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017445if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017446 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017447else
17448 ac_check_lib_save_LIBS=$LIBS
17449LIBS="-lresolv $LIBS"
17450cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017451/* confdefs.h. */
17452_ACEOF
17453cat confdefs.h >>conftest.$ac_ext
17454cat >>conftest.$ac_ext <<_ACEOF
17455/* end confdefs.h. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017456
Martin v. Löwiseba40652007-08-30 20:10:57 +000017457/* Override any GCC internal prototype to avoid an error.
17458 Use char because int might match the return type of a GCC
17459 builtin and then its argument prototype would still apply. */
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017460#ifdef __cplusplus
17461extern "C"
17462#endif
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017463char inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017464int
17465main ()
17466{
Martin v. Löwiseba40652007-08-30 20:10:57 +000017467return inet_aton ();
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017468 ;
17469 return 0;
17470}
17471_ACEOF
17472rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017473if { (ac_try="$ac_link"
17474case "(($ac_try" in
17475 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17476 *) ac_try_echo=$ac_try;;
17477esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017478eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017479 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017480 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017481 grep -v '^ *+' conftest.er1 >conftest.err
17482 rm -f conftest.er1
17483 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017484 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017485 (exit $ac_status); } && {
17486 test -z "$ac_c_werror_flag" ||
17487 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000017488 } && test -s conftest$ac_exeext &&
17489 $as_test_x conftest$ac_exeext; then
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017490 ac_cv_lib_resolv_inet_aton=yes
17491else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017492 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017493sed 's/^/| /' conftest.$ac_ext >&5
17494
Martin v. Löwiseba40652007-08-30 20:10:57 +000017495 ac_cv_lib_resolv_inet_aton=no
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017496fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017497
17498rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017499 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017500LIBS=$ac_check_lib_save_LIBS
17501fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000017502{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_inet_aton" >&5
17503echo "${ECHO_T}$ac_cv_lib_resolv_inet_aton" >&6; }
17504if test $ac_cv_lib_resolv_inet_aton = yes; then
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017505 cat >>confdefs.h <<_ACEOF
17506#define HAVE_LIBRESOLV 1
17507_ACEOF
17508
17509 LIBS="-lresolv $LIBS"
17510
17511fi
17512
17513
17514fi
17515
17516
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017517# On Tru64, chflags seems to be present, but calling it will
17518# exit Python
Ronald Oussoren450d5612009-06-08 21:12:41 +000017519{ echo "$as_me:$LINENO: checking for chflags" >&5
17520echo $ECHO_N "checking for chflags... $ECHO_C" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017521if test "$cross_compiling" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017522 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017523See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017524echo "$as_me: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017525See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000017526 { (exit 1); exit 1; }; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017527else
17528 cat >conftest.$ac_ext <<_ACEOF
17529/* confdefs.h. */
17530_ACEOF
17531cat confdefs.h >>conftest.$ac_ext
17532cat >>conftest.$ac_ext <<_ACEOF
17533/* end confdefs.h. */
17534
17535#include <sys/stat.h>
17536#include <unistd.h>
17537int main(int argc, char*argv[])
17538{
17539 if(chflags(argv[0], 0) != 0)
17540 return 1;
17541 return 0;
17542}
17543
17544_ACEOF
17545rm -f conftest$ac_exeext
17546if { (ac_try="$ac_link"
17547case "(($ac_try" in
17548 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17549 *) ac_try_echo=$ac_try;;
17550esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017551eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017552 (eval "$ac_link") 2>&5
17553 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000017554 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017555 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17556 { (case "(($ac_try" in
17557 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17558 *) ac_try_echo=$ac_try;;
17559esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017560eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017561 (eval "$ac_try") 2>&5
17562 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000017563 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017564 (exit $ac_status); }; }; then
17565
17566cat >>confdefs.h <<\_ACEOF
17567#define HAVE_CHFLAGS 1
17568_ACEOF
17569
Ronald Oussoren450d5612009-06-08 21:12:41 +000017570 { echo "$as_me:$LINENO: result: yes" >&5
17571echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017572else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017573 echo "$as_me: program exited with status $ac_status" >&5
17574echo "$as_me: failed program was:" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017575sed 's/^/| /' conftest.$ac_ext >&5
17576
17577( exit $ac_status )
Ronald Oussoren450d5612009-06-08 21:12:41 +000017578{ echo "$as_me:$LINENO: result: no" >&5
17579echo "${ECHO_T}no" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017580
17581fi
17582rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17583fi
17584
17585
17586
Ronald Oussoren450d5612009-06-08 21:12:41 +000017587{ echo "$as_me:$LINENO: checking for lchflags" >&5
17588echo $ECHO_N "checking for lchflags... $ECHO_C" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017589if test "$cross_compiling" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017590 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017591See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017592echo "$as_me: error: cannot run test program while cross compiling
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017593See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000017594 { (exit 1); exit 1; }; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017595else
17596 cat >conftest.$ac_ext <<_ACEOF
17597/* confdefs.h. */
17598_ACEOF
17599cat confdefs.h >>conftest.$ac_ext
17600cat >>conftest.$ac_ext <<_ACEOF
17601/* end confdefs.h. */
17602
17603#include <sys/stat.h>
17604#include <unistd.h>
17605int main(int argc, char*argv[])
17606{
17607 if(lchflags(argv[0], 0) != 0)
17608 return 1;
17609 return 0;
17610}
17611
17612_ACEOF
17613rm -f conftest$ac_exeext
17614if { (ac_try="$ac_link"
17615case "(($ac_try" in
17616 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17617 *) ac_try_echo=$ac_try;;
17618esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017619eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017620 (eval "$ac_link") 2>&5
17621 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000017622 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017623 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17624 { (case "(($ac_try" in
17625 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17626 *) ac_try_echo=$ac_try;;
17627esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017628eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017629 (eval "$ac_try") 2>&5
17630 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000017631 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017632 (exit $ac_status); }; }; then
17633
17634cat >>confdefs.h <<\_ACEOF
17635#define HAVE_LCHFLAGS 1
17636_ACEOF
17637
Ronald Oussoren450d5612009-06-08 21:12:41 +000017638 { echo "$as_me:$LINENO: result: yes" >&5
17639echo "${ECHO_T}yes" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017640else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017641 echo "$as_me: program exited with status $ac_status" >&5
17642echo "$as_me: failed program was:" >&5
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017643sed 's/^/| /' conftest.$ac_ext >&5
17644
17645( exit $ac_status )
Ronald Oussoren450d5612009-06-08 21:12:41 +000017646{ echo "$as_me:$LINENO: result: no" >&5
17647echo "${ECHO_T}no" >&6; }
Martin v. Löwisa51d5c82007-12-04 08:37:59 +000017648
17649fi
17650rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17651fi
17652
17653
17654
Ronald Oussorenf8752642006-07-06 10:13:35 +000017655case $ac_sys_system/$ac_sys_release in
17656Darwin/*)
17657 _CUR_CFLAGS="${CFLAGS}"
17658 _CUR_LDFLAGS="${LDFLAGS}"
17659 CFLAGS="${CFLAGS} -Wl,-search_paths_first"
17660 LDFLAGS="${LDFLAGS} -Wl,-search_paths_first -L/usr/local/lib"
17661 ;;
17662esac
17663
Ronald Oussoren450d5612009-06-08 21:12:41 +000017664{ echo "$as_me:$LINENO: checking for inflateCopy in -lz" >&5
17665echo $ECHO_N "checking for inflateCopy in -lz... $ECHO_C" >&6; }
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017666if test "${ac_cv_lib_z_inflateCopy+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017667 echo $ECHO_N "(cached) $ECHO_C" >&6
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017668else
17669 ac_check_lib_save_LIBS=$LIBS
17670LIBS="-lz $LIBS"
17671cat >conftest.$ac_ext <<_ACEOF
17672/* confdefs.h. */
17673_ACEOF
17674cat confdefs.h >>conftest.$ac_ext
17675cat >>conftest.$ac_ext <<_ACEOF
17676/* end confdefs.h. */
17677
Martin v. Löwiseba40652007-08-30 20:10:57 +000017678/* Override any GCC internal prototype to avoid an error.
17679 Use char because int might match the return type of a GCC
17680 builtin and then its argument prototype would still apply. */
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017681#ifdef __cplusplus
17682extern "C"
17683#endif
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017684char inflateCopy ();
17685int
17686main ()
17687{
Martin v. Löwiseba40652007-08-30 20:10:57 +000017688return inflateCopy ();
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017689 ;
17690 return 0;
17691}
17692_ACEOF
17693rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017694if { (ac_try="$ac_link"
17695case "(($ac_try" in
17696 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17697 *) ac_try_echo=$ac_try;;
17698esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017699eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017700 (eval "$ac_link") 2>conftest.er1
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017701 ac_status=$?
17702 grep -v '^ *+' conftest.er1 >conftest.err
17703 rm -f conftest.er1
17704 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017705 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017706 (exit $ac_status); } && {
17707 test -z "$ac_c_werror_flag" ||
17708 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000017709 } && test -s conftest$ac_exeext &&
17710 $as_test_x conftest$ac_exeext; then
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017711 ac_cv_lib_z_inflateCopy=yes
17712else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017713 echo "$as_me: failed program was:" >&5
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017714sed 's/^/| /' conftest.$ac_ext >&5
17715
Martin v. Löwiseba40652007-08-30 20:10:57 +000017716 ac_cv_lib_z_inflateCopy=no
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017717fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017718
17719rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017720 conftest$ac_exeext conftest.$ac_ext
17721LIBS=$ac_check_lib_save_LIBS
17722fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000017723{ echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflateCopy" >&5
17724echo "${ECHO_T}$ac_cv_lib_z_inflateCopy" >&6; }
17725if test $ac_cv_lib_z_inflateCopy = yes; then
Neal Norwitz6e73aaa2006-06-12 03:33:09 +000017726
17727cat >>confdefs.h <<\_ACEOF
17728#define HAVE_ZLIB_COPY 1
17729_ACEOF
17730
17731fi
17732
17733
Ronald Oussorenf8752642006-07-06 10:13:35 +000017734case $ac_sys_system/$ac_sys_release in
17735Darwin/*)
17736 CFLAGS="${_CUR_CFLAGS}"
17737 LDFLAGS="${_CUR_LDFLAGS}"
17738 ;;
17739esac
17740
Ronald Oussoren450d5612009-06-08 21:12:41 +000017741{ echo "$as_me:$LINENO: checking for hstrerror" >&5
17742echo $ECHO_N "checking for hstrerror... $ECHO_C" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017743cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017744/* confdefs.h. */
17745_ACEOF
17746cat confdefs.h >>conftest.$ac_ext
17747cat >>conftest.$ac_ext <<_ACEOF
17748/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000017749
17750#include "confdefs.h"
17751#include <netdb.h>
17752
Martin v. Löwise9416172003-05-03 10:12:45 +000017753int
17754main ()
17755{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017756void* p = hstrerror; hstrerror(0)
Martin v. Löwise9416172003-05-03 10:12:45 +000017757 ;
17758 return 0;
17759}
17760_ACEOF
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017761rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017762if { (ac_try="$ac_link"
17763case "(($ac_try" in
17764 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17765 *) ac_try_echo=$ac_try;;
17766esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017767eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017768 (eval "$ac_link") 2>conftest.er1
Martin v. Löwise9416172003-05-03 10:12:45 +000017769 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017770 grep -v '^ *+' conftest.er1 >conftest.err
17771 rm -f conftest.er1
17772 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017773 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017774 (exit $ac_status); } && {
17775 test -z "$ac_c_werror_flag" ||
17776 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000017777 } && test -s conftest$ac_exeext &&
17778 $as_test_x conftest$ac_exeext; then
Martin v. Löwise9416172003-05-03 10:12:45 +000017779
17780cat >>confdefs.h <<\_ACEOF
17781#define HAVE_HSTRERROR 1
17782_ACEOF
17783
Ronald Oussoren450d5612009-06-08 21:12:41 +000017784 { echo "$as_me:$LINENO: result: yes" >&5
17785echo "${ECHO_T}yes" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017786else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017787 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017788sed 's/^/| /' conftest.$ac_ext >&5
17789
Ronald Oussoren450d5612009-06-08 21:12:41 +000017790 { echo "$as_me:$LINENO: result: no" >&5
17791echo "${ECHO_T}no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017792
17793fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017794
17795rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017796 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000017797
Ronald Oussoren450d5612009-06-08 21:12:41 +000017798{ echo "$as_me:$LINENO: checking for inet_aton" >&5
17799echo $ECHO_N "checking for inet_aton... $ECHO_C" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017800cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017801/* confdefs.h. */
17802_ACEOF
17803cat confdefs.h >>conftest.$ac_ext
17804cat >>conftest.$ac_ext <<_ACEOF
17805/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000017806
17807#include "confdefs.h"
Martin v. Löwis86d66262006-02-17 08:40:11 +000017808#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000017809#include <sys/socket.h>
17810#include <netinet/in.h>
17811#include <arpa/inet.h>
17812
Martin v. Löwise9416172003-05-03 10:12:45 +000017813int
17814main ()
17815{
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017816void* p = inet_aton;inet_aton(0,0)
Martin v. Löwise9416172003-05-03 10:12:45 +000017817 ;
17818 return 0;
17819}
17820_ACEOF
Martin v. Löwis95c419b2003-05-03 12:10:48 +000017821rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017822if { (ac_try="$ac_link"
17823case "(($ac_try" in
17824 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17825 *) ac_try_echo=$ac_try;;
17826esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017827eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017828 (eval "$ac_link") 2>conftest.er1
Martin v. Löwise9416172003-05-03 10:12:45 +000017829 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017830 grep -v '^ *+' conftest.er1 >conftest.err
17831 rm -f conftest.er1
17832 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017833 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017834 (exit $ac_status); } && {
17835 test -z "$ac_c_werror_flag" ||
17836 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000017837 } && test -s conftest$ac_exeext &&
17838 $as_test_x conftest$ac_exeext; then
Martin v. Löwise9416172003-05-03 10:12:45 +000017839
17840cat >>confdefs.h <<\_ACEOF
17841#define HAVE_INET_ATON 1
17842_ACEOF
17843
Ronald Oussoren450d5612009-06-08 21:12:41 +000017844 { echo "$as_me:$LINENO: result: yes" >&5
17845echo "${ECHO_T}yes" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017846else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017847 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017848sed 's/^/| /' conftest.$ac_ext >&5
17849
Ronald Oussoren450d5612009-06-08 21:12:41 +000017850 { echo "$as_me:$LINENO: result: no" >&5
17851echo "${ECHO_T}no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017852
17853fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017854
17855rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000017856 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000017857
Ronald Oussoren450d5612009-06-08 21:12:41 +000017858{ echo "$as_me:$LINENO: checking for inet_pton" >&5
17859echo $ECHO_N "checking for inet_pton... $ECHO_C" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017860cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017861/* confdefs.h. */
17862_ACEOF
17863cat confdefs.h >>conftest.$ac_ext
17864cat >>conftest.$ac_ext <<_ACEOF
17865/* end confdefs.h. */
Martin v. Löwise9416172003-05-03 10:12:45 +000017866
17867#include "confdefs.h"
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000017868#include <sys/types.h>
Martin v. Löwise9416172003-05-03 10:12:45 +000017869#include <sys/socket.h>
17870#include <netinet/in.h>
17871#include <arpa/inet.h>
17872
Martin v. Löwise9416172003-05-03 10:12:45 +000017873int
17874main ()
17875{
17876void* p = inet_pton
17877 ;
17878 return 0;
17879}
17880_ACEOF
17881rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017882if { (ac_try="$ac_compile"
17883case "(($ac_try" in
17884 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17885 *) ac_try_echo=$ac_try;;
17886esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017887eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017888 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwise9416172003-05-03 10:12:45 +000017889 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017890 grep -v '^ *+' conftest.er1 >conftest.err
17891 rm -f conftest.er1
17892 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017893 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017894 (exit $ac_status); } && {
17895 test -z "$ac_c_werror_flag" ||
17896 test ! -s conftest.err
17897 } && test -s conftest.$ac_objext; then
Martin v. Löwise9416172003-05-03 10:12:45 +000017898
17899cat >>confdefs.h <<\_ACEOF
17900#define HAVE_INET_PTON 1
17901_ACEOF
17902
Ronald Oussoren450d5612009-06-08 21:12:41 +000017903 { echo "$as_me:$LINENO: result: yes" >&5
17904echo "${ECHO_T}yes" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017905else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017906 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017907sed 's/^/| /' conftest.$ac_ext >&5
17908
Ronald Oussoren450d5612009-06-08 21:12:41 +000017909 { echo "$as_me:$LINENO: result: no" >&5
17910echo "${ECHO_T}no" >&6; }
Martin v. Löwise9416172003-05-03 10:12:45 +000017911
17912fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017913
17914rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwise9416172003-05-03 10:12:45 +000017915
Martin v. Löwisd6640d42003-07-06 09:29:52 +000017916# On some systems, setgroups is in unistd.h, on others, in grp.h
Ronald Oussoren450d5612009-06-08 21:12:41 +000017917{ echo "$as_me:$LINENO: checking for setgroups" >&5
17918echo $ECHO_N "checking for setgroups... $ECHO_C" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017919cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017920/* confdefs.h. */
17921_ACEOF
17922cat confdefs.h >>conftest.$ac_ext
17923cat >>conftest.$ac_ext <<_ACEOF
17924/* end confdefs.h. */
Martin v. Löwisd5843682002-11-21 20:41:28 +000017925
17926#include "confdefs.h"
Martin v. Löwisf2e488d2003-05-05 22:00:11 +000017927#include <unistd.h>
Martin v. Löwisd6640d42003-07-06 09:29:52 +000017928#ifdef HAVE_GRP_H
17929#include <grp.h>
17930#endif
Martin v. Löwisd5843682002-11-21 20:41:28 +000017931
Martin v. Löwisd5843682002-11-21 20:41:28 +000017932int
17933main ()
17934{
17935void* p = setgroups
17936 ;
17937 return 0;
17938}
17939_ACEOF
17940rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000017941if { (ac_try="$ac_compile"
17942case "(($ac_try" in
17943 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17944 *) ac_try_echo=$ac_try;;
17945esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000017946eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017947 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisd5843682002-11-21 20:41:28 +000017948 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000017949 grep -v '^ *+' conftest.er1 >conftest.err
17950 rm -f conftest.er1
17951 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000017952 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000017953 (exit $ac_status); } && {
17954 test -z "$ac_c_werror_flag" ||
17955 test ! -s conftest.err
17956 } && test -s conftest.$ac_objext; then
Martin v. Löwisd5843682002-11-21 20:41:28 +000017957
17958cat >>confdefs.h <<\_ACEOF
17959#define HAVE_SETGROUPS 1
17960_ACEOF
17961
Ronald Oussoren450d5612009-06-08 21:12:41 +000017962 { echo "$as_me:$LINENO: result: yes" >&5
17963echo "${ECHO_T}yes" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017964else
Ronald Oussoren450d5612009-06-08 21:12:41 +000017965 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000017966sed 's/^/| /' conftest.$ac_ext >&5
17967
Ronald Oussoren450d5612009-06-08 21:12:41 +000017968 { echo "$as_me:$LINENO: result: no" >&5
17969echo "${ECHO_T}no" >&6; }
Martin v. Löwisd5843682002-11-21 20:41:28 +000017970
17971fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000017972
17973rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisd5843682002-11-21 20:41:28 +000017974
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000017975# check for openpty and forkpty
17976
Martin v. Löwis11437992002-04-12 09:54:03 +000017977
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000017978for ac_func in openpty
17979do
Ronald Oussoren450d5612009-06-08 21:12:41 +000017980as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17981{ echo "$as_me:$LINENO: checking for $ac_func" >&5
17982echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000017983if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000017984 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000017985else
Martin v. Löwis11437992002-04-12 09:54:03 +000017986 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000017987/* confdefs.h. */
17988_ACEOF
17989cat confdefs.h >>conftest.$ac_ext
17990cat >>conftest.$ac_ext <<_ACEOF
17991/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000017992/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17993 For example, HP-UX 11i <limits.h> declares gettimeofday. */
17994#define $ac_func innocuous_$ac_func
17995
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000017996/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000017997 which can conflict with char $ac_func (); below.
17998 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000017999 <limits.h> exists even on freestanding compilers. */
18000
18001#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018002# include <limits.h>
18003#else
18004# include <assert.h>
18005#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018006
18007#undef $ac_func
18008
Martin v. Löwiseba40652007-08-30 20:10:57 +000018009/* Override any GCC internal prototype to avoid an error.
18010 Use char because int might match the return type of a GCC
18011 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018012#ifdef __cplusplus
18013extern "C"
18014#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018015char $ac_func ();
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018016/* The GNU C library defines this for functions which it implements
18017 to always fail with ENOSYS. Some functions are actually named
18018 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018019#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018020choke me
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018021#endif
18022
Skip Montanaro6dead952003-09-25 14:50:04 +000018023int
18024main ()
18025{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018026return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018027 ;
18028 return 0;
18029}
18030_ACEOF
18031rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018032if { (ac_try="$ac_link"
18033case "(($ac_try" in
18034 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18035 *) ac_try_echo=$ac_try;;
18036esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018037eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018038 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018039 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018040 grep -v '^ *+' conftest.er1 >conftest.err
18041 rm -f conftest.er1
18042 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018044 (exit $ac_status); } && {
18045 test -z "$ac_c_werror_flag" ||
18046 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018047 } && test -s conftest$ac_exeext &&
18048 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018049 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000018050else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018051 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018052sed 's/^/| /' conftest.$ac_ext >&5
18053
Martin v. Löwiseba40652007-08-30 20:10:57 +000018054 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018055fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018056
18057rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018058 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018059fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018060ac_res=`eval echo '${'$as_ac_var'}'`
18061 { echo "$as_me:$LINENO: result: $ac_res" >&5
18062echo "${ECHO_T}$ac_res" >&6; }
18063if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018064 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018065#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018066_ACEOF
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018067
Guido van Rossumd0b69ec2001-09-10 14:10:54 +000018068else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018069 { echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
18070echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000018071if test "${ac_cv_lib_util_openpty+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018072 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000018073else
Martin v. Löwis11437992002-04-12 09:54:03 +000018074 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018075LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000018076cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018077/* confdefs.h. */
18078_ACEOF
18079cat confdefs.h >>conftest.$ac_ext
18080cat >>conftest.$ac_ext <<_ACEOF
18081/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018082
Martin v. Löwiseba40652007-08-30 20:10:57 +000018083/* Override any GCC internal prototype to avoid an error.
18084 Use char because int might match the return type of a GCC
18085 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018086#ifdef __cplusplus
18087extern "C"
18088#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018089char openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018090int
18091main ()
18092{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018093return openpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018094 ;
18095 return 0;
18096}
18097_ACEOF
18098rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018099if { (ac_try="$ac_link"
18100case "(($ac_try" in
18101 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18102 *) ac_try_echo=$ac_try;;
18103esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018104eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018105 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018106 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018107 grep -v '^ *+' conftest.er1 >conftest.err
18108 rm -f conftest.er1
18109 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018110 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018111 (exit $ac_status); } && {
18112 test -z "$ac_c_werror_flag" ||
18113 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018114 } && test -s conftest$ac_exeext &&
18115 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018116 ac_cv_lib_util_openpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000018117else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018118 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018119sed 's/^/| /' conftest.$ac_ext >&5
18120
Martin v. Löwiseba40652007-08-30 20:10:57 +000018121 ac_cv_lib_util_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018122fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018123
18124rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018125 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018126LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018127fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018128{ echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
18129echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6; }
18130if test $ac_cv_lib_util_openpty = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018131 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018132#define HAVE_OPENPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018133_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018134 LIBS="$LIBS -lutil"
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018135else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018136 { echo "$as_me:$LINENO: checking for openpty in -lbsd" >&5
18137echo $ECHO_N "checking for openpty in -lbsd... $ECHO_C" >&6; }
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018138if test "${ac_cv_lib_bsd_openpty+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018139 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018140else
18141 ac_check_lib_save_LIBS=$LIBS
18142LIBS="-lbsd $LIBS"
18143cat >conftest.$ac_ext <<_ACEOF
18144/* confdefs.h. */
18145_ACEOF
18146cat confdefs.h >>conftest.$ac_ext
18147cat >>conftest.$ac_ext <<_ACEOF
18148/* end confdefs.h. */
18149
Martin v. Löwiseba40652007-08-30 20:10:57 +000018150/* Override any GCC internal prototype to avoid an error.
18151 Use char because int might match the return type of a GCC
18152 builtin and then its argument prototype would still apply. */
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018153#ifdef __cplusplus
18154extern "C"
18155#endif
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018156char openpty ();
18157int
18158main ()
18159{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018160return openpty ();
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018161 ;
18162 return 0;
18163}
18164_ACEOF
18165rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018166if { (ac_try="$ac_link"
18167case "(($ac_try" in
18168 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18169 *) ac_try_echo=$ac_try;;
18170esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018171eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018172 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018173 ac_status=$?
18174 grep -v '^ *+' conftest.er1 >conftest.err
18175 rm -f conftest.er1
18176 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018177 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018178 (exit $ac_status); } && {
18179 test -z "$ac_c_werror_flag" ||
18180 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018181 } && test -s conftest$ac_exeext &&
18182 $as_test_x conftest$ac_exeext; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018183 ac_cv_lib_bsd_openpty=yes
18184else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018185 echo "$as_me: failed program was:" >&5
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018186sed 's/^/| /' conftest.$ac_ext >&5
18187
Martin v. Löwiseba40652007-08-30 20:10:57 +000018188 ac_cv_lib_bsd_openpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018189fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018190
18191rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018192 conftest$ac_exeext conftest.$ac_ext
18193LIBS=$ac_check_lib_save_LIBS
18194fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018195{ echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_openpty" >&5
18196echo "${ECHO_T}$ac_cv_lib_bsd_openpty" >&6; }
18197if test $ac_cv_lib_bsd_openpty = yes; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018198 cat >>confdefs.h <<\_ACEOF
18199#define HAVE_OPENPTY 1
18200_ACEOF
18201 LIBS="$LIBS -lbsd"
18202fi
18203
18204
18205fi
18206
Fred Drake8cef4cf2000-06-28 16:40:38 +000018207
18208fi
18209done
18210
Martin v. Löwis11437992002-04-12 09:54:03 +000018211
Fred Drake8cef4cf2000-06-28 16:40:38 +000018212for ac_func in forkpty
18213do
Ronald Oussoren450d5612009-06-08 21:12:41 +000018214as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18215{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18216echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018217if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018218 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000018219else
Martin v. Löwis11437992002-04-12 09:54:03 +000018220 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018221/* confdefs.h. */
18222_ACEOF
18223cat confdefs.h >>conftest.$ac_ext
18224cat >>conftest.$ac_ext <<_ACEOF
18225/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018226/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18227 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18228#define $ac_func innocuous_$ac_func
18229
Fred Drake8cef4cf2000-06-28 16:40:38 +000018230/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018231 which can conflict with char $ac_func (); below.
18232 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018233 <limits.h> exists even on freestanding compilers. */
18234
18235#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018236# include <limits.h>
18237#else
18238# include <assert.h>
18239#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018240
18241#undef $ac_func
18242
Martin v. Löwiseba40652007-08-30 20:10:57 +000018243/* Override any GCC internal prototype to avoid an error.
18244 Use char because int might match the return type of a GCC
18245 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018246#ifdef __cplusplus
18247extern "C"
18248#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018249char $ac_func ();
Fred Drake8cef4cf2000-06-28 16:40:38 +000018250/* The GNU C library defines this for functions which it implements
18251 to always fail with ENOSYS. Some functions are actually named
18252 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018253#if defined __stub_$ac_func || defined __stub___$ac_func
Fred Drake8cef4cf2000-06-28 16:40:38 +000018254choke me
Fred Drake8cef4cf2000-06-28 16:40:38 +000018255#endif
18256
Skip Montanaro6dead952003-09-25 14:50:04 +000018257int
18258main ()
18259{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018260return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018261 ;
18262 return 0;
18263}
18264_ACEOF
18265rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018266if { (ac_try="$ac_link"
18267case "(($ac_try" in
18268 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18269 *) ac_try_echo=$ac_try;;
18270esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018271eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018272 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018273 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018274 grep -v '^ *+' conftest.er1 >conftest.err
18275 rm -f conftest.er1
18276 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018277 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018278 (exit $ac_status); } && {
18279 test -z "$ac_c_werror_flag" ||
18280 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018281 } && test -s conftest$ac_exeext &&
18282 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018283 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000018284else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018285 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018286sed 's/^/| /' conftest.$ac_ext >&5
18287
Martin v. Löwiseba40652007-08-30 20:10:57 +000018288 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018289fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018290
18291rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018292 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018293fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018294ac_res=`eval echo '${'$as_ac_var'}'`
18295 { echo "$as_me:$LINENO: result: $ac_res" >&5
18296echo "${ECHO_T}$ac_res" >&6; }
18297if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018298 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018299#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018300_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018301
Fred Drake8cef4cf2000-06-28 16:40:38 +000018302else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018303 { echo "$as_me:$LINENO: checking for forkpty in -lutil" >&5
18304echo $ECHO_N "checking for forkpty in -lutil... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000018305if test "${ac_cv_lib_util_forkpty+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018306 echo $ECHO_N "(cached) $ECHO_C" >&6
Fred Drake8cef4cf2000-06-28 16:40:38 +000018307else
Martin v. Löwis11437992002-04-12 09:54:03 +000018308 ac_check_lib_save_LIBS=$LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018309LIBS="-lutil $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000018310cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018311/* confdefs.h. */
18312_ACEOF
18313cat confdefs.h >>conftest.$ac_ext
18314cat >>conftest.$ac_ext <<_ACEOF
18315/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018316
Martin v. Löwiseba40652007-08-30 20:10:57 +000018317/* Override any GCC internal prototype to avoid an error.
18318 Use char because int might match the return type of a GCC
18319 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018320#ifdef __cplusplus
18321extern "C"
18322#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018323char forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018324int
18325main ()
18326{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018327return forkpty ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018328 ;
18329 return 0;
18330}
18331_ACEOF
18332rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018333if { (ac_try="$ac_link"
18334case "(($ac_try" in
18335 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18336 *) ac_try_echo=$ac_try;;
18337esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018338eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018339 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018340 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018341 grep -v '^ *+' conftest.er1 >conftest.err
18342 rm -f conftest.er1
18343 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018344 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018345 (exit $ac_status); } && {
18346 test -z "$ac_c_werror_flag" ||
18347 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018348 } && test -s conftest$ac_exeext &&
18349 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018350 ac_cv_lib_util_forkpty=yes
Fred Drake8cef4cf2000-06-28 16:40:38 +000018351else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018352 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018353sed 's/^/| /' conftest.$ac_ext >&5
18354
Martin v. Löwiseba40652007-08-30 20:10:57 +000018355 ac_cv_lib_util_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018356fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018357
18358rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018359 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000018360LIBS=$ac_check_lib_save_LIBS
Fred Drake8cef4cf2000-06-28 16:40:38 +000018361fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018362{ echo "$as_me:$LINENO: result: $ac_cv_lib_util_forkpty" >&5
18363echo "${ECHO_T}$ac_cv_lib_util_forkpty" >&6; }
18364if test $ac_cv_lib_util_forkpty = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018365 cat >>confdefs.h <<\_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018366#define HAVE_FORKPTY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018367_ACEOF
Fred Drake8cef4cf2000-06-28 16:40:38 +000018368 LIBS="$LIBS -lutil"
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018369else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018370 { echo "$as_me:$LINENO: checking for forkpty in -lbsd" >&5
18371echo $ECHO_N "checking for forkpty in -lbsd... $ECHO_C" >&6; }
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018372if test "${ac_cv_lib_bsd_forkpty+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018373 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018374else
18375 ac_check_lib_save_LIBS=$LIBS
18376LIBS="-lbsd $LIBS"
18377cat >conftest.$ac_ext <<_ACEOF
18378/* confdefs.h. */
18379_ACEOF
18380cat confdefs.h >>conftest.$ac_ext
18381cat >>conftest.$ac_ext <<_ACEOF
18382/* end confdefs.h. */
18383
Martin v. Löwiseba40652007-08-30 20:10:57 +000018384/* Override any GCC internal prototype to avoid an error.
18385 Use char because int might match the return type of a GCC
18386 builtin and then its argument prototype would still apply. */
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018387#ifdef __cplusplus
18388extern "C"
18389#endif
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018390char forkpty ();
18391int
18392main ()
18393{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018394return forkpty ();
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018395 ;
18396 return 0;
18397}
18398_ACEOF
18399rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018400if { (ac_try="$ac_link"
18401case "(($ac_try" in
18402 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18403 *) ac_try_echo=$ac_try;;
18404esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018405eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018406 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018407 ac_status=$?
18408 grep -v '^ *+' conftest.er1 >conftest.err
18409 rm -f conftest.er1
18410 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018411 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018412 (exit $ac_status); } && {
18413 test -z "$ac_c_werror_flag" ||
18414 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018415 } && test -s conftest$ac_exeext &&
18416 $as_test_x conftest$ac_exeext; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018417 ac_cv_lib_bsd_forkpty=yes
18418else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018419 echo "$as_me: failed program was:" >&5
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018420sed 's/^/| /' conftest.$ac_ext >&5
18421
Martin v. Löwiseba40652007-08-30 20:10:57 +000018422 ac_cv_lib_bsd_forkpty=no
Fred Drake8cef4cf2000-06-28 16:40:38 +000018423fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018424
18425rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018426 conftest$ac_exeext conftest.$ac_ext
18427LIBS=$ac_check_lib_save_LIBS
18428fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018429{ echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_forkpty" >&5
18430echo "${ECHO_T}$ac_cv_lib_bsd_forkpty" >&6; }
18431if test $ac_cv_lib_bsd_forkpty = yes; then
Martin v. Löwisfd9a72a2006-01-08 10:07:33 +000018432 cat >>confdefs.h <<\_ACEOF
18433#define HAVE_FORKPTY 1
18434_ACEOF
18435 LIBS="$LIBS -lbsd"
18436fi
18437
18438
18439fi
18440
Fred Drake8cef4cf2000-06-28 16:40:38 +000018441
18442fi
18443done
18444
Jack Jansendd19cf82001-12-06 22:36:17 +000018445
Brett Cannonaa5778d2008-03-18 04:09:00 +000018446# Stuff for expat.
18447
18448for ac_func in memmove
18449do
Ronald Oussoren450d5612009-06-08 21:12:41 +000018450as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18451{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18452echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Brett Cannonaa5778d2008-03-18 04:09:00 +000018453if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018454 echo $ECHO_N "(cached) $ECHO_C" >&6
Brett Cannonaa5778d2008-03-18 04:09:00 +000018455else
18456 cat >conftest.$ac_ext <<_ACEOF
18457/* confdefs.h. */
18458_ACEOF
18459cat confdefs.h >>conftest.$ac_ext
18460cat >>conftest.$ac_ext <<_ACEOF
18461/* end confdefs.h. */
18462/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18463 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18464#define $ac_func innocuous_$ac_func
18465
18466/* System header to define __stub macros and hopefully few prototypes,
18467 which can conflict with char $ac_func (); below.
18468 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18469 <limits.h> exists even on freestanding compilers. */
18470
18471#ifdef __STDC__
18472# include <limits.h>
18473#else
18474# include <assert.h>
18475#endif
18476
18477#undef $ac_func
18478
18479/* Override any GCC internal prototype to avoid an error.
18480 Use char because int might match the return type of a GCC
18481 builtin and then its argument prototype would still apply. */
18482#ifdef __cplusplus
18483extern "C"
18484#endif
18485char $ac_func ();
18486/* The GNU C library defines this for functions which it implements
18487 to always fail with ENOSYS. Some functions are actually named
18488 something starting with __ and the normal name is an alias. */
18489#if defined __stub_$ac_func || defined __stub___$ac_func
18490choke me
18491#endif
18492
18493int
18494main ()
18495{
18496return $ac_func ();
18497 ;
18498 return 0;
18499}
18500_ACEOF
18501rm -f conftest.$ac_objext conftest$ac_exeext
18502if { (ac_try="$ac_link"
18503case "(($ac_try" in
18504 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18505 *) ac_try_echo=$ac_try;;
18506esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018507eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Brett Cannonaa5778d2008-03-18 04:09:00 +000018508 (eval "$ac_link") 2>conftest.er1
18509 ac_status=$?
18510 grep -v '^ *+' conftest.er1 >conftest.err
18511 rm -f conftest.er1
18512 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Brett Cannonaa5778d2008-03-18 04:09:00 +000018514 (exit $ac_status); } && {
18515 test -z "$ac_c_werror_flag" ||
18516 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018517 } && test -s conftest$ac_exeext &&
18518 $as_test_x conftest$ac_exeext; then
Brett Cannonaa5778d2008-03-18 04:09:00 +000018519 eval "$as_ac_var=yes"
18520else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018521 echo "$as_me: failed program was:" >&5
Brett Cannonaa5778d2008-03-18 04:09:00 +000018522sed 's/^/| /' conftest.$ac_ext >&5
18523
18524 eval "$as_ac_var=no"
18525fi
18526
18527rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18528 conftest$ac_exeext conftest.$ac_ext
18529fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018530ac_res=`eval echo '${'$as_ac_var'}'`
18531 { echo "$as_me:$LINENO: result: $ac_res" >&5
18532echo "${ECHO_T}$ac_res" >&6; }
18533if test `eval echo '${'$as_ac_var'}'` = yes; then
Brett Cannonaa5778d2008-03-18 04:09:00 +000018534 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018535#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Brett Cannonaa5778d2008-03-18 04:09:00 +000018536_ACEOF
18537
18538fi
18539done
18540
18541
Michael W. Hudson54241132001-12-07 15:38:26 +000018542# check for long file support functions
Martin v. Löwis11437992002-04-12 09:54:03 +000018543
18544
18545
18546
18547
18548
Fred Drake8cef4cf2000-06-28 16:40:38 +000018549for ac_func in fseek64 fseeko fstatvfs ftell64 ftello statvfs
18550do
Ronald Oussoren450d5612009-06-08 21:12:41 +000018551as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18552{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18553echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018554if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018555 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018556else
Martin v. Löwis11437992002-04-12 09:54:03 +000018557 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018558/* confdefs.h. */
18559_ACEOF
18560cat confdefs.h >>conftest.$ac_ext
18561cat >>conftest.$ac_ext <<_ACEOF
18562/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018563/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18564 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18565#define $ac_func innocuous_$ac_func
18566
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018567/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018568 which can conflict with char $ac_func (); below.
18569 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018570 <limits.h> exists even on freestanding compilers. */
18571
18572#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018573# include <limits.h>
18574#else
18575# include <assert.h>
18576#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018577
18578#undef $ac_func
18579
Martin v. Löwiseba40652007-08-30 20:10:57 +000018580/* Override any GCC internal prototype to avoid an error.
18581 Use char because int might match the return type of a GCC
18582 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018583#ifdef __cplusplus
18584extern "C"
18585#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018586char $ac_func ();
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018587/* The GNU C library defines this for functions which it implements
18588 to always fail with ENOSYS. Some functions are actually named
18589 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018590#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018591choke me
Guido van Rossumf98e2a71999-01-06 18:53:34 +000018592#endif
18593
Skip Montanaro6dead952003-09-25 14:50:04 +000018594int
18595main ()
18596{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018597return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018598 ;
18599 return 0;
18600}
18601_ACEOF
18602rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018603if { (ac_try="$ac_link"
18604case "(($ac_try" in
18605 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18606 *) ac_try_echo=$ac_try;;
18607esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018608eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018609 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018610 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018611 grep -v '^ *+' conftest.er1 >conftest.err
18612 rm -f conftest.er1
18613 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018614 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018615 (exit $ac_status); } && {
18616 test -z "$ac_c_werror_flag" ||
18617 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018618 } && test -s conftest$ac_exeext &&
18619 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018620 eval "$as_ac_var=yes"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018621else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018622 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018623sed 's/^/| /' conftest.$ac_ext >&5
18624
Martin v. Löwiseba40652007-08-30 20:10:57 +000018625 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018626fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018627
18628rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018629 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018630fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018631ac_res=`eval echo '${'$as_ac_var'}'`
18632 { echo "$as_me:$LINENO: result: $ac_res" >&5
18633echo "${ECHO_T}$ac_res" >&6; }
18634if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018635 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018636#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018637_ACEOF
Michael W. Hudson54241132001-12-07 15:38:26 +000018638
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018639fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000018640done
18641
Michael W. Hudson54241132001-12-07 15:38:26 +000018642
Martin v. Löwis11437992002-04-12 09:54:03 +000018643
18644
18645
Brett Cannonaa5778d2008-03-18 04:09:00 +000018646for ac_func in dup2 getcwd strdup
Thomas Wouters3a584202000-08-05 23:28:51 +000018647do
Ronald Oussoren450d5612009-06-08 21:12:41 +000018648as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18649{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18650echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018651if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018652 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018653else
Martin v. Löwis11437992002-04-12 09:54:03 +000018654 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018655/* confdefs.h. */
18656_ACEOF
18657cat confdefs.h >>conftest.$ac_ext
18658cat >>conftest.$ac_ext <<_ACEOF
18659/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018660/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18661 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18662#define $ac_func innocuous_$ac_func
18663
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000018664/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018665 which can conflict with char $ac_func (); below.
18666 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018667 <limits.h> exists even on freestanding compilers. */
18668
18669#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018670# include <limits.h>
18671#else
18672# include <assert.h>
18673#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018674
18675#undef $ac_func
18676
Martin v. Löwiseba40652007-08-30 20:10:57 +000018677/* Override any GCC internal prototype to avoid an error.
18678 Use char because int might match the return type of a GCC
18679 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018680#ifdef __cplusplus
18681extern "C"
18682#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018683char $ac_func ();
Guido van Rossum627b2d71993-12-24 10:39:16 +000018684/* The GNU C library defines this for functions which it implements
18685 to always fail with ENOSYS. Some functions are actually named
18686 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018687#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossum627b2d71993-12-24 10:39:16 +000018688choke me
Guido van Rossum627b2d71993-12-24 10:39:16 +000018689#endif
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018690
Skip Montanaro6dead952003-09-25 14:50:04 +000018691int
18692main ()
18693{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018694return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018695 ;
18696 return 0;
18697}
18698_ACEOF
18699rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018700if { (ac_try="$ac_link"
18701case "(($ac_try" in
18702 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18703 *) ac_try_echo=$ac_try;;
18704esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018705eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018706 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018707 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018708 grep -v '^ *+' conftest.er1 >conftest.err
18709 rm -f conftest.er1
18710 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018711 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018712 (exit $ac_status); } && {
18713 test -z "$ac_c_werror_flag" ||
18714 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018715 } && test -s conftest$ac_exeext &&
18716 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018717 eval "$as_ac_var=yes"
Martin v. Löwis1142de32002-03-29 16:28:31 +000018718else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018719 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018720sed 's/^/| /' conftest.$ac_ext >&5
18721
Martin v. Löwiseba40652007-08-30 20:10:57 +000018722 eval "$as_ac_var=no"
Martin v. Löwis1142de32002-03-29 16:28:31 +000018723fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018724
18725rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018726 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis1142de32002-03-29 16:28:31 +000018727fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018728ac_res=`eval echo '${'$as_ac_var'}'`
18729 { echo "$as_me:$LINENO: result: $ac_res" >&5
18730echo "${ECHO_T}$ac_res" >&6; }
18731if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018732 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018733#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018734_ACEOF
Martin v. Löwis1142de32002-03-29 16:28:31 +000018735
Martin v. Löwis1142de32002-03-29 16:28:31 +000018736else
Martin v. Löwiseba40652007-08-30 20:10:57 +000018737 case " $LIBOBJS " in
Skip Montanarof0d5f792004-08-15 14:08:23 +000018738 *" $ac_func.$ac_objext "* ) ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000018739 *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18740 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000018741esac
18742
Martin v. Löwis1142de32002-03-29 16:28:31 +000018743fi
18744done
18745
18746
Martin v. Löwis11437992002-04-12 09:54:03 +000018747
Martin v. Löwis1142de32002-03-29 16:28:31 +000018748for ac_func in getpgrp
18749do
Ronald Oussoren450d5612009-06-08 21:12:41 +000018750as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18751{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18752echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018753if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018754 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis1142de32002-03-29 16:28:31 +000018755else
Martin v. Löwis11437992002-04-12 09:54:03 +000018756 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018757/* confdefs.h. */
18758_ACEOF
18759cat confdefs.h >>conftest.$ac_ext
18760cat >>conftest.$ac_ext <<_ACEOF
18761/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018762/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18763 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18764#define $ac_func innocuous_$ac_func
18765
Martin v. Löwis1142de32002-03-29 16:28:31 +000018766/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018767 which can conflict with char $ac_func (); below.
18768 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018769 <limits.h> exists even on freestanding compilers. */
18770
18771#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018772# include <limits.h>
18773#else
18774# include <assert.h>
18775#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018776
18777#undef $ac_func
18778
Martin v. Löwiseba40652007-08-30 20:10:57 +000018779/* Override any GCC internal prototype to avoid an error.
18780 Use char because int might match the return type of a GCC
18781 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000018782#ifdef __cplusplus
18783extern "C"
18784#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000018785char $ac_func ();
Martin v. Löwis1142de32002-03-29 16:28:31 +000018786/* The GNU C library defines this for functions which it implements
18787 to always fail with ENOSYS. Some functions are actually named
18788 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018789#if defined __stub_$ac_func || defined __stub___$ac_func
Martin v. Löwis1142de32002-03-29 16:28:31 +000018790choke me
Martin v. Löwis1142de32002-03-29 16:28:31 +000018791#endif
18792
Skip Montanaro6dead952003-09-25 14:50:04 +000018793int
18794main ()
18795{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018796return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018797 ;
18798 return 0;
18799}
18800_ACEOF
18801rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018802if { (ac_try="$ac_link"
18803case "(($ac_try" in
18804 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18805 *) ac_try_echo=$ac_try;;
18806esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018807eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018808 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018809 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018810 grep -v '^ *+' conftest.er1 >conftest.err
18811 rm -f conftest.er1
18812 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018813 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018814 (exit $ac_status); } && {
18815 test -z "$ac_c_werror_flag" ||
18816 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018817 } && test -s conftest$ac_exeext &&
18818 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018819 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000018820else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018821 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018822sed 's/^/| /' conftest.$ac_ext >&5
18823
Martin v. Löwiseba40652007-08-30 20:10:57 +000018824 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018825fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018826
18827rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018828 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018829fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018830ac_res=`eval echo '${'$as_ac_var'}'`
18831 { echo "$as_me:$LINENO: result: $ac_res" >&5
18832echo "${ECHO_T}$ac_res" >&6; }
18833if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018834 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018835#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018836_ACEOF
18837 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018838/* confdefs.h. */
18839_ACEOF
18840cat confdefs.h >>conftest.$ac_ext
18841cat >>conftest.$ac_ext <<_ACEOF
18842/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018843#include <unistd.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000018844int
18845main ()
18846{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018847getpgrp(0);
Martin v. Löwis11437992002-04-12 09:54:03 +000018848 ;
18849 return 0;
18850}
18851_ACEOF
18852rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018853if { (ac_try="$ac_compile"
18854case "(($ac_try" in
18855 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18856 *) ac_try_echo=$ac_try;;
18857esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018858eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018859 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018860 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018861 grep -v '^ *+' conftest.er1 >conftest.err
18862 rm -f conftest.er1
18863 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018864 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018865 (exit $ac_status); } && {
18866 test -z "$ac_c_werror_flag" ||
18867 test ! -s conftest.err
18868 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000018869
18870cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018871#define GETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000018872_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000018873
Martin v. Löwis11437992002-04-12 09:54:03 +000018874
Guido van Rossumf78abae1997-01-21 22:02:36 +000018875else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018876 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018877sed 's/^/| /' conftest.$ac_ext >&5
18878
Martin v. Löwiseba40652007-08-30 20:10:57 +000018879
Guido van Rossum627b2d71993-12-24 10:39:16 +000018880fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018881
18882rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000018883
Guido van Rossum627b2d71993-12-24 10:39:16 +000018884fi
Thomas Wouters3a584202000-08-05 23:28:51 +000018885done
Guido van Rossum627b2d71993-12-24 10:39:16 +000018886
Jack Jansen150753c2003-03-29 22:07:47 +000018887
18888for ac_func in setpgrp
18889do
Ronald Oussoren450d5612009-06-08 21:12:41 +000018890as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18891{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18892echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000018893if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000018894 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000018895else
Martin v. Löwis11437992002-04-12 09:54:03 +000018896 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018897/* confdefs.h. */
18898_ACEOF
18899cat confdefs.h >>conftest.$ac_ext
18900cat >>conftest.$ac_ext <<_ACEOF
18901/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018902/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18903 For example, HP-UX 11i <limits.h> declares gettimeofday. */
18904#define $ac_func innocuous_$ac_func
18905
Jack Jansen150753c2003-03-29 22:07:47 +000018906/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000018907 which can conflict with char $ac_func (); below.
18908 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018909 <limits.h> exists even on freestanding compilers. */
18910
18911#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000018912# include <limits.h>
18913#else
18914# include <assert.h>
18915#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000018916
18917#undef $ac_func
18918
Martin v. Löwiseba40652007-08-30 20:10:57 +000018919/* Override any GCC internal prototype to avoid an error.
18920 Use char because int might match the return type of a GCC
18921 builtin and then its argument prototype would still apply. */
Jack Jansen150753c2003-03-29 22:07:47 +000018922#ifdef __cplusplus
18923extern "C"
Martin v. Löwis11437992002-04-12 09:54:03 +000018924#endif
Jack Jansen150753c2003-03-29 22:07:47 +000018925char $ac_func ();
Jack Jansen150753c2003-03-29 22:07:47 +000018926/* The GNU C library defines this for functions which it implements
18927 to always fail with ENOSYS. Some functions are actually named
18928 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000018929#if defined __stub_$ac_func || defined __stub___$ac_func
Jack Jansen150753c2003-03-29 22:07:47 +000018930choke me
Jack Jansen150753c2003-03-29 22:07:47 +000018931#endif
18932
Skip Montanaro6dead952003-09-25 14:50:04 +000018933int
18934main ()
18935{
Martin v. Löwiseba40652007-08-30 20:10:57 +000018936return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000018937 ;
18938 return 0;
18939}
18940_ACEOF
Jack Jansen150753c2003-03-29 22:07:47 +000018941rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018942if { (ac_try="$ac_link"
18943case "(($ac_try" in
18944 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18945 *) ac_try_echo=$ac_try;;
18946esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018947eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018948 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000018949 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000018950 grep -v '^ *+' conftest.er1 >conftest.err
18951 rm -f conftest.er1
18952 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000018953 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018954 (exit $ac_status); } && {
18955 test -z "$ac_c_werror_flag" ||
18956 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000018957 } && test -s conftest$ac_exeext &&
18958 $as_test_x conftest$ac_exeext; then
Jack Jansen150753c2003-03-29 22:07:47 +000018959 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000018960else
Ronald Oussoren450d5612009-06-08 21:12:41 +000018961 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000018962sed 's/^/| /' conftest.$ac_ext >&5
18963
Martin v. Löwiseba40652007-08-30 20:10:57 +000018964 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000018965fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000018966
18967rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000018968 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000018969fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000018970ac_res=`eval echo '${'$as_ac_var'}'`
18971 { echo "$as_me:$LINENO: result: $ac_res" >&5
18972echo "${ECHO_T}$ac_res" >&6; }
18973if test `eval echo '${'$as_ac_var'}'` = yes; then
Jack Jansen150753c2003-03-29 22:07:47 +000018974 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000018975#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Jack Jansen150753c2003-03-29 22:07:47 +000018976_ACEOF
18977 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000018978/* confdefs.h. */
18979_ACEOF
18980cat confdefs.h >>conftest.$ac_ext
18981cat >>conftest.$ac_ext <<_ACEOF
18982/* end confdefs.h. */
Jack Jansen150753c2003-03-29 22:07:47 +000018983#include <unistd.h>
Jack Jansen150753c2003-03-29 22:07:47 +000018984int
18985main ()
18986{
18987setpgrp(0,0);
18988 ;
18989 return 0;
18990}
18991_ACEOF
18992rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000018993if { (ac_try="$ac_compile"
18994case "(($ac_try" in
18995 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18996 *) ac_try_echo=$ac_try;;
18997esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000018998eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000018999 (eval "$ac_compile") 2>conftest.er1
Jack Jansen150753c2003-03-29 22:07:47 +000019000 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019001 grep -v '^ *+' conftest.er1 >conftest.err
19002 rm -f conftest.er1
19003 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019005 (exit $ac_status); } && {
19006 test -z "$ac_c_werror_flag" ||
19007 test ! -s conftest.err
19008 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019009
19010cat >>confdefs.h <<\_ACEOF
Jack Jansen150753c2003-03-29 22:07:47 +000019011#define SETPGRP_HAVE_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019012_ACEOF
Guido van Rossum8eee56f1994-10-20 22:18:37 +000019013
Jack Jansen150753c2003-03-29 22:07:47 +000019014
19015else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019016 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019017sed 's/^/| /' conftest.$ac_ext >&5
19018
Martin v. Löwiseba40652007-08-30 20:10:57 +000019019
Guido van Rossum8eee56f1994-10-20 22:18:37 +000019020fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019021
19022rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Jack Jansen150753c2003-03-29 22:07:47 +000019023
19024fi
19025done
Guido van Rossum8eee56f1994-10-20 22:18:37 +000019026
Martin v. Löwis11437992002-04-12 09:54:03 +000019027
Thomas Wouters3a584202000-08-05 23:28:51 +000019028for ac_func in gettimeofday
19029do
Ronald Oussoren450d5612009-06-08 21:12:41 +000019030as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19031{ echo "$as_me:$LINENO: checking for $ac_func" >&5
19032echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019033if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019034 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019035else
Martin v. Löwis11437992002-04-12 09:54:03 +000019036 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019037/* confdefs.h. */
19038_ACEOF
19039cat confdefs.h >>conftest.$ac_ext
19040cat >>conftest.$ac_ext <<_ACEOF
19041/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019042/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19043 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19044#define $ac_func innocuous_$ac_func
19045
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000019046/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019047 which can conflict with char $ac_func (); below.
19048 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019049 <limits.h> exists even on freestanding compilers. */
19050
19051#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019052# include <limits.h>
19053#else
19054# include <assert.h>
19055#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019056
19057#undef $ac_func
19058
Martin v. Löwiseba40652007-08-30 20:10:57 +000019059/* Override any GCC internal prototype to avoid an error.
19060 Use char because int might match the return type of a GCC
19061 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019062#ifdef __cplusplus
19063extern "C"
19064#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019065char $ac_func ();
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019066/* The GNU C library defines this for functions which it implements
19067 to always fail with ENOSYS. Some functions are actually named
19068 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019069#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019070choke me
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019071#endif
19072
Skip Montanaro6dead952003-09-25 14:50:04 +000019073int
19074main ()
19075{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019076return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019077 ;
19078 return 0;
19079}
19080_ACEOF
19081rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019082if { (ac_try="$ac_link"
19083case "(($ac_try" in
19084 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19085 *) ac_try_echo=$ac_try;;
19086esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019087eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019088 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019089 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019090 grep -v '^ *+' conftest.er1 >conftest.err
19091 rm -f conftest.er1
19092 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019093 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019094 (exit $ac_status); } && {
19095 test -z "$ac_c_werror_flag" ||
19096 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000019097 } && test -s conftest$ac_exeext &&
19098 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019099 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000019100else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019101 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019102sed 's/^/| /' conftest.$ac_ext >&5
19103
Martin v. Löwiseba40652007-08-30 20:10:57 +000019104 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000019105fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019106
19107rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019108 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019109fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019110ac_res=`eval echo '${'$as_ac_var'}'`
19111 { echo "$as_me:$LINENO: result: $ac_res" >&5
19112echo "${ECHO_T}$ac_res" >&6; }
19113if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019114 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000019115#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019116_ACEOF
19117 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019118/* confdefs.h. */
19119_ACEOF
19120cat confdefs.h >>conftest.$ac_ext
19121cat >>conftest.$ac_ext <<_ACEOF
19122/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000019123#include <sys/time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000019124int
19125main ()
19126{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019127gettimeofday((struct timeval*)0,(struct timezone*)0);
Martin v. Löwis11437992002-04-12 09:54:03 +000019128 ;
19129 return 0;
19130}
19131_ACEOF
19132rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019133if { (ac_try="$ac_compile"
19134case "(($ac_try" in
19135 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19136 *) ac_try_echo=$ac_try;;
19137esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019138eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019139 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019140 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019141 grep -v '^ *+' conftest.er1 >conftest.err
19142 rm -f conftest.er1
19143 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019144 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019145 (exit $ac_status); } && {
19146 test -z "$ac_c_werror_flag" ||
19147 test ! -s conftest.err
19148 } && test -s conftest.$ac_objext; then
Guido van Rossum627b2d71993-12-24 10:39:16 +000019149 :
19150else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019151 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019152sed 's/^/| /' conftest.$ac_ext >&5
19153
Martin v. Löwis11437992002-04-12 09:54:03 +000019154
19155cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019156#define GETTIMEOFDAY_NO_TZ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019157_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000019158
Martin v. Löwis11437992002-04-12 09:54:03 +000019159
Guido van Rossum627b2d71993-12-24 10:39:16 +000019160fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019161
19162rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisc45929e2002-04-06 10:10:49 +000019163
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019164fi
Thomas Wouters3a584202000-08-05 23:28:51 +000019165done
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019166
Michael W. Hudson54241132001-12-07 15:38:26 +000019167
Ronald Oussoren450d5612009-06-08 21:12:41 +000019168{ echo "$as_me:$LINENO: checking for major" >&5
19169echo $ECHO_N "checking for major... $ECHO_C" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019170cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019171/* confdefs.h. */
19172_ACEOF
19173cat confdefs.h >>conftest.$ac_ext
19174cat >>conftest.$ac_ext <<_ACEOF
19175/* end confdefs.h. */
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019176
Neal Norwitz6eb37f02003-02-23 23:28:15 +000019177#if defined(MAJOR_IN_MKDEV)
19178#include <sys/mkdev.h>
19179#elif defined(MAJOR_IN_SYSMACROS)
19180#include <sys/sysmacros.h>
19181#else
19182#include <sys/types.h>
19183#endif
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019184
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019185int
19186main ()
19187{
19188
19189 makedev(major(0),minor(0));
19190
19191 ;
19192 return 0;
19193}
19194_ACEOF
Martin v. Löwise3271202002-11-07 07:42:30 +000019195rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019196if { (ac_try="$ac_link"
19197case "(($ac_try" in
19198 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19199 *) ac_try_echo=$ac_try;;
19200esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019201eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019202 (eval "$ac_link") 2>conftest.er1
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019203 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019204 grep -v '^ *+' conftest.er1 >conftest.err
19205 rm -f conftest.er1
19206 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019207 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019208 (exit $ac_status); } && {
19209 test -z "$ac_c_werror_flag" ||
19210 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000019211 } && test -s conftest$ac_exeext &&
19212 $as_test_x conftest$ac_exeext; then
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019213
19214
19215cat >>confdefs.h <<\_ACEOF
19216#define HAVE_DEVICE_MACROS 1
19217_ACEOF
19218
Ronald Oussoren450d5612009-06-08 21:12:41 +000019219 { echo "$as_me:$LINENO: result: yes" >&5
19220echo "${ECHO_T}yes" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019221
19222else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019223 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019224sed 's/^/| /' conftest.$ac_ext >&5
19225
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019226
Ronald Oussoren450d5612009-06-08 21:12:41 +000019227 { echo "$as_me:$LINENO: result: no" >&5
19228echo "${ECHO_T}no" >&6; }
Martin v. Löwisdbe3f762002-10-10 14:27:30 +000019229
19230fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019231
19232rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019233 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019234
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019235# On OSF/1 V5.1, getaddrinfo is available, but a define
Martin v. Löwis11437992002-04-12 09:54:03 +000019236# for [no]getaddrinfo in netdb.h.
Ronald Oussoren450d5612009-06-08 21:12:41 +000019237{ echo "$as_me:$LINENO: checking for getaddrinfo" >&5
19238echo $ECHO_N "checking for getaddrinfo... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019239cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019240/* confdefs.h. */
19241_ACEOF
19242cat confdefs.h >>conftest.$ac_ext
19243cat >>conftest.$ac_ext <<_ACEOF
19244/* end confdefs.h. */
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019245
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000019246#include <sys/types.h>
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019247#include <sys/socket.h>
19248#include <netdb.h>
Martin v. Löwisc010b6d2001-11-09 17:50:52 +000019249#include <stdio.h>
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019250
Martin v. Löwis11437992002-04-12 09:54:03 +000019251int
19252main ()
19253{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019254
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019255getaddrinfo(NULL, NULL, NULL, NULL);
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019256
Martin v. Löwis11437992002-04-12 09:54:03 +000019257 ;
19258 return 0;
19259}
19260_ACEOF
19261rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019262if { (ac_try="$ac_link"
19263case "(($ac_try" in
19264 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19265 *) ac_try_echo=$ac_try;;
19266esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019267eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019268 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019269 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019270 grep -v '^ *+' conftest.er1 >conftest.err
19271 rm -f conftest.er1
19272 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019273 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019274 (exit $ac_status); } && {
19275 test -z "$ac_c_werror_flag" ||
19276 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000019277 } && test -s conftest$ac_exeext &&
19278 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019279
Ronald Oussoren450d5612009-06-08 21:12:41 +000019280{ echo "$as_me:$LINENO: result: yes" >&5
19281echo "${ECHO_T}yes" >&6; }
19282{ echo "$as_me:$LINENO: checking getaddrinfo bug" >&5
19283echo $ECHO_N "checking getaddrinfo bug... $ECHO_C" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019284if test "$cross_compiling" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019285 { echo "$as_me:$LINENO: result: buggy" >&5
19286echo "${ECHO_T}buggy" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019287buggygetaddrinfo=yes
19288else
Martin v. Löwis11437992002-04-12 09:54:03 +000019289 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019290/* confdefs.h. */
19291_ACEOF
19292cat confdefs.h >>conftest.$ac_ext
19293cat >>conftest.$ac_ext <<_ACEOF
19294/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019295
19296#include <sys/types.h>
19297#include <netdb.h>
19298#include <string.h>
19299#include <sys/socket.h>
19300#include <netinet/in.h>
19301
19302main()
19303{
19304 int passive, gaierr, inet4 = 0, inet6 = 0;
19305 struct addrinfo hints, *ai, *aitop;
19306 char straddr[INET6_ADDRSTRLEN], strport[16];
19307
19308 for (passive = 0; passive <= 1; passive++) {
19309 memset(&hints, 0, sizeof(hints));
19310 hints.ai_family = AF_UNSPEC;
19311 hints.ai_flags = passive ? AI_PASSIVE : 0;
19312 hints.ai_socktype = SOCK_STREAM;
Hye-Shik Chang54f94392004-04-14 07:55:31 +000019313 hints.ai_protocol = IPPROTO_TCP;
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019314 if ((gaierr = getaddrinfo(NULL, "54321", &hints, &aitop)) != 0) {
19315 (void)gai_strerror(gaierr);
19316 goto bad;
19317 }
19318 for (ai = aitop; ai; ai = ai->ai_next) {
19319 if (ai->ai_addr == NULL ||
19320 ai->ai_addrlen == 0 ||
19321 getnameinfo(ai->ai_addr, ai->ai_addrlen,
19322 straddr, sizeof(straddr), strport, sizeof(strport),
19323 NI_NUMERICHOST|NI_NUMERICSERV) != 0) {
19324 goto bad;
19325 }
19326 switch (ai->ai_family) {
19327 case AF_INET:
19328 if (strcmp(strport, "54321") != 0) {
19329 goto bad;
19330 }
19331 if (passive) {
19332 if (strcmp(straddr, "0.0.0.0") != 0) {
19333 goto bad;
19334 }
19335 } else {
19336 if (strcmp(straddr, "127.0.0.1") != 0) {
19337 goto bad;
19338 }
19339 }
19340 inet4++;
19341 break;
19342 case AF_INET6:
19343 if (strcmp(strport, "54321") != 0) {
19344 goto bad;
19345 }
19346 if (passive) {
19347 if (strcmp(straddr, "::") != 0) {
19348 goto bad;
19349 }
19350 } else {
19351 if (strcmp(straddr, "::1") != 0) {
19352 goto bad;
19353 }
19354 }
19355 inet6++;
19356 break;
19357 case AF_UNSPEC:
19358 goto bad;
19359 break;
19360 default:
19361 /* another family support? */
19362 break;
19363 }
19364 }
19365 }
19366
19367 if (!(inet4 == 0 || inet4 == 2))
19368 goto bad;
19369 if (!(inet6 == 0 || inet6 == 2))
19370 goto bad;
19371
19372 if (aitop)
19373 freeaddrinfo(aitop);
19374 exit(0);
19375
19376 bad:
19377 if (aitop)
19378 freeaddrinfo(aitop);
19379 exit(1);
19380}
19381
Martin v. Löwis11437992002-04-12 09:54:03 +000019382_ACEOF
19383rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019384if { (ac_try="$ac_link"
19385case "(($ac_try" in
19386 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19387 *) ac_try_echo=$ac_try;;
19388esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019389eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019390 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019391 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000019392 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019393 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000019394 { (case "(($ac_try" in
19395 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19396 *) ac_try_echo=$ac_try;;
19397esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019398eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019399 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019400 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000019401 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000019402 (exit $ac_status); }; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019403 { echo "$as_me:$LINENO: result: good" >&5
19404echo "${ECHO_T}good" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019405buggygetaddrinfo=no
19406else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019407 echo "$as_me: program exited with status $ac_status" >&5
19408echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019409sed 's/^/| /' conftest.$ac_ext >&5
19410
Martin v. Löwis11437992002-04-12 09:54:03 +000019411( exit $ac_status )
Ronald Oussoren450d5612009-06-08 21:12:41 +000019412{ echo "$as_me:$LINENO: result: buggy" >&5
19413echo "${ECHO_T}buggy" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019414buggygetaddrinfo=yes
19415fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019416rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019417fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019418
19419
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019420else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019421 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019422sed 's/^/| /' conftest.$ac_ext >&5
19423
Martin v. Löwis11437992002-04-12 09:54:03 +000019424
Ronald Oussoren450d5612009-06-08 21:12:41 +000019425{ echo "$as_me:$LINENO: result: no" >&5
19426echo "${ECHO_T}no" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019427buggygetaddrinfo=yes
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019428
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019429fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019430
19431rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019432 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019433
19434if test "$buggygetaddrinfo" = "yes"; then
19435 if test "$ipv6" = "yes"; then
19436 echo 'Fatal: You must get working getaddrinfo() function.'
19437 echo ' or you can specify "--disable-ipv6"'.
19438 exit 1
19439 fi
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019440else
Martin v. Löwis11437992002-04-12 09:54:03 +000019441
19442cat >>confdefs.h <<\_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019443#define HAVE_GETADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019444_ACEOF
Martin v. Löwis861a65b2001-10-24 14:36:00 +000019445
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019446fi
Martin v. Löwis11437992002-04-12 09:54:03 +000019447
Jack Jansen9a66b6d2001-08-08 13:56:14 +000019448for ac_func in getnameinfo
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019449do
Ronald Oussoren450d5612009-06-08 21:12:41 +000019450as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19451{ echo "$as_me:$LINENO: checking for $ac_func" >&5
19452echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019453if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019454 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019455else
Martin v. Löwis11437992002-04-12 09:54:03 +000019456 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019457/* confdefs.h. */
19458_ACEOF
19459cat confdefs.h >>conftest.$ac_ext
19460cat >>conftest.$ac_ext <<_ACEOF
19461/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019462/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19463 For example, HP-UX 11i <limits.h> declares gettimeofday. */
19464#define $ac_func innocuous_$ac_func
19465
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019466/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000019467 which can conflict with char $ac_func (); below.
19468 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019469 <limits.h> exists even on freestanding compilers. */
19470
19471#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000019472# include <limits.h>
19473#else
19474# include <assert.h>
19475#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000019476
19477#undef $ac_func
19478
Martin v. Löwiseba40652007-08-30 20:10:57 +000019479/* Override any GCC internal prototype to avoid an error.
19480 Use char because int might match the return type of a GCC
19481 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019482#ifdef __cplusplus
19483extern "C"
19484#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019485char $ac_func ();
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019486/* The GNU C library defines this for functions which it implements
19487 to always fail with ENOSYS. Some functions are actually named
19488 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000019489#if defined __stub_$ac_func || defined __stub___$ac_func
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019490choke me
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019491#endif
19492
Skip Montanaro6dead952003-09-25 14:50:04 +000019493int
19494main ()
19495{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019496return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000019497 ;
19498 return 0;
19499}
19500_ACEOF
19501rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019502if { (ac_try="$ac_link"
19503case "(($ac_try" in
19504 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19505 *) ac_try_echo=$ac_try;;
19506esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019507eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019508 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019509 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019510 grep -v '^ *+' conftest.er1 >conftest.err
19511 rm -f conftest.er1
19512 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019513 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019514 (exit $ac_status); } && {
19515 test -z "$ac_c_werror_flag" ||
19516 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000019517 } && test -s conftest$ac_exeext &&
19518 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019519 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000019520else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019521 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019522sed 's/^/| /' conftest.$ac_ext >&5
19523
Martin v. Löwiseba40652007-08-30 20:10:57 +000019524 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000019525fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019526
19527rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019528 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000019529fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019530ac_res=`eval echo '${'$as_ac_var'}'`
19531 { echo "$as_me:$LINENO: result: $ac_res" >&5
19532echo "${ECHO_T}$ac_res" >&6; }
19533if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019534 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000019535#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019536_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019537
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000019538fi
19539done
19540
Michael W. Hudson54241132001-12-07 15:38:26 +000019541
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019542# checks for structures
Ronald Oussoren450d5612009-06-08 21:12:41 +000019543{ echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
19544echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019545if test "${ac_cv_header_time+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019546 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019547else
Martin v. Löwis11437992002-04-12 09:54:03 +000019548 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019549/* confdefs.h. */
19550_ACEOF
19551cat confdefs.h >>conftest.$ac_ext
19552cat >>conftest.$ac_ext <<_ACEOF
19553/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019554#include <sys/types.h>
19555#include <sys/time.h>
19556#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000019557
Martin v. Löwis11437992002-04-12 09:54:03 +000019558int
19559main ()
19560{
19561if ((struct tm *) 0)
19562return 0;
19563 ;
19564 return 0;
19565}
19566_ACEOF
19567rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019568if { (ac_try="$ac_compile"
19569case "(($ac_try" in
19570 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19571 *) ac_try_echo=$ac_try;;
19572esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019573eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019574 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019575 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019576 grep -v '^ *+' conftest.er1 >conftest.err
19577 rm -f conftest.er1
19578 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019579 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019580 (exit $ac_status); } && {
19581 test -z "$ac_c_werror_flag" ||
19582 test ! -s conftest.err
19583 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019584 ac_cv_header_time=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000019585else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019586 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019587sed 's/^/| /' conftest.$ac_ext >&5
19588
Martin v. Löwiseba40652007-08-30 20:10:57 +000019589 ac_cv_header_time=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000019590fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019591
19592rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019593fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019594{ echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
19595echo "${ECHO_T}$ac_cv_header_time" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000019596if test $ac_cv_header_time = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019597
19598cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019599#define TIME_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019600_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019601
19602fi
19603
Ronald Oussoren450d5612009-06-08 21:12:41 +000019604{ echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
19605echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019606if test "${ac_cv_struct_tm+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019607 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019608else
Martin v. Löwis11437992002-04-12 09:54:03 +000019609 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019610/* confdefs.h. */
19611_ACEOF
19612cat confdefs.h >>conftest.$ac_ext
19613cat >>conftest.$ac_ext <<_ACEOF
19614/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019615#include <sys/types.h>
19616#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000019617
Martin v. Löwis11437992002-04-12 09:54:03 +000019618int
19619main ()
19620{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019621struct tm tm;
19622 int *p = &tm.tm_sec;
Ronald Oussoren450d5612009-06-08 21:12:41 +000019623 return !p;
Martin v. Löwis11437992002-04-12 09:54:03 +000019624 ;
19625 return 0;
19626}
19627_ACEOF
19628rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019629if { (ac_try="$ac_compile"
19630case "(($ac_try" in
19631 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19632 *) ac_try_echo=$ac_try;;
19633esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019634eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019635 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019636 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019637 grep -v '^ *+' conftest.er1 >conftest.err
19638 rm -f conftest.er1
19639 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019640 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019641 (exit $ac_status); } && {
19642 test -z "$ac_c_werror_flag" ||
19643 test ! -s conftest.err
19644 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019645 ac_cv_struct_tm=time.h
19646else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019647 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019648sed 's/^/| /' conftest.$ac_ext >&5
19649
Martin v. Löwiseba40652007-08-30 20:10:57 +000019650 ac_cv_struct_tm=sys/time.h
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019651fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019652
19653rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019654fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019655{ echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
19656echo "${ECHO_T}$ac_cv_struct_tm" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000019657if test $ac_cv_struct_tm = sys/time.h; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019658
19659cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019660#define TM_IN_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019661_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019662
19663fi
19664
Ronald Oussoren450d5612009-06-08 21:12:41 +000019665{ echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
19666echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019667if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019668 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019669else
Martin v. Löwis11437992002-04-12 09:54:03 +000019670 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019671/* confdefs.h. */
19672_ACEOF
19673cat confdefs.h >>conftest.$ac_ext
19674cat >>conftest.$ac_ext <<_ACEOF
19675/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019676#include <sys/types.h>
19677#include <$ac_cv_struct_tm>
Martin v. Löwis11437992002-04-12 09:54:03 +000019678
19679
Martin v. Löwis11437992002-04-12 09:54:03 +000019680int
19681main ()
19682{
19683static struct tm ac_aggr;
19684if (ac_aggr.tm_zone)
19685return 0;
19686 ;
19687 return 0;
19688}
19689_ACEOF
19690rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019691if { (ac_try="$ac_compile"
19692case "(($ac_try" in
19693 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19694 *) ac_try_echo=$ac_try;;
19695esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019696eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019697 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019698 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019699 grep -v '^ *+' conftest.er1 >conftest.err
19700 rm -f conftest.er1
19701 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019702 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019703 (exit $ac_status); } && {
19704 test -z "$ac_c_werror_flag" ||
19705 test ! -s conftest.err
19706 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019707 ac_cv_member_struct_tm_tm_zone=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000019708else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019709 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019710sed 's/^/| /' conftest.$ac_ext >&5
19711
Martin v. Löwiseba40652007-08-30 20:10:57 +000019712 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019713/* confdefs.h. */
19714_ACEOF
19715cat confdefs.h >>conftest.$ac_ext
19716cat >>conftest.$ac_ext <<_ACEOF
19717/* end confdefs.h. */
19718#include <sys/types.h>
19719#include <$ac_cv_struct_tm>
19720
19721
19722int
19723main ()
19724{
19725static struct tm ac_aggr;
19726if (sizeof ac_aggr.tm_zone)
19727return 0;
19728 ;
19729 return 0;
19730}
19731_ACEOF
19732rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019733if { (ac_try="$ac_compile"
19734case "(($ac_try" in
19735 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19736 *) ac_try_echo=$ac_try;;
19737esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019738eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019739 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000019740 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019741 grep -v '^ *+' conftest.er1 >conftest.err
19742 rm -f conftest.er1
19743 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019744 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019745 (exit $ac_status); } && {
19746 test -z "$ac_c_werror_flag" ||
19747 test ! -s conftest.err
19748 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000019749 ac_cv_member_struct_tm_tm_zone=yes
19750else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019751 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019752sed 's/^/| /' conftest.$ac_ext >&5
19753
Martin v. Löwiseba40652007-08-30 20:10:57 +000019754 ac_cv_member_struct_tm_tm_zone=no
Michael W. Hudson54241132001-12-07 15:38:26 +000019755fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019756
19757rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000019758fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019759
19760rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000019761fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019762{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
19763echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6; }
19764if test $ac_cv_member_struct_tm_tm_zone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019765
19766cat >>confdefs.h <<_ACEOF
19767#define HAVE_STRUCT_TM_TM_ZONE 1
19768_ACEOF
19769
19770
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019771fi
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000019772
Martin v. Löwis11437992002-04-12 09:54:03 +000019773if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19774
19775cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019776#define HAVE_TM_ZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019777_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019778
19779else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019780 { echo "$as_me:$LINENO: checking whether tzname is declared" >&5
19781echo $ECHO_N "checking whether tzname is declared... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000019782if test "${ac_cv_have_decl_tzname+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019783 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwiseba40652007-08-30 20:10:57 +000019784else
19785 cat >conftest.$ac_ext <<_ACEOF
19786/* confdefs.h. */
19787_ACEOF
19788cat confdefs.h >>conftest.$ac_ext
19789cat >>conftest.$ac_ext <<_ACEOF
19790/* end confdefs.h. */
19791#include <time.h>
19792
19793int
19794main ()
19795{
19796#ifndef tzname
19797 (void) tzname;
19798#endif
19799
19800 ;
19801 return 0;
19802}
19803_ACEOF
19804rm -f conftest.$ac_objext
19805if { (ac_try="$ac_compile"
19806case "(($ac_try" in
19807 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19808 *) ac_try_echo=$ac_try;;
19809esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019810eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019811 (eval "$ac_compile") 2>conftest.er1
19812 ac_status=$?
19813 grep -v '^ *+' conftest.er1 >conftest.err
19814 rm -f conftest.er1
19815 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019816 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019817 (exit $ac_status); } && {
19818 test -z "$ac_c_werror_flag" ||
19819 test ! -s conftest.err
19820 } && test -s conftest.$ac_objext; then
19821 ac_cv_have_decl_tzname=yes
19822else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019823 echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019824sed 's/^/| /' conftest.$ac_ext >&5
19825
19826 ac_cv_have_decl_tzname=no
19827fi
19828
19829rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19830fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019831{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_tzname" >&5
19832echo "${ECHO_T}$ac_cv_have_decl_tzname" >&6; }
19833if test $ac_cv_have_decl_tzname = yes; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000019834
19835cat >>confdefs.h <<_ACEOF
19836#define HAVE_DECL_TZNAME 1
19837_ACEOF
19838
19839
19840else
19841 cat >>confdefs.h <<_ACEOF
19842#define HAVE_DECL_TZNAME 0
19843_ACEOF
19844
19845
19846fi
19847
19848
Ronald Oussoren450d5612009-06-08 21:12:41 +000019849 { echo "$as_me:$LINENO: checking for tzname" >&5
19850echo $ECHO_N "checking for tzname... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019851if test "${ac_cv_var_tzname+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019852 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019853else
Martin v. Löwis11437992002-04-12 09:54:03 +000019854 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019855/* confdefs.h. */
19856_ACEOF
19857cat confdefs.h >>conftest.$ac_ext
19858cat >>conftest.$ac_ext <<_ACEOF
19859/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000019860#include <time.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +000019861#if !HAVE_DECL_TZNAME
19862extern char *tzname[];
Guido van Rossum627b2d71993-12-24 10:39:16 +000019863#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000019864
Martin v. Löwis11437992002-04-12 09:54:03 +000019865int
19866main ()
19867{
Martin v. Löwiseba40652007-08-30 20:10:57 +000019868return tzname[0][0];
Martin v. Löwis11437992002-04-12 09:54:03 +000019869 ;
19870 return 0;
19871}
19872_ACEOF
19873rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019874if { (ac_try="$ac_link"
19875case "(($ac_try" in
19876 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19877 *) ac_try_echo=$ac_try;;
19878esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019879eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019880 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019881 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019882 grep -v '^ *+' conftest.er1 >conftest.err
19883 rm -f conftest.er1
19884 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019885 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019886 (exit $ac_status); } && {
19887 test -z "$ac_c_werror_flag" ||
19888 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000019889 } && test -s conftest$ac_exeext &&
19890 $as_test_x conftest$ac_exeext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019891 ac_cv_var_tzname=yes
19892else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019893 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019894sed 's/^/| /' conftest.$ac_ext >&5
19895
Martin v. Löwiseba40652007-08-30 20:10:57 +000019896 ac_cv_var_tzname=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000019897fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019898
19899rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000019900 conftest$ac_exeext conftest.$ac_ext
Guido van Rossum627b2d71993-12-24 10:39:16 +000019901fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000019902{ echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
19903echo "${ECHO_T}$ac_cv_var_tzname" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000019904 if test $ac_cv_var_tzname = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019905
19906cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019907#define HAVE_TZNAME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000019908_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000019909
Guido van Rossum76be6ed1995-01-02 18:33:54 +000019910 fi
19911fi
19912
Ronald Oussoren450d5612009-06-08 21:12:41 +000019913{ echo "$as_me:$LINENO: checking for struct stat.st_rdev" >&5
19914echo $ECHO_N "checking for struct stat.st_rdev... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000019915if test "${ac_cv_member_struct_stat_st_rdev+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000019916 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000019917else
19918 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019919/* confdefs.h. */
19920_ACEOF
19921cat confdefs.h >>conftest.$ac_ext
19922cat >>conftest.$ac_ext <<_ACEOF
19923/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000019924$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000019925int
19926main ()
19927{
19928static struct stat ac_aggr;
19929if (ac_aggr.st_rdev)
19930return 0;
19931 ;
19932 return 0;
19933}
19934_ACEOF
19935rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019936if { (ac_try="$ac_compile"
19937case "(($ac_try" in
19938 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19939 *) ac_try_echo=$ac_try;;
19940esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019941eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019942 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000019943 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019944 grep -v '^ *+' conftest.er1 >conftest.err
19945 rm -f conftest.er1
19946 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019947 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019948 (exit $ac_status); } && {
19949 test -z "$ac_c_werror_flag" ||
19950 test ! -s conftest.err
19951 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000019952 ac_cv_member_struct_stat_st_rdev=yes
19953else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019954 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019955sed 's/^/| /' conftest.$ac_ext >&5
19956
Martin v. Löwiseba40652007-08-30 20:10:57 +000019957 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000019958/* confdefs.h. */
19959_ACEOF
19960cat confdefs.h >>conftest.$ac_ext
19961cat >>conftest.$ac_ext <<_ACEOF
19962/* end confdefs.h. */
19963$ac_includes_default
19964int
19965main ()
19966{
19967static struct stat ac_aggr;
19968if (sizeof ac_aggr.st_rdev)
19969return 0;
19970 ;
19971 return 0;
19972}
19973_ACEOF
19974rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000019975if { (ac_try="$ac_compile"
19976case "(($ac_try" in
19977 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19978 *) ac_try_echo=$ac_try;;
19979esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000019980eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019981 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000019982 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000019983 grep -v '^ *+' conftest.er1 >conftest.err
19984 rm -f conftest.er1
19985 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000019986 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000019987 (exit $ac_status); } && {
19988 test -z "$ac_c_werror_flag" ||
19989 test ! -s conftest.err
19990 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000019991 ac_cv_member_struct_stat_st_rdev=yes
19992else
Ronald Oussoren450d5612009-06-08 21:12:41 +000019993 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000019994sed 's/^/| /' conftest.$ac_ext >&5
19995
Martin v. Löwiseba40652007-08-30 20:10:57 +000019996 ac_cv_member_struct_stat_st_rdev=no
Martin v. Löwis11437992002-04-12 09:54:03 +000019997fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000019998
19999rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000020000fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020001
20002rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000020003fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020004{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_rdev" >&5
20005echo "${ECHO_T}$ac_cv_member_struct_stat_st_rdev" >&6; }
20006if test $ac_cv_member_struct_stat_st_rdev = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020007
20008cat >>confdefs.h <<_ACEOF
20009#define HAVE_STRUCT_STAT_ST_RDEV 1
20010_ACEOF
20011
20012
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020013fi
20014
Ronald Oussoren450d5612009-06-08 21:12:41 +000020015{ echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
20016echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020017if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020018 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020019else
Martin v. Löwis11437992002-04-12 09:54:03 +000020020 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020021/* confdefs.h. */
20022_ACEOF
20023cat confdefs.h >>conftest.$ac_ext
20024cat >>conftest.$ac_ext <<_ACEOF
20025/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000020026$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000020027int
20028main ()
20029{
20030static struct stat ac_aggr;
20031if (ac_aggr.st_blksize)
20032return 0;
20033 ;
20034 return 0;
20035}
20036_ACEOF
20037rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020038if { (ac_try="$ac_compile"
20039case "(($ac_try" in
20040 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20041 *) ac_try_echo=$ac_try;;
20042esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020043eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020044 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020045 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020046 grep -v '^ *+' conftest.er1 >conftest.err
20047 rm -f conftest.er1
20048 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020050 (exit $ac_status); } && {
20051 test -z "$ac_c_werror_flag" ||
20052 test ! -s conftest.err
20053 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020054 ac_cv_member_struct_stat_st_blksize=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000020055else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020056 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020057sed 's/^/| /' conftest.$ac_ext >&5
20058
Martin v. Löwiseba40652007-08-30 20:10:57 +000020059 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020060/* confdefs.h. */
20061_ACEOF
20062cat confdefs.h >>conftest.$ac_ext
20063cat >>conftest.$ac_ext <<_ACEOF
20064/* end confdefs.h. */
20065$ac_includes_default
20066int
20067main ()
20068{
20069static struct stat ac_aggr;
20070if (sizeof ac_aggr.st_blksize)
20071return 0;
20072 ;
20073 return 0;
20074}
20075_ACEOF
20076rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020077if { (ac_try="$ac_compile"
20078case "(($ac_try" in
20079 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20080 *) ac_try_echo=$ac_try;;
20081esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020082eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020083 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000020084 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020085 grep -v '^ *+' conftest.er1 >conftest.err
20086 rm -f conftest.er1
20087 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020088 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020089 (exit $ac_status); } && {
20090 test -z "$ac_c_werror_flag" ||
20091 test ! -s conftest.err
20092 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000020093 ac_cv_member_struct_stat_st_blksize=yes
20094else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020095 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020096sed 's/^/| /' conftest.$ac_ext >&5
20097
Martin v. Löwiseba40652007-08-30 20:10:57 +000020098 ac_cv_member_struct_stat_st_blksize=no
Michael W. Hudson54241132001-12-07 15:38:26 +000020099fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020100
20101rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000020102fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020103
20104rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000020105fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020106{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
20107echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6; }
20108if test $ac_cv_member_struct_stat_st_blksize = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000020109
Martin v. Löwis11437992002-04-12 09:54:03 +000020110cat >>confdefs.h <<_ACEOF
20111#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
20112_ACEOF
20113
20114
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020115fi
20116
Ronald Oussoren450d5612009-06-08 21:12:41 +000020117{ echo "$as_me:$LINENO: checking for struct stat.st_flags" >&5
20118echo $ECHO_N "checking for struct stat.st_flags... $ECHO_C" >&6; }
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020119if test "${ac_cv_member_struct_stat_st_flags+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020120 echo $ECHO_N "(cached) $ECHO_C" >&6
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020121else
20122 cat >conftest.$ac_ext <<_ACEOF
20123/* confdefs.h. */
20124_ACEOF
20125cat confdefs.h >>conftest.$ac_ext
20126cat >>conftest.$ac_ext <<_ACEOF
20127/* end confdefs.h. */
20128$ac_includes_default
20129int
20130main ()
20131{
20132static struct stat ac_aggr;
20133if (ac_aggr.st_flags)
20134return 0;
20135 ;
20136 return 0;
20137}
20138_ACEOF
20139rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020140if { (ac_try="$ac_compile"
20141case "(($ac_try" in
20142 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20143 *) ac_try_echo=$ac_try;;
20144esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020145eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020146 (eval "$ac_compile") 2>conftest.er1
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020147 ac_status=$?
20148 grep -v '^ *+' conftest.er1 >conftest.err
20149 rm -f conftest.er1
20150 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020152 (exit $ac_status); } && {
20153 test -z "$ac_c_werror_flag" ||
20154 test ! -s conftest.err
20155 } && test -s conftest.$ac_objext; then
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020156 ac_cv_member_struct_stat_st_flags=yes
20157else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020158 echo "$as_me: failed program was:" >&5
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020159sed 's/^/| /' conftest.$ac_ext >&5
20160
Martin v. Löwiseba40652007-08-30 20:10:57 +000020161 cat >conftest.$ac_ext <<_ACEOF
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020162/* confdefs.h. */
20163_ACEOF
20164cat confdefs.h >>conftest.$ac_ext
20165cat >>conftest.$ac_ext <<_ACEOF
20166/* end confdefs.h. */
20167$ac_includes_default
20168int
20169main ()
20170{
20171static struct stat ac_aggr;
20172if (sizeof ac_aggr.st_flags)
20173return 0;
20174 ;
20175 return 0;
20176}
20177_ACEOF
20178rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020179if { (ac_try="$ac_compile"
20180case "(($ac_try" in
20181 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20182 *) ac_try_echo=$ac_try;;
20183esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020184eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020185 (eval "$ac_compile") 2>conftest.er1
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020186 ac_status=$?
20187 grep -v '^ *+' conftest.er1 >conftest.err
20188 rm -f conftest.er1
20189 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020190 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020191 (exit $ac_status); } && {
20192 test -z "$ac_c_werror_flag" ||
20193 test ! -s conftest.err
20194 } && test -s conftest.$ac_objext; then
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020195 ac_cv_member_struct_stat_st_flags=yes
20196else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020197 echo "$as_me: failed program was:" >&5
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020198sed 's/^/| /' conftest.$ac_ext >&5
20199
Martin v. Löwiseba40652007-08-30 20:10:57 +000020200 ac_cv_member_struct_stat_st_flags=no
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020201fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020202
20203rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020204fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020205
20206rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020207fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020208{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_flags" >&5
20209echo "${ECHO_T}$ac_cv_member_struct_stat_st_flags" >&6; }
20210if test $ac_cv_member_struct_stat_st_flags = yes; then
Hye-Shik Chang5f937a72005-06-02 13:09:30 +000020211
20212cat >>confdefs.h <<_ACEOF
20213#define HAVE_STRUCT_STAT_ST_FLAGS 1
20214_ACEOF
20215
20216
20217fi
20218
Ronald Oussoren450d5612009-06-08 21:12:41 +000020219{ echo "$as_me:$LINENO: checking for struct stat.st_gen" >&5
20220echo $ECHO_N "checking for struct stat.st_gen... $ECHO_C" >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020221if test "${ac_cv_member_struct_stat_st_gen+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020222 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020223else
20224 cat >conftest.$ac_ext <<_ACEOF
20225/* confdefs.h. */
20226_ACEOF
20227cat confdefs.h >>conftest.$ac_ext
20228cat >>conftest.$ac_ext <<_ACEOF
20229/* end confdefs.h. */
20230$ac_includes_default
20231int
20232main ()
20233{
20234static struct stat ac_aggr;
20235if (ac_aggr.st_gen)
20236return 0;
20237 ;
20238 return 0;
20239}
20240_ACEOF
20241rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020242if { (ac_try="$ac_compile"
20243case "(($ac_try" in
20244 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20245 *) ac_try_echo=$ac_try;;
20246esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020247eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020248 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020249 ac_status=$?
20250 grep -v '^ *+' conftest.er1 >conftest.err
20251 rm -f conftest.er1
20252 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020253 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020254 (exit $ac_status); } && {
20255 test -z "$ac_c_werror_flag" ||
20256 test ! -s conftest.err
20257 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020258 ac_cv_member_struct_stat_st_gen=yes
20259else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020260 echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020261sed 's/^/| /' conftest.$ac_ext >&5
20262
Martin v. Löwiseba40652007-08-30 20:10:57 +000020263 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020264/* confdefs.h. */
20265_ACEOF
20266cat confdefs.h >>conftest.$ac_ext
20267cat >>conftest.$ac_ext <<_ACEOF
20268/* end confdefs.h. */
20269$ac_includes_default
20270int
20271main ()
20272{
20273static struct stat ac_aggr;
20274if (sizeof ac_aggr.st_gen)
20275return 0;
20276 ;
20277 return 0;
20278}
20279_ACEOF
20280rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020281if { (ac_try="$ac_compile"
20282case "(($ac_try" in
20283 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20284 *) ac_try_echo=$ac_try;;
20285esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020286eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020287 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020288 ac_status=$?
20289 grep -v '^ *+' conftest.er1 >conftest.err
20290 rm -f conftest.er1
20291 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020292 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020293 (exit $ac_status); } && {
20294 test -z "$ac_c_werror_flag" ||
20295 test ! -s conftest.err
20296 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020297 ac_cv_member_struct_stat_st_gen=yes
20298else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020299 echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020300sed 's/^/| /' conftest.$ac_ext >&5
20301
Martin v. Löwiseba40652007-08-30 20:10:57 +000020302 ac_cv_member_struct_stat_st_gen=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020303fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020304
20305rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020306fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020307
20308rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020309fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020310{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_gen" >&5
20311echo "${ECHO_T}$ac_cv_member_struct_stat_st_gen" >&6; }
20312if test $ac_cv_member_struct_stat_st_gen = yes; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020313
20314cat >>confdefs.h <<_ACEOF
20315#define HAVE_STRUCT_STAT_ST_GEN 1
20316_ACEOF
20317
20318
20319fi
20320
Ronald Oussoren450d5612009-06-08 21:12:41 +000020321{ echo "$as_me:$LINENO: checking for struct stat.st_birthtime" >&5
20322echo $ECHO_N "checking for struct stat.st_birthtime... $ECHO_C" >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020323if test "${ac_cv_member_struct_stat_st_birthtime+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020324 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020325else
20326 cat >conftest.$ac_ext <<_ACEOF
20327/* confdefs.h. */
20328_ACEOF
20329cat confdefs.h >>conftest.$ac_ext
20330cat >>conftest.$ac_ext <<_ACEOF
20331/* end confdefs.h. */
20332$ac_includes_default
20333int
20334main ()
20335{
20336static struct stat ac_aggr;
20337if (ac_aggr.st_birthtime)
20338return 0;
20339 ;
20340 return 0;
20341}
20342_ACEOF
20343rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020344if { (ac_try="$ac_compile"
20345case "(($ac_try" in
20346 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20347 *) ac_try_echo=$ac_try;;
20348esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020349eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020350 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020351 ac_status=$?
20352 grep -v '^ *+' conftest.er1 >conftest.err
20353 rm -f conftest.er1
20354 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020355 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020356 (exit $ac_status); } && {
20357 test -z "$ac_c_werror_flag" ||
20358 test ! -s conftest.err
20359 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020360 ac_cv_member_struct_stat_st_birthtime=yes
20361else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020362 echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020363sed 's/^/| /' conftest.$ac_ext >&5
20364
Martin v. Löwiseba40652007-08-30 20:10:57 +000020365 cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020366/* confdefs.h. */
20367_ACEOF
20368cat confdefs.h >>conftest.$ac_ext
20369cat >>conftest.$ac_ext <<_ACEOF
20370/* end confdefs.h. */
20371$ac_includes_default
20372int
20373main ()
20374{
20375static struct stat ac_aggr;
20376if (sizeof ac_aggr.st_birthtime)
20377return 0;
20378 ;
20379 return 0;
20380}
20381_ACEOF
20382rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020383if { (ac_try="$ac_compile"
20384case "(($ac_try" in
20385 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20386 *) ac_try_echo=$ac_try;;
20387esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020388eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020389 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020390 ac_status=$?
20391 grep -v '^ *+' conftest.er1 >conftest.err
20392 rm -f conftest.er1
20393 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020394 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020395 (exit $ac_status); } && {
20396 test -z "$ac_c_werror_flag" ||
20397 test ! -s conftest.err
20398 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020399 ac_cv_member_struct_stat_st_birthtime=yes
20400else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020401 echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020402sed 's/^/| /' conftest.$ac_ext >&5
20403
Martin v. Löwiseba40652007-08-30 20:10:57 +000020404 ac_cv_member_struct_stat_st_birthtime=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020405fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020406
20407rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020408fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020409
20410rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020411fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020412{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_birthtime" >&5
20413echo "${ECHO_T}$ac_cv_member_struct_stat_st_birthtime" >&6; }
20414if test $ac_cv_member_struct_stat_st_birthtime = yes; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000020415
20416cat >>confdefs.h <<_ACEOF
20417#define HAVE_STRUCT_STAT_ST_BIRTHTIME 1
20418_ACEOF
20419
20420
20421fi
20422
Ronald Oussoren450d5612009-06-08 21:12:41 +000020423{ echo "$as_me:$LINENO: checking for struct stat.st_blocks" >&5
20424echo $ECHO_N "checking for struct stat.st_blocks... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020425if test "${ac_cv_member_struct_stat_st_blocks+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020426 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020427else
Martin v. Löwis11437992002-04-12 09:54:03 +000020428 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020429/* confdefs.h. */
20430_ACEOF
20431cat confdefs.h >>conftest.$ac_ext
20432cat >>conftest.$ac_ext <<_ACEOF
20433/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000020434$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000020435int
20436main ()
20437{
20438static struct stat ac_aggr;
20439if (ac_aggr.st_blocks)
20440return 0;
20441 ;
20442 return 0;
20443}
20444_ACEOF
20445rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020446if { (ac_try="$ac_compile"
20447case "(($ac_try" in
20448 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20449 *) ac_try_echo=$ac_try;;
20450esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020451eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020452 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020453 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020454 grep -v '^ *+' conftest.er1 >conftest.err
20455 rm -f conftest.er1
20456 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020457 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020458 (exit $ac_status); } && {
20459 test -z "$ac_c_werror_flag" ||
20460 test ! -s conftest.err
20461 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020462 ac_cv_member_struct_stat_st_blocks=yes
Michael W. Hudson54241132001-12-07 15:38:26 +000020463else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020464 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020465sed 's/^/| /' conftest.$ac_ext >&5
20466
Martin v. Löwiseba40652007-08-30 20:10:57 +000020467 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020468/* confdefs.h. */
20469_ACEOF
20470cat confdefs.h >>conftest.$ac_ext
20471cat >>conftest.$ac_ext <<_ACEOF
20472/* end confdefs.h. */
20473$ac_includes_default
20474int
20475main ()
20476{
20477static struct stat ac_aggr;
20478if (sizeof ac_aggr.st_blocks)
20479return 0;
20480 ;
20481 return 0;
20482}
20483_ACEOF
20484rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020485if { (ac_try="$ac_compile"
20486case "(($ac_try" in
20487 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20488 *) ac_try_echo=$ac_try;;
20489esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020490eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020491 (eval "$ac_compile") 2>conftest.er1
Skip Montanaro6dead952003-09-25 14:50:04 +000020492 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020493 grep -v '^ *+' conftest.er1 >conftest.err
20494 rm -f conftest.er1
20495 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020496 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020497 (exit $ac_status); } && {
20498 test -z "$ac_c_werror_flag" ||
20499 test ! -s conftest.err
20500 } && test -s conftest.$ac_objext; then
Skip Montanaro6dead952003-09-25 14:50:04 +000020501 ac_cv_member_struct_stat_st_blocks=yes
20502else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020503 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020504sed 's/^/| /' conftest.$ac_ext >&5
20505
Martin v. Löwiseba40652007-08-30 20:10:57 +000020506 ac_cv_member_struct_stat_st_blocks=no
Michael W. Hudson54241132001-12-07 15:38:26 +000020507fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020508
20509rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000020510fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020511
20512rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Skip Montanaro6dead952003-09-25 14:50:04 +000020513fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020514{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blocks" >&5
20515echo "${ECHO_T}$ac_cv_member_struct_stat_st_blocks" >&6; }
20516if test $ac_cv_member_struct_stat_st_blocks = yes; then
Jack Jansendd19cf82001-12-06 22:36:17 +000020517
Martin v. Löwis11437992002-04-12 09:54:03 +000020518cat >>confdefs.h <<_ACEOF
20519#define HAVE_STRUCT_STAT_ST_BLOCKS 1
20520_ACEOF
20521
20522
20523cat >>confdefs.h <<\_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020524#define HAVE_ST_BLOCKS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020525_ACEOF
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020526
20527else
Martin v. Löwiseba40652007-08-30 20:10:57 +000020528 case " $LIBOBJS " in
Skip Montanarof0d5f792004-08-15 14:08:23 +000020529 *" fileblocks.$ac_objext "* ) ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000020530 *) LIBOBJS="$LIBOBJS fileblocks.$ac_objext"
20531 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000020532esac
20533
Guido van Rossum98bf58f2001-10-18 20:34:25 +000020534fi
20535
Michael W. Hudson54241132001-12-07 15:38:26 +000020536
Martin v. Löwis11437992002-04-12 09:54:03 +000020537
Ronald Oussoren450d5612009-06-08 21:12:41 +000020538{ echo "$as_me:$LINENO: checking for time.h that defines altzone" >&5
20539echo $ECHO_N "checking for time.h that defines altzone... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020540if test "${ac_cv_header_time_altzone+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020541 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020542else
Martin v. Löwis11437992002-04-12 09:54:03 +000020543 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020544/* confdefs.h. */
20545_ACEOF
20546cat confdefs.h >>conftest.$ac_ext
20547cat >>conftest.$ac_ext <<_ACEOF
20548/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000020549#include <time.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000020550int
20551main ()
20552{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020553return altzone;
Martin v. Löwis11437992002-04-12 09:54:03 +000020554 ;
20555 return 0;
20556}
20557_ACEOF
20558rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020559if { (ac_try="$ac_compile"
20560case "(($ac_try" in
20561 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20562 *) ac_try_echo=$ac_try;;
20563esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020564eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020565 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020566 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020567 grep -v '^ *+' conftest.er1 >conftest.err
20568 rm -f conftest.er1
20569 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020570 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020571 (exit $ac_status); } && {
20572 test -z "$ac_c_werror_flag" ||
20573 test ! -s conftest.err
20574 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020575 ac_cv_header_time_altzone=yes
20576else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020577 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020578sed 's/^/| /' conftest.$ac_ext >&5
20579
Martin v. Löwiseba40652007-08-30 20:10:57 +000020580 ac_cv_header_time_altzone=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020581fi
20582
Martin v. Löwiseba40652007-08-30 20:10:57 +000020583rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20584fi
20585
Ronald Oussoren450d5612009-06-08 21:12:41 +000020586{ echo "$as_me:$LINENO: result: $ac_cv_header_time_altzone" >&5
20587echo "${ECHO_T}$ac_cv_header_time_altzone" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020588if test $ac_cv_header_time_altzone = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020589
20590cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020591#define HAVE_ALTZONE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020592_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020593
20594fi
20595
Guido van Rossumda88dad1995-01-26 00:46:29 +000020596was_it_defined=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000020597{ echo "$as_me:$LINENO: checking whether sys/select.h and sys/time.h may both be included" >&5
20598echo $ECHO_N "checking whether sys/select.h and sys/time.h may both be included... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020599cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020600/* confdefs.h. */
20601_ACEOF
20602cat confdefs.h >>conftest.$ac_ext
20603cat >>conftest.$ac_ext <<_ACEOF
20604/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000020605
20606#include <sys/types.h>
20607#include <sys/select.h>
20608#include <sys/time.h>
20609
Martin v. Löwis11437992002-04-12 09:54:03 +000020610int
20611main ()
20612{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020613;
Martin v. Löwis11437992002-04-12 09:54:03 +000020614 ;
20615 return 0;
20616}
20617_ACEOF
20618rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020619if { (ac_try="$ac_compile"
20620case "(($ac_try" in
20621 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20622 *) ac_try_echo=$ac_try;;
20623esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020624eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020625 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020626 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020627 grep -v '^ *+' conftest.er1 >conftest.err
20628 rm -f conftest.er1
20629 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020630 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020631 (exit $ac_status); } && {
20632 test -z "$ac_c_werror_flag" ||
20633 test ! -s conftest.err
20634 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020635
20636
20637cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020638#define SYS_SELECT_WITH_SYS_TIME 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020639_ACEOF
20640
Martin v. Löwisc45929e2002-04-06 10:10:49 +000020641 was_it_defined=yes
20642
Guido van Rossumf78abae1997-01-21 22:02:36 +000020643else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020644 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020645sed 's/^/| /' conftest.$ac_ext >&5
20646
Brett Cannon19fab762007-06-02 03:02:29 +000020647
Martin v. Löwiseba40652007-08-30 20:10:57 +000020648fi
20649
20650rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000020651{ echo "$as_me:$LINENO: result: $was_it_defined" >&5
20652echo "${ECHO_T}$was_it_defined" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000020653
Ronald Oussoren450d5612009-06-08 21:12:41 +000020654{ echo "$as_me:$LINENO: checking for addrinfo" >&5
20655echo $ECHO_N "checking for addrinfo... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020656if test "${ac_cv_struct_addrinfo+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020657 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020658else
Martin v. Löwis11437992002-04-12 09:54:03 +000020659 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020660/* confdefs.h. */
20661_ACEOF
20662cat confdefs.h >>conftest.$ac_ext
20663cat >>conftest.$ac_ext <<_ACEOF
20664/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020665
20666# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000020667int
20668main ()
20669{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020670struct addrinfo a
Martin v. Löwis11437992002-04-12 09:54:03 +000020671 ;
20672 return 0;
20673}
20674_ACEOF
20675rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020676if { (ac_try="$ac_compile"
20677case "(($ac_try" in
20678 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20679 *) ac_try_echo=$ac_try;;
20680esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020681eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020682 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020683 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020684 grep -v '^ *+' conftest.er1 >conftest.err
20685 rm -f conftest.er1
20686 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020687 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020688 (exit $ac_status); } && {
20689 test -z "$ac_c_werror_flag" ||
20690 test ! -s conftest.err
20691 } && test -s conftest.$ac_objext; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020692 ac_cv_struct_addrinfo=yes
20693else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020694 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020695sed 's/^/| /' conftest.$ac_ext >&5
20696
Martin v. Löwiseba40652007-08-30 20:10:57 +000020697 ac_cv_struct_addrinfo=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020698fi
20699
Martin v. Löwiseba40652007-08-30 20:10:57 +000020700rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20701fi
20702
Ronald Oussoren450d5612009-06-08 21:12:41 +000020703{ echo "$as_me:$LINENO: result: $ac_cv_struct_addrinfo" >&5
20704echo "${ECHO_T}$ac_cv_struct_addrinfo" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020705if test $ac_cv_struct_addrinfo = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020706
20707cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020708#define HAVE_ADDRINFO 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020709_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020710
20711fi
20712
Ronald Oussoren450d5612009-06-08 21:12:41 +000020713{ echo "$as_me:$LINENO: checking for sockaddr_storage" >&5
20714echo $ECHO_N "checking for sockaddr_storage... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020715if test "${ac_cv_struct_sockaddr_storage+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020716 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020717else
Martin v. Löwis11437992002-04-12 09:54:03 +000020718 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020719/* confdefs.h. */
20720_ACEOF
20721cat confdefs.h >>conftest.$ac_ext
20722cat >>conftest.$ac_ext <<_ACEOF
20723/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020724
20725# include <sys/types.h>
20726# include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000020727int
20728main ()
20729{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020730struct sockaddr_storage s
Martin v. Löwis11437992002-04-12 09:54:03 +000020731 ;
20732 return 0;
20733}
20734_ACEOF
20735rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020736if { (ac_try="$ac_compile"
20737case "(($ac_try" in
20738 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20739 *) ac_try_echo=$ac_try;;
20740esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020741eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020742 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020743 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020744 grep -v '^ *+' conftest.er1 >conftest.err
20745 rm -f conftest.er1
20746 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020747 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020748 (exit $ac_status); } && {
20749 test -z "$ac_c_werror_flag" ||
20750 test ! -s conftest.err
20751 } && test -s conftest.$ac_objext; then
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020752 ac_cv_struct_sockaddr_storage=yes
20753else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020754 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020755sed 's/^/| /' conftest.$ac_ext >&5
20756
Martin v. Löwiseba40652007-08-30 20:10:57 +000020757 ac_cv_struct_sockaddr_storage=no
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020758fi
20759
Martin v. Löwiseba40652007-08-30 20:10:57 +000020760rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20761fi
20762
Ronald Oussoren450d5612009-06-08 21:12:41 +000020763{ echo "$as_me:$LINENO: result: $ac_cv_struct_sockaddr_storage" >&5
20764echo "${ECHO_T}$ac_cv_struct_sockaddr_storage" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020765if test $ac_cv_struct_sockaddr_storage = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020766
20767cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020768#define HAVE_SOCKADDR_STORAGE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020769_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000020770
20771fi
20772
Guido van Rossum627b2d71993-12-24 10:39:16 +000020773# checks for compiler characteristics
Guido van Rossum7f43da71994-08-01 12:15:30 +000020774
Michael W. Hudson54241132001-12-07 15:38:26 +000020775
Ronald Oussoren450d5612009-06-08 21:12:41 +000020776{ echo "$as_me:$LINENO: checking whether char is unsigned" >&5
20777echo $ECHO_N "checking whether char is unsigned... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020778if test "${ac_cv_c_char_unsigned+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020779 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansendd19cf82001-12-06 22:36:17 +000020780else
Martin v. Löwis11437992002-04-12 09:54:03 +000020781 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020782/* confdefs.h. */
20783_ACEOF
20784cat confdefs.h >>conftest.$ac_ext
20785cat >>conftest.$ac_ext <<_ACEOF
20786/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000020787$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000020788int
20789main ()
20790{
20791static int test_array [1 - 2 * !(((char) -1) < 0)];
20792test_array [0] = 0
20793
20794 ;
20795 return 0;
Michael W. Hudson54241132001-12-07 15:38:26 +000020796}
Martin v. Löwis11437992002-04-12 09:54:03 +000020797_ACEOF
20798rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020799if { (ac_try="$ac_compile"
20800case "(($ac_try" in
20801 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20802 *) ac_try_echo=$ac_try;;
20803esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020804eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020805 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020806 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020807 grep -v '^ *+' conftest.er1 >conftest.err
20808 rm -f conftest.er1
20809 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020810 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020811 (exit $ac_status); } && {
20812 test -z "$ac_c_werror_flag" ||
20813 test ! -s conftest.err
20814 } && test -s conftest.$ac_objext; then
Michael W. Hudson54241132001-12-07 15:38:26 +000020815 ac_cv_c_char_unsigned=no
Martin v. Löwis11437992002-04-12 09:54:03 +000020816else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020817 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020818sed 's/^/| /' conftest.$ac_ext >&5
20819
Martin v. Löwiseba40652007-08-30 20:10:57 +000020820 ac_cv_c_char_unsigned=yes
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020821fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020822
20823rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000020824fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020825{ echo "$as_me:$LINENO: result: $ac_cv_c_char_unsigned" >&5
20826echo "${ECHO_T}$ac_cv_c_char_unsigned" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020827if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020828 cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020829#define __CHAR_UNSIGNED__ 1
Martin v. Löwis11437992002-04-12 09:54:03 +000020830_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020831
20832fi
Guido van Rossum7f43da71994-08-01 12:15:30 +000020833
Ronald Oussoren450d5612009-06-08 21:12:41 +000020834{ echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
20835echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020836if test "${ac_cv_c_const+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000020837 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000020838else
20839 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020840/* confdefs.h. */
20841_ACEOF
20842cat confdefs.h >>conftest.$ac_ext
20843cat >>conftest.$ac_ext <<_ACEOF
20844/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020845
Martin v. Löwis11437992002-04-12 09:54:03 +000020846int
20847main ()
20848{
20849/* FIXME: Include the comments suggested by Paul. */
20850#ifndef __cplusplus
20851 /* Ultrix mips cc rejects this. */
20852 typedef int charset[2];
Martin v. Löwiseba40652007-08-30 20:10:57 +000020853 const charset cs;
Martin v. Löwis11437992002-04-12 09:54:03 +000020854 /* SunOS 4.1.1 cc rejects this. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000020855 char const *const *pcpcc;
20856 char **ppc;
Martin v. Löwis11437992002-04-12 09:54:03 +000020857 /* NEC SVR4.0.2 mips cc rejects this. */
20858 struct point {int x, y;};
20859 static struct point const zero = {0,0};
20860 /* AIX XL C 1.02.0.0 rejects this.
20861 It does not let you subtract one const X* pointer from another in
20862 an arm of an if-expression whose if-part is not a constant
20863 expression */
20864 const char *g = "string";
Martin v. Löwiseba40652007-08-30 20:10:57 +000020865 pcpcc = &g + (g ? g-g : 0);
Martin v. Löwis11437992002-04-12 09:54:03 +000020866 /* HPUX 7.0 cc rejects these. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000020867 ++pcpcc;
20868 ppc = (char**) pcpcc;
20869 pcpcc = (char const *const *) ppc;
Martin v. Löwis11437992002-04-12 09:54:03 +000020870 { /* SCO 3.2v4 cc rejects this. */
20871 char *t;
20872 char const *s = 0 ? (char *) 0 : (char const *) 0;
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020873
Martin v. Löwis11437992002-04-12 09:54:03 +000020874 *t++ = 0;
Martin v. Löwiseba40652007-08-30 20:10:57 +000020875 if (s) return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000020876 }
20877 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
20878 int x[] = {25, 17};
20879 const int *foo = &x[0];
20880 ++foo;
20881 }
20882 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
20883 typedef const int *iptr;
20884 iptr p = 0;
20885 ++p;
20886 }
20887 { /* AIX XL C 1.02.0.0 rejects this saying
20888 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
20889 struct s { int j; const int *ap[3]; };
20890 struct s *b; b->j = 5;
20891 }
20892 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
20893 const int foo = 10;
Martin v. Löwiseba40652007-08-30 20:10:57 +000020894 if (!foo) return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000020895 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000020896 return !cs[0] && !zero.x;
Martin v. Löwis11437992002-04-12 09:54:03 +000020897#endif
Guido van Rossum627b2d71993-12-24 10:39:16 +000020898
Martin v. Löwis11437992002-04-12 09:54:03 +000020899 ;
20900 return 0;
Guido van Rossum627b2d71993-12-24 10:39:16 +000020901}
Martin v. Löwis11437992002-04-12 09:54:03 +000020902_ACEOF
20903rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020904if { (ac_try="$ac_compile"
20905case "(($ac_try" in
20906 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20907 *) ac_try_echo=$ac_try;;
20908esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020909eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020910 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020911 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020912 grep -v '^ *+' conftest.er1 >conftest.err
20913 rm -f conftest.er1
20914 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020915 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020916 (exit $ac_status); } && {
20917 test -z "$ac_c_werror_flag" ||
20918 test ! -s conftest.err
20919 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020920 ac_cv_c_const=yes
20921else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020922 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020923sed 's/^/| /' conftest.$ac_ext >&5
20924
Martin v. Löwiseba40652007-08-30 20:10:57 +000020925 ac_cv_c_const=no
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020926fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020927
20928rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020929fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000020930{ echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
20931echo "${ECHO_T}$ac_cv_c_const" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020932if test $ac_cv_c_const = no; then
Martin v. Löwis11437992002-04-12 09:54:03 +000020933
20934cat >>confdefs.h <<\_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000020935#define const
Martin v. Löwis11437992002-04-12 09:54:03 +000020936_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020937
20938fi
20939
Michael W. Hudson54241132001-12-07 15:38:26 +000020940
Guido van Rossumda88dad1995-01-26 00:46:29 +000020941works=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000020942{ echo "$as_me:$LINENO: checking for working volatile" >&5
20943echo $ECHO_N "checking for working volatile... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020944cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020945/* confdefs.h. */
20946_ACEOF
20947cat confdefs.h >>conftest.$ac_ext
20948cat >>conftest.$ac_ext <<_ACEOF
20949/* end confdefs.h. */
Guido van Rossum627b2d71993-12-24 10:39:16 +000020950
Martin v. Löwis11437992002-04-12 09:54:03 +000020951int
20952main ()
20953{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000020954volatile int x; x = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000020955 ;
20956 return 0;
20957}
20958_ACEOF
20959rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000020960if { (ac_try="$ac_compile"
20961case "(($ac_try" in
20962 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20963 *) ac_try_echo=$ac_try;;
20964esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000020965eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020966 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000020967 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000020968 grep -v '^ *+' conftest.er1 >conftest.err
20969 rm -f conftest.er1
20970 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000020971 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000020972 (exit $ac_status); } && {
20973 test -z "$ac_c_werror_flag" ||
20974 test ! -s conftest.err
20975 } && test -s conftest.$ac_objext; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000020976 works=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000020977else
Ronald Oussoren450d5612009-06-08 21:12:41 +000020978 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000020979sed 's/^/| /' conftest.$ac_ext >&5
20980
Martin v. Löwis11437992002-04-12 09:54:03 +000020981
20982cat >>confdefs.h <<\_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000020983#define volatile
Martin v. Löwis11437992002-04-12 09:54:03 +000020984_ACEOF
Guido van Rossum627b2d71993-12-24 10:39:16 +000020985
Martin v. Löwisc45929e2002-04-06 10:10:49 +000020986
Guido van Rossum627b2d71993-12-24 10:39:16 +000020987fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000020988
20989rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000020990{ echo "$as_me:$LINENO: result: $works" >&5
20991echo "${ECHO_T}$works" >&6; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000020992
Guido van Rossumda88dad1995-01-26 00:46:29 +000020993works=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000020994{ echo "$as_me:$LINENO: checking for working signed char" >&5
20995echo $ECHO_N "checking for working signed char... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000020996cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000020997/* confdefs.h. */
20998_ACEOF
20999cat confdefs.h >>conftest.$ac_ext
21000cat >>conftest.$ac_ext <<_ACEOF
21001/* end confdefs.h. */
Guido van Rossumdabb11b1994-10-11 15:04:27 +000021002
Martin v. Löwis11437992002-04-12 09:54:03 +000021003int
21004main ()
21005{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021006signed char c;
Martin v. Löwis11437992002-04-12 09:54:03 +000021007 ;
21008 return 0;
21009}
21010_ACEOF
21011rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021012if { (ac_try="$ac_compile"
21013case "(($ac_try" in
21014 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21015 *) ac_try_echo=$ac_try;;
21016esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021017eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021018 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021019 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021020 grep -v '^ *+' conftest.er1 >conftest.err
21021 rm -f conftest.er1
21022 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021023 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021024 (exit $ac_status); } && {
21025 test -z "$ac_c_werror_flag" ||
21026 test ! -s conftest.err
21027 } && test -s conftest.$ac_objext; then
Guido van Rossumda88dad1995-01-26 00:46:29 +000021028 works=yes
Guido van Rossumdabb11b1994-10-11 15:04:27 +000021029else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021030 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021031sed 's/^/| /' conftest.$ac_ext >&5
21032
Martin v. Löwis11437992002-04-12 09:54:03 +000021033
21034cat >>confdefs.h <<\_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000021035#define signed
Martin v. Löwis11437992002-04-12 09:54:03 +000021036_ACEOF
Guido van Rossum7f43da71994-08-01 12:15:30 +000021037
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021038
Guido van Rossum7f43da71994-08-01 12:15:30 +000021039fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021040
21041rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000021042{ echo "$as_me:$LINENO: result: $works" >&5
21043echo "${ECHO_T}$works" >&6; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000021044
Guido van Rossumda88dad1995-01-26 00:46:29 +000021045have_prototypes=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000021046{ echo "$as_me:$LINENO: checking for prototypes" >&5
21047echo $ECHO_N "checking for prototypes... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021048cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021049/* confdefs.h. */
21050_ACEOF
21051cat confdefs.h >>conftest.$ac_ext
21052cat >>conftest.$ac_ext <<_ACEOF
21053/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000021054int foo(int x) { return 0; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021055int
21056main ()
21057{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021058return foo(10);
Martin v. Löwis11437992002-04-12 09:54:03 +000021059 ;
21060 return 0;
21061}
21062_ACEOF
21063rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021064if { (ac_try="$ac_compile"
21065case "(($ac_try" in
21066 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21067 *) ac_try_echo=$ac_try;;
21068esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021069eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021070 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021071 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021072 grep -v '^ *+' conftest.er1 >conftest.err
21073 rm -f conftest.er1
21074 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021075 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021076 (exit $ac_status); } && {
21077 test -z "$ac_c_werror_flag" ||
21078 test ! -s conftest.err
21079 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021080
21081
21082cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021083#define HAVE_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021084_ACEOF
21085
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021086 have_prototypes=yes
21087
Guido van Rossumf78abae1997-01-21 22:02:36 +000021088else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021089 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021090sed 's/^/| /' conftest.$ac_ext >&5
21091
Martin v. Löwiseba40652007-08-30 20:10:57 +000021092
Guido van Rossum7f43da71994-08-01 12:15:30 +000021093fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021094
21095rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000021096{ echo "$as_me:$LINENO: result: $have_prototypes" >&5
21097echo "${ECHO_T}$have_prototypes" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021098
Guido van Rossumda88dad1995-01-26 00:46:29 +000021099works=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000021100{ echo "$as_me:$LINENO: checking for variable length prototypes and stdarg.h" >&5
21101echo $ECHO_N "checking for variable length prototypes and stdarg.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021102cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021103/* confdefs.h. */
21104_ACEOF
21105cat confdefs.h >>conftest.$ac_ext
21106cat >>conftest.$ac_ext <<_ACEOF
21107/* end confdefs.h. */
Guido van Rossum7f43da71994-08-01 12:15:30 +000021108
21109#include <stdarg.h>
Guido van Rossum90eea071996-08-30 20:58:57 +000021110int foo(int x, ...) {
21111 va_list va;
21112 va_start(va, x);
21113 va_arg(va, int);
21114 va_arg(va, char *);
21115 va_arg(va, double);
21116 return 0;
21117}
Guido van Rossum7f43da71994-08-01 12:15:30 +000021118
Martin v. Löwis11437992002-04-12 09:54:03 +000021119int
21120main ()
21121{
Guido van Rossum90eea071996-08-30 20:58:57 +000021122return foo(10, "", 3.14);
Martin v. Löwis11437992002-04-12 09:54:03 +000021123 ;
21124 return 0;
21125}
21126_ACEOF
21127rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021128if { (ac_try="$ac_compile"
21129case "(($ac_try" in
21130 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21131 *) ac_try_echo=$ac_try;;
21132esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021133eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021134 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021135 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021136 grep -v '^ *+' conftest.er1 >conftest.err
21137 rm -f conftest.er1
21138 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021140 (exit $ac_status); } && {
21141 test -z "$ac_c_werror_flag" ||
21142 test ! -s conftest.err
21143 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021144
21145
21146cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021147#define HAVE_STDARG_PROTOTYPES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021148_ACEOF
21149
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021150 works=yes
21151
Guido van Rossumf78abae1997-01-21 22:02:36 +000021152else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021153 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021154sed 's/^/| /' conftest.$ac_ext >&5
21155
Martin v. Löwiseba40652007-08-30 20:10:57 +000021156
Guido van Rossum627b2d71993-12-24 10:39:16 +000021157fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021158
21159rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000021160{ echo "$as_me:$LINENO: result: $works" >&5
21161echo "${ECHO_T}$works" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021162
Martin v. Löwisd6320502004-08-12 13:45:08 +000021163# check for socketpair
Ronald Oussoren450d5612009-06-08 21:12:41 +000021164{ echo "$as_me:$LINENO: checking for socketpair" >&5
21165echo $ECHO_N "checking for socketpair... $ECHO_C" >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000021166cat >conftest.$ac_ext <<_ACEOF
Martin v. Löwisd6320502004-08-12 13:45:08 +000021167/* confdefs.h. */
21168_ACEOF
21169cat confdefs.h >>conftest.$ac_ext
21170cat >>conftest.$ac_ext <<_ACEOF
21171/* end confdefs.h. */
21172
21173#include <sys/types.h>
21174#include <sys/socket.h>
21175
21176int
21177main ()
21178{
21179void *x=socketpair
21180 ;
21181 return 0;
21182}
21183_ACEOF
21184rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021185if { (ac_try="$ac_compile"
21186case "(($ac_try" in
21187 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21188 *) ac_try_echo=$ac_try;;
21189esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021190eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021191 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisd6320502004-08-12 13:45:08 +000021192 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021193 grep -v '^ *+' conftest.er1 >conftest.err
21194 rm -f conftest.er1
21195 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021196 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021197 (exit $ac_status); } && {
21198 test -z "$ac_c_werror_flag" ||
21199 test ! -s conftest.err
21200 } && test -s conftest.$ac_objext; then
Martin v. Löwisd6320502004-08-12 13:45:08 +000021201
21202cat >>confdefs.h <<\_ACEOF
21203#define HAVE_SOCKETPAIR 1
21204_ACEOF
21205
Ronald Oussoren450d5612009-06-08 21:12:41 +000021206 { echo "$as_me:$LINENO: result: yes" >&5
21207echo "${ECHO_T}yes" >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000021208else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021209 echo "$as_me: failed program was:" >&5
Martin v. Löwisd6320502004-08-12 13:45:08 +000021210sed 's/^/| /' conftest.$ac_ext >&5
21211
Ronald Oussoren450d5612009-06-08 21:12:41 +000021212 { echo "$as_me:$LINENO: result: no" >&5
21213echo "${ECHO_T}no" >&6; }
Martin v. Löwisd6320502004-08-12 13:45:08 +000021214
21215fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021216
21217rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwisd6320502004-08-12 13:45:08 +000021218
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021219# check if sockaddr has sa_len member
Ronald Oussoren450d5612009-06-08 21:12:41 +000021220{ echo "$as_me:$LINENO: checking if sockaddr has sa_len member" >&5
21221echo $ECHO_N "checking if sockaddr has sa_len member... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021222cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021223/* confdefs.h. */
21224_ACEOF
21225cat confdefs.h >>conftest.$ac_ext
21226cat >>conftest.$ac_ext <<_ACEOF
21227/* end confdefs.h. */
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021228#include <sys/types.h>
21229#include <sys/socket.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021230int
21231main ()
21232{
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021233struct sockaddr x;
21234x.sa_len = 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000021235 ;
21236 return 0;
21237}
21238_ACEOF
21239rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021240if { (ac_try="$ac_compile"
21241case "(($ac_try" in
21242 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21243 *) ac_try_echo=$ac_try;;
21244esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021245eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021246 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021247 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021248 grep -v '^ *+' conftest.er1 >conftest.err
21249 rm -f conftest.er1
21250 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021251 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021252 (exit $ac_status); } && {
21253 test -z "$ac_c_werror_flag" ||
21254 test ! -s conftest.err
21255 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000021256 { echo "$as_me:$LINENO: result: yes" >&5
21257echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021258
21259cat >>confdefs.h <<\_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021260#define HAVE_SOCKADDR_SA_LEN 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021261_ACEOF
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021262
21263else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021264 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021265sed 's/^/| /' conftest.$ac_ext >&5
21266
Ronald Oussoren450d5612009-06-08 21:12:41 +000021267 { echo "$as_me:$LINENO: result: no" >&5
21268echo "${ECHO_T}no" >&6; }
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021269fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021270
21271rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis01dfdb32001-06-23 16:30:13 +000021272
Guido van Rossumda88dad1995-01-26 00:46:29 +000021273va_list_is_array=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000021274{ echo "$as_me:$LINENO: checking whether va_list is an array" >&5
21275echo $ECHO_N "checking whether va_list is an array... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021276cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021277/* confdefs.h. */
21278_ACEOF
21279cat confdefs.h >>conftest.$ac_ext
21280cat >>conftest.$ac_ext <<_ACEOF
21281/* end confdefs.h. */
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021282
21283#ifdef HAVE_STDARG_PROTOTYPES
21284#include <stdarg.h>
21285#else
21286#include <varargs.h>
21287#endif
21288
Martin v. Löwis11437992002-04-12 09:54:03 +000021289int
21290main ()
21291{
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021292va_list list1, list2; list1 = list2;
Martin v. Löwis11437992002-04-12 09:54:03 +000021293 ;
21294 return 0;
21295}
21296_ACEOF
21297rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021298if { (ac_try="$ac_compile"
21299case "(($ac_try" in
21300 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21301 *) ac_try_echo=$ac_try;;
21302esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021303eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021304 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021305 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021306 grep -v '^ *+' conftest.er1 >conftest.err
21307 rm -f conftest.er1
21308 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021309 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021310 (exit $ac_status); } && {
21311 test -z "$ac_c_werror_flag" ||
21312 test ! -s conftest.err
21313 } && test -s conftest.$ac_objext; then
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021314 :
21315else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021316 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021317sed 's/^/| /' conftest.$ac_ext >&5
21318
Martin v. Löwis11437992002-04-12 09:54:03 +000021319
21320
21321cat >>confdefs.h <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021322#define VA_LIST_IS_ARRAY 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021323_ACEOF
21324
Guido van Rossumda88dad1995-01-26 00:46:29 +000021325 va_list_is_array=yes
Martin v. Löwisc45929e2002-04-06 10:10:49 +000021326
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021327fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021328
21329rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000021330{ echo "$as_me:$LINENO: result: $va_list_is_array" >&5
21331echo "${ECHO_T}$va_list_is_array" >&6; }
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021332
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021333# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
Martin v. Löwis11437992002-04-12 09:54:03 +000021334
21335
21336
Ronald Oussoren450d5612009-06-08 21:12:41 +000021337{ echo "$as_me:$LINENO: checking for gethostbyname_r" >&5
21338echo $ECHO_N "checking for gethostbyname_r... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021339if test "${ac_cv_func_gethostbyname_r+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000021340 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021341else
Martin v. Löwis11437992002-04-12 09:54:03 +000021342 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021343/* confdefs.h. */
21344_ACEOF
21345cat confdefs.h >>conftest.$ac_ext
21346cat >>conftest.$ac_ext <<_ACEOF
21347/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021348/* Define gethostbyname_r to an innocuous variant, in case <limits.h> declares gethostbyname_r.
21349 For example, HP-UX 11i <limits.h> declares gettimeofday. */
21350#define gethostbyname_r innocuous_gethostbyname_r
21351
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021352/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000021353 which can conflict with char gethostbyname_r (); below.
21354 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021355 <limits.h> exists even on freestanding compilers. */
21356
21357#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000021358# include <limits.h>
21359#else
21360# include <assert.h>
21361#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021362
21363#undef gethostbyname_r
21364
Martin v. Löwiseba40652007-08-30 20:10:57 +000021365/* Override any GCC internal prototype to avoid an error.
21366 Use char because int might match the return type of a GCC
21367 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021368#ifdef __cplusplus
21369extern "C"
21370#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000021371char gethostbyname_r ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021372/* The GNU C library defines this for functions which it implements
21373 to always fail with ENOSYS. Some functions are actually named
21374 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000021375#if defined __stub_gethostbyname_r || defined __stub___gethostbyname_r
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021376choke me
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021377#endif
21378
Skip Montanaro6dead952003-09-25 14:50:04 +000021379int
21380main ()
21381{
Martin v. Löwiseba40652007-08-30 20:10:57 +000021382return gethostbyname_r ();
Martin v. Löwis11437992002-04-12 09:54:03 +000021383 ;
21384 return 0;
21385}
21386_ACEOF
21387rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021388if { (ac_try="$ac_link"
21389case "(($ac_try" in
21390 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21391 *) ac_try_echo=$ac_try;;
21392esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021393eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021394 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021395 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021396 grep -v '^ *+' conftest.er1 >conftest.err
21397 rm -f conftest.er1
21398 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021399 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021400 (exit $ac_status); } && {
21401 test -z "$ac_c_werror_flag" ||
21402 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000021403 } && test -s conftest$ac_exeext &&
21404 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021405 ac_cv_func_gethostbyname_r=yes
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021406else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021407 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021408sed 's/^/| /' conftest.$ac_ext >&5
21409
Martin v. Löwiseba40652007-08-30 20:10:57 +000021410 ac_cv_func_gethostbyname_r=no
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021411fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021412
21413rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000021414 conftest$ac_exeext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021415fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000021416{ echo "$as_me:$LINENO: result: $ac_cv_func_gethostbyname_r" >&5
21417echo "${ECHO_T}$ac_cv_func_gethostbyname_r" >&6; }
21418if test $ac_cv_func_gethostbyname_r = yes; then
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021419
Martin v. Löwis11437992002-04-12 09:54:03 +000021420 cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021421#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021422_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021423
Ronald Oussoren450d5612009-06-08 21:12:41 +000021424 { echo "$as_me:$LINENO: checking gethostbyname_r with 6 args" >&5
21425echo $ECHO_N "checking gethostbyname_r with 6 args... $ECHO_C" >&6; }
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021426 OLD_CFLAGS=$CFLAGS
21427 CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
Martin v. Löwis11437992002-04-12 09:54:03 +000021428 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021429/* confdefs.h. */
21430_ACEOF
21431cat confdefs.h >>conftest.$ac_ext
21432cat >>conftest.$ac_ext <<_ACEOF
21433/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021434
21435# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021436
Martin v. Löwis11437992002-04-12 09:54:03 +000021437int
21438main ()
21439{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021440
21441 char *name;
21442 struct hostent *he, *res;
21443 char buffer[2048];
21444 int buflen = 2048;
21445 int h_errnop;
21446
21447 (void) gethostbyname_r(name, he, buffer, buflen, &res, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000021448
21449 ;
21450 return 0;
21451}
21452_ACEOF
21453rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021454if { (ac_try="$ac_compile"
21455case "(($ac_try" in
21456 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21457 *) ac_try_echo=$ac_try;;
21458esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021459eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021460 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021461 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021462 grep -v '^ *+' conftest.er1 >conftest.err
21463 rm -f conftest.er1
21464 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021465 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021466 (exit $ac_status); } && {
21467 test -z "$ac_c_werror_flag" ||
21468 test ! -s conftest.err
21469 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021470
21471 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021472#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021473_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021474
Martin v. Löwis11437992002-04-12 09:54:03 +000021475
21476cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021477#define HAVE_GETHOSTBYNAME_R_6_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021478_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021479
Ronald Oussoren450d5612009-06-08 21:12:41 +000021480 { echo "$as_me:$LINENO: result: yes" >&5
21481echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021482
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021483else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021484 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021485sed 's/^/| /' conftest.$ac_ext >&5
21486
Martin v. Löwis11437992002-04-12 09:54:03 +000021487
Ronald Oussoren450d5612009-06-08 21:12:41 +000021488 { echo "$as_me:$LINENO: result: no" >&5
21489echo "${ECHO_T}no" >&6; }
21490 { echo "$as_me:$LINENO: checking gethostbyname_r with 5 args" >&5
21491echo $ECHO_N "checking gethostbyname_r with 5 args... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021492 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021493/* confdefs.h. */
21494_ACEOF
21495cat confdefs.h >>conftest.$ac_ext
21496cat >>conftest.$ac_ext <<_ACEOF
21497/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021498
21499# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021500
Martin v. Löwis11437992002-04-12 09:54:03 +000021501int
21502main ()
21503{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021504
21505 char *name;
21506 struct hostent *he;
21507 char buffer[2048];
21508 int buflen = 2048;
21509 int h_errnop;
21510
21511 (void) gethostbyname_r(name, he, buffer, buflen, &h_errnop)
Martin v. Löwis11437992002-04-12 09:54:03 +000021512
21513 ;
21514 return 0;
21515}
21516_ACEOF
21517rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021518if { (ac_try="$ac_compile"
21519case "(($ac_try" in
21520 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21521 *) ac_try_echo=$ac_try;;
21522esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021523eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021524 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021525 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021526 grep -v '^ *+' conftest.er1 >conftest.err
21527 rm -f conftest.er1
21528 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021529 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021530 (exit $ac_status); } && {
21531 test -z "$ac_c_werror_flag" ||
21532 test ! -s conftest.err
21533 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021534
21535 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021536#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021537_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021538
Martin v. Löwis11437992002-04-12 09:54:03 +000021539
21540cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021541#define HAVE_GETHOSTBYNAME_R_5_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021542_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021543
Ronald Oussoren450d5612009-06-08 21:12:41 +000021544 { echo "$as_me:$LINENO: result: yes" >&5
21545echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021546
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021547else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021548 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021549sed 's/^/| /' conftest.$ac_ext >&5
21550
Martin v. Löwis11437992002-04-12 09:54:03 +000021551
Ronald Oussoren450d5612009-06-08 21:12:41 +000021552 { echo "$as_me:$LINENO: result: no" >&5
21553echo "${ECHO_T}no" >&6; }
21554 { echo "$as_me:$LINENO: checking gethostbyname_r with 3 args" >&5
21555echo $ECHO_N "checking gethostbyname_r with 3 args... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021556 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021557/* confdefs.h. */
21558_ACEOF
21559cat confdefs.h >>conftest.$ac_ext
21560cat >>conftest.$ac_ext <<_ACEOF
21561/* end confdefs.h. */
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021562
21563# include <netdb.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000021564
Martin v. Löwis11437992002-04-12 09:54:03 +000021565int
21566main ()
21567{
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021568
21569 char *name;
21570 struct hostent *he;
21571 struct hostent_data data;
21572
21573 (void) gethostbyname_r(name, he, &data);
Martin v. Löwis11437992002-04-12 09:54:03 +000021574
21575 ;
21576 return 0;
21577}
21578_ACEOF
21579rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021580if { (ac_try="$ac_compile"
21581case "(($ac_try" in
21582 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21583 *) ac_try_echo=$ac_try;;
21584esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021585eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021586 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021587 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021588 grep -v '^ *+' conftest.er1 >conftest.err
21589 rm -f conftest.er1
21590 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021591 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021592 (exit $ac_status); } && {
21593 test -z "$ac_c_werror_flag" ||
21594 test ! -s conftest.err
21595 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021596
21597 cat >>confdefs.h <<\_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021598#define HAVE_GETHOSTBYNAME_R 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021599_ACEOF
Guido van Rossum8db7d8b1999-03-23 16:40:33 +000021600
Martin v. Löwis11437992002-04-12 09:54:03 +000021601
21602cat >>confdefs.h <<\_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021603#define HAVE_GETHOSTBYNAME_R_3_ARG 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021604_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021605
Ronald Oussoren450d5612009-06-08 21:12:41 +000021606 { echo "$as_me:$LINENO: result: yes" >&5
21607echo "${ECHO_T}yes" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021608
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021609else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021610 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021611sed 's/^/| /' conftest.$ac_ext >&5
21612
Martin v. Löwis11437992002-04-12 09:54:03 +000021613
Ronald Oussoren450d5612009-06-08 21:12:41 +000021614 { echo "$as_me:$LINENO: result: no" >&5
21615echo "${ECHO_T}no" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021616
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021617fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021618
21619rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000021620
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021621fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021622
21623rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000021624
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021625fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021626
21627rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021628 CFLAGS=$OLD_CFLAGS
21629
21630else
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021631
Martin v. Löwis11437992002-04-12 09:54:03 +000021632
21633for ac_func in gethostbyname
Thomas Wouters3a584202000-08-05 23:28:51 +000021634do
Ronald Oussoren450d5612009-06-08 21:12:41 +000021635as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21636{ echo "$as_me:$LINENO: checking for $ac_func" >&5
21637echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000021638if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000021639 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021640else
Martin v. Löwis11437992002-04-12 09:54:03 +000021641 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021642/* confdefs.h. */
21643_ACEOF
21644cat confdefs.h >>conftest.$ac_ext
21645cat >>conftest.$ac_ext <<_ACEOF
21646/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021647/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21648 For example, HP-UX 11i <limits.h> declares gettimeofday. */
21649#define $ac_func innocuous_$ac_func
21650
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021651/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000021652 which can conflict with char $ac_func (); below.
21653 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021654 <limits.h> exists even on freestanding compilers. */
21655
21656#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000021657# include <limits.h>
21658#else
21659# include <assert.h>
21660#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021661
21662#undef $ac_func
21663
Martin v. Löwiseba40652007-08-30 20:10:57 +000021664/* Override any GCC internal prototype to avoid an error.
21665 Use char because int might match the return type of a GCC
21666 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021667#ifdef __cplusplus
21668extern "C"
21669#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000021670char $ac_func ();
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021671/* The GNU C library defines this for functions which it implements
21672 to always fail with ENOSYS. Some functions are actually named
21673 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000021674#if defined __stub_$ac_func || defined __stub___$ac_func
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021675choke me
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021676#endif
21677
Skip Montanaro6dead952003-09-25 14:50:04 +000021678int
21679main ()
21680{
Martin v. Löwiseba40652007-08-30 20:10:57 +000021681return $ac_func ();
Martin v. Löwis11437992002-04-12 09:54:03 +000021682 ;
21683 return 0;
21684}
21685_ACEOF
21686rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021687if { (ac_try="$ac_link"
21688case "(($ac_try" in
21689 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21690 *) ac_try_echo=$ac_try;;
21691esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021692eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021693 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021694 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021695 grep -v '^ *+' conftest.er1 >conftest.err
21696 rm -f conftest.er1
21697 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021698 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021699 (exit $ac_status); } && {
21700 test -z "$ac_c_werror_flag" ||
21701 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000021702 } && test -s conftest$ac_exeext &&
21703 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021704 eval "$as_ac_var=yes"
Michael W. Hudson54241132001-12-07 15:38:26 +000021705else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021706 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021707sed 's/^/| /' conftest.$ac_ext >&5
21708
Martin v. Löwiseba40652007-08-30 20:10:57 +000021709 eval "$as_ac_var=no"
Michael W. Hudson54241132001-12-07 15:38:26 +000021710fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021711
21712rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000021713 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson54241132001-12-07 15:38:26 +000021714fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000021715ac_res=`eval echo '${'$as_ac_var'}'`
21716 { echo "$as_me:$LINENO: result: $ac_res" >&5
21717echo "${ECHO_T}$ac_res" >&6; }
21718if test `eval echo '${'$as_ac_var'}'` = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021719 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000021720#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021721_ACEOF
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021722
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021723fi
Thomas Wouters3a584202000-08-05 23:28:51 +000021724done
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021725
Michael W. Hudson54241132001-12-07 15:38:26 +000021726
Guido van Rossuma96f0ba1999-03-22 21:49:51 +000021727fi
21728
Michael W. Hudson54241132001-12-07 15:38:26 +000021729
21730
21731
21732
21733
21734
Guido van Rossum627b2d71993-12-24 10:39:16 +000021735# checks for system services
21736# (none yet)
21737
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021738# Linux requires this for correct f.p. operations
Ronald Oussoren450d5612009-06-08 21:12:41 +000021739{ echo "$as_me:$LINENO: checking for __fpu_control" >&5
21740echo $ECHO_N "checking for __fpu_control... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021741if test "${ac_cv_func___fpu_control+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000021742 echo $ECHO_N "(cached) $ECHO_C" >&6
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021743else
Martin v. Löwis11437992002-04-12 09:54:03 +000021744 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021745/* confdefs.h. */
21746_ACEOF
21747cat confdefs.h >>conftest.$ac_ext
21748cat >>conftest.$ac_ext <<_ACEOF
21749/* end confdefs.h. */
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021750/* Define __fpu_control to an innocuous variant, in case <limits.h> declares __fpu_control.
21751 For example, HP-UX 11i <limits.h> declares gettimeofday. */
21752#define __fpu_control innocuous___fpu_control
21753
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021754/* System header to define __stub macros and hopefully few prototypes,
Skip Montanaro6dead952003-09-25 14:50:04 +000021755 which can conflict with char __fpu_control (); below.
21756 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021757 <limits.h> exists even on freestanding compilers. */
21758
21759#ifdef __STDC__
Skip Montanaro6dead952003-09-25 14:50:04 +000021760# include <limits.h>
21761#else
21762# include <assert.h>
21763#endif
Martin v. Löwis4ddc78a2006-01-29 09:53:44 +000021764
21765#undef __fpu_control
21766
Martin v. Löwiseba40652007-08-30 20:10:57 +000021767/* Override any GCC internal prototype to avoid an error.
21768 Use char because int might match the return type of a GCC
21769 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021770#ifdef __cplusplus
21771extern "C"
21772#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000021773char __fpu_control ();
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021774/* The GNU C library defines this for functions which it implements
21775 to always fail with ENOSYS. Some functions are actually named
21776 something starting with __ and the normal name is an alias. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000021777#if defined __stub___fpu_control || defined __stub_____fpu_control
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021778choke me
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021779#endif
21780
Skip Montanaro6dead952003-09-25 14:50:04 +000021781int
21782main ()
21783{
Martin v. Löwiseba40652007-08-30 20:10:57 +000021784return __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000021785 ;
21786 return 0;
21787}
21788_ACEOF
21789rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021790if { (ac_try="$ac_link"
21791case "(($ac_try" in
21792 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21793 *) ac_try_echo=$ac_try;;
21794esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021795eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021796 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021797 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021798 grep -v '^ *+' conftest.er1 >conftest.err
21799 rm -f conftest.er1
21800 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021801 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021802 (exit $ac_status); } && {
21803 test -z "$ac_c_werror_flag" ||
21804 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000021805 } && test -s conftest$ac_exeext &&
21806 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021807 ac_cv_func___fpu_control=yes
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021808else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021809 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021810sed 's/^/| /' conftest.$ac_ext >&5
21811
Martin v. Löwiseba40652007-08-30 20:10:57 +000021812 ac_cv_func___fpu_control=no
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021813fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021814
21815rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000021816 conftest$ac_exeext conftest.$ac_ext
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021817fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000021818{ echo "$as_me:$LINENO: result: $ac_cv_func___fpu_control" >&5
21819echo "${ECHO_T}$ac_cv_func___fpu_control" >&6; }
21820if test $ac_cv_func___fpu_control = yes; then
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021821 :
21822else
Martin v. Löwis11437992002-04-12 09:54:03 +000021823
Ronald Oussoren450d5612009-06-08 21:12:41 +000021824{ echo "$as_me:$LINENO: checking for __fpu_control in -lieee" >&5
21825echo $ECHO_N "checking for __fpu_control in -lieee... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021826if test "${ac_cv_lib_ieee___fpu_control+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000021827 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021828else
Martin v. Löwis11437992002-04-12 09:54:03 +000021829 ac_check_lib_save_LIBS=$LIBS
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000021830LIBS="-lieee $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000021831cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000021832/* confdefs.h. */
21833_ACEOF
21834cat confdefs.h >>conftest.$ac_ext
21835cat >>conftest.$ac_ext <<_ACEOF
21836/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021837
Martin v. Löwiseba40652007-08-30 20:10:57 +000021838/* Override any GCC internal prototype to avoid an error.
21839 Use char because int might match the return type of a GCC
21840 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000021841#ifdef __cplusplus
21842extern "C"
21843#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000021844char __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000021845int
21846main ()
21847{
Martin v. Löwiseba40652007-08-30 20:10:57 +000021848return __fpu_control ();
Martin v. Löwis11437992002-04-12 09:54:03 +000021849 ;
21850 return 0;
21851}
21852_ACEOF
21853rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000021854if { (ac_try="$ac_link"
21855case "(($ac_try" in
21856 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21857 *) ac_try_echo=$ac_try;;
21858esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021859eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021860 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000021861 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000021862 grep -v '^ *+' conftest.er1 >conftest.err
21863 rm -f conftest.er1
21864 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000021865 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000021866 (exit $ac_status); } && {
21867 test -z "$ac_c_werror_flag" ||
21868 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000021869 } && test -s conftest$ac_exeext &&
21870 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021871 ac_cv_lib_ieee___fpu_control=yes
Guido van Rossum627b2d71993-12-24 10:39:16 +000021872else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021873 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000021874sed 's/^/| /' conftest.$ac_ext >&5
21875
Martin v. Löwiseba40652007-08-30 20:10:57 +000021876 ac_cv_lib_ieee___fpu_control=no
Guido van Rossum627b2d71993-12-24 10:39:16 +000021877fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000021878
21879rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000021880 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000021881LIBS=$ac_check_lib_save_LIBS
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021882fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000021883{ echo "$as_me:$LINENO: result: $ac_cv_lib_ieee___fpu_control" >&5
21884echo "${ECHO_T}$ac_cv_lib_ieee___fpu_control" >&6; }
21885if test $ac_cv_lib_ieee___fpu_control = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000021886 cat >>confdefs.h <<_ACEOF
21887#define HAVE_LIBIEEE 1
21888_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021889
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000021890 LIBS="-lieee $LIBS"
Guido van Rossum76be6ed1995-01-02 18:33:54 +000021891
Guido van Rossum627b2d71993-12-24 10:39:16 +000021892fi
21893
Michael W. Hudson54241132001-12-07 15:38:26 +000021894
Jeremy Hyltonbe28f5b2000-07-27 21:03:04 +000021895fi
21896
Michael W. Hudson54241132001-12-07 15:38:26 +000021897
Guido van Rossum7f253911997-05-09 02:42:48 +000021898# Check for --with-fpectl
Ronald Oussoren450d5612009-06-08 21:12:41 +000021899{ echo "$as_me:$LINENO: checking for --with-fpectl" >&5
21900echo $ECHO_N "checking for --with-fpectl... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021901
Martin v. Löwiseba40652007-08-30 20:10:57 +000021902# Check whether --with-fpectl was given.
Guido van Rossum7f253911997-05-09 02:42:48 +000021903if test "${with_fpectl+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000021904 withval=$with_fpectl;
Guido van Rossum7f253911997-05-09 02:42:48 +000021905if test "$withval" != no
Martin v. Löwis11437992002-04-12 09:54:03 +000021906then
21907
21908cat >>confdefs.h <<\_ACEOF
Guido van Rossum7f253911997-05-09 02:42:48 +000021909#define WANT_SIGFPE_HANDLER 1
Martin v. Löwis11437992002-04-12 09:54:03 +000021910_ACEOF
21911
Ronald Oussoren450d5612009-06-08 21:12:41 +000021912 { echo "$as_me:$LINENO: result: yes" >&5
21913echo "${ECHO_T}yes" >&6; }
21914else { echo "$as_me:$LINENO: result: no" >&5
21915echo "${ECHO_T}no" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000021916fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000021917else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021918 { echo "$as_me:$LINENO: result: no" >&5
21919echo "${ECHO_T}no" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000021920fi
21921
Guido van Rossum7f253911997-05-09 02:42:48 +000021922
Guido van Rossum7f43da71994-08-01 12:15:30 +000021923# check for --with-libm=...
21924
Guido van Rossum563e7081996-09-10 18:20:48 +000021925case $ac_sys_system in
Guido van Rossum3dc0a512000-10-05 18:00:06 +000021926Darwin) ;;
Guido van Rossumec95c7b1998-08-04 17:59:56 +000021927BeOS) ;;
Guido van Rossum563e7081996-09-10 18:20:48 +000021928*) LIBM=-lm
21929esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000021930{ echo "$as_me:$LINENO: checking for --with-libm=STRING" >&5
21931echo $ECHO_N "checking for --with-libm=STRING... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021932
Martin v. Löwiseba40652007-08-30 20:10:57 +000021933# Check whether --with-libm was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000021934if test "${with_libm+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000021935 withval=$with_libm;
Guido van Rossum7f253911997-05-09 02:42:48 +000021936if test "$withval" = no
21937then LIBM=
Ronald Oussoren450d5612009-06-08 21:12:41 +000021938 { echo "$as_me:$LINENO: result: force LIBM empty" >&5
21939echo "${ECHO_T}force LIBM empty" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000021940elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000021941then LIBM=$withval
Ronald Oussoren450d5612009-06-08 21:12:41 +000021942 { echo "$as_me:$LINENO: result: set LIBM=\"$withval\"" >&5
21943echo "${ECHO_T}set LIBM=\"$withval\"" >&6; }
21944else { { echo "$as_me:$LINENO: error: proper usage is --with-libm=STRING" >&5
21945echo "$as_me: error: proper usage is --with-libm=STRING" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000021946 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000021947fi
Guido van Rossum7f253911997-05-09 02:42:48 +000021948else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021949 { echo "$as_me:$LINENO: result: default LIBM=\"$LIBM\"" >&5
21950echo "${ECHO_T}default LIBM=\"$LIBM\"" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000021951fi
21952
Guido van Rossum7f43da71994-08-01 12:15:30 +000021953
21954# check for --with-libc=...
21955
Ronald Oussoren450d5612009-06-08 21:12:41 +000021956{ echo "$as_me:$LINENO: checking for --with-libc=STRING" >&5
21957echo $ECHO_N "checking for --with-libc=STRING... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000021958
Martin v. Löwiseba40652007-08-30 20:10:57 +000021959# Check whether --with-libc was given.
Guido van Rossum48bdbfc1996-05-28 22:53:48 +000021960if test "${with_libc+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000021961 withval=$with_libc;
Guido van Rossum7f253911997-05-09 02:42:48 +000021962if test "$withval" = no
21963then LIBC=
Ronald Oussoren450d5612009-06-08 21:12:41 +000021964 { echo "$as_me:$LINENO: result: force LIBC empty" >&5
21965echo "${ECHO_T}force LIBC empty" >&6; }
Guido van Rossum7f253911997-05-09 02:42:48 +000021966elif test "$withval" != yes
Guido van Rossum7f43da71994-08-01 12:15:30 +000021967then LIBC=$withval
Ronald Oussoren450d5612009-06-08 21:12:41 +000021968 { echo "$as_me:$LINENO: result: set LIBC=\"$withval\"" >&5
21969echo "${ECHO_T}set LIBC=\"$withval\"" >&6; }
21970else { { echo "$as_me:$LINENO: error: proper usage is --with-libc=STRING" >&5
21971echo "$as_me: error: proper usage is --with-libc=STRING" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000021972 { (exit 1); exit 1; }; }
Guido van Rossum7f43da71994-08-01 12:15:30 +000021973fi
Guido van Rossum7f253911997-05-09 02:42:48 +000021974else
Ronald Oussoren450d5612009-06-08 21:12:41 +000021975 { echo "$as_me:$LINENO: result: default LIBC=\"$LIBC\"" >&5
21976echo "${ECHO_T}default LIBC=\"$LIBC\"" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000021977fi
21978
Guido van Rossum7f43da71994-08-01 12:15:30 +000021979
Christian Heimes0a8143f2007-12-18 23:22:54 +000021980# ************************************
21981# * Check for mathematical functions *
21982# ************************************
Mark Dickinson265d7382008-04-21 22:32:24 +000021983
Mark Dickinson7a3d8642008-04-22 00:54:27 +000021984LIBS_SAVE=$LIBS
21985LIBS="$LIBS $LIBM"
21986
Mark Dickinson04b27232009-01-04 12:29:36 +000021987# Detect whether system arithmetic is subject to x87-style double
21988# rounding issues. The result of this test has little meaning on non
21989# IEEE 754 platforms. On IEEE 754, test should return 1 if rounding
21990# mode is round-to-nearest and double rounding issues are present, and
21991# 0 otherwise. See http://bugs.python.org/issue2937 for more info.
Ronald Oussoren450d5612009-06-08 21:12:41 +000021992{ echo "$as_me:$LINENO: checking for x87-style double rounding" >&5
21993echo $ECHO_N "checking for x87-style double rounding... $ECHO_C" >&6; }
Mark Dickinson04b27232009-01-04 12:29:36 +000021994if test "${ac_cv_x87_double_rounding+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000021995 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinson04b27232009-01-04 12:29:36 +000021996else
21997
21998if test "$cross_compiling" = yes; then
21999 ac_cv_x87_double_rounding=no
22000else
22001 cat >conftest.$ac_ext <<_ACEOF
22002/* confdefs.h. */
22003_ACEOF
22004cat confdefs.h >>conftest.$ac_ext
22005cat >>conftest.$ac_ext <<_ACEOF
22006/* end confdefs.h. */
22007
22008#include <stdlib.h>
22009#include <math.h>
22010int main() {
22011 volatile double x, y, z;
22012 /* 1./(1-2**-53) -> 1+2**-52 (correct), 1.0 (double rounding) */
22013 x = 0.99999999999999989; /* 1-2**-53 */
22014 y = 1./x;
22015 if (y != 1.)
22016 exit(0);
22017 /* 1e16+2.99999 -> 1e16+2. (correct), 1e16+4. (double rounding) */
22018 x = 1e16;
22019 y = 2.99999;
22020 z = x + y;
22021 if (z != 1e16+4.)
22022 exit(0);
22023 /* both tests show evidence of double rounding */
22024 exit(1);
22025}
22026
22027_ACEOF
22028rm -f conftest$ac_exeext
22029if { (ac_try="$ac_link"
22030case "(($ac_try" in
22031 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22032 *) ac_try_echo=$ac_try;;
22033esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022034eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022035 (eval "$ac_link") 2>&5
22036 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022037 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022038 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22039 { (case "(($ac_try" in
22040 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22041 *) ac_try_echo=$ac_try;;
22042esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022043eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022044 (eval "$ac_try") 2>&5
22045 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022046 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022047 (exit $ac_status); }; }; then
22048 ac_cv_x87_double_rounding=no
22049else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022050 echo "$as_me: program exited with status $ac_status" >&5
22051echo "$as_me: failed program was:" >&5
Mark Dickinson04b27232009-01-04 12:29:36 +000022052sed 's/^/| /' conftest.$ac_ext >&5
22053
22054( exit $ac_status )
22055ac_cv_x87_double_rounding=yes
22056fi
22057rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22058fi
22059
22060
22061fi
22062
Ronald Oussoren450d5612009-06-08 21:12:41 +000022063{ echo "$as_me:$LINENO: result: $ac_cv_x87_double_rounding" >&5
22064echo "${ECHO_T}$ac_cv_x87_double_rounding" >&6; }
Mark Dickinson04b27232009-01-04 12:29:36 +000022065if test "$ac_cv_x87_double_rounding" = yes
22066then
22067
22068cat >>confdefs.h <<\_ACEOF
22069#define X87_DOUBLE_ROUNDING 1
22070_ACEOF
22071
22072fi
22073
Jesse Noller355b1262009-04-02 00:03:28 +000022074# Multiprocessing check for broken sem_getvalue
Ronald Oussoren450d5612009-06-08 21:12:41 +000022075{ echo "$as_me:$LINENO: checking for broken sem_getvalue" >&5
22076echo $ECHO_N "checking for broken sem_getvalue... $ECHO_C" >&6; }
Jesse Noller355b1262009-04-02 00:03:28 +000022077if test "$cross_compiling" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022078 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Jesse Noller355b1262009-04-02 00:03:28 +000022079See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022080echo "$as_me: error: cannot run test program while cross compiling
Jesse Noller355b1262009-04-02 00:03:28 +000022081See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000022082 { (exit 1); exit 1; }; }
Jesse Noller355b1262009-04-02 00:03:28 +000022083else
22084 cat >conftest.$ac_ext <<_ACEOF
22085/* confdefs.h. */
22086_ACEOF
22087cat confdefs.h >>conftest.$ac_ext
22088cat >>conftest.$ac_ext <<_ACEOF
22089/* end confdefs.h. */
22090
22091#include <unistd.h>
22092#include <fcntl.h>
22093#include <stdio.h>
22094#include <semaphore.h>
22095#include <sys/stat.h>
22096
22097int main(void){
22098 sem_t *a = sem_open("/autoconf", O_CREAT, S_IRUSR|S_IWUSR, 0);
22099 int count;
22100 int res;
22101 if(a==SEM_FAILED){
22102 perror("sem_open");
22103 return 1;
22104
22105 }
22106 res = sem_getvalue(a, &count);
22107 sem_close(a);
22108 return res==-1 ? 1 : 0;
22109}
22110
22111
22112_ACEOF
22113rm -f conftest$ac_exeext
22114if { (ac_try="$ac_link"
22115case "(($ac_try" in
22116 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22117 *) ac_try_echo=$ac_try;;
22118esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022119eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022120 (eval "$ac_link") 2>&5
22121 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022122 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022123 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22124 { (case "(($ac_try" in
22125 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22126 *) ac_try_echo=$ac_try;;
22127esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022128eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022129 (eval "$ac_try") 2>&5
22130 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022131 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022132 (exit $ac_status); }; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022133 { echo "$as_me:$LINENO: result: no" >&5
22134echo "${ECHO_T}no" >&6; }
Jesse Noller355b1262009-04-02 00:03:28 +000022135else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022136 echo "$as_me: program exited with status $ac_status" >&5
22137echo "$as_me: failed program was:" >&5
Jesse Noller355b1262009-04-02 00:03:28 +000022138sed 's/^/| /' conftest.$ac_ext >&5
22139
22140( exit $ac_status )
Ronald Oussoren450d5612009-06-08 21:12:41 +000022141{ echo "$as_me:$LINENO: result: yes" >&5
22142echo "${ECHO_T}yes" >&6; }
Jesse Noller355b1262009-04-02 00:03:28 +000022143
22144cat >>confdefs.h <<\_ACEOF
22145#define HAVE_BROKEN_SEM_GETVALUE 1
22146_ACEOF
22147
22148
22149fi
22150rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22151fi
22152
22153
Mark Dickinson04b27232009-01-04 12:29:36 +000022154
Mark Dickinson265d7382008-04-21 22:32:24 +000022155# On FreeBSD 6.2, it appears that tanh(-0.) returns 0. instead of
22156# -0. on some architectures.
Ronald Oussoren450d5612009-06-08 21:12:41 +000022157{ echo "$as_me:$LINENO: checking whether tanh preserves the sign of zero" >&5
22158echo $ECHO_N "checking whether tanh preserves the sign of zero... $ECHO_C" >&6; }
Mark Dickinson265d7382008-04-21 22:32:24 +000022159if test "${ac_cv_tanh_preserves_zero_sign+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022160 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinson265d7382008-04-21 22:32:24 +000022161else
22162
22163if test "$cross_compiling" = yes; then
22164 ac_cv_tanh_preserves_zero_sign=no
22165else
22166 cat >conftest.$ac_ext <<_ACEOF
22167/* confdefs.h. */
22168_ACEOF
22169cat confdefs.h >>conftest.$ac_ext
22170cat >>conftest.$ac_ext <<_ACEOF
22171/* end confdefs.h. */
22172
22173#include <math.h>
Mark Dickinson7a3d8642008-04-22 00:54:27 +000022174#include <stdlib.h>
Mark Dickinson265d7382008-04-21 22:32:24 +000022175int main() {
22176 /* return 0 if either negative zeros don't exist
22177 on this platform or if negative zeros exist
22178 and tanh(-0.) == -0. */
22179 if (atan2(0., -1.) == atan2(-0., -1.) ||
22180 atan2(tanh(-0.), -1.) == atan2(-0., -1.)) exit(0);
22181 else exit(1);
22182}
22183
22184_ACEOF
22185rm -f conftest$ac_exeext
22186if { (ac_try="$ac_link"
22187case "(($ac_try" in
22188 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22189 *) ac_try_echo=$ac_try;;
22190esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022191eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022192 (eval "$ac_link") 2>&5
22193 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022194 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022195 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22196 { (case "(($ac_try" in
22197 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22198 *) ac_try_echo=$ac_try;;
22199esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022200eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022201 (eval "$ac_try") 2>&5
22202 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022203 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022204 (exit $ac_status); }; }; then
22205 ac_cv_tanh_preserves_zero_sign=yes
22206else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022207 echo "$as_me: program exited with status $ac_status" >&5
22208echo "$as_me: failed program was:" >&5
Mark Dickinson265d7382008-04-21 22:32:24 +000022209sed 's/^/| /' conftest.$ac_ext >&5
22210
22211( exit $ac_status )
22212ac_cv_tanh_preserves_zero_sign=no
22213fi
22214rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22215fi
22216
22217
22218fi
22219
Ronald Oussoren450d5612009-06-08 21:12:41 +000022220{ echo "$as_me:$LINENO: result: $ac_cv_tanh_preserves_zero_sign" >&5
22221echo "${ECHO_T}$ac_cv_tanh_preserves_zero_sign" >&6; }
Mark Dickinson265d7382008-04-21 22:32:24 +000022222if test "$ac_cv_tanh_preserves_zero_sign" = yes
22223then
22224
22225cat >>confdefs.h <<\_ACEOF
22226#define TANH_PRESERVES_ZERO_SIGN 1
22227_ACEOF
22228
22229fi
22230
Martin v. Löwis11437992002-04-12 09:54:03 +000022231
Guido van Rossum2b3ac691996-08-30 15:18:41 +000022232
Michael W. Hudson54241132001-12-07 15:38:26 +000022233
Christian Heimes0a8143f2007-12-18 23:22:54 +000022234
22235
22236
22237
22238
Mark Dickinson8e5446f2009-04-18 14:41:37 +000022239
22240for ac_func in acosh asinh atanh copysign expm1 finite hypot log1p round
Christian Heimes0a8143f2007-12-18 23:22:54 +000022241do
Ronald Oussoren450d5612009-06-08 21:12:41 +000022242as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22243{ echo "$as_me:$LINENO: checking for $ac_func" >&5
22244echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
Christian Heimes0a8143f2007-12-18 23:22:54 +000022245if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022246 echo $ECHO_N "(cached) $ECHO_C" >&6
Christian Heimes0a8143f2007-12-18 23:22:54 +000022247else
22248 cat >conftest.$ac_ext <<_ACEOF
22249/* confdefs.h. */
22250_ACEOF
22251cat confdefs.h >>conftest.$ac_ext
22252cat >>conftest.$ac_ext <<_ACEOF
22253/* end confdefs.h. */
22254/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22255 For example, HP-UX 11i <limits.h> declares gettimeofday. */
22256#define $ac_func innocuous_$ac_func
22257
22258/* System header to define __stub macros and hopefully few prototypes,
22259 which can conflict with char $ac_func (); below.
22260 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22261 <limits.h> exists even on freestanding compilers. */
22262
22263#ifdef __STDC__
22264# include <limits.h>
22265#else
22266# include <assert.h>
22267#endif
22268
22269#undef $ac_func
22270
22271/* Override any GCC internal prototype to avoid an error.
22272 Use char because int might match the return type of a GCC
22273 builtin and then its argument prototype would still apply. */
22274#ifdef __cplusplus
22275extern "C"
22276#endif
22277char $ac_func ();
22278/* The GNU C library defines this for functions which it implements
22279 to always fail with ENOSYS. Some functions are actually named
22280 something starting with __ and the normal name is an alias. */
22281#if defined __stub_$ac_func || defined __stub___$ac_func
22282choke me
22283#endif
22284
22285int
22286main ()
22287{
22288return $ac_func ();
22289 ;
22290 return 0;
22291}
22292_ACEOF
22293rm -f conftest.$ac_objext conftest$ac_exeext
22294if { (ac_try="$ac_link"
22295case "(($ac_try" in
22296 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22297 *) ac_try_echo=$ac_try;;
22298esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022299eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Christian Heimes0a8143f2007-12-18 23:22:54 +000022300 (eval "$ac_link") 2>conftest.er1
22301 ac_status=$?
22302 grep -v '^ *+' conftest.er1 >conftest.err
22303 rm -f conftest.er1
22304 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022305 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Christian Heimes0a8143f2007-12-18 23:22:54 +000022306 (exit $ac_status); } && {
22307 test -z "$ac_c_werror_flag" ||
22308 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000022309 } && test -s conftest$ac_exeext &&
22310 $as_test_x conftest$ac_exeext; then
Christian Heimes0a8143f2007-12-18 23:22:54 +000022311 eval "$as_ac_var=yes"
22312else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022313 echo "$as_me: failed program was:" >&5
Christian Heimes0a8143f2007-12-18 23:22:54 +000022314sed 's/^/| /' conftest.$ac_ext >&5
22315
22316 eval "$as_ac_var=no"
22317fi
22318
22319rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22320 conftest$ac_exeext conftest.$ac_ext
22321fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022322ac_res=`eval echo '${'$as_ac_var'}'`
22323 { echo "$as_me:$LINENO: result: $ac_res" >&5
22324echo "${ECHO_T}$ac_res" >&6; }
22325if test `eval echo '${'$as_ac_var'}'` = yes; then
Christian Heimes0a8143f2007-12-18 23:22:54 +000022326 cat >>confdefs.h <<_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000022327#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
Christian Heimes0a8143f2007-12-18 23:22:54 +000022328_ACEOF
22329
22330fi
22331done
22332
Ronald Oussoren450d5612009-06-08 21:12:41 +000022333{ echo "$as_me:$LINENO: checking whether isinf is declared" >&5
22334echo $ECHO_N "checking whether isinf is declared... $ECHO_C" >&6; }
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022335if test "${ac_cv_have_decl_isinf+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022336 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022337else
22338 cat >conftest.$ac_ext <<_ACEOF
22339/* confdefs.h. */
22340_ACEOF
22341cat confdefs.h >>conftest.$ac_ext
22342cat >>conftest.$ac_ext <<_ACEOF
22343/* end confdefs.h. */
22344#include <math.h>
22345
22346int
22347main ()
22348{
22349#ifndef isinf
22350 (void) isinf;
22351#endif
22352
22353 ;
22354 return 0;
22355}
22356_ACEOF
22357rm -f conftest.$ac_objext
22358if { (ac_try="$ac_compile"
22359case "(($ac_try" in
22360 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22361 *) ac_try_echo=$ac_try;;
22362esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022363eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022364 (eval "$ac_compile") 2>conftest.er1
22365 ac_status=$?
22366 grep -v '^ *+' conftest.er1 >conftest.err
22367 rm -f conftest.er1
22368 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022369 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022370 (exit $ac_status); } && {
22371 test -z "$ac_c_werror_flag" ||
22372 test ! -s conftest.err
22373 } && test -s conftest.$ac_objext; then
22374 ac_cv_have_decl_isinf=yes
22375else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022376 echo "$as_me: failed program was:" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022377sed 's/^/| /' conftest.$ac_ext >&5
22378
22379 ac_cv_have_decl_isinf=no
22380fi
22381
22382rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22383fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022384{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_isinf" >&5
22385echo "${ECHO_T}$ac_cv_have_decl_isinf" >&6; }
22386if test $ac_cv_have_decl_isinf = yes; then
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022387
22388cat >>confdefs.h <<_ACEOF
22389#define HAVE_DECL_ISINF 1
22390_ACEOF
22391
22392
22393else
22394 cat >>confdefs.h <<_ACEOF
22395#define HAVE_DECL_ISINF 0
22396_ACEOF
22397
22398
22399fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022400{ echo "$as_me:$LINENO: checking whether isnan is declared" >&5
22401echo $ECHO_N "checking whether isnan is declared... $ECHO_C" >&6; }
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022402if test "${ac_cv_have_decl_isnan+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022403 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022404else
22405 cat >conftest.$ac_ext <<_ACEOF
22406/* confdefs.h. */
22407_ACEOF
22408cat confdefs.h >>conftest.$ac_ext
22409cat >>conftest.$ac_ext <<_ACEOF
22410/* end confdefs.h. */
22411#include <math.h>
22412
22413int
22414main ()
22415{
22416#ifndef isnan
22417 (void) isnan;
22418#endif
22419
22420 ;
22421 return 0;
22422}
22423_ACEOF
22424rm -f conftest.$ac_objext
22425if { (ac_try="$ac_compile"
22426case "(($ac_try" in
22427 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22428 *) ac_try_echo=$ac_try;;
22429esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022430eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022431 (eval "$ac_compile") 2>conftest.er1
22432 ac_status=$?
22433 grep -v '^ *+' conftest.er1 >conftest.err
22434 rm -f conftest.er1
22435 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022436 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022437 (exit $ac_status); } && {
22438 test -z "$ac_c_werror_flag" ||
22439 test ! -s conftest.err
22440 } && test -s conftest.$ac_objext; then
22441 ac_cv_have_decl_isnan=yes
22442else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022443 echo "$as_me: failed program was:" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022444sed 's/^/| /' conftest.$ac_ext >&5
22445
22446 ac_cv_have_decl_isnan=no
22447fi
22448
22449rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22450fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022451{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_isnan" >&5
22452echo "${ECHO_T}$ac_cv_have_decl_isnan" >&6; }
22453if test $ac_cv_have_decl_isnan = yes; then
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022454
22455cat >>confdefs.h <<_ACEOF
22456#define HAVE_DECL_ISNAN 1
22457_ACEOF
22458
22459
22460else
22461 cat >>confdefs.h <<_ACEOF
22462#define HAVE_DECL_ISNAN 0
22463_ACEOF
22464
22465
22466fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022467{ echo "$as_me:$LINENO: checking whether isfinite is declared" >&5
22468echo $ECHO_N "checking whether isfinite is declared... $ECHO_C" >&6; }
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022469if test "${ac_cv_have_decl_isfinite+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022470 echo $ECHO_N "(cached) $ECHO_C" >&6
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022471else
22472 cat >conftest.$ac_ext <<_ACEOF
22473/* confdefs.h. */
22474_ACEOF
22475cat confdefs.h >>conftest.$ac_ext
22476cat >>conftest.$ac_ext <<_ACEOF
22477/* end confdefs.h. */
22478#include <math.h>
22479
22480int
22481main ()
22482{
22483#ifndef isfinite
22484 (void) isfinite;
22485#endif
22486
22487 ;
22488 return 0;
22489}
22490_ACEOF
22491rm -f conftest.$ac_objext
22492if { (ac_try="$ac_compile"
22493case "(($ac_try" in
22494 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22495 *) ac_try_echo=$ac_try;;
22496esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022497eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022498 (eval "$ac_compile") 2>conftest.er1
22499 ac_status=$?
22500 grep -v '^ *+' conftest.er1 >conftest.err
22501 rm -f conftest.er1
22502 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022503 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022504 (exit $ac_status); } && {
22505 test -z "$ac_c_werror_flag" ||
22506 test ! -s conftest.err
22507 } && test -s conftest.$ac_objext; then
22508 ac_cv_have_decl_isfinite=yes
22509else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022510 echo "$as_me: failed program was:" >&5
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022511sed 's/^/| /' conftest.$ac_ext >&5
22512
22513 ac_cv_have_decl_isfinite=no
22514fi
22515
22516rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22517fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022518{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_isfinite" >&5
22519echo "${ECHO_T}$ac_cv_have_decl_isfinite" >&6; }
22520if test $ac_cv_have_decl_isfinite = yes; then
Mark Dickinsond181e3a2009-01-04 13:57:26 +000022521
22522cat >>confdefs.h <<_ACEOF
22523#define HAVE_DECL_ISFINITE 1
22524_ACEOF
22525
22526
22527else
22528 cat >>confdefs.h <<_ACEOF
22529#define HAVE_DECL_ISFINITE 0
22530_ACEOF
22531
22532
22533fi
22534
22535
Christian Heimes0a8143f2007-12-18 23:22:54 +000022536
Guido van Rossumaf5b83e1995-01-04 19:02:35 +000022537LIBS=$LIBS_SAVE
22538
Mark Dickinsonefc82f72009-03-20 15:51:55 +000022539# determine what size digit to use for Python's longs
Ronald Oussoren450d5612009-06-08 21:12:41 +000022540{ echo "$as_me:$LINENO: checking digit size for Python's longs" >&5
22541echo $ECHO_N "checking digit size for Python's longs... $ECHO_C" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +000022542# Check whether --enable-big-digits was given.
22543if test "${enable_big_digits+set}" = set; then
22544 enableval=$enable_big_digits; case $enable_big_digits in
22545yes)
22546 enable_big_digits=30 ;;
22547no)
22548 enable_big_digits=15 ;;
2254915|30)
22550 ;;
22551*)
Ronald Oussoren450d5612009-06-08 21:12:41 +000022552 { { echo "$as_me:$LINENO: error: bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" >&5
22553echo "$as_me: error: bad value $enable_big_digits for --enable-big-digits; value should be 15 or 30" >&2;}
Mark Dickinsonefc82f72009-03-20 15:51:55 +000022554 { (exit 1); exit 1; }; } ;;
22555esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022556{ echo "$as_me:$LINENO: result: $enable_big_digits" >&5
22557echo "${ECHO_T}$enable_big_digits" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +000022558
22559cat >>confdefs.h <<_ACEOF
22560#define PYLONG_BITS_IN_DIGIT $enable_big_digits
22561_ACEOF
22562
22563
22564else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022565 { echo "$as_me:$LINENO: result: no value specified" >&5
22566echo "${ECHO_T}no value specified" >&6; }
Mark Dickinsonefc82f72009-03-20 15:51:55 +000022567fi
22568
22569
Guido van Rossumef2255b2000-03-10 22:30:29 +000022570# check for wchar.h
Martin v. Löwis11437992002-04-12 09:54:03 +000022571if test "${ac_cv_header_wchar_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022572 { echo "$as_me:$LINENO: checking for wchar.h" >&5
22573echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022574if test "${ac_cv_header_wchar_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022575 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000022576fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022577{ echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
22578echo "${ECHO_T}$ac_cv_header_wchar_h" >&6; }
Guido van Rossumef2255b2000-03-10 22:30:29 +000022579else
Martin v. Löwis11437992002-04-12 09:54:03 +000022580 # Is the header compilable?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022581{ echo "$as_me:$LINENO: checking wchar.h usability" >&5
22582echo $ECHO_N "checking wchar.h usability... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022583cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022584/* confdefs.h. */
22585_ACEOF
22586cat confdefs.h >>conftest.$ac_ext
22587cat >>conftest.$ac_ext <<_ACEOF
22588/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022589$ac_includes_default
22590#include <wchar.h>
22591_ACEOF
22592rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022593if { (ac_try="$ac_compile"
22594case "(($ac_try" in
22595 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22596 *) ac_try_echo=$ac_try;;
22597esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022598eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022599 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022600 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022601 grep -v '^ *+' conftest.er1 >conftest.err
22602 rm -f conftest.er1
22603 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022605 (exit $ac_status); } && {
22606 test -z "$ac_c_werror_flag" ||
22607 test ! -s conftest.err
22608 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022609 ac_header_compiler=yes
22610else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022611 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022612sed 's/^/| /' conftest.$ac_ext >&5
22613
Martin v. Löwiseba40652007-08-30 20:10:57 +000022614 ac_header_compiler=no
Martin v. Löwis11437992002-04-12 09:54:03 +000022615fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022616
22617rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000022618{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22619echo "${ECHO_T}$ac_header_compiler" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022620
22621# Is the header present?
Ronald Oussoren450d5612009-06-08 21:12:41 +000022622{ echo "$as_me:$LINENO: checking wchar.h presence" >&5
22623echo $ECHO_N "checking wchar.h presence... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022624cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022625/* confdefs.h. */
22626_ACEOF
22627cat confdefs.h >>conftest.$ac_ext
22628cat >>conftest.$ac_ext <<_ACEOF
22629/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000022630#include <wchar.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000022631_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000022632if { (ac_try="$ac_cpp conftest.$ac_ext"
22633case "(($ac_try" in
22634 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22635 *) ac_try_echo=$ac_try;;
22636esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022637eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022638 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022639 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000022640 grep -v '^ *+' conftest.er1 >conftest.err
Martin v. Löwis11437992002-04-12 09:54:03 +000022641 rm -f conftest.er1
22642 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022643 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022644 (exit $ac_status); } >/dev/null && {
22645 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22646 test ! -s conftest.err
22647 }; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022648 ac_header_preproc=yes
22649else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022650 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022651sed 's/^/| /' conftest.$ac_ext >&5
22652
Martin v. Löwis11437992002-04-12 09:54:03 +000022653 ac_header_preproc=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000022654fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022655
Martin v. Löwis11437992002-04-12 09:54:03 +000022656rm -f conftest.err conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000022657{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22658echo "${ECHO_T}$ac_header_preproc" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022659
22660# So? What about this header?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022661case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22662 yes:no: )
Ronald Oussoren450d5612009-06-08 21:12:41 +000022663 { echo "$as_me:$LINENO: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&5
22664echo "$as_me: WARNING: wchar.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22665 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the compiler's result" >&5
22666echo "$as_me: WARNING: wchar.h: proceeding with the compiler's result" >&2;}
Skip Montanarof0d5f792004-08-15 14:08:23 +000022667 ac_header_preproc=yes
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000022668 ;;
Skip Montanarof0d5f792004-08-15 14:08:23 +000022669 no:yes:* )
Ronald Oussoren450d5612009-06-08 21:12:41 +000022670 { echo "$as_me:$LINENO: WARNING: wchar.h: present but cannot be compiled" >&5
22671echo "$as_me: WARNING: wchar.h: present but cannot be compiled" >&2;}
22672 { echo "$as_me:$LINENO: WARNING: wchar.h: check for missing prerequisite headers?" >&5
22673echo "$as_me: WARNING: wchar.h: check for missing prerequisite headers?" >&2;}
22674 { echo "$as_me:$LINENO: WARNING: wchar.h: see the Autoconf documentation" >&5
22675echo "$as_me: WARNING: wchar.h: see the Autoconf documentation" >&2;}
22676 { echo "$as_me:$LINENO: WARNING: wchar.h: section \"Present But Cannot Be Compiled\"" >&5
22677echo "$as_me: WARNING: wchar.h: section \"Present But Cannot Be Compiled\"" >&2;}
22678 { echo "$as_me:$LINENO: WARNING: wchar.h: proceeding with the preprocessor's result" >&5
22679echo "$as_me: WARNING: wchar.h: proceeding with the preprocessor's result" >&2;}
22680 { echo "$as_me:$LINENO: WARNING: wchar.h: in the future, the compiler will take precedence" >&5
22681echo "$as_me: WARNING: wchar.h: in the future, the compiler will take precedence" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000022682 ( cat <<\_ASBOX
Georg Brandl464432d2009-05-20 18:24:08 +000022683## -------------------------------------- ##
22684## Report this to http://bugs.python.org/ ##
22685## -------------------------------------- ##
Skip Montanaro6dead952003-09-25 14:50:04 +000022686_ASBOX
Martin v. Löwiseba40652007-08-30 20:10:57 +000022687 ) | sed "s/^/$as_me: WARNING: /" >&2
Skip Montanaro6dead952003-09-25 14:50:04 +000022688 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000022689esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022690{ echo "$as_me:$LINENO: checking for wchar.h" >&5
22691echo $ECHO_N "checking for wchar.h... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022692if test "${ac_cv_header_wchar_h+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022693 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000022694else
22695 ac_cv_header_wchar_h=$ac_header_preproc
Guido van Rossumef2255b2000-03-10 22:30:29 +000022696fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022697{ echo "$as_me:$LINENO: result: $ac_cv_header_wchar_h" >&5
22698echo "${ECHO_T}$ac_cv_header_wchar_h" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022699
22700fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000022701if test $ac_cv_header_wchar_h = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022702
22703
22704cat >>confdefs.h <<\_ACEOF
Guido van Rossumef2255b2000-03-10 22:30:29 +000022705#define HAVE_WCHAR_H 1
Martin v. Löwis11437992002-04-12 09:54:03 +000022706_ACEOF
22707
Martin v. Löwisc45929e2002-04-06 10:10:49 +000022708 wchar_h="yes"
22709
Guido van Rossumef2255b2000-03-10 22:30:29 +000022710else
Martin v. Löwis11437992002-04-12 09:54:03 +000022711 wchar_h="no"
Guido van Rossumef2255b2000-03-10 22:30:29 +000022712
22713fi
22714
Michael W. Hudson54241132001-12-07 15:38:26 +000022715
Martin v. Löwis11437992002-04-12 09:54:03 +000022716
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000022717# determine wchar_t size
22718if test "$wchar_h" = yes
22719then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022720 { echo "$as_me:$LINENO: checking for wchar_t" >&5
22721echo $ECHO_N "checking for wchar_t... $ECHO_C" >&6; }
22722if test "${ac_cv_type_wchar_t+set}" = set; then
22723 echo $ECHO_N "(cached) $ECHO_C" >&6
22724else
22725 cat >conftest.$ac_ext <<_ACEOF
22726/* confdefs.h. */
22727_ACEOF
22728cat confdefs.h >>conftest.$ac_ext
22729cat >>conftest.$ac_ext <<_ACEOF
22730/* end confdefs.h. */
22731#include <wchar.h>
22732
22733typedef wchar_t ac__type_new_;
22734int
22735main ()
22736{
22737if ((ac__type_new_ *) 0)
22738 return 0;
22739if (sizeof (ac__type_new_))
22740 return 0;
22741 ;
22742 return 0;
22743}
22744_ACEOF
22745rm -f conftest.$ac_objext
22746if { (ac_try="$ac_compile"
22747case "(($ac_try" in
22748 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22749 *) ac_try_echo=$ac_try;;
22750esac
22751eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22752 (eval "$ac_compile") 2>conftest.er1
22753 ac_status=$?
22754 grep -v '^ *+' conftest.er1 >conftest.err
22755 rm -f conftest.er1
22756 cat conftest.err >&5
22757 echo "$as_me:$LINENO: \$? = $ac_status" >&5
22758 (exit $ac_status); } && {
22759 test -z "$ac_c_werror_flag" ||
22760 test ! -s conftest.err
22761 } && test -s conftest.$ac_objext; then
22762 ac_cv_type_wchar_t=yes
22763else
22764 echo "$as_me: failed program was:" >&5
22765sed 's/^/| /' conftest.$ac_ext >&5
22766
22767 ac_cv_type_wchar_t=no
22768fi
22769
22770rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22771fi
22772{ echo "$as_me:$LINENO: result: $ac_cv_type_wchar_t" >&5
22773echo "${ECHO_T}$ac_cv_type_wchar_t" >&6; }
22774
22775# The cast to long int works around a bug in the HP C Compiler
Martin v. Löwiseba40652007-08-30 20:10:57 +000022776# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
22777# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
22778# This bug is HP SR number 8606223364.
Ronald Oussoren450d5612009-06-08 21:12:41 +000022779{ echo "$as_me:$LINENO: checking size of wchar_t" >&5
22780echo $ECHO_N "checking size of wchar_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000022781if test "${ac_cv_sizeof_wchar_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000022782 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis11437992002-04-12 09:54:03 +000022783else
Martin v. Löwis11437992002-04-12 09:54:03 +000022784 if test "$cross_compiling" = yes; then
22785 # Depending upon the size, compute the lo and hi bounds.
22786cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022787/* confdefs.h. */
22788_ACEOF
22789cat confdefs.h >>conftest.$ac_ext
22790cat >>conftest.$ac_ext <<_ACEOF
22791/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022792#include <wchar.h>
22793
Ronald Oussoren450d5612009-06-08 21:12:41 +000022794 typedef wchar_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000022795int
22796main ()
22797{
Ronald Oussoren450d5612009-06-08 21:12:41 +000022798static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000022799test_array [0] = 0
22800
22801 ;
22802 return 0;
22803}
22804_ACEOF
22805rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022806if { (ac_try="$ac_compile"
22807case "(($ac_try" in
22808 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22809 *) ac_try_echo=$ac_try;;
22810esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022811eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022812 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022813 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022814 grep -v '^ *+' conftest.er1 >conftest.err
22815 rm -f conftest.er1
22816 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022818 (exit $ac_status); } && {
22819 test -z "$ac_c_werror_flag" ||
22820 test ! -s conftest.err
22821 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022822 ac_lo=0 ac_mid=0
22823 while :; do
22824 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022825/* confdefs.h. */
22826_ACEOF
22827cat confdefs.h >>conftest.$ac_ext
22828cat >>conftest.$ac_ext <<_ACEOF
22829/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022830#include <wchar.h>
22831
Ronald Oussoren450d5612009-06-08 21:12:41 +000022832 typedef wchar_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000022833int
22834main ()
22835{
Ronald Oussoren450d5612009-06-08 21:12:41 +000022836static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000022837test_array [0] = 0
22838
22839 ;
22840 return 0;
22841}
22842_ACEOF
22843rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022844if { (ac_try="$ac_compile"
22845case "(($ac_try" in
22846 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22847 *) ac_try_echo=$ac_try;;
22848esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022849eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022850 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022851 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022852 grep -v '^ *+' conftest.er1 >conftest.err
22853 rm -f conftest.er1
22854 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022855 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022856 (exit $ac_status); } && {
22857 test -z "$ac_c_werror_flag" ||
22858 test ! -s conftest.err
22859 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022860 ac_hi=$ac_mid; break
22861else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022862 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022863sed 's/^/| /' conftest.$ac_ext >&5
22864
Martin v. Löwiseba40652007-08-30 20:10:57 +000022865 ac_lo=`expr $ac_mid + 1`
22866 if test $ac_lo -le $ac_mid; then
22867 ac_lo= ac_hi=
22868 break
22869 fi
22870 ac_mid=`expr 2 '*' $ac_mid + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000022871fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022872
22873rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022874 done
22875else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022876 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022877sed 's/^/| /' conftest.$ac_ext >&5
22878
Martin v. Löwiseba40652007-08-30 20:10:57 +000022879 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022880/* confdefs.h. */
22881_ACEOF
22882cat confdefs.h >>conftest.$ac_ext
22883cat >>conftest.$ac_ext <<_ACEOF
22884/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022885#include <wchar.h>
22886
Ronald Oussoren450d5612009-06-08 21:12:41 +000022887 typedef wchar_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000022888int
22889main ()
22890{
Ronald Oussoren450d5612009-06-08 21:12:41 +000022891static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
Martin v. Löwis11437992002-04-12 09:54:03 +000022892test_array [0] = 0
22893
22894 ;
22895 return 0;
22896}
22897_ACEOF
22898rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022899if { (ac_try="$ac_compile"
22900case "(($ac_try" in
22901 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22902 *) ac_try_echo=$ac_try;;
22903esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022904eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022905 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022906 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022907 grep -v '^ *+' conftest.er1 >conftest.err
22908 rm -f conftest.er1
22909 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022910 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022911 (exit $ac_status); } && {
22912 test -z "$ac_c_werror_flag" ||
22913 test ! -s conftest.err
22914 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022915 ac_hi=-1 ac_mid=-1
22916 while :; do
22917 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022918/* confdefs.h. */
22919_ACEOF
22920cat confdefs.h >>conftest.$ac_ext
22921cat >>conftest.$ac_ext <<_ACEOF
22922/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022923#include <wchar.h>
22924
Ronald Oussoren450d5612009-06-08 21:12:41 +000022925 typedef wchar_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000022926int
22927main ()
22928{
Ronald Oussoren450d5612009-06-08 21:12:41 +000022929static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000022930test_array [0] = 0
22931
22932 ;
22933 return 0;
22934}
22935_ACEOF
22936rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000022937if { (ac_try="$ac_compile"
22938case "(($ac_try" in
22939 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22940 *) ac_try_echo=$ac_try;;
22941esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000022942eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022943 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000022944 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000022945 grep -v '^ *+' conftest.er1 >conftest.err
22946 rm -f conftest.er1
22947 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000022948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000022949 (exit $ac_status); } && {
22950 test -z "$ac_c_werror_flag" ||
22951 test ! -s conftest.err
22952 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000022953 ac_lo=$ac_mid; break
22954else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022955 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022956sed 's/^/| /' conftest.$ac_ext >&5
22957
Martin v. Löwiseba40652007-08-30 20:10:57 +000022958 ac_hi=`expr '(' $ac_mid ')' - 1`
22959 if test $ac_mid -le $ac_hi; then
22960 ac_lo= ac_hi=
22961 break
22962 fi
22963 ac_mid=`expr 2 '*' $ac_mid`
Martin v. Löwis11437992002-04-12 09:54:03 +000022964fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022965
22966rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022967 done
22968else
Ronald Oussoren450d5612009-06-08 21:12:41 +000022969 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000022970sed 's/^/| /' conftest.$ac_ext >&5
22971
Martin v. Löwiseba40652007-08-30 20:10:57 +000022972 ac_lo= ac_hi=
Martin v. Löwis11437992002-04-12 09:54:03 +000022973fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022974
22975rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022976fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000022977
22978rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000022979# Binary search between lo and hi bounds.
22980while test "x$ac_lo" != "x$ac_hi"; do
22981 ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
22982 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000022983/* confdefs.h. */
22984_ACEOF
22985cat confdefs.h >>conftest.$ac_ext
22986cat >>conftest.$ac_ext <<_ACEOF
22987/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000022988#include <wchar.h>
22989
Ronald Oussoren450d5612009-06-08 21:12:41 +000022990 typedef wchar_t ac__type_sizeof_;
Martin v. Löwis11437992002-04-12 09:54:03 +000022991int
22992main ()
22993{
Ronald Oussoren450d5612009-06-08 21:12:41 +000022994static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
Martin v. Löwis11437992002-04-12 09:54:03 +000022995test_array [0] = 0
22996
22997 ;
22998 return 0;
22999}
23000_ACEOF
23001rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023002if { (ac_try="$ac_compile"
23003case "(($ac_try" in
23004 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23005 *) ac_try_echo=$ac_try;;
23006esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023007eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023008 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023009 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023010 grep -v '^ *+' conftest.er1 >conftest.err
23011 rm -f conftest.er1
23012 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023013 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023014 (exit $ac_status); } && {
23015 test -z "$ac_c_werror_flag" ||
23016 test ! -s conftest.err
23017 } && test -s conftest.$ac_objext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023018 ac_hi=$ac_mid
23019else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023020 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023021sed 's/^/| /' conftest.$ac_ext >&5
23022
Martin v. Löwiseba40652007-08-30 20:10:57 +000023023 ac_lo=`expr '(' $ac_mid ')' + 1`
Martin v. Löwis11437992002-04-12 09:54:03 +000023024fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023025
23026rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023027done
23028case $ac_lo in
23029?*) ac_cv_sizeof_wchar_t=$ac_lo;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000023030'') if test "$ac_cv_type_wchar_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023031 { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023032See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023033echo "$as_me: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023034See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000023035 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023036 else
23037 ac_cv_sizeof_wchar_t=0
23038 fi ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000023039esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023040else
Martin v. Löwis11437992002-04-12 09:54:03 +000023041 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023042/* confdefs.h. */
23043_ACEOF
23044cat confdefs.h >>conftest.$ac_ext
23045cat >>conftest.$ac_ext <<_ACEOF
23046/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023047#include <wchar.h>
23048
Ronald Oussoren450d5612009-06-08 21:12:41 +000023049 typedef wchar_t ac__type_sizeof_;
23050static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
23051static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
Michael W. Hudson54241132001-12-07 15:38:26 +000023052#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000023053#include <stdlib.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000023054int
23055main ()
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023056{
Martin v. Löwis11437992002-04-12 09:54:03 +000023057
23058 FILE *f = fopen ("conftest.val", "w");
23059 if (! f)
Martin v. Löwiseba40652007-08-30 20:10:57 +000023060 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000023061 if (((long int) (sizeof (ac__type_sizeof_))) < 0)
Martin v. Löwis11437992002-04-12 09:54:03 +000023062 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000023063 long int i = longval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000023064 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000023065 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000023066 fprintf (f, "%ld\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000023067 }
23068 else
23069 {
Martin v. Löwiseba40652007-08-30 20:10:57 +000023070 unsigned long int i = ulongval ();
Ronald Oussoren450d5612009-06-08 21:12:41 +000023071 if (i != ((long int) (sizeof (ac__type_sizeof_))))
Martin v. Löwiseba40652007-08-30 20:10:57 +000023072 return 1;
Ronald Oussoren450d5612009-06-08 21:12:41 +000023073 fprintf (f, "%lu\n", i);
Martin v. Löwis11437992002-04-12 09:54:03 +000023074 }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023075 return ferror (f) || fclose (f) != 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000023076
23077 ;
23078 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000023079}
Martin v. Löwis11437992002-04-12 09:54:03 +000023080_ACEOF
23081rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023082if { (ac_try="$ac_link"
23083case "(($ac_try" in
23084 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23085 *) ac_try_echo=$ac_try;;
23086esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023087eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023088 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023089 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023090 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023091 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000023092 { (case "(($ac_try" in
23093 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23094 *) ac_try_echo=$ac_try;;
23095esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023096eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023097 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023098 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023099 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023100 (exit $ac_status); }; }; then
23101 ac_cv_sizeof_wchar_t=`cat conftest.val`
Guido van Rossumef2255b2000-03-10 22:30:29 +000023102else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023103 echo "$as_me: program exited with status $ac_status" >&5
23104echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023105sed 's/^/| /' conftest.$ac_ext >&5
23106
Martin v. Löwis11437992002-04-12 09:54:03 +000023107( exit $ac_status )
Martin v. Löwiseba40652007-08-30 20:10:57 +000023108if test "$ac_cv_type_wchar_t" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023109 { { echo "$as_me:$LINENO: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023110See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023111echo "$as_me: error: cannot compute sizeof (wchar_t)
Skip Montanaro6dead952003-09-25 14:50:04 +000023112See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000023113 { (exit 77); exit 77; }; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023114 else
23115 ac_cv_sizeof_wchar_t=0
23116 fi
Martin v. Löwis11437992002-04-12 09:54:03 +000023117fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023118rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023119fi
23120rm -f conftest.val
Guido van Rossumef2255b2000-03-10 22:30:29 +000023121fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000023122{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_wchar_t" >&5
23123echo "${ECHO_T}$ac_cv_sizeof_wchar_t" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023124
23125
23126
Martin v. Löwis11437992002-04-12 09:54:03 +000023127cat >>confdefs.h <<_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023128#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000023129_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023130
Michael W. Hudson54241132001-12-07 15:38:26 +000023131
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023132fi
23133
Ronald Oussoren450d5612009-06-08 21:12:41 +000023134{ echo "$as_me:$LINENO: checking for UCS-4 tcl" >&5
23135echo $ECHO_N "checking for UCS-4 tcl... $ECHO_C" >&6; }
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023136have_ucs4_tcl=no
23137cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023138/* confdefs.h. */
23139_ACEOF
23140cat confdefs.h >>conftest.$ac_ext
23141cat >>conftest.$ac_ext <<_ACEOF
23142/* end confdefs.h. */
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023143
23144#include <tcl.h>
23145#if TCL_UTF_MAX != 6
23146# error "NOT UCS4_TCL"
23147#endif
23148int
23149main ()
23150{
23151
23152 ;
23153 return 0;
23154}
23155_ACEOF
23156rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023157if { (ac_try="$ac_compile"
23158case "(($ac_try" in
23159 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23160 *) ac_try_echo=$ac_try;;
23161esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023162eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023163 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023164 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023165 grep -v '^ *+' conftest.er1 >conftest.err
23166 rm -f conftest.er1
23167 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023168 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023169 (exit $ac_status); } && {
23170 test -z "$ac_c_werror_flag" ||
23171 test ! -s conftest.err
23172 } && test -s conftest.$ac_objext; then
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023173
23174
23175cat >>confdefs.h <<\_ACEOF
23176#define HAVE_UCS4_TCL 1
23177_ACEOF
23178
23179 have_ucs4_tcl=yes
23180
23181else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023182 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023183sed 's/^/| /' conftest.$ac_ext >&5
23184
Martin v. Löwiseba40652007-08-30 20:10:57 +000023185
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023186fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023187
23188rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Ronald Oussoren450d5612009-06-08 21:12:41 +000023189{ echo "$as_me:$LINENO: result: $have_ucs4_tcl" >&5
23190echo "${ECHO_T}$have_ucs4_tcl" >&6; }
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023191
Skip Montanaro6dead952003-09-25 14:50:04 +000023192# check whether wchar_t is signed or not
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023193if test "$wchar_h" = yes
23194then
23195 # check whether wchar_t is signed or not
Ronald Oussoren450d5612009-06-08 21:12:41 +000023196 { echo "$as_me:$LINENO: checking whether wchar_t is signed" >&5
23197echo $ECHO_N "checking whether wchar_t is signed... $ECHO_C" >&6; }
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023198 if test "${ac_cv_wchar_t_signed+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023199 echo $ECHO_N "(cached) $ECHO_C" >&6
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023200else
23201
23202 if test "$cross_compiling" = yes; then
23203 ac_cv_wchar_t_signed=yes
23204else
23205 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023206/* confdefs.h. */
23207_ACEOF
23208cat confdefs.h >>conftest.$ac_ext
23209cat >>conftest.$ac_ext <<_ACEOF
23210/* end confdefs.h. */
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023211
23212 #include <wchar.h>
23213 int main()
23214 {
Martin v. Löwis44fe0e42006-04-11 07:15:30 +000023215 /* Success: exit code 0 */
23216 exit((((wchar_t) -1) < ((wchar_t) 0)) ? 0 : 1);
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023217 }
23218
23219_ACEOF
23220rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023221if { (ac_try="$ac_link"
23222case "(($ac_try" in
23223 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23224 *) ac_try_echo=$ac_try;;
23225esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023226eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023227 (eval "$ac_link") 2>&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023228 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023229 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023230 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000023231 { (case "(($ac_try" in
23232 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23233 *) ac_try_echo=$ac_try;;
23234esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023235eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023236 (eval "$ac_try") 2>&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023237 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023238 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023239 (exit $ac_status); }; }; then
23240 ac_cv_wchar_t_signed=yes
23241else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023242 echo "$as_me: program exited with status $ac_status" >&5
23243echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023244sed 's/^/| /' conftest.$ac_ext >&5
23245
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023246( exit $ac_status )
23247ac_cv_wchar_t_signed=no
23248fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023249rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023250fi
23251
Martin v. Löwiseba40652007-08-30 20:10:57 +000023252
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023253fi
23254
Ronald Oussoren450d5612009-06-08 21:12:41 +000023255 { echo "$as_me:$LINENO: result: $ac_cv_wchar_t_signed" >&5
23256echo "${ECHO_T}$ac_cv_wchar_t_signed" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023257fi
23258
Ronald Oussoren450d5612009-06-08 21:12:41 +000023259{ echo "$as_me:$LINENO: checking what type to use for unicode" >&5
23260echo $ECHO_N "checking what type to use for unicode... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000023261# Check whether --enable-unicode was given.
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023262if test "${enable_unicode+set}" = set; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000023263 enableval=$enable_unicode;
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023264else
23265 enable_unicode=yes
Martin v. Löwiseba40652007-08-30 20:10:57 +000023266fi
23267
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023268
23269if test $enable_unicode = yes
23270then
Martin v. Löwisfd917792001-06-27 20:22:04 +000023271 # Without any arguments, Py_UNICODE defaults to two-byte mode
Martin v. Löwisfa3bdea2003-09-04 18:50:54 +000023272 case "$have_ucs4_tcl" in
23273 yes) enable_unicode="ucs4"
23274 ;;
23275 *) enable_unicode="ucs2"
23276 ;;
23277 esac
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023278fi
23279
Martin v. Löwis0036cba2002-04-12 09:58:45 +000023280
23281
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023282case "$enable_unicode" in
23283ucs2) unicode_size="2"
Martin v. Löwis11437992002-04-12 09:54:03 +000023284 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023285#define Py_UNICODE_SIZE 2
Martin v. Löwis11437992002-04-12 09:54:03 +000023286_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023287
23288 ;;
23289ucs4) unicode_size="4"
Martin v. Löwis11437992002-04-12 09:54:03 +000023290 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023291#define Py_UNICODE_SIZE 4
Martin v. Löwis11437992002-04-12 09:54:03 +000023292_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023293
23294 ;;
23295esac
23296
Michael W. Hudson54241132001-12-07 15:38:26 +000023297
Martin v. Löwis11437992002-04-12 09:54:03 +000023298
23299
Martin v. Löwis0036cba2002-04-12 09:58:45 +000023300
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023301if test "$enable_unicode" = "no"
23302then
Martin v. Löwis339d0f72001-08-17 18:39:25 +000023303 UNICODE_OBJS=""
Ronald Oussoren450d5612009-06-08 21:12:41 +000023304 { echo "$as_me:$LINENO: result: not used" >&5
23305echo "${ECHO_T}not used" >&6; }
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023306else
Martin v. Löwis339d0f72001-08-17 18:39:25 +000023307 UNICODE_OBJS="Objects/unicodeobject.o Objects/unicodectype.o"
Martin v. Löwis11437992002-04-12 09:54:03 +000023308
23309cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023310#define Py_USING_UNICODE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000023311_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023312
Marc-André Lemburgd7160f82003-09-22 11:14:40 +000023313
23314 # wchar_t is only usable if it maps to an unsigned type
23315 if test "$unicode_size" = "$ac_cv_sizeof_wchar_t" \
Matthias Klose7dbeed72004-12-24 08:22:17 +000023316 -a "$ac_cv_wchar_t_signed" = "no"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023317 then
23318 PY_UNICODE_TYPE="wchar_t"
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023319
Martin v. Löwis11437992002-04-12 09:54:03 +000023320cat >>confdefs.h <<\_ACEOF
23321#define HAVE_USABLE_WCHAR_T 1
23322_ACEOF
23323
23324 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023325#define PY_UNICODE_TYPE wchar_t
Martin v. Löwis11437992002-04-12 09:54:03 +000023326_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023327
23328 elif test "$ac_cv_sizeof_short" = "$unicode_size"
23329 then
23330 PY_UNICODE_TYPE="unsigned short"
Martin v. Löwis11437992002-04-12 09:54:03 +000023331 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023332#define PY_UNICODE_TYPE unsigned short
Martin v. Löwis11437992002-04-12 09:54:03 +000023333_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023334
23335 elif test "$ac_cv_sizeof_long" = "$unicode_size"
23336 then
23337 PY_UNICODE_TYPE="unsigned long"
Martin v. Löwis11437992002-04-12 09:54:03 +000023338 cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023339#define PY_UNICODE_TYPE unsigned long
Martin v. Löwis11437992002-04-12 09:54:03 +000023340_ACEOF
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023341
23342 else
23343 PY_UNICODE_TYPE="no type found"
23344 fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000023345 { echo "$as_me:$LINENO: result: $PY_UNICODE_TYPE" >&5
23346echo "${ECHO_T}$PY_UNICODE_TYPE" >&6; }
Martin v. Löwis0ba70cc2001-06-26 22:22:37 +000023347fi
Guido van Rossumef2255b2000-03-10 22:30:29 +000023348
23349# check for endianness
Ronald Oussoren450d5612009-06-08 21:12:41 +000023350{ echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
23351echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023352if test "${ac_cv_c_bigendian+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023353 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumef2255b2000-03-10 22:30:29 +000023354else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023355 # See if sys/param.h defines the BYTE_ORDER macro.
23356cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023357/* confdefs.h. */
23358_ACEOF
23359cat confdefs.h >>conftest.$ac_ext
23360cat >>conftest.$ac_ext <<_ACEOF
23361/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000023362#include <sys/types.h>
Ronald Oussoren450d5612009-06-08 21:12:41 +000023363#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000023364
Martin v. Löwis11437992002-04-12 09:54:03 +000023365int
23366main ()
23367{
Ronald Oussoren450d5612009-06-08 21:12:41 +000023368#if ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
23369 && BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
23370 bogus endian macros
23371#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000023372
23373 ;
23374 return 0;
23375}
23376_ACEOF
23377rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023378if { (ac_try="$ac_compile"
23379case "(($ac_try" in
23380 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23381 *) ac_try_echo=$ac_try;;
23382esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023383eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023384 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023385 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023386 grep -v '^ *+' conftest.er1 >conftest.err
23387 rm -f conftest.er1
23388 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023389 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023390 (exit $ac_status); } && {
23391 test -z "$ac_c_werror_flag" ||
23392 test ! -s conftest.err
23393 } && test -s conftest.$ac_objext; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000023394 # It does; now see whether it defined to BIG_ENDIAN or not.
Ronald Oussoren450d5612009-06-08 21:12:41 +000023395cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023396/* confdefs.h. */
23397_ACEOF
23398cat confdefs.h >>conftest.$ac_ext
23399cat >>conftest.$ac_ext <<_ACEOF
23400/* end confdefs.h. */
Guido van Rossumef2255b2000-03-10 22:30:29 +000023401#include <sys/types.h>
Ronald Oussoren450d5612009-06-08 21:12:41 +000023402#include <sys/param.h>
Guido van Rossumef2255b2000-03-10 22:30:29 +000023403
Martin v. Löwis11437992002-04-12 09:54:03 +000023404int
23405main ()
23406{
Guido van Rossumef2255b2000-03-10 22:30:29 +000023407#if BYTE_ORDER != BIG_ENDIAN
Ronald Oussoren450d5612009-06-08 21:12:41 +000023408 not big endian
23409#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000023410
23411 ;
23412 return 0;
23413}
23414_ACEOF
23415rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023416if { (ac_try="$ac_compile"
23417case "(($ac_try" in
23418 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23419 *) ac_try_echo=$ac_try;;
23420esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023421eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023422 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023423 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023424 grep -v '^ *+' conftest.er1 >conftest.err
23425 rm -f conftest.er1
23426 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023427 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023428 (exit $ac_status); } && {
23429 test -z "$ac_c_werror_flag" ||
23430 test ! -s conftest.err
23431 } && test -s conftest.$ac_objext; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000023432 ac_cv_c_bigendian=yes
23433else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023434 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023435sed 's/^/| /' conftest.$ac_ext >&5
23436
Martin v. Löwiseba40652007-08-30 20:10:57 +000023437 ac_cv_c_bigendian=no
Guido van Rossumef2255b2000-03-10 22:30:29 +000023438fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023439
23440rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000023441else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023442 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023443sed 's/^/| /' conftest.$ac_ext >&5
23444
Ronald Oussoren450d5612009-06-08 21:12:41 +000023445 # It does not; compile a test program.
23446if test "$cross_compiling" = yes; then
23447 # try to guess the endianness by grepping values into an object file
23448 ac_cv_c_bigendian=unknown
23449 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023450/* confdefs.h. */
23451_ACEOF
23452cat confdefs.h >>conftest.$ac_ext
23453cat >>conftest.$ac_ext <<_ACEOF
23454/* end confdefs.h. */
Ronald Oussoren450d5612009-06-08 21:12:41 +000023455short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
23456short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
23457void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
23458short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
23459short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
23460void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023461int
23462main ()
23463{
Ronald Oussoren450d5612009-06-08 21:12:41 +000023464 _ascii (); _ebcdic ();
Martin v. Löwis11437992002-04-12 09:54:03 +000023465 ;
23466 return 0;
23467}
23468_ACEOF
23469rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023470if { (ac_try="$ac_compile"
23471case "(($ac_try" in
23472 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23473 *) ac_try_echo=$ac_try;;
23474esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023475eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023476 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023477 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023478 grep -v '^ *+' conftest.er1 >conftest.err
23479 rm -f conftest.er1
23480 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023481 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023482 (exit $ac_status); } && {
23483 test -z "$ac_c_werror_flag" ||
23484 test ! -s conftest.err
23485 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023486 if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023487 ac_cv_c_bigendian=yes
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023488fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000023489if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
23490 if test "$ac_cv_c_bigendian" = unknown; then
23491 ac_cv_c_bigendian=no
23492 else
23493 # finding both strings is unlikely to happen, but who knows?
23494 ac_cv_c_bigendian=unknown
23495 fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023496fi
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023497else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023498 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023499sed 's/^/| /' conftest.$ac_ext >&5
23500
Martin v. Löwiseba40652007-08-30 20:10:57 +000023501
Martin v. Löwis11437992002-04-12 09:54:03 +000023502fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023503
23504rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023505else
23506 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023507/* confdefs.h. */
23508_ACEOF
23509cat confdefs.h >>conftest.$ac_ext
23510cat >>conftest.$ac_ext <<_ACEOF
23511/* end confdefs.h. */
Martin v. Löwiseba40652007-08-30 20:10:57 +000023512$ac_includes_default
Martin v. Löwis11437992002-04-12 09:54:03 +000023513int
23514main ()
23515{
Martin v. Löwiseba40652007-08-30 20:10:57 +000023516
Ronald Oussoren450d5612009-06-08 21:12:41 +000023517 /* Are we little or big endian? From Harbison&Steele. */
23518 union
23519 {
23520 long int l;
23521 char c[sizeof (long int)];
23522 } u;
23523 u.l = 1;
23524 return u.c[sizeof (long int) - 1] == 1;
Martin v. Löwiseba40652007-08-30 20:10:57 +000023525
23526 ;
23527 return 0;
Guido van Rossumef2255b2000-03-10 22:30:29 +000023528}
Martin v. Löwis11437992002-04-12 09:54:03 +000023529_ACEOF
23530rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023531if { (ac_try="$ac_link"
23532case "(($ac_try" in
23533 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23534 *) ac_try_echo=$ac_try;;
23535esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023536eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023537 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023538 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023539 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023540 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000023541 { (case "(($ac_try" in
23542 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23543 *) ac_try_echo=$ac_try;;
23544esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023545eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023546 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023547 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023548 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023549 (exit $ac_status); }; }; then
Guido van Rossumef2255b2000-03-10 22:30:29 +000023550 ac_cv_c_bigendian=no
23551else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023552 echo "$as_me: program exited with status $ac_status" >&5
23553echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023554sed 's/^/| /' conftest.$ac_ext >&5
23555
Martin v. Löwis11437992002-04-12 09:54:03 +000023556( exit $ac_status )
23557ac_cv_c_bigendian=yes
Guido van Rossumef2255b2000-03-10 22:30:29 +000023558fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023559rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumef2255b2000-03-10 22:30:29 +000023560fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023561
23562
Martin v. Löwis11437992002-04-12 09:54:03 +000023563fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000023564
23565rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23566fi
23567{ echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
23568echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
23569case $ac_cv_c_bigendian in
23570 yes)
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023571
23572cat >>confdefs.h <<\_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000023573#define WORDS_BIGENDIAN 1
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000023574_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000023575 ;;
23576 no)
23577 ;;
23578 *)
23579 { { echo "$as_me:$LINENO: error: unknown endianness
23580presetting ac_cv_c_bigendian=no (or yes) will help" >&5
23581echo "$as_me: error: unknown endianness
23582presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000023583 { (exit 1); exit 1; }; } ;;
Ronald Oussoren450d5612009-06-08 21:12:41 +000023584esac
Guido van Rossumef2255b2000-03-10 22:30:29 +000023585
Michael W. Hudson54241132001-12-07 15:38:26 +000023586
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023587# Check whether right shifting a negative integer extends the sign bit
23588# or fills with zeros (like the Cray J90, according to Tim Peters).
Ronald Oussoren450d5612009-06-08 21:12:41 +000023589{ echo "$as_me:$LINENO: checking whether right shift extends the sign bit" >&5
23590echo $ECHO_N "checking whether right shift extends the sign bit... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023591if test "${ac_cv_rshift_extends_sign+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023592 echo $ECHO_N "(cached) $ECHO_C" >&6
Vladimir Marangozova6180282000-07-12 05:05:06 +000023593else
Martin v. Löwis11437992002-04-12 09:54:03 +000023594
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023595if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000023596 ac_cv_rshift_extends_sign=yes
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023597else
Martin v. Löwis11437992002-04-12 09:54:03 +000023598 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023599/* confdefs.h. */
23600_ACEOF
23601cat confdefs.h >>conftest.$ac_ext
23602cat >>conftest.$ac_ext <<_ACEOF
23603/* end confdefs.h. */
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023604
23605int main()
23606{
Vladimir Marangozova6180282000-07-12 05:05:06 +000023607 exit(((-1)>>3 == -1) ? 0 : 1);
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023608}
23609
Martin v. Löwis11437992002-04-12 09:54:03 +000023610_ACEOF
23611rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023612if { (ac_try="$ac_link"
23613case "(($ac_try" in
23614 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23615 *) ac_try_echo=$ac_try;;
23616esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023617eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023618 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023619 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023620 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023621 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000023622 { (case "(($ac_try" in
23623 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23624 *) ac_try_echo=$ac_try;;
23625esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023626eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023627 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023628 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000023629 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000023630 (exit $ac_status); }; }; then
Vladimir Marangozova6180282000-07-12 05:05:06 +000023631 ac_cv_rshift_extends_sign=yes
23632else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023633 echo "$as_me: program exited with status $ac_status" >&5
23634echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023635sed 's/^/| /' conftest.$ac_ext >&5
23636
Martin v. Löwis11437992002-04-12 09:54:03 +000023637( exit $ac_status )
23638ac_cv_rshift_extends_sign=no
Vladimir Marangozova6180282000-07-12 05:05:06 +000023639fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023640rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Vladimir Marangozova6180282000-07-12 05:05:06 +000023641fi
23642
Martin v. Löwiseba40652007-08-30 20:10:57 +000023643
23644fi
23645
Ronald Oussoren450d5612009-06-08 21:12:41 +000023646{ echo "$as_me:$LINENO: result: $ac_cv_rshift_extends_sign" >&5
23647echo "${ECHO_T}$ac_cv_rshift_extends_sign" >&6; }
Vladimir Marangozova6180282000-07-12 05:05:06 +000023648if test "$ac_cv_rshift_extends_sign" = no
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023649then
Martin v. Löwis11437992002-04-12 09:54:03 +000023650
23651cat >>confdefs.h <<\_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023652#define SIGNED_RIGHT_SHIFT_ZERO_FILLS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000023653_ACEOF
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023654
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023655fi
23656
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023657# check for getc_unlocked and related locking functions
Ronald Oussoren450d5612009-06-08 21:12:41 +000023658{ echo "$as_me:$LINENO: checking for getc_unlocked() and friends" >&5
23659echo $ECHO_N "checking for getc_unlocked() and friends... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023660if test "${ac_cv_have_getc_unlocked+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023661 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023662else
Martin v. Löwis11437992002-04-12 09:54:03 +000023663
23664cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023665/* confdefs.h. */
23666_ACEOF
23667cat confdefs.h >>conftest.$ac_ext
23668cat >>conftest.$ac_ext <<_ACEOF
23669/* end confdefs.h. */
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023670#include <stdio.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000023671int
23672main ()
23673{
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023674
23675 FILE *f = fopen("/dev/null", "r");
23676 flockfile(f);
23677 getc_unlocked(f);
23678 funlockfile(f);
23679
Martin v. Löwis11437992002-04-12 09:54:03 +000023680 ;
23681 return 0;
23682}
23683_ACEOF
23684rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023685if { (ac_try="$ac_link"
23686case "(($ac_try" in
23687 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23688 *) ac_try_echo=$ac_try;;
23689esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023690eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023691 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023692 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023693 grep -v '^ *+' conftest.er1 >conftest.err
23694 rm -f conftest.er1
23695 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023697 (exit $ac_status); } && {
23698 test -z "$ac_c_werror_flag" ||
23699 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000023700 } && test -s conftest$ac_exeext &&
23701 $as_test_x conftest$ac_exeext; then
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023702 ac_cv_have_getc_unlocked=yes
23703else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023704 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023705sed 's/^/| /' conftest.$ac_ext >&5
23706
Martin v. Löwiseba40652007-08-30 20:10:57 +000023707 ac_cv_have_getc_unlocked=no
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023708fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023709
23710rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000023711 conftest$ac_exeext conftest.$ac_ext
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023712fi
23713
Ronald Oussoren450d5612009-06-08 21:12:41 +000023714{ echo "$as_me:$LINENO: result: $ac_cv_have_getc_unlocked" >&5
23715echo "${ECHO_T}$ac_cv_have_getc_unlocked" >&6; }
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023716if test "$ac_cv_have_getc_unlocked" = yes
23717then
Martin v. Löwis11437992002-04-12 09:54:03 +000023718
23719cat >>confdefs.h <<\_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023720#define HAVE_GETC_UNLOCKED 1
Martin v. Löwis11437992002-04-12 09:54:03 +000023721_ACEOF
Guido van Rossumcadfaec2001-01-05 14:45:49 +000023722
23723fi
Vladimir Marangozov676aa882000-07-12 03:02:43 +000023724
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023725# check where readline lives
Martin v. Löwis82bca632006-02-10 20:49:30 +000023726# save the value of LIBS so we don't actually link Python with readline
23727LIBS_no_readline=$LIBS
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023728
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023729# On some systems we need to link readline to a termcap compatible
23730# library. NOTE: Keep the precedence of listed libraries synchronised
23731# with setup.py.
23732py_cv_lib_readline=no
Ronald Oussoren450d5612009-06-08 21:12:41 +000023733{ echo "$as_me:$LINENO: checking how to link readline libs" >&5
23734echo $ECHO_N "checking how to link readline libs... $ECHO_C" >&6; }
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023735for py_libtermcap in "" ncursesw ncurses curses termcap; do
23736 if test -z "$py_libtermcap"; then
23737 READLINE_LIBS="-lreadline"
23738 else
23739 READLINE_LIBS="-lreadline -l$py_libtermcap"
23740 fi
23741 LIBS="$READLINE_LIBS $LIBS_no_readline"
23742 cat >conftest.$ac_ext <<_ACEOF
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023743/* confdefs.h. */
23744_ACEOF
23745cat confdefs.h >>conftest.$ac_ext
23746cat >>conftest.$ac_ext <<_ACEOF
23747/* end confdefs.h. */
23748
Martin v. Löwiseba40652007-08-30 20:10:57 +000023749/* Override any GCC internal prototype to avoid an error.
23750 Use char because int might match the return type of a GCC
23751 builtin and then its argument prototype would still apply. */
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023752#ifdef __cplusplus
23753extern "C"
23754#endif
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023755char readline ();
23756int
23757main ()
23758{
Martin v. Löwiseba40652007-08-30 20:10:57 +000023759return readline ();
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023760 ;
23761 return 0;
23762}
23763_ACEOF
23764rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023765if { (ac_try="$ac_link"
23766case "(($ac_try" in
23767 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23768 *) ac_try_echo=$ac_try;;
23769esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023770eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023771 (eval "$ac_link") 2>conftest.er1
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023772 ac_status=$?
23773 grep -v '^ *+' conftest.er1 >conftest.err
23774 rm -f conftest.er1
23775 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023776 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023777 (exit $ac_status); } && {
23778 test -z "$ac_c_werror_flag" ||
23779 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000023780 } && test -s conftest$ac_exeext &&
23781 $as_test_x conftest$ac_exeext; then
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023782 py_cv_lib_readline=yes
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023783else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023784 echo "$as_me: failed program was:" >&5
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023785sed 's/^/| /' conftest.$ac_ext >&5
23786
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023787
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023788fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023789
23790rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023791 conftest$ac_exeext conftest.$ac_ext
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023792 if test $py_cv_lib_readline = yes; then
23793 break
23794 fi
23795done
23796# Uncomment this line if you want to use READINE_LIBS in Makefile or scripts
23797#AC_SUBST([READLINE_LIBS])
Gregory P. Smithe080cdf2008-09-07 19:19:04 +000023798if test $py_cv_lib_readline = no; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023799 { echo "$as_me:$LINENO: result: none" >&5
23800echo "${ECHO_T}none" >&6; }
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023801else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023802 { echo "$as_me:$LINENO: result: $READLINE_LIBS" >&5
23803echo "${ECHO_T}$READLINE_LIBS" >&6; }
Gregory P. Smithcc023f12008-09-07 05:15:58 +000023804
23805cat >>confdefs.h <<\_ACEOF
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023806#define HAVE_LIBREADLINE 1
23807_ACEOF
23808
Neal Norwitzfe8e3d92006-01-07 21:07:20 +000023809fi
23810
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023811# check for readline 2.1
Ronald Oussoren450d5612009-06-08 21:12:41 +000023812{ echo "$as_me:$LINENO: checking for rl_callback_handler_install in -lreadline" >&5
23813echo $ECHO_N "checking for rl_callback_handler_install in -lreadline... $ECHO_C" >&6; }
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023814if test "${ac_cv_lib_readline_rl_callback_handler_install+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023815 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023816else
23817 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000023818LIBS="-lreadline $READLINE_LIBS $LIBS"
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023819cat >conftest.$ac_ext <<_ACEOF
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023820/* confdefs.h. */
23821_ACEOF
23822cat confdefs.h >>conftest.$ac_ext
23823cat >>conftest.$ac_ext <<_ACEOF
23824/* end confdefs.h. */
23825
Martin v. Löwiseba40652007-08-30 20:10:57 +000023826/* Override any GCC internal prototype to avoid an error.
23827 Use char because int might match the return type of a GCC
23828 builtin and then its argument prototype would still apply. */
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023829#ifdef __cplusplus
23830extern "C"
23831#endif
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023832char rl_callback_handler_install ();
23833int
23834main ()
23835{
Martin v. Löwiseba40652007-08-30 20:10:57 +000023836return rl_callback_handler_install ();
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023837 ;
23838 return 0;
23839}
23840_ACEOF
23841rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023842if { (ac_try="$ac_link"
23843case "(($ac_try" in
23844 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23845 *) ac_try_echo=$ac_try;;
23846esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023847eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023848 (eval "$ac_link") 2>conftest.er1
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023849 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023850 grep -v '^ *+' conftest.er1 >conftest.err
23851 rm -f conftest.er1
23852 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023853 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023854 (exit $ac_status); } && {
23855 test -z "$ac_c_werror_flag" ||
23856 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000023857 } && test -s conftest$ac_exeext &&
23858 $as_test_x conftest$ac_exeext; then
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023859 ac_cv_lib_readline_rl_callback_handler_install=yes
23860else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023861 echo "$as_me: failed program was:" >&5
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023862sed 's/^/| /' conftest.$ac_ext >&5
23863
Martin v. Löwiseba40652007-08-30 20:10:57 +000023864 ac_cv_lib_readline_rl_callback_handler_install=no
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023865fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023866
23867rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000023868 conftest$ac_exeext conftest.$ac_ext
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023869LIBS=$ac_check_lib_save_LIBS
23870fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000023871{ echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_callback_handler_install" >&5
23872echo "${ECHO_T}$ac_cv_lib_readline_rl_callback_handler_install" >&6; }
23873if test $ac_cv_lib_readline_rl_callback_handler_install = yes; then
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000023874
23875cat >>confdefs.h <<\_ACEOF
23876#define HAVE_RL_CALLBACK 1
23877_ACEOF
23878
23879fi
23880
23881
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023882# check for readline 2.2
23883cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023884/* confdefs.h. */
23885_ACEOF
23886cat confdefs.h >>conftest.$ac_ext
23887cat >>conftest.$ac_ext <<_ACEOF
23888/* end confdefs.h. */
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023889#include <readline/readline.h>
23890_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000023891if { (ac_try="$ac_cpp conftest.$ac_ext"
23892case "(($ac_try" in
23893 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23894 *) ac_try_echo=$ac_try;;
23895esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023896eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023897 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023898 ac_status=$?
Skip Montanaro6dead952003-09-25 14:50:04 +000023899 grep -v '^ *+' conftest.er1 >conftest.err
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023900 rm -f conftest.er1
23901 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023902 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023903 (exit $ac_status); } >/dev/null && {
23904 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
23905 test ! -s conftest.err
23906 }; then
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023907 have_readline=yes
23908else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023909 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023910sed 's/^/| /' conftest.$ac_ext >&5
23911
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023912 have_readline=no
23913fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023914
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023915rm -f conftest.err conftest.$ac_ext
23916if test $have_readline = yes
23917then
23918 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023919/* confdefs.h. */
23920_ACEOF
23921cat confdefs.h >>conftest.$ac_ext
23922cat >>conftest.$ac_ext <<_ACEOF
23923/* end confdefs.h. */
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023924#include <readline/readline.h>
23925
23926_ACEOF
23927if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Skip Montanaro6dead952003-09-25 14:50:04 +000023928 $EGREP "extern int rl_completion_append_character;" >/dev/null 2>&1; then
Guido van Rossumfaf5e4d2002-12-30 16:25:41 +000023929
23930cat >>confdefs.h <<\_ACEOF
23931#define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
23932_ACEOF
23933
23934fi
23935rm -f conftest*
23936
23937fi
23938
Martin v. Löwis0daad592001-09-30 21:09:59 +000023939# check for readline 4.0
Ronald Oussoren450d5612009-06-08 21:12:41 +000023940{ echo "$as_me:$LINENO: checking for rl_pre_input_hook in -lreadline" >&5
23941echo $ECHO_N "checking for rl_pre_input_hook in -lreadline... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000023942if test "${ac_cv_lib_readline_rl_pre_input_hook+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000023943 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum353ae582001-07-10 16:45:32 +000023944else
Martin v. Löwis11437992002-04-12 09:54:03 +000023945 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000023946LIBS="-lreadline $READLINE_LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000023947cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000023948/* confdefs.h. */
23949_ACEOF
23950cat confdefs.h >>conftest.$ac_ext
23951cat >>conftest.$ac_ext <<_ACEOF
23952/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023953
Martin v. Löwiseba40652007-08-30 20:10:57 +000023954/* Override any GCC internal prototype to avoid an error.
23955 Use char because int might match the return type of a GCC
23956 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000023957#ifdef __cplusplus
23958extern "C"
23959#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000023960char rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000023961int
23962main ()
23963{
Martin v. Löwiseba40652007-08-30 20:10:57 +000023964return rl_pre_input_hook ();
Martin v. Löwis11437992002-04-12 09:54:03 +000023965 ;
23966 return 0;
23967}
23968_ACEOF
23969rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000023970if { (ac_try="$ac_link"
23971case "(($ac_try" in
23972 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23973 *) ac_try_echo=$ac_try;;
23974esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000023975eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023976 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000023977 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000023978 grep -v '^ *+' conftest.er1 >conftest.err
23979 rm -f conftest.er1
23980 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000023981 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000023982 (exit $ac_status); } && {
23983 test -z "$ac_c_werror_flag" ||
23984 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000023985 } && test -s conftest$ac_exeext &&
23986 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000023987 ac_cv_lib_readline_rl_pre_input_hook=yes
Martin v. Löwis0daad592001-09-30 21:09:59 +000023988else
Ronald Oussoren450d5612009-06-08 21:12:41 +000023989 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000023990sed 's/^/| /' conftest.$ac_ext >&5
23991
Martin v. Löwiseba40652007-08-30 20:10:57 +000023992 ac_cv_lib_readline_rl_pre_input_hook=no
Martin v. Löwis0daad592001-09-30 21:09:59 +000023993fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000023994
23995rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000023996 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000023997LIBS=$ac_check_lib_save_LIBS
23998fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000023999{ echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_pre_input_hook" >&5
24000echo "${ECHO_T}$ac_cv_lib_readline_rl_pre_input_hook" >&6; }
24001if test $ac_cv_lib_readline_rl_pre_input_hook = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000024002
Martin v. Löwis11437992002-04-12 09:54:03 +000024003cat >>confdefs.h <<\_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000024004#define HAVE_RL_PRE_INPUT_HOOK 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024005_ACEOF
Martin v. Löwis0daad592001-09-30 21:09:59 +000024006
Martin v. Löwis0daad592001-09-30 21:09:59 +000024007fi
24008
Michael W. Hudson54241132001-12-07 15:38:26 +000024009
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024010# also in 4.0
Ronald Oussoren450d5612009-06-08 21:12:41 +000024011{ echo "$as_me:$LINENO: checking for rl_completion_display_matches_hook in -lreadline" >&5
24012echo $ECHO_N "checking for rl_completion_display_matches_hook in -lreadline... $ECHO_C" >&6; }
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024013if test "${ac_cv_lib_readline_rl_completion_display_matches_hook+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024014 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024015else
24016 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000024017LIBS="-lreadline $READLINE_LIBS $LIBS"
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024018cat >conftest.$ac_ext <<_ACEOF
24019/* confdefs.h. */
24020_ACEOF
24021cat confdefs.h >>conftest.$ac_ext
24022cat >>conftest.$ac_ext <<_ACEOF
24023/* end confdefs.h. */
24024
24025/* Override any GCC internal prototype to avoid an error.
24026 Use char because int might match the return type of a GCC
24027 builtin and then its argument prototype would still apply. */
24028#ifdef __cplusplus
24029extern "C"
24030#endif
24031char rl_completion_display_matches_hook ();
24032int
24033main ()
24034{
24035return rl_completion_display_matches_hook ();
24036 ;
24037 return 0;
24038}
24039_ACEOF
24040rm -f conftest.$ac_objext conftest$ac_exeext
24041if { (ac_try="$ac_link"
24042case "(($ac_try" in
24043 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24044 *) ac_try_echo=$ac_try;;
24045esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024046eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024047 (eval "$ac_link") 2>conftest.er1
24048 ac_status=$?
24049 grep -v '^ *+' conftest.er1 >conftest.err
24050 rm -f conftest.er1
24051 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024052 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024053 (exit $ac_status); } && {
24054 test -z "$ac_c_werror_flag" ||
24055 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000024056 } && test -s conftest$ac_exeext &&
24057 $as_test_x conftest$ac_exeext; then
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024058 ac_cv_lib_readline_rl_completion_display_matches_hook=yes
24059else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024060 echo "$as_me: failed program was:" >&5
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024061sed 's/^/| /' conftest.$ac_ext >&5
24062
24063 ac_cv_lib_readline_rl_completion_display_matches_hook=no
24064fi
24065
24066rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
24067 conftest$ac_exeext conftest.$ac_ext
24068LIBS=$ac_check_lib_save_LIBS
24069fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000024070{ echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_display_matches_hook" >&5
24071echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_display_matches_hook" >&6; }
24072if test $ac_cv_lib_readline_rl_completion_display_matches_hook = yes; then
Martin v. Löwis58bd49f2007-09-04 13:13:14 +000024073
24074cat >>confdefs.h <<\_ACEOF
24075#define HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK 1
24076_ACEOF
24077
24078fi
24079
24080
Martin v. Löwis0daad592001-09-30 21:09:59 +000024081# check for readline 4.2
Ronald Oussoren450d5612009-06-08 21:12:41 +000024082{ echo "$as_me:$LINENO: checking for rl_completion_matches in -lreadline" >&5
24083echo $ECHO_N "checking for rl_completion_matches in -lreadline... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024084if test "${ac_cv_lib_readline_rl_completion_matches+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024085 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis0daad592001-09-30 21:09:59 +000024086else
Martin v. Löwis11437992002-04-12 09:54:03 +000024087 ac_check_lib_save_LIBS=$LIBS
Gregory P. Smithff7b2d52008-09-03 05:57:48 +000024088LIBS="-lreadline $READLINE_LIBS $LIBS"
Martin v. Löwis11437992002-04-12 09:54:03 +000024089cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024090/* confdefs.h. */
24091_ACEOF
24092cat confdefs.h >>conftest.$ac_ext
24093cat >>conftest.$ac_ext <<_ACEOF
24094/* end confdefs.h. */
Martin v. Löwis11437992002-04-12 09:54:03 +000024095
Martin v. Löwiseba40652007-08-30 20:10:57 +000024096/* Override any GCC internal prototype to avoid an error.
24097 Use char because int might match the return type of a GCC
24098 builtin and then its argument prototype would still apply. */
Martin v. Löwis11437992002-04-12 09:54:03 +000024099#ifdef __cplusplus
24100extern "C"
24101#endif
Martin v. Löwis11437992002-04-12 09:54:03 +000024102char rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000024103int
24104main ()
24105{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024106return rl_completion_matches ();
Martin v. Löwis11437992002-04-12 09:54:03 +000024107 ;
24108 return 0;
24109}
24110_ACEOF
24111rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024112if { (ac_try="$ac_link"
24113case "(($ac_try" in
24114 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24115 *) ac_try_echo=$ac_try;;
24116esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024117eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024118 (eval "$ac_link") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024119 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024120 grep -v '^ *+' conftest.er1 >conftest.err
24121 rm -f conftest.er1
24122 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024123 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024124 (exit $ac_status); } && {
24125 test -z "$ac_c_werror_flag" ||
24126 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000024127 } && test -s conftest$ac_exeext &&
24128 $as_test_x conftest$ac_exeext; then
Martin v. Löwis11437992002-04-12 09:54:03 +000024129 ac_cv_lib_readline_rl_completion_matches=yes
Guido van Rossum353ae582001-07-10 16:45:32 +000024130else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024131 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024132sed 's/^/| /' conftest.$ac_ext >&5
24133
Martin v. Löwiseba40652007-08-30 20:10:57 +000024134 ac_cv_lib_readline_rl_completion_matches=no
Guido van Rossum353ae582001-07-10 16:45:32 +000024135fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024136
24137rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Skip Montanarof0d5f792004-08-15 14:08:23 +000024138 conftest$ac_exeext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000024139LIBS=$ac_check_lib_save_LIBS
24140fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000024141{ echo "$as_me:$LINENO: result: $ac_cv_lib_readline_rl_completion_matches" >&5
24142echo "${ECHO_T}$ac_cv_lib_readline_rl_completion_matches" >&6; }
24143if test $ac_cv_lib_readline_rl_completion_matches = yes; then
Michael W. Hudson54241132001-12-07 15:38:26 +000024144
Martin v. Löwis11437992002-04-12 09:54:03 +000024145cat >>confdefs.h <<\_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000024146#define HAVE_RL_COMPLETION_MATCHES 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024147_ACEOF
Guido van Rossum353ae582001-07-10 16:45:32 +000024148
Guido van Rossum353ae582001-07-10 16:45:32 +000024149fi
24150
Jack Jansendd19cf82001-12-06 22:36:17 +000024151
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024152# also in readline 4.2
24153cat >conftest.$ac_ext <<_ACEOF
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024154/* confdefs.h. */
24155_ACEOF
24156cat confdefs.h >>conftest.$ac_ext
24157cat >>conftest.$ac_ext <<_ACEOF
24158/* end confdefs.h. */
24159#include <readline/readline.h>
24160_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000024161if { (ac_try="$ac_cpp conftest.$ac_ext"
24162case "(($ac_try" in
24163 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24164 *) ac_try_echo=$ac_try;;
24165esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024166eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024167 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024168 ac_status=$?
24169 grep -v '^ *+' conftest.er1 >conftest.err
24170 rm -f conftest.er1
24171 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024172 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024173 (exit $ac_status); } >/dev/null && {
24174 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
24175 test ! -s conftest.err
24176 }; then
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024177 have_readline=yes
24178else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024179 echo "$as_me: failed program was:" >&5
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024180sed 's/^/| /' conftest.$ac_ext >&5
24181
24182 have_readline=no
24183fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024184
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024185rm -f conftest.err conftest.$ac_ext
24186if test $have_readline = yes
24187then
24188 cat >conftest.$ac_ext <<_ACEOF
Michael W. Hudson30ea2f22004-07-07 17:44:12 +000024189/* confdefs.h. */
24190_ACEOF
24191cat confdefs.h >>conftest.$ac_ext
24192cat >>conftest.$ac_ext <<_ACEOF
24193/* end confdefs.h. */
24194#include <readline/readline.h>
24195
24196_ACEOF
24197if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24198 $EGREP "extern int rl_catch_signals;" >/dev/null 2>&1; then
24199
24200cat >>confdefs.h <<\_ACEOF
24201#define HAVE_RL_CATCH_SIGNAL 1
24202_ACEOF
24203
24204fi
24205rm -f conftest*
24206
24207fi
24208
Martin v. Löwis82bca632006-02-10 20:49:30 +000024209# End of readline checks: restore LIBS
24210LIBS=$LIBS_no_readline
24211
Ronald Oussoren450d5612009-06-08 21:12:41 +000024212{ echo "$as_me:$LINENO: checking for broken nice()" >&5
24213echo $ECHO_N "checking for broken nice()... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024214if test "${ac_cv_broken_nice+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024215 echo $ECHO_N "(cached) $ECHO_C" >&6
Michael W. Hudson54241132001-12-07 15:38:26 +000024216else
Martin v. Löwis11437992002-04-12 09:54:03 +000024217
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024218if test "$cross_compiling" = yes; then
Guido van Rossum3065c942001-09-17 04:03:14 +000024219 ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024220else
Martin v. Löwis11437992002-04-12 09:54:03 +000024221 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024222/* confdefs.h. */
24223_ACEOF
24224cat confdefs.h >>conftest.$ac_ext
24225cat >>conftest.$ac_ext <<_ACEOF
24226/* end confdefs.h. */
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024227
24228int main()
24229{
24230 int val1 = nice(1);
24231 if (val1 != -1 && val1 == nice(2))
24232 exit(0);
24233 exit(1);
24234}
24235
Martin v. Löwis11437992002-04-12 09:54:03 +000024236_ACEOF
24237rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024238if { (ac_try="$ac_link"
24239case "(($ac_try" in
24240 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24241 *) ac_try_echo=$ac_try;;
24242esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024243eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024244 (eval "$ac_link") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024245 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000024246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024247 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024248 { (case "(($ac_try" in
24249 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24250 *) ac_try_echo=$ac_try;;
24251esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024252eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024253 (eval "$ac_try") 2>&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024254 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000024255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000024256 (exit $ac_status); }; }; then
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024257 ac_cv_broken_nice=yes
24258else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024259 echo "$as_me: program exited with status $ac_status" >&5
24260echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024261sed 's/^/| /' conftest.$ac_ext >&5
24262
Martin v. Löwis11437992002-04-12 09:54:03 +000024263( exit $ac_status )
24264ac_cv_broken_nice=no
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024265fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024266rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024267fi
24268
Martin v. Löwiseba40652007-08-30 20:10:57 +000024269
24270fi
24271
Ronald Oussoren450d5612009-06-08 21:12:41 +000024272{ echo "$as_me:$LINENO: result: $ac_cv_broken_nice" >&5
24273echo "${ECHO_T}$ac_cv_broken_nice" >&6; }
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024274if test "$ac_cv_broken_nice" = yes
24275then
Martin v. Löwis11437992002-04-12 09:54:03 +000024276
24277cat >>confdefs.h <<\_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024278#define HAVE_BROKEN_NICE 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024279_ACEOF
Thomas Wouterse38b2f12001-07-11 22:35:31 +000024280
24281fi
24282
Ronald Oussoren450d5612009-06-08 21:12:41 +000024283{ echo "$as_me:$LINENO: checking for broken poll()" >&5
24284echo $ECHO_N "checking for broken poll()... $ECHO_C" >&6; }
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024285if test "$cross_compiling" = yes; then
24286 ac_cv_broken_poll=no
24287else
24288 cat >conftest.$ac_ext <<_ACEOF
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024289/* confdefs.h. */
24290_ACEOF
24291cat confdefs.h >>conftest.$ac_ext
24292cat >>conftest.$ac_ext <<_ACEOF
24293/* end confdefs.h. */
24294
24295#include <poll.h>
24296
24297int main (void)
24298 {
24299 struct pollfd poll_struct = { 42, POLLIN|POLLPRI|POLLOUT, 0 };
24300
24301 close (42);
24302
24303 int poll_test = poll (&poll_struct, 1, 0);
24304
24305 if (poll_test < 0)
24306 {
24307 exit(0);
24308 }
24309 else if (poll_test == 0 && poll_struct.revents != POLLNVAL)
24310 {
24311 exit(0);
24312 }
24313 else
24314 {
24315 exit(1);
24316 }
24317 }
24318
24319_ACEOF
24320rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024321if { (ac_try="$ac_link"
24322case "(($ac_try" in
24323 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24324 *) ac_try_echo=$ac_try;;
24325esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024326eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024327 (eval "$ac_link") 2>&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024328 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000024329 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024330 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024331 { (case "(($ac_try" in
24332 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24333 *) ac_try_echo=$ac_try;;
24334esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024335eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024336 (eval "$ac_try") 2>&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024337 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000024338 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024339 (exit $ac_status); }; }; then
24340 ac_cv_broken_poll=yes
24341else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024342 echo "$as_me: program exited with status $ac_status" >&5
24343echo "$as_me: failed program was:" >&5
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024344sed 's/^/| /' conftest.$ac_ext >&5
24345
24346( exit $ac_status )
24347ac_cv_broken_poll=no
24348fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024349rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024350fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024351
24352
Ronald Oussoren450d5612009-06-08 21:12:41 +000024353{ echo "$as_me:$LINENO: result: $ac_cv_broken_poll" >&5
24354echo "${ECHO_T}$ac_cv_broken_poll" >&6; }
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024355if test "$ac_cv_broken_poll" = yes
24356then
24357
24358cat >>confdefs.h <<\_ACEOF
24359#define HAVE_BROKEN_POLL 1
24360_ACEOF
24361
24362fi
24363
Brett Cannon43802422005-02-10 20:48:03 +000024364# Before we can test tzset, we need to check if struct tm has a tm_zone
Martin v. Löwis1d459062005-03-14 21:23:33 +000024365# (which is not required by ISO C or UNIX spec) and/or if we support
24366# tzname[]
Ronald Oussoren450d5612009-06-08 21:12:41 +000024367{ echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
24368echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6; }
Brett Cannon43802422005-02-10 20:48:03 +000024369if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024370 echo $ECHO_N "(cached) $ECHO_C" >&6
Brett Cannon43802422005-02-10 20:48:03 +000024371else
24372 cat >conftest.$ac_ext <<_ACEOF
24373/* confdefs.h. */
24374_ACEOF
24375cat confdefs.h >>conftest.$ac_ext
24376cat >>conftest.$ac_ext <<_ACEOF
24377/* end confdefs.h. */
24378#include <sys/types.h>
24379#include <$ac_cv_struct_tm>
24380
24381
24382int
24383main ()
24384{
24385static struct tm ac_aggr;
24386if (ac_aggr.tm_zone)
24387return 0;
24388 ;
24389 return 0;
24390}
24391_ACEOF
24392rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024393if { (ac_try="$ac_compile"
24394case "(($ac_try" in
24395 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24396 *) ac_try_echo=$ac_try;;
24397esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024398eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024399 (eval "$ac_compile") 2>conftest.er1
Brett Cannon43802422005-02-10 20:48:03 +000024400 ac_status=$?
24401 grep -v '^ *+' conftest.er1 >conftest.err
24402 rm -f conftest.er1
24403 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024404 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024405 (exit $ac_status); } && {
24406 test -z "$ac_c_werror_flag" ||
24407 test ! -s conftest.err
24408 } && test -s conftest.$ac_objext; then
Brett Cannon43802422005-02-10 20:48:03 +000024409 ac_cv_member_struct_tm_tm_zone=yes
24410else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024411 echo "$as_me: failed program was:" >&5
Brett Cannon43802422005-02-10 20:48:03 +000024412sed 's/^/| /' conftest.$ac_ext >&5
24413
Martin v. Löwiseba40652007-08-30 20:10:57 +000024414 cat >conftest.$ac_ext <<_ACEOF
Brett Cannon43802422005-02-10 20:48:03 +000024415/* confdefs.h. */
24416_ACEOF
24417cat confdefs.h >>conftest.$ac_ext
24418cat >>conftest.$ac_ext <<_ACEOF
24419/* end confdefs.h. */
24420#include <sys/types.h>
24421#include <$ac_cv_struct_tm>
24422
24423
24424int
24425main ()
24426{
24427static struct tm ac_aggr;
24428if (sizeof ac_aggr.tm_zone)
24429return 0;
24430 ;
24431 return 0;
24432}
24433_ACEOF
24434rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024435if { (ac_try="$ac_compile"
24436case "(($ac_try" in
24437 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24438 *) ac_try_echo=$ac_try;;
24439esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024440eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024441 (eval "$ac_compile") 2>conftest.er1
Brett Cannon43802422005-02-10 20:48:03 +000024442 ac_status=$?
24443 grep -v '^ *+' conftest.er1 >conftest.err
24444 rm -f conftest.er1
24445 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024446 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024447 (exit $ac_status); } && {
24448 test -z "$ac_c_werror_flag" ||
24449 test ! -s conftest.err
24450 } && test -s conftest.$ac_objext; then
Brett Cannon43802422005-02-10 20:48:03 +000024451 ac_cv_member_struct_tm_tm_zone=yes
24452else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024453 echo "$as_me: failed program was:" >&5
Brett Cannon43802422005-02-10 20:48:03 +000024454sed 's/^/| /' conftest.$ac_ext >&5
24455
Martin v. Löwiseba40652007-08-30 20:10:57 +000024456 ac_cv_member_struct_tm_tm_zone=no
Brett Cannon43802422005-02-10 20:48:03 +000024457fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024458
24459rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Brett Cannon43802422005-02-10 20:48:03 +000024460fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024461
24462rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Brett Cannon43802422005-02-10 20:48:03 +000024463fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000024464{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
24465echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6; }
24466if test $ac_cv_member_struct_tm_tm_zone = yes; then
Brett Cannon43802422005-02-10 20:48:03 +000024467
24468cat >>confdefs.h <<_ACEOF
24469#define HAVE_STRUCT_TM_TM_ZONE 1
24470_ACEOF
24471
24472
24473fi
24474
24475if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
24476
24477cat >>confdefs.h <<\_ACEOF
24478#define HAVE_TM_ZONE 1
24479_ACEOF
24480
24481else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024482 { echo "$as_me:$LINENO: checking whether tzname is declared" >&5
24483echo $ECHO_N "checking whether tzname is declared... $ECHO_C" >&6; }
Martin v. Löwiseba40652007-08-30 20:10:57 +000024484if test "${ac_cv_have_decl_tzname+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024485 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwiseba40652007-08-30 20:10:57 +000024486else
24487 cat >conftest.$ac_ext <<_ACEOF
24488/* confdefs.h. */
24489_ACEOF
24490cat confdefs.h >>conftest.$ac_ext
24491cat >>conftest.$ac_ext <<_ACEOF
24492/* end confdefs.h. */
24493#include <time.h>
24494
24495int
24496main ()
24497{
24498#ifndef tzname
24499 (void) tzname;
24500#endif
24501
24502 ;
24503 return 0;
24504}
24505_ACEOF
24506rm -f conftest.$ac_objext
24507if { (ac_try="$ac_compile"
24508case "(($ac_try" in
24509 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24510 *) ac_try_echo=$ac_try;;
24511esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024512eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024513 (eval "$ac_compile") 2>conftest.er1
24514 ac_status=$?
24515 grep -v '^ *+' conftest.er1 >conftest.err
24516 rm -f conftest.er1
24517 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024519 (exit $ac_status); } && {
24520 test -z "$ac_c_werror_flag" ||
24521 test ! -s conftest.err
24522 } && test -s conftest.$ac_objext; then
24523 ac_cv_have_decl_tzname=yes
24524else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024525 echo "$as_me: failed program was:" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024526sed 's/^/| /' conftest.$ac_ext >&5
24527
24528 ac_cv_have_decl_tzname=no
24529fi
24530
24531rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24532fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000024533{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_tzname" >&5
24534echo "${ECHO_T}$ac_cv_have_decl_tzname" >&6; }
24535if test $ac_cv_have_decl_tzname = yes; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000024536
24537cat >>confdefs.h <<_ACEOF
24538#define HAVE_DECL_TZNAME 1
24539_ACEOF
24540
24541
24542else
24543 cat >>confdefs.h <<_ACEOF
24544#define HAVE_DECL_TZNAME 0
24545_ACEOF
24546
24547
24548fi
24549
24550
Ronald Oussoren450d5612009-06-08 21:12:41 +000024551 { echo "$as_me:$LINENO: checking for tzname" >&5
24552echo $ECHO_N "checking for tzname... $ECHO_C" >&6; }
Brett Cannon43802422005-02-10 20:48:03 +000024553if test "${ac_cv_var_tzname+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024554 echo $ECHO_N "(cached) $ECHO_C" >&6
Brett Cannon43802422005-02-10 20:48:03 +000024555else
24556 cat >conftest.$ac_ext <<_ACEOF
24557/* confdefs.h. */
24558_ACEOF
24559cat confdefs.h >>conftest.$ac_ext
24560cat >>conftest.$ac_ext <<_ACEOF
24561/* end confdefs.h. */
24562#include <time.h>
Martin v. Löwiseba40652007-08-30 20:10:57 +000024563#if !HAVE_DECL_TZNAME
24564extern char *tzname[];
Brett Cannon43802422005-02-10 20:48:03 +000024565#endif
24566
24567int
24568main ()
24569{
Martin v. Löwiseba40652007-08-30 20:10:57 +000024570return tzname[0][0];
Brett Cannon43802422005-02-10 20:48:03 +000024571 ;
24572 return 0;
24573}
24574_ACEOF
24575rm -f conftest.$ac_objext conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024576if { (ac_try="$ac_link"
24577case "(($ac_try" in
24578 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24579 *) ac_try_echo=$ac_try;;
24580esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024581eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024582 (eval "$ac_link") 2>conftest.er1
Brett Cannon43802422005-02-10 20:48:03 +000024583 ac_status=$?
24584 grep -v '^ *+' conftest.er1 >conftest.err
24585 rm -f conftest.er1
24586 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024587 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024588 (exit $ac_status); } && {
24589 test -z "$ac_c_werror_flag" ||
24590 test ! -s conftest.err
Ronald Oussoren450d5612009-06-08 21:12:41 +000024591 } && test -s conftest$ac_exeext &&
24592 $as_test_x conftest$ac_exeext; then
Brett Cannon43802422005-02-10 20:48:03 +000024593 ac_cv_var_tzname=yes
24594else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024595 echo "$as_me: failed program was:" >&5
Brett Cannon43802422005-02-10 20:48:03 +000024596sed 's/^/| /' conftest.$ac_ext >&5
24597
Martin v. Löwiseba40652007-08-30 20:10:57 +000024598 ac_cv_var_tzname=no
Brett Cannon43802422005-02-10 20:48:03 +000024599fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024600
24601rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
Brett Cannon43802422005-02-10 20:48:03 +000024602 conftest$ac_exeext conftest.$ac_ext
24603fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000024604{ echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
24605echo "${ECHO_T}$ac_cv_var_tzname" >&6; }
Brett Cannon43802422005-02-10 20:48:03 +000024606 if test $ac_cv_var_tzname = yes; then
24607
24608cat >>confdefs.h <<\_ACEOF
24609#define HAVE_TZNAME 1
24610_ACEOF
24611
24612 fi
24613fi
24614
Nicholas Bastine62c5c82004-03-21 23:45:42 +000024615
Martin v. Löwis1d459062005-03-14 21:23:33 +000024616# check tzset(3) exists and works like we expect it to
Ronald Oussoren450d5612009-06-08 21:12:41 +000024617{ echo "$as_me:$LINENO: checking for working tzset()" >&5
24618echo $ECHO_N "checking for working tzset()... $ECHO_C" >&6; }
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024619if test "${ac_cv_working_tzset+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024620 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024621else
24622
24623if test "$cross_compiling" = yes; then
24624 ac_cv_working_tzset=no
24625else
24626 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024627/* confdefs.h. */
24628_ACEOF
24629cat confdefs.h >>conftest.$ac_ext
24630cat >>conftest.$ac_ext <<_ACEOF
24631/* end confdefs.h. */
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024632
24633#include <stdlib.h>
24634#include <time.h>
Brett Cannon18367812003-09-19 00:59:16 +000024635#include <string.h>
Brett Cannon43802422005-02-10 20:48:03 +000024636
24637#if HAVE_TZNAME
24638extern char *tzname[];
24639#endif
24640
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024641int main()
24642{
Brett Cannon18367812003-09-19 00:59:16 +000024643 /* Note that we need to ensure that not only does tzset(3)
24644 do 'something' with localtime, but it works as documented
24645 in the library reference and as expected by the test suite.
Martin v. Löwis1d459062005-03-14 21:23:33 +000024646 This includes making sure that tzname is set properly if
24647 tm->tm_zone does not exist since it is the alternative way
24648 of getting timezone info.
Brett Cannon18367812003-09-19 00:59:16 +000024649
24650 Red Hat 6.2 doesn't understand the southern hemisphere
Martin v. Löwis1d459062005-03-14 21:23:33 +000024651 after New Year's Day.
Brett Cannon18367812003-09-19 00:59:16 +000024652 */
24653
Martin v. Löwis1d459062005-03-14 21:23:33 +000024654 time_t groundhogday = 1044144000; /* GMT-based */
Brett Cannon18367812003-09-19 00:59:16 +000024655 time_t midyear = groundhogday + (365 * 24 * 3600 / 2);
24656
Neal Norwitz7f2588c2003-04-11 15:35:53 +000024657 putenv("TZ=UTC+0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024658 tzset();
Brett Cannon18367812003-09-19 00:59:16 +000024659 if (localtime(&groundhogday)->tm_hour != 0)
24660 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000024661#if HAVE_TZNAME
24662 /* For UTC, tzname[1] is sometimes "", sometimes " " */
24663 if (strcmp(tzname[0], "UTC") ||
24664 (tzname[1][0] != 0 && tzname[1][0] != ' '))
24665 exit(1);
24666#endif
Brett Cannon18367812003-09-19 00:59:16 +000024667
Neal Norwitz7f2588c2003-04-11 15:35:53 +000024668 putenv("TZ=EST+5EDT,M4.1.0,M10.5.0");
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024669 tzset();
Brett Cannon18367812003-09-19 00:59:16 +000024670 if (localtime(&groundhogday)->tm_hour != 19)
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024671 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000024672#if HAVE_TZNAME
24673 if (strcmp(tzname[0], "EST") || strcmp(tzname[1], "EDT"))
24674 exit(1);
24675#endif
Brett Cannon18367812003-09-19 00:59:16 +000024676
24677 putenv("TZ=AEST-10AEDT-11,M10.5.0,M3.5.0");
24678 tzset();
24679 if (localtime(&groundhogday)->tm_hour != 11)
24680 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000024681#if HAVE_TZNAME
24682 if (strcmp(tzname[0], "AEST") || strcmp(tzname[1], "AEDT"))
24683 exit(1);
24684#endif
24685
24686#if HAVE_STRUCT_TM_TM_ZONE
Brett Cannon18367812003-09-19 00:59:16 +000024687 if (strcmp(localtime(&groundhogday)->tm_zone, "AEDT"))
24688 exit(1);
24689 if (strcmp(localtime(&midyear)->tm_zone, "AEST"))
24690 exit(1);
Brett Cannon43802422005-02-10 20:48:03 +000024691#endif
Brett Cannon18367812003-09-19 00:59:16 +000024692
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024693 exit(0);
24694}
24695
24696_ACEOF
24697rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024698if { (ac_try="$ac_link"
24699case "(($ac_try" in
24700 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24701 *) ac_try_echo=$ac_try;;
24702esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024703eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024704 (eval "$ac_link") 2>&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024705 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000024706 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024707 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000024708 { (case "(($ac_try" in
24709 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24710 *) ac_try_echo=$ac_try;;
24711esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024712eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024713 (eval "$ac_try") 2>&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024714 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000024715 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024716 (exit $ac_status); }; }; then
24717 ac_cv_working_tzset=yes
24718else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024719 echo "$as_me: program exited with status $ac_status" >&5
24720echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024721sed 's/^/| /' conftest.$ac_ext >&5
24722
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024723( exit $ac_status )
24724ac_cv_working_tzset=no
24725fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000024726rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024727fi
24728
Martin v. Löwiseba40652007-08-30 20:10:57 +000024729
24730fi
24731
Ronald Oussoren450d5612009-06-08 21:12:41 +000024732{ echo "$as_me:$LINENO: result: $ac_cv_working_tzset" >&5
24733echo "${ECHO_T}$ac_cv_working_tzset" >&6; }
Guido van Rossumd11b62e2003-03-14 21:51:36 +000024734if test "$ac_cv_working_tzset" = yes
24735then
24736
24737cat >>confdefs.h <<\_ACEOF
24738#define HAVE_WORKING_TZSET 1
24739_ACEOF
24740
24741fi
24742
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024743# Look for subsecond timestamps in struct stat
Ronald Oussoren450d5612009-06-08 21:12:41 +000024744{ echo "$as_me:$LINENO: checking for tv_nsec in struct stat" >&5
24745echo $ECHO_N "checking for tv_nsec in struct stat... $ECHO_C" >&6; }
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024746if test "${ac_cv_stat_tv_nsec+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024747 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024748else
24749 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024750/* confdefs.h. */
24751_ACEOF
24752cat confdefs.h >>conftest.$ac_ext
24753cat >>conftest.$ac_ext <<_ACEOF
24754/* end confdefs.h. */
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024755#include <sys/stat.h>
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024756int
24757main ()
24758{
24759
24760struct stat st;
24761st.st_mtim.tv_nsec = 1;
24762
24763 ;
24764 return 0;
24765}
24766_ACEOF
24767rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024768if { (ac_try="$ac_compile"
24769case "(($ac_try" in
24770 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24771 *) ac_try_echo=$ac_try;;
24772esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024773eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024774 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024775 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024776 grep -v '^ *+' conftest.er1 >conftest.err
24777 rm -f conftest.er1
24778 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024779 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024780 (exit $ac_status); } && {
24781 test -z "$ac_c_werror_flag" ||
24782 test ! -s conftest.err
24783 } && test -s conftest.$ac_objext; then
Martin v. Löwisa32c9942002-09-09 16:17:47 +000024784 ac_cv_stat_tv_nsec=yes
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024785else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024786 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024787sed 's/^/| /' conftest.$ac_ext >&5
24788
Martin v. Löwiseba40652007-08-30 20:10:57 +000024789 ac_cv_stat_tv_nsec=no
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024790fi
24791
Martin v. Löwiseba40652007-08-30 20:10:57 +000024792rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24793fi
24794
Ronald Oussoren450d5612009-06-08 21:12:41 +000024795{ echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec" >&5
24796echo "${ECHO_T}$ac_cv_stat_tv_nsec" >&6; }
Martin v. Löwis94717ed2002-09-09 14:24:16 +000024797if test "$ac_cv_stat_tv_nsec" = yes
24798then
24799
24800cat >>confdefs.h <<\_ACEOF
24801#define HAVE_STAT_TV_NSEC 1
24802_ACEOF
24803
24804fi
24805
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024806# Look for BSD style subsecond timestamps in struct stat
Ronald Oussoren450d5612009-06-08 21:12:41 +000024807{ echo "$as_me:$LINENO: checking for tv_nsec2 in struct stat" >&5
24808echo $ECHO_N "checking for tv_nsec2 in struct stat... $ECHO_C" >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024809if test "${ac_cv_stat_tv_nsec2+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024810 echo $ECHO_N "(cached) $ECHO_C" >&6
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024811else
24812 cat >conftest.$ac_ext <<_ACEOF
24813/* confdefs.h. */
24814_ACEOF
24815cat confdefs.h >>conftest.$ac_ext
24816cat >>conftest.$ac_ext <<_ACEOF
24817/* end confdefs.h. */
24818#include <sys/stat.h>
24819int
24820main ()
24821{
24822
24823struct stat st;
24824st.st_mtimespec.tv_nsec = 1;
24825
24826 ;
24827 return 0;
24828}
24829_ACEOF
24830rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024831if { (ac_try="$ac_compile"
24832case "(($ac_try" in
24833 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24834 *) ac_try_echo=$ac_try;;
24835esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024836eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024837 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024838 ac_status=$?
24839 grep -v '^ *+' conftest.er1 >conftest.err
24840 rm -f conftest.er1
24841 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024842 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024843 (exit $ac_status); } && {
24844 test -z "$ac_c_werror_flag" ||
24845 test ! -s conftest.err
24846 } && test -s conftest.$ac_objext; then
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024847 ac_cv_stat_tv_nsec2=yes
24848else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024849 echo "$as_me: failed program was:" >&5
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024850sed 's/^/| /' conftest.$ac_ext >&5
24851
Martin v. Löwiseba40652007-08-30 20:10:57 +000024852 ac_cv_stat_tv_nsec2=no
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024853fi
24854
Martin v. Löwiseba40652007-08-30 20:10:57 +000024855rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24856fi
24857
Ronald Oussoren450d5612009-06-08 21:12:41 +000024858{ echo "$as_me:$LINENO: result: $ac_cv_stat_tv_nsec2" >&5
24859echo "${ECHO_T}$ac_cv_stat_tv_nsec2" >&6; }
Martin v. Löwisebd9d5b2005-08-09 15:00:59 +000024860if test "$ac_cv_stat_tv_nsec2" = yes
24861then
24862
24863cat >>confdefs.h <<\_ACEOF
24864#define HAVE_STAT_TV_NSEC2 1
24865_ACEOF
24866
24867fi
24868
Jack Jansen666b1e72001-10-31 12:11:48 +000024869# On HP/UX 11.0, mvwdelch is a block with a return statement
Ronald Oussoren450d5612009-06-08 21:12:41 +000024870{ echo "$as_me:$LINENO: checking whether mvwdelch is an expression" >&5
24871echo $ECHO_N "checking whether mvwdelch is an expression... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024872if test "${ac_cv_mvwdelch_is_expression+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024873 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000024874else
Martin v. Löwis11437992002-04-12 09:54:03 +000024875 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024876/* confdefs.h. */
24877_ACEOF
24878cat confdefs.h >>conftest.$ac_ext
24879cat >>conftest.$ac_ext <<_ACEOF
24880/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000024881#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000024882int
24883main ()
24884{
Jack Jansen666b1e72001-10-31 12:11:48 +000024885
24886 int rtn;
24887 rtn = mvwdelch(0,0,0);
24888
Martin v. Löwis11437992002-04-12 09:54:03 +000024889 ;
24890 return 0;
24891}
24892_ACEOF
24893rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024894if { (ac_try="$ac_compile"
24895case "(($ac_try" in
24896 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24897 *) ac_try_echo=$ac_try;;
24898esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024899eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024900 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024901 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024902 grep -v '^ *+' conftest.er1 >conftest.err
24903 rm -f conftest.er1
24904 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024905 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024906 (exit $ac_status); } && {
24907 test -z "$ac_c_werror_flag" ||
24908 test ! -s conftest.err
24909 } && test -s conftest.$ac_objext; then
Jack Jansen666b1e72001-10-31 12:11:48 +000024910 ac_cv_mvwdelch_is_expression=yes
24911else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024912 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024913sed 's/^/| /' conftest.$ac_ext >&5
24914
Martin v. Löwiseba40652007-08-30 20:10:57 +000024915 ac_cv_mvwdelch_is_expression=no
Jack Jansen666b1e72001-10-31 12:11:48 +000024916fi
24917
Martin v. Löwiseba40652007-08-30 20:10:57 +000024918rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24919fi
24920
Ronald Oussoren450d5612009-06-08 21:12:41 +000024921{ echo "$as_me:$LINENO: result: $ac_cv_mvwdelch_is_expression" >&5
24922echo "${ECHO_T}$ac_cv_mvwdelch_is_expression" >&6; }
Jack Jansen666b1e72001-10-31 12:11:48 +000024923
24924if test "$ac_cv_mvwdelch_is_expression" = yes
24925then
Martin v. Löwis11437992002-04-12 09:54:03 +000024926
24927cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000024928#define MVWDELCH_IS_EXPRESSION 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024929_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000024930
24931fi
24932
Ronald Oussoren450d5612009-06-08 21:12:41 +000024933{ echo "$as_me:$LINENO: checking whether WINDOW has _flags" >&5
24934echo $ECHO_N "checking whether WINDOW has _flags... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000024935if test "${ac_cv_window_has_flags+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000024936 echo $ECHO_N "(cached) $ECHO_C" >&6
Jack Jansen666b1e72001-10-31 12:11:48 +000024937else
Martin v. Löwis11437992002-04-12 09:54:03 +000024938 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000024939/* confdefs.h. */
24940_ACEOF
24941cat confdefs.h >>conftest.$ac_ext
24942cat >>conftest.$ac_ext <<_ACEOF
24943/* end confdefs.h. */
Jack Jansen666b1e72001-10-31 12:11:48 +000024944#include <curses.h>
Martin v. Löwis11437992002-04-12 09:54:03 +000024945int
24946main ()
24947{
Jack Jansen666b1e72001-10-31 12:11:48 +000024948
24949 WINDOW *w;
24950 w->_flags = 0;
24951
Martin v. Löwis11437992002-04-12 09:54:03 +000024952 ;
24953 return 0;
24954}
24955_ACEOF
24956rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000024957if { (ac_try="$ac_compile"
24958case "(($ac_try" in
24959 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24960 *) ac_try_echo=$ac_try;;
24961esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000024962eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024963 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000024964 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000024965 grep -v '^ *+' conftest.er1 >conftest.err
24966 rm -f conftest.er1
24967 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000024968 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000024969 (exit $ac_status); } && {
24970 test -z "$ac_c_werror_flag" ||
24971 test ! -s conftest.err
24972 } && test -s conftest.$ac_objext; then
Jack Jansen666b1e72001-10-31 12:11:48 +000024973 ac_cv_window_has_flags=yes
24974else
Ronald Oussoren450d5612009-06-08 21:12:41 +000024975 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000024976sed 's/^/| /' conftest.$ac_ext >&5
24977
Martin v. Löwiseba40652007-08-30 20:10:57 +000024978 ac_cv_window_has_flags=no
Jack Jansen666b1e72001-10-31 12:11:48 +000024979fi
24980
Martin v. Löwiseba40652007-08-30 20:10:57 +000024981rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24982fi
24983
Ronald Oussoren450d5612009-06-08 21:12:41 +000024984{ echo "$as_me:$LINENO: result: $ac_cv_window_has_flags" >&5
24985echo "${ECHO_T}$ac_cv_window_has_flags" >&6; }
Michael W. Hudson54241132001-12-07 15:38:26 +000024986
Jack Jansen666b1e72001-10-31 12:11:48 +000024987
24988if test "$ac_cv_window_has_flags" = yes
24989then
Martin v. Löwis11437992002-04-12 09:54:03 +000024990
24991cat >>confdefs.h <<\_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000024992#define WINDOW_HAS_FLAGS 1
Martin v. Löwis11437992002-04-12 09:54:03 +000024993_ACEOF
Jack Jansen666b1e72001-10-31 12:11:48 +000024994
24995fi
24996
Ronald Oussoren450d5612009-06-08 21:12:41 +000024997{ echo "$as_me:$LINENO: checking for is_term_resized" >&5
24998echo $ECHO_N "checking for is_term_resized... $ECHO_C" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000024999cat >conftest.$ac_ext <<_ACEOF
25000/* confdefs.h. */
25001_ACEOF
25002cat confdefs.h >>conftest.$ac_ext
25003cat >>conftest.$ac_ext <<_ACEOF
25004/* end confdefs.h. */
25005#include <curses.h>
25006int
25007main ()
25008{
25009void *x=is_term_resized
25010 ;
25011 return 0;
25012}
25013_ACEOF
25014rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025015if { (ac_try="$ac_compile"
25016case "(($ac_try" in
25017 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25018 *) ac_try_echo=$ac_try;;
25019esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025020eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025021 (eval "$ac_compile") 2>conftest.er1
Walter Dörwald4994d952006-06-19 08:07:50 +000025022 ac_status=$?
25023 grep -v '^ *+' conftest.er1 >conftest.err
25024 rm -f conftest.er1
25025 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000025026 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025027 (exit $ac_status); } && {
25028 test -z "$ac_c_werror_flag" ||
25029 test ! -s conftest.err
25030 } && test -s conftest.$ac_objext; then
Walter Dörwald4994d952006-06-19 08:07:50 +000025031
25032cat >>confdefs.h <<\_ACEOF
25033#define HAVE_CURSES_IS_TERM_RESIZED 1
25034_ACEOF
25035
Ronald Oussoren450d5612009-06-08 21:12:41 +000025036 { echo "$as_me:$LINENO: result: yes" >&5
25037echo "${ECHO_T}yes" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025038else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025039 echo "$as_me: failed program was:" >&5
Walter Dörwald4994d952006-06-19 08:07:50 +000025040sed 's/^/| /' conftest.$ac_ext >&5
25041
Ronald Oussoren450d5612009-06-08 21:12:41 +000025042 { echo "$as_me:$LINENO: result: no" >&5
25043echo "${ECHO_T}no" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025044
25045fi
Walter Dörwald4994d952006-06-19 08:07:50 +000025046
Martin v. Löwiseba40652007-08-30 20:10:57 +000025047rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25048
Ronald Oussoren450d5612009-06-08 21:12:41 +000025049{ echo "$as_me:$LINENO: checking for resize_term" >&5
25050echo $ECHO_N "checking for resize_term... $ECHO_C" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025051cat >conftest.$ac_ext <<_ACEOF
25052/* confdefs.h. */
25053_ACEOF
25054cat confdefs.h >>conftest.$ac_ext
25055cat >>conftest.$ac_ext <<_ACEOF
25056/* end confdefs.h. */
25057#include <curses.h>
25058int
25059main ()
25060{
25061void *x=resize_term
25062 ;
25063 return 0;
25064}
25065_ACEOF
25066rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025067if { (ac_try="$ac_compile"
25068case "(($ac_try" in
25069 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25070 *) ac_try_echo=$ac_try;;
25071esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025072eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025073 (eval "$ac_compile") 2>conftest.er1
Walter Dörwald4994d952006-06-19 08:07:50 +000025074 ac_status=$?
25075 grep -v '^ *+' conftest.er1 >conftest.err
25076 rm -f conftest.er1
25077 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000025078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025079 (exit $ac_status); } && {
25080 test -z "$ac_c_werror_flag" ||
25081 test ! -s conftest.err
25082 } && test -s conftest.$ac_objext; then
Walter Dörwald4994d952006-06-19 08:07:50 +000025083
25084cat >>confdefs.h <<\_ACEOF
25085#define HAVE_CURSES_RESIZE_TERM 1
25086_ACEOF
25087
Ronald Oussoren450d5612009-06-08 21:12:41 +000025088 { echo "$as_me:$LINENO: result: yes" >&5
25089echo "${ECHO_T}yes" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025090else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025091 echo "$as_me: failed program was:" >&5
Walter Dörwald4994d952006-06-19 08:07:50 +000025092sed 's/^/| /' conftest.$ac_ext >&5
25093
Ronald Oussoren450d5612009-06-08 21:12:41 +000025094 { echo "$as_me:$LINENO: result: no" >&5
25095echo "${ECHO_T}no" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025096
25097fi
Walter Dörwald4994d952006-06-19 08:07:50 +000025098
Martin v. Löwiseba40652007-08-30 20:10:57 +000025099rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25100
Ronald Oussoren450d5612009-06-08 21:12:41 +000025101{ echo "$as_me:$LINENO: checking for resizeterm" >&5
25102echo $ECHO_N "checking for resizeterm... $ECHO_C" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025103cat >conftest.$ac_ext <<_ACEOF
25104/* confdefs.h. */
25105_ACEOF
25106cat confdefs.h >>conftest.$ac_ext
25107cat >>conftest.$ac_ext <<_ACEOF
25108/* end confdefs.h. */
25109#include <curses.h>
25110int
25111main ()
25112{
25113void *x=resizeterm
25114 ;
25115 return 0;
25116}
25117_ACEOF
25118rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025119if { (ac_try="$ac_compile"
25120case "(($ac_try" in
25121 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25122 *) ac_try_echo=$ac_try;;
25123esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025124eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025125 (eval "$ac_compile") 2>conftest.er1
Walter Dörwald4994d952006-06-19 08:07:50 +000025126 ac_status=$?
25127 grep -v '^ *+' conftest.er1 >conftest.err
25128 rm -f conftest.er1
25129 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000025130 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025131 (exit $ac_status); } && {
25132 test -z "$ac_c_werror_flag" ||
25133 test ! -s conftest.err
25134 } && test -s conftest.$ac_objext; then
Walter Dörwald4994d952006-06-19 08:07:50 +000025135
25136cat >>confdefs.h <<\_ACEOF
25137#define HAVE_CURSES_RESIZETERM 1
25138_ACEOF
25139
Ronald Oussoren450d5612009-06-08 21:12:41 +000025140 { echo "$as_me:$LINENO: result: yes" >&5
25141echo "${ECHO_T}yes" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025142else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025143 echo "$as_me: failed program was:" >&5
Walter Dörwald4994d952006-06-19 08:07:50 +000025144sed 's/^/| /' conftest.$ac_ext >&5
25145
Ronald Oussoren450d5612009-06-08 21:12:41 +000025146 { echo "$as_me:$LINENO: result: no" >&5
25147echo "${ECHO_T}no" >&6; }
Walter Dörwald4994d952006-06-19 08:07:50 +000025148
25149fi
Walter Dörwald4994d952006-06-19 08:07:50 +000025150
Martin v. Löwiseba40652007-08-30 20:10:57 +000025151rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25152
Ronald Oussoren450d5612009-06-08 21:12:41 +000025153{ echo "$as_me:$LINENO: checking for /dev/ptmx" >&5
25154echo $ECHO_N "checking for /dev/ptmx... $ECHO_C" >&6; }
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025155
25156if test -r /dev/ptmx
25157then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025158 { echo "$as_me:$LINENO: result: yes" >&5
25159echo "${ECHO_T}yes" >&6; }
Martin v. Löwis24a880b2002-12-31 12:55:15 +000025160
25161cat >>confdefs.h <<\_ACEOF
25162#define HAVE_DEV_PTMX 1
25163_ACEOF
25164
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025165else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025166 { echo "$as_me:$LINENO: result: no" >&5
25167echo "${ECHO_T}no" >&6; }
Martin v. Löwis24a880b2002-12-31 12:55:15 +000025168fi
25169
Ronald Oussoren450d5612009-06-08 21:12:41 +000025170{ echo "$as_me:$LINENO: checking for /dev/ptc" >&5
25171echo $ECHO_N "checking for /dev/ptc... $ECHO_C" >&6; }
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025172
25173if test -r /dev/ptc
25174then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025175 { echo "$as_me:$LINENO: result: yes" >&5
25176echo "${ECHO_T}yes" >&6; }
Neal Norwitz865400f2003-03-21 01:42:58 +000025177
25178cat >>confdefs.h <<\_ACEOF
25179#define HAVE_DEV_PTC 1
25180_ACEOF
25181
Martin v. Löwisfefbc202006-10-17 18:59:23 +000025182else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025183 { echo "$as_me:$LINENO: result: no" >&5
25184echo "${ECHO_T}no" >&6; }
Neal Norwitz865400f2003-03-21 01:42:58 +000025185fi
25186
Ronald Oussoren450d5612009-06-08 21:12:41 +000025187{ echo "$as_me:$LINENO: checking for %zd printf() format support" >&5
25188echo $ECHO_N "checking for %zd printf() format support... $ECHO_C" >&6; }
Brett Cannon09d12362006-05-11 05:11:33 +000025189if test "$cross_compiling" = yes; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025190 { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
Brett Cannon09d12362006-05-11 05:11:33 +000025191See \`config.log' for more details." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000025192echo "$as_me: error: cannot run test program while cross compiling
Brett Cannon09d12362006-05-11 05:11:33 +000025193See \`config.log' for more details." >&2;}
Ronald Oussoren450d5612009-06-08 21:12:41 +000025194 { (exit 1); exit 1; }; }
Brett Cannon09d12362006-05-11 05:11:33 +000025195else
25196 cat >conftest.$ac_ext <<_ACEOF
25197/* confdefs.h. */
25198_ACEOF
25199cat confdefs.h >>conftest.$ac_ext
25200cat >>conftest.$ac_ext <<_ACEOF
25201/* end confdefs.h. */
25202#include <stdio.h>
25203#include <stddef.h>
25204#include <string.h>
25205
Christian Heimesdb3d6cb2007-12-16 21:39:43 +000025206#ifdef HAVE_SYS_TYPES_H
25207#include <sys/types.h>
25208#endif
Neal Norwitz4a8fbdb2006-09-22 08:16:26 +000025209
25210#ifdef HAVE_SSIZE_T
25211typedef ssize_t Py_ssize_t;
25212#elif SIZEOF_VOID_P == SIZEOF_LONG
25213typedef long Py_ssize_t;
25214#else
25215typedef int Py_ssize_t;
25216#endif
Brett Cannon09d12362006-05-11 05:11:33 +000025217
Christian Heimesdb3d6cb2007-12-16 21:39:43 +000025218int main()
25219{
25220 char buffer[256];
25221
Brett Cannon09d12362006-05-11 05:11:33 +000025222 if(sprintf(buffer, "%zd", (size_t)123) < 0)
25223 return 1;
25224
Neal Norwitz4a8fbdb2006-09-22 08:16:26 +000025225 if (strcmp(buffer, "123"))
25226 return 1;
25227
25228 if (sprintf(buffer, "%zd", (Py_ssize_t)-123) < 0)
25229 return 1;
25230
25231 if (strcmp(buffer, "-123"))
Brett Cannon09d12362006-05-11 05:11:33 +000025232 return 1;
25233
25234 return 0;
25235}
25236_ACEOF
25237rm -f conftest$ac_exeext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025238if { (ac_try="$ac_link"
25239case "(($ac_try" in
25240 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25241 *) ac_try_echo=$ac_try;;
25242esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025243eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025244 (eval "$ac_link") 2>&5
Brett Cannon09d12362006-05-11 05:11:33 +000025245 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000025246 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Brett Cannon09d12362006-05-11 05:11:33 +000025247 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
Martin v. Löwiseba40652007-08-30 20:10:57 +000025248 { (case "(($ac_try" in
25249 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25250 *) ac_try_echo=$ac_try;;
25251esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025252eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025253 (eval "$ac_try") 2>&5
Brett Cannon09d12362006-05-11 05:11:33 +000025254 ac_status=$?
Ronald Oussoren450d5612009-06-08 21:12:41 +000025255 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Brett Cannon09d12362006-05-11 05:11:33 +000025256 (exit $ac_status); }; }; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025257 { echo "$as_me:$LINENO: result: yes" >&5
25258echo "${ECHO_T}yes" >&6; }
Brett Cannon09d12362006-05-11 05:11:33 +000025259
25260cat >>confdefs.h <<\_ACEOF
25261#define PY_FORMAT_SIZE_T "z"
25262_ACEOF
25263
25264else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025265 echo "$as_me: program exited with status $ac_status" >&5
25266echo "$as_me: failed program was:" >&5
Brett Cannon09d12362006-05-11 05:11:33 +000025267sed 's/^/| /' conftest.$ac_ext >&5
25268
25269( exit $ac_status )
Ronald Oussoren450d5612009-06-08 21:12:41 +000025270{ echo "$as_me:$LINENO: result: no" >&5
25271echo "${ECHO_T}no" >&6; }
Brett Cannon09d12362006-05-11 05:11:33 +000025272fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025273rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
Brett Cannon09d12362006-05-11 05:11:33 +000025274fi
25275
Martin v. Löwiseba40652007-08-30 20:10:57 +000025276
25277
Ronald Oussoren450d5612009-06-08 21:12:41 +000025278{ echo "$as_me:$LINENO: checking for socklen_t" >&5
25279echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6; }
Martin v. Löwis11437992002-04-12 09:54:03 +000025280if test "${ac_cv_type_socklen_t+set}" = set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025281 echo $ECHO_N "(cached) $ECHO_C" >&6
Guido van Rossum95713eb2000-05-18 20:53:31 +000025282else
Martin v. Löwis11437992002-04-12 09:54:03 +000025283 cat >conftest.$ac_ext <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000025284/* confdefs.h. */
25285_ACEOF
25286cat confdefs.h >>conftest.$ac_ext
25287cat >>conftest.$ac_ext <<_ACEOF
25288/* end confdefs.h. */
Martin v. Löwis01c04012002-11-11 14:58:44 +000025289
25290#ifdef HAVE_SYS_TYPES_H
25291#include <sys/types.h>
25292#endif
25293#ifdef HAVE_SYS_SOCKET_H
25294#include <sys/socket.h>
25295#endif
25296
25297
Ronald Oussoren450d5612009-06-08 21:12:41 +000025298typedef socklen_t ac__type_new_;
Martin v. Löwis11437992002-04-12 09:54:03 +000025299int
25300main ()
25301{
Ronald Oussoren450d5612009-06-08 21:12:41 +000025302if ((ac__type_new_ *) 0)
25303 return 0;
25304if (sizeof (ac__type_new_))
25305 return 0;
Martin v. Löwis11437992002-04-12 09:54:03 +000025306 ;
25307 return 0;
25308}
25309_ACEOF
25310rm -f conftest.$ac_objext
Martin v. Löwiseba40652007-08-30 20:10:57 +000025311if { (ac_try="$ac_compile"
25312case "(($ac_try" in
25313 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25314 *) ac_try_echo=$ac_try;;
25315esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025316eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025317 (eval "$ac_compile") 2>conftest.er1
Martin v. Löwis11437992002-04-12 09:54:03 +000025318 ac_status=$?
Skip Montanarof0d5f792004-08-15 14:08:23 +000025319 grep -v '^ *+' conftest.er1 >conftest.err
25320 rm -f conftest.er1
25321 cat conftest.err >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000025322 echo "$as_me:$LINENO: \$? = $ac_status" >&5
Martin v. Löwiseba40652007-08-30 20:10:57 +000025323 (exit $ac_status); } && {
25324 test -z "$ac_c_werror_flag" ||
25325 test ! -s conftest.err
25326 } && test -s conftest.$ac_objext; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025327 ac_cv_type_socklen_t=yes
Guido van Rossum95713eb2000-05-18 20:53:31 +000025328else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025329 echo "$as_me: failed program was:" >&5
Skip Montanaro6dead952003-09-25 14:50:04 +000025330sed 's/^/| /' conftest.$ac_ext >&5
25331
Ronald Oussoren450d5612009-06-08 21:12:41 +000025332 ac_cv_type_socklen_t=no
Guido van Rossum95713eb2000-05-18 20:53:31 +000025333fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025334
25335rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
Martin v. Löwis11437992002-04-12 09:54:03 +000025336fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000025337{ echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
25338echo "${ECHO_T}$ac_cv_type_socklen_t" >&6; }
25339if test $ac_cv_type_socklen_t = yes; then
Martin v. Löwis11437992002-04-12 09:54:03 +000025340 :
25341else
Guido van Rossum95713eb2000-05-18 20:53:31 +000025342
Martin v. Löwis01c04012002-11-11 14:58:44 +000025343cat >>confdefs.h <<\_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000025344#define socklen_t int
Martin v. Löwis11437992002-04-12 09:54:03 +000025345_ACEOF
Guido van Rossum95713eb2000-05-18 20:53:31 +000025346
25347fi
25348
Michael W. Hudson54241132001-12-07 15:38:26 +000025349
Michael W. Hudson54241132001-12-07 15:38:26 +000025350
25351
Martin v. Löwis06f15bb2001-12-02 13:02:32 +000025352for h in `(cd $srcdir;echo Python/thread_*.h)`
25353do
25354 THREADHEADERS="$THREADHEADERS \$(srcdir)/$h"
25355done
25356
Michael W. Hudson54241132001-12-07 15:38:26 +000025357
Neal Norwitzd24499d2005-12-18 21:36:39 +000025358SRCDIRS="Parser Grammar Objects Python Modules Mac"
Ronald Oussoren450d5612009-06-08 21:12:41 +000025359{ echo "$as_me:$LINENO: checking for build directories" >&5
25360echo $ECHO_N "checking for build directories... $ECHO_C" >&6; }
Neil Schemenauerd32c2492001-01-24 17:25:28 +000025361for dir in $SRCDIRS; do
25362 if test ! -d $dir; then
25363 mkdir $dir
Guido van Rossum262cf202000-11-02 19:33:53 +000025364 fi
Neil Schemenauerd32c2492001-01-24 17:25:28 +000025365done
Ronald Oussoren450d5612009-06-08 21:12:41 +000025366{ echo "$as_me:$LINENO: result: done" >&5
25367echo "${ECHO_T}done" >&6; }
Fred Drake036144d2000-10-26 17:09:35 +000025368
Guido van Rossum627b2d71993-12-24 10:39:16 +000025369# generate output files
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025370ac_config_files="$ac_config_files Makefile.pre Modules/Setup.config Misc/python.pc"
Martin v. Löwis88afe662002-10-26 13:47:44 +000025371
Martin v. Löwis11437992002-04-12 09:54:03 +000025372cat >confcache <<\_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025373# This file is a shell script that caches the results of configure
25374# tests run on this system so they can be shared between configure
Martin v. Löwis11437992002-04-12 09:54:03 +000025375# scripts and configure runs, see configure's option --config-cache.
25376# It is not useful on other systems. If it contains results you don't
25377# want to keep, you may remove or edit it.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025378#
Martin v. Löwis11437992002-04-12 09:54:03 +000025379# config.status only pays attention to the cache file if you give it
25380# the --recheck option to rerun configure.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025381#
Skip Montanaro6dead952003-09-25 14:50:04 +000025382# `ac_cv_env_foo' variables (set or unset) will be overridden when
Martin v. Löwis11437992002-04-12 09:54:03 +000025383# loading this file, other *unset* `ac_cv_foo' will be assigned the
25384# following values.
25385
25386_ACEOF
25387
Guido van Rossumf78abae1997-01-21 22:02:36 +000025388# The following way of writing the cache mishandles newlines in values,
25389# but we know of no workaround that is simple, portable, and efficient.
Martin v. Löwiseba40652007-08-30 20:10:57 +000025390# So, we kill variables containing newlines.
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000025391# Ultrix sh set writes to stderr and can't be redirected directly,
25392# and sets the high bit in the cache file unless we assign to the vars.
Martin v. Löwiseba40652007-08-30 20:10:57 +000025393(
25394 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
25395 eval ac_val=\$$ac_var
25396 case $ac_val in #(
25397 *${as_nl}*)
25398 case $ac_var in #(
Ronald Oussoren450d5612009-06-08 21:12:41 +000025399 *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
25400echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025401 esac
25402 case $ac_var in #(
25403 _ | IFS | as_nl) ;; #(
25404 *) $as_unset $ac_var ;;
25405 esac ;;
25406 esac
25407 done
25408
Martin v. Löwis11437992002-04-12 09:54:03 +000025409 (set) 2>&1 |
Martin v. Löwiseba40652007-08-30 20:10:57 +000025410 case $as_nl`(ac_space=' '; set) 2>&1` in #(
25411 *${as_nl}ac_space=\ *)
Martin v. Löwis11437992002-04-12 09:54:03 +000025412 # `set' does not quote correctly, so add quotes (double-quote
25413 # substitution turns \\\\ into \\, and sed turns \\ into \).
25414 sed -n \
Skip Montanarof0d5f792004-08-15 14:08:23 +000025415 "s/'/'\\\\''/g;
25416 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
Martin v. Löwiseba40652007-08-30 20:10:57 +000025417 ;; #(
Martin v. Löwis11437992002-04-12 09:54:03 +000025418 *)
25419 # `set' quotes correctly as required by POSIX, so do not add quotes.
Martin v. Löwiseba40652007-08-30 20:10:57 +000025420 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
Martin v. Löwis11437992002-04-12 09:54:03 +000025421 ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025422 esac |
25423 sort
25424) |
Martin v. Löwis11437992002-04-12 09:54:03 +000025425 sed '
Martin v. Löwiseba40652007-08-30 20:10:57 +000025426 /^ac_cv_env_/b end
Martin v. Löwis11437992002-04-12 09:54:03 +000025427 t clear
Martin v. Löwiseba40652007-08-30 20:10:57 +000025428 :clear
Martin v. Löwis11437992002-04-12 09:54:03 +000025429 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
25430 t end
Martin v. Löwiseba40652007-08-30 20:10:57 +000025431 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
25432 :end' >>confcache
25433if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
25434 if test -w "$cache_file"; then
25435 test "x$cache_file" != "x/dev/null" &&
Ronald Oussoren450d5612009-06-08 21:12:41 +000025436 { echo "$as_me:$LINENO: updating cache $cache_file" >&5
25437echo "$as_me: updating cache $cache_file" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +000025438 cat confcache >$cache_file
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000025439 else
Ronald Oussoren450d5612009-06-08 21:12:41 +000025440 { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
25441echo "$as_me: not updating unwritable cache $cache_file" >&6;}
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000025442 fi
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025443fi
Guido van Rossum8ddd0ad1995-06-14 23:10:28 +000025444rm -f confcache
Guido van Rossum0a516c91994-09-12 10:58:40 +000025445
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025446test "x$prefix" = xNONE && prefix=$ac_default_prefix
25447# Let make expand exec_prefix.
25448test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
Guido van Rossum0a516c91994-09-12 10:58:40 +000025449
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025450DEFS=-DHAVE_CONFIG_H
25451
Skip Montanaro6dead952003-09-25 14:50:04 +000025452ac_libobjs=
25453ac_ltlibobjs=
25454for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
25455 # 1. Remove the extension, and $U if already installed.
Martin v. Löwiseba40652007-08-30 20:10:57 +000025456 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
Ronald Oussoren450d5612009-06-08 21:12:41 +000025457 ac_i=`echo "$ac_i" | sed "$ac_script"`
Martin v. Löwiseba40652007-08-30 20:10:57 +000025458 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
25459 # will be set to the directory where LIBOBJS objects are built.
25460 ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
25461 ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
Skip Montanaro6dead952003-09-25 14:50:04 +000025462done
25463LIBOBJS=$ac_libobjs
25464
25465LTLIBOBJS=$ac_ltlibobjs
25466
25467
Martin v. Löwis11437992002-04-12 09:54:03 +000025468
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025469: ${CONFIG_STATUS=./config.status}
Martin v. Löwis11437992002-04-12 09:54:03 +000025470ac_clean_files_save=$ac_clean_files
25471ac_clean_files="$ac_clean_files $CONFIG_STATUS"
Ronald Oussoren450d5612009-06-08 21:12:41 +000025472{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
25473echo "$as_me: creating $CONFIG_STATUS" >&6;}
25474cat >$CONFIG_STATUS <<_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025475#! $SHELL
25476# Generated by $as_me.
Guido van Rossum627b2d71993-12-24 10:39:16 +000025477# Run this file to recreate the current configuration.
Guido van Rossum76be6ed1995-01-02 18:33:54 +000025478# Compiler output produced by configure, useful for debugging
Martin v. Löwis11437992002-04-12 09:54:03 +000025479# configure, is in config.log if it exists.
Guido van Rossum627b2d71993-12-24 10:39:16 +000025480
Martin v. Löwis11437992002-04-12 09:54:03 +000025481debug=false
Skip Montanaro6dead952003-09-25 14:50:04 +000025482ac_cs_recheck=false
25483ac_cs_silent=false
Martin v. Löwis11437992002-04-12 09:54:03 +000025484SHELL=\${CONFIG_SHELL-$SHELL}
25485_ACEOF
Jack Jansendd19cf82001-12-06 22:36:17 +000025486
Ronald Oussoren450d5612009-06-08 21:12:41 +000025487cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025488## --------------------- ##
25489## M4sh Initialization. ##
25490## --------------------- ##
Jack Jansendd19cf82001-12-06 22:36:17 +000025491
Martin v. Löwiseba40652007-08-30 20:10:57 +000025492# Be more Bourne compatible
25493DUALCASE=1; export DUALCASE # for MKS sh
Martin v. Löwis11437992002-04-12 09:54:03 +000025494if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
25495 emulate sh
25496 NULLCMD=:
Ronald Oussoren450d5612009-06-08 21:12:41 +000025497 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
Skip Montanaro6dead952003-09-25 14:50:04 +000025498 # is contrary to our usage. Disable this feature.
25499 alias -g '${1+"$@"}'='"$@"'
Martin v. Löwiseba40652007-08-30 20:10:57 +000025500 setopt NO_GLOB_SUBST
Skip Montanaro89e975f2007-08-22 19:05:21 +000025501else
Martin v. Löwiseba40652007-08-30 20:10:57 +000025502 case `(set -o) 2>/dev/null` in
25503 *posix*) set -o posix ;;
25504esac
25505
Martin v. Löwis11437992002-04-12 09:54:03 +000025506fi
Michael W. Hudson54241132001-12-07 15:38:26 +000025507
Skip Montanaro6dead952003-09-25 14:50:04 +000025508
Martin v. Löwis11437992002-04-12 09:54:03 +000025509
25510
Martin v. Löwiseba40652007-08-30 20:10:57 +000025511# PATH needs CR
Martin v. Löwis11437992002-04-12 09:54:03 +000025512# Avoid depending upon Character Ranges.
25513as_cr_letters='abcdefghijklmnopqrstuvwxyz'
25514as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
25515as_cr_Letters=$as_cr_letters$as_cr_LETTERS
25516as_cr_digits='0123456789'
25517as_cr_alnum=$as_cr_Letters$as_cr_digits
25518
25519# The user is always right.
25520if test "${PATH_SEPARATOR+set}" != set; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025521 echo "#! /bin/sh" >conf$$.sh
25522 echo "exit 0" >>conf$$.sh
25523 chmod +x conf$$.sh
25524 if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
25525 PATH_SEPARATOR=';'
25526 else
25527 PATH_SEPARATOR=:
25528 fi
25529 rm -f conf$$.sh
Martin v. Löwis11437992002-04-12 09:54:03 +000025530fi
25531
Martin v. Löwiseba40652007-08-30 20:10:57 +000025532# Support unset when possible.
25533if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
25534 as_unset=unset
25535else
25536 as_unset=false
25537fi
Martin v. Löwis11437992002-04-12 09:54:03 +000025538
Martin v. Löwiseba40652007-08-30 20:10:57 +000025539
25540# IFS
25541# We need space, tab and new line, in precisely that order. Quoting is
25542# there to prevent editors from complaining about space-tab.
25543# (If _AS_PATH_WALK were called with IFS unset, it would disable word
25544# splitting by setting IFS to empty value.)
Ronald Oussoren450d5612009-06-08 21:12:41 +000025545as_nl='
25546'
Martin v. Löwiseba40652007-08-30 20:10:57 +000025547IFS=" "" $as_nl"
25548
25549# Find who we are. Look in the path if we contain no directory separator.
25550case $0 in
25551 *[\\/]* ) as_myself=$0 ;;
25552 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
Martin v. Löwis11437992002-04-12 09:54:03 +000025553for as_dir in $PATH
25554do
25555 IFS=$as_save_IFS
25556 test -z "$as_dir" && as_dir=.
25557 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
25558done
Martin v. Löwiseba40652007-08-30 20:10:57 +000025559IFS=$as_save_IFS
Martin v. Löwis11437992002-04-12 09:54:03 +000025560
Martin v. Löwiseba40652007-08-30 20:10:57 +000025561 ;;
25562esac
25563# We did not find ourselves, most probably we were run as `sh COMMAND'
25564# in which case we are not to be found in the path.
25565if test "x$as_myself" = x; then
25566 as_myself=$0
25567fi
25568if test ! -f "$as_myself"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025569 echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
Martin v. Löwiseba40652007-08-30 20:10:57 +000025570 { (exit 1); exit 1; }
25571fi
25572
25573# Work around bugs in pre-3.0 UWIN ksh.
25574for as_var in ENV MAIL MAILPATH
25575do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
25576done
25577PS1='$ '
25578PS2='> '
25579PS4='+ '
25580
25581# NLS nuisances.
Ronald Oussoren450d5612009-06-08 21:12:41 +000025582for as_var in \
25583 LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
25584 LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
25585 LC_TELEPHONE LC_TIME
25586do
25587 if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
25588 eval $as_var=C; export $as_var
25589 else
25590 ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
25591 fi
25592done
Martin v. Löwiseba40652007-08-30 20:10:57 +000025593
25594# Required to use basename.
25595if expr a : '\(a\)' >/dev/null 2>&1 &&
25596 test "X`expr 00001 : '.*\(...\)'`" = X001; then
25597 as_expr=expr
25598else
25599 as_expr=false
25600fi
25601
25602if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
25603 as_basename=basename
25604else
25605 as_basename=false
25606fi
25607
25608
25609# Name of the executable.
25610as_me=`$as_basename -- "$0" ||
25611$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
25612 X"$0" : 'X\(//\)$' \| \
25613 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
Ronald Oussoren450d5612009-06-08 21:12:41 +000025614echo X/"$0" |
Martin v. Löwiseba40652007-08-30 20:10:57 +000025615 sed '/^.*\/\([^/][^/]*\)\/*$/{
25616 s//\1/
25617 q
25618 }
25619 /^X\/\(\/\/\)$/{
25620 s//\1/
25621 q
25622 }
25623 /^X\/\(\/\).*/{
25624 s//\1/
25625 q
25626 }
25627 s/.*/./; q'`
25628
25629# CDPATH.
25630$as_unset CDPATH
25631
25632
25633
Martin v. Löwis11437992002-04-12 09:54:03 +000025634 as_lineno_1=$LINENO
25635 as_lineno_2=$LINENO
Martin v. Löwis11437992002-04-12 09:54:03 +000025636 test "x$as_lineno_1" != "x$as_lineno_2" &&
Martin v. Löwiseba40652007-08-30 20:10:57 +000025637 test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
Jack Jansendd19cf82001-12-06 22:36:17 +000025638
Martin v. Löwis11437992002-04-12 09:54:03 +000025639 # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
25640 # uniformly replaced by the line number. The first 'sed' inserts a
Martin v. Löwiseba40652007-08-30 20:10:57 +000025641 # line-number line after each line using $LINENO; the second 'sed'
25642 # does the real work. The second script uses 'N' to pair each
25643 # line-number line with the line containing $LINENO, and appends
25644 # trailing '-' during substitution so that $LINENO is not a special
25645 # case at line end.
Martin v. Löwis11437992002-04-12 09:54:03 +000025646 # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
Martin v. Löwiseba40652007-08-30 20:10:57 +000025647 # scripts with optimization help from Paolo Bonzini. Blame Lee
25648 # E. McMahon (1931-1989) for sed's syntax. :-)
25649 sed -n '
25650 p
25651 /[$]LINENO/=
25652 ' <$as_myself |
Martin v. Löwis11437992002-04-12 09:54:03 +000025653 sed '
Martin v. Löwiseba40652007-08-30 20:10:57 +000025654 s/[$]LINENO.*/&-/
25655 t lineno
25656 b
25657 :lineno
Martin v. Löwis11437992002-04-12 09:54:03 +000025658 N
Martin v. Löwiseba40652007-08-30 20:10:57 +000025659 :loop
25660 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
Martin v. Löwis11437992002-04-12 09:54:03 +000025661 t loop
Martin v. Löwiseba40652007-08-30 20:10:57 +000025662 s/-\n.*//
Martin v. Löwis11437992002-04-12 09:54:03 +000025663 ' >$as_me.lineno &&
Martin v. Löwiseba40652007-08-30 20:10:57 +000025664 chmod +x "$as_me.lineno" ||
Ronald Oussoren450d5612009-06-08 21:12:41 +000025665 { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000025666 { (exit 1); exit 1; }; }
Michael W. Hudson54241132001-12-07 15:38:26 +000025667
Martin v. Löwis11437992002-04-12 09:54:03 +000025668 # Don't try to exec as it changes $[0], causing all sort of problems
25669 # (the dirname of $[0] is not the place where we might find the
Martin v. Löwiseba40652007-08-30 20:10:57 +000025670 # original and so on. Autoconf is especially sensitive to this).
25671 . "./$as_me.lineno"
Martin v. Löwis11437992002-04-12 09:54:03 +000025672 # Exit status is that of the last command.
25673 exit
25674}
25675
25676
Martin v. Löwiseba40652007-08-30 20:10:57 +000025677if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
25678 as_dirname=dirname
25679else
25680 as_dirname=false
25681fi
25682
25683ECHO_C= ECHO_N= ECHO_T=
25684case `echo -n x` in
25685-n*)
25686 case `echo 'x\c'` in
25687 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
25688 *) ECHO_C='\c';;
25689 esac;;
25690*)
25691 ECHO_N='-n';;
Martin v. Löwis11437992002-04-12 09:54:03 +000025692esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000025693
Martin v. Löwiseba40652007-08-30 20:10:57 +000025694if expr a : '\(a\)' >/dev/null 2>&1 &&
25695 test "X`expr 00001 : '.*\(...\)'`" = X001; then
Martin v. Löwis11437992002-04-12 09:54:03 +000025696 as_expr=expr
25697else
25698 as_expr=false
25699fi
25700
25701rm -f conf$$ conf$$.exe conf$$.file
Martin v. Löwiseba40652007-08-30 20:10:57 +000025702if test -d conf$$.dir; then
25703 rm -f conf$$.dir/conf$$.file
25704else
25705 rm -f conf$$.dir
Ronald Oussoren450d5612009-06-08 21:12:41 +000025706 mkdir conf$$.dir
Martin v. Löwiseba40652007-08-30 20:10:57 +000025707fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000025708echo >conf$$.file
25709if ln -s conf$$.file conf$$ 2>/dev/null; then
25710 as_ln_s='ln -s'
25711 # ... but there are two gotchas:
25712 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
25713 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
25714 # In both cases, we have to default to `cp -p'.
25715 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
Martin v. Löwis11437992002-04-12 09:54:03 +000025716 as_ln_s='cp -p'
Ronald Oussoren450d5612009-06-08 21:12:41 +000025717elif ln conf$$.file conf$$ 2>/dev/null; then
25718 as_ln_s=ln
Martin v. Löwis11437992002-04-12 09:54:03 +000025719else
25720 as_ln_s='cp -p'
25721fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000025722rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
25723rmdir conf$$.dir 2>/dev/null
Martin v. Löwis11437992002-04-12 09:54:03 +000025724
Skip Montanaro6dead952003-09-25 14:50:04 +000025725if mkdir -p . 2>/dev/null; then
25726 as_mkdir_p=:
25727else
Skip Montanarof0d5f792004-08-15 14:08:23 +000025728 test -d ./-p && rmdir ./-p
Skip Montanaro6dead952003-09-25 14:50:04 +000025729 as_mkdir_p=false
25730fi
25731
Martin v. Löwiseba40652007-08-30 20:10:57 +000025732if test -x / >/dev/null 2>&1; then
25733 as_test_x='test -x'
25734else
25735 if ls -dL / >/dev/null 2>&1; then
25736 as_ls_L_option=L
25737 else
25738 as_ls_L_option=
25739 fi
25740 as_test_x='
25741 eval sh -c '\''
25742 if test -d "$1"; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025743 test -d "$1/.";
Martin v. Löwiseba40652007-08-30 20:10:57 +000025744 else
25745 case $1 in
Ronald Oussoren450d5612009-06-08 21:12:41 +000025746 -*)set "./$1";;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025747 esac;
25748 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
25749 ???[sx]*):;;*)false;;esac;fi
25750 '\'' sh
25751 '
25752fi
25753as_executable_p=$as_test_x
Martin v. Löwis11437992002-04-12 09:54:03 +000025754
25755# Sed expression to map a string onto a valid CPP name.
Skip Montanarof0d5f792004-08-15 14:08:23 +000025756as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +000025757
25758# Sed expression to map a string onto a valid variable name.
Skip Montanarof0d5f792004-08-15 14:08:23 +000025759as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
Martin v. Löwis11437992002-04-12 09:54:03 +000025760
25761
Martin v. Löwis11437992002-04-12 09:54:03 +000025762exec 6>&1
25763
Martin v. Löwiseba40652007-08-30 20:10:57 +000025764# Save the log message, to keep $[0] and so on meaningful, and to
Martin v. Löwis11437992002-04-12 09:54:03 +000025765# report actual input values of CONFIG_FILES etc. instead of their
Martin v. Löwiseba40652007-08-30 20:10:57 +000025766# values after options handling.
25767ac_log="
Martin v. Löwis174440b2008-10-03 08:59:41 +000025768This file was extended by python $as_me 2.7, which was
Ronald Oussoren450d5612009-06-08 21:12:41 +000025769generated by GNU Autoconf 2.61. Invocation command line was
Martin v. Löwis11437992002-04-12 09:54:03 +000025770
25771 CONFIG_FILES = $CONFIG_FILES
25772 CONFIG_HEADERS = $CONFIG_HEADERS
25773 CONFIG_LINKS = $CONFIG_LINKS
25774 CONFIG_COMMANDS = $CONFIG_COMMANDS
25775 $ $0 $@
25776
Martin v. Löwiseba40652007-08-30 20:10:57 +000025777on `(hostname || uname -n) 2>/dev/null | sed 1q`
25778"
25779
Martin v. Löwis11437992002-04-12 09:54:03 +000025780_ACEOF
25781
Ronald Oussoren450d5612009-06-08 21:12:41 +000025782cat >>$CONFIG_STATUS <<_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025783# Files that config.status was made for.
Ronald Oussoren450d5612009-06-08 21:12:41 +000025784config_files="$ac_config_files"
25785config_headers="$ac_config_headers"
Martin v. Löwis11437992002-04-12 09:54:03 +000025786
Martin v. Löwiseba40652007-08-30 20:10:57 +000025787_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025788
Ronald Oussoren450d5612009-06-08 21:12:41 +000025789cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025790ac_cs_usage="\
25791\`$as_me' instantiates files from templates according to the
25792current configuration.
25793
Ronald Oussoren450d5612009-06-08 21:12:41 +000025794Usage: $0 [OPTIONS] [FILE]...
Martin v. Löwis11437992002-04-12 09:54:03 +000025795
25796 -h, --help print this help, then exit
Martin v. Löwiseba40652007-08-30 20:10:57 +000025797 -V, --version print version number and configuration settings, then exit
Ronald Oussoren450d5612009-06-08 21:12:41 +000025798 -q, --quiet do not print progress messages
Martin v. Löwis11437992002-04-12 09:54:03 +000025799 -d, --debug don't remove temporary files
25800 --recheck update $as_me by reconfiguring in the same conditions
Ronald Oussoren450d5612009-06-08 21:12:41 +000025801 --file=FILE[:TEMPLATE]
25802 instantiate the configuration file FILE
25803 --header=FILE[:TEMPLATE]
25804 instantiate the configuration header FILE
Martin v. Löwis11437992002-04-12 09:54:03 +000025805
25806Configuration files:
25807$config_files
25808
25809Configuration headers:
25810$config_headers
25811
25812Report bugs to <bug-autoconf@gnu.org>."
Skip Montanaro89e975f2007-08-22 19:05:21 +000025813
Martin v. Löwiseba40652007-08-30 20:10:57 +000025814_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000025815cat >>$CONFIG_STATUS <<_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025816ac_cs_version="\\
Martin v. Löwis174440b2008-10-03 08:59:41 +000025817python config.status 2.7
Ronald Oussoren450d5612009-06-08 21:12:41 +000025818configured by $0, generated by GNU Autoconf 2.61,
25819 with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
Martin v. Löwis11437992002-04-12 09:54:03 +000025820
Ronald Oussoren450d5612009-06-08 21:12:41 +000025821Copyright (C) 2006 Free Software Foundation, Inc.
Martin v. Löwis11437992002-04-12 09:54:03 +000025822This config.status script is free software; the Free Software Foundation
25823gives unlimited permission to copy, distribute and modify it."
Martin v. Löwiseba40652007-08-30 20:10:57 +000025824
25825ac_pwd='$ac_pwd'
25826srcdir='$srcdir'
25827INSTALL='$INSTALL'
Martin v. Löwis11437992002-04-12 09:54:03 +000025828_ACEOF
25829
Ronald Oussoren450d5612009-06-08 21:12:41 +000025830cat >>$CONFIG_STATUS <<\_ACEOF
25831# If no file are specified by the user, then we need to provide default
25832# value. By we need to know if files were specified by the user.
Martin v. Löwis11437992002-04-12 09:54:03 +000025833ac_need_defaults=:
25834while test $# != 0
25835do
25836 case $1 in
25837 --*=*)
Martin v. Löwiseba40652007-08-30 20:10:57 +000025838 ac_option=`expr "X$1" : 'X\([^=]*\)='`
25839 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
Skip Montanaro6dead952003-09-25 14:50:04 +000025840 ac_shift=:
Martin v. Löwis11437992002-04-12 09:54:03 +000025841 ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025842 *)
Skip Montanaro6dead952003-09-25 14:50:04 +000025843 ac_option=$1
25844 ac_optarg=$2
25845 ac_shift=shift
25846 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000025847 esac
25848
Skip Montanaro6dead952003-09-25 14:50:04 +000025849 case $ac_option in
Martin v. Löwis11437992002-04-12 09:54:03 +000025850 # Handling of the options.
Skip Montanaro6dead952003-09-25 14:50:04 +000025851 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25852 ac_cs_recheck=: ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025853 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
Ronald Oussoren450d5612009-06-08 21:12:41 +000025854 echo "$ac_cs_version"; exit ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025855 --debug | --debu | --deb | --de | --d | -d )
Martin v. Löwis11437992002-04-12 09:54:03 +000025856 debug=: ;;
25857 --file | --fil | --fi | --f )
Skip Montanaro6dead952003-09-25 14:50:04 +000025858 $ac_shift
Ronald Oussoren450d5612009-06-08 21:12:41 +000025859 CONFIG_FILES="$CONFIG_FILES $ac_optarg"
Martin v. Löwis11437992002-04-12 09:54:03 +000025860 ac_need_defaults=false;;
25861 --header | --heade | --head | --hea )
Skip Montanaro6dead952003-09-25 14:50:04 +000025862 $ac_shift
Ronald Oussoren450d5612009-06-08 21:12:41 +000025863 CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
Martin v. Löwis11437992002-04-12 09:54:03 +000025864 ac_need_defaults=false;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025865 --he | --h)
25866 # Conflict between --help and --header
Ronald Oussoren450d5612009-06-08 21:12:41 +000025867 { echo "$as_me: error: ambiguous option: $1
Martin v. Löwiseba40652007-08-30 20:10:57 +000025868Try \`$0 --help' for more information." >&2
25869 { (exit 1); exit 1; }; };;
25870 --help | --hel | -h )
Ronald Oussoren450d5612009-06-08 21:12:41 +000025871 echo "$ac_cs_usage"; exit ;;
Skip Montanaro6dead952003-09-25 14:50:04 +000025872 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25873 | -silent | --silent | --silen | --sile | --sil | --si | --s)
25874 ac_cs_silent=: ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000025875
25876 # This is an error.
Ronald Oussoren450d5612009-06-08 21:12:41 +000025877 -*) { echo "$as_me: error: unrecognized option: $1
Martin v. Löwiseba40652007-08-30 20:10:57 +000025878Try \`$0 --help' for more information." >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000025879 { (exit 1); exit 1; }; } ;;
25880
Martin v. Löwiseba40652007-08-30 20:10:57 +000025881 *) ac_config_targets="$ac_config_targets $1"
25882 ac_need_defaults=false ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000025883
25884 esac
25885 shift
25886done
25887
Skip Montanaro6dead952003-09-25 14:50:04 +000025888ac_configure_extra_args=
25889
25890if $ac_cs_silent; then
25891 exec 6>/dev/null
25892 ac_configure_extra_args="$ac_configure_extra_args --silent"
25893fi
25894
25895_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000025896cat >>$CONFIG_STATUS <<_ACEOF
Skip Montanaro6dead952003-09-25 14:50:04 +000025897if \$ac_cs_recheck; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000025898 echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
25899 CONFIG_SHELL=$SHELL
Martin v. Löwiseba40652007-08-30 20:10:57 +000025900 export CONFIG_SHELL
Ronald Oussoren450d5612009-06-08 21:12:41 +000025901 exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
Skip Montanaro6dead952003-09-25 14:50:04 +000025902fi
25903
Martin v. Löwis11437992002-04-12 09:54:03 +000025904_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000025905cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000025906exec 5>>config.log
25907{
25908 echo
25909 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25910## Running $as_me. ##
25911_ASBOX
Ronald Oussoren450d5612009-06-08 21:12:41 +000025912 echo "$ac_log"
Martin v. Löwiseba40652007-08-30 20:10:57 +000025913} >&5
Martin v. Löwis11437992002-04-12 09:54:03 +000025914
Martin v. Löwiseba40652007-08-30 20:10:57 +000025915_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000025916cat >>$CONFIG_STATUS <<_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000025917_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000025918
Ronald Oussoren450d5612009-06-08 21:12:41 +000025919cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000025920
25921# Handling of arguments.
Martin v. Löwis11437992002-04-12 09:54:03 +000025922for ac_config_target in $ac_config_targets
25923do
Martin v. Löwiseba40652007-08-30 20:10:57 +000025924 case $ac_config_target in
25925 "pyconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS pyconfig.h" ;;
25926 "Mac/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/Makefile" ;;
25927 "Mac/PythonLauncher/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/PythonLauncher/Makefile" ;;
25928 "Mac/IDLE/Makefile") CONFIG_FILES="$CONFIG_FILES Mac/IDLE/Makefile" ;;
Ronald Oussoren580c7fe2008-05-02 19:45:11 +000025929 "Mac/Resources/framework/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/framework/Info.plist" ;;
25930 "Mac/Resources/app/Info.plist") CONFIG_FILES="$CONFIG_FILES Mac/Resources/app/Info.plist" ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025931 "Makefile.pre") CONFIG_FILES="$CONFIG_FILES Makefile.pre" ;;
25932 "Modules/Setup.config") CONFIG_FILES="$CONFIG_FILES Modules/Setup.config" ;;
Antoine Pitrouf2caeed2009-05-24 20:23:57 +000025933 "Misc/python.pc") CONFIG_FILES="$CONFIG_FILES Misc/python.pc" ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000025934
Ronald Oussoren450d5612009-06-08 21:12:41 +000025935 *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
25936echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
Martin v. Löwis11437992002-04-12 09:54:03 +000025937 { (exit 1); exit 1; }; };;
25938 esac
25939done
25940
Martin v. Löwiseba40652007-08-30 20:10:57 +000025941
Martin v. Löwis11437992002-04-12 09:54:03 +000025942# If the user did not use the arguments to specify the items to instantiate,
25943# then the envvar interface is used. Set only those that are not.
25944# We use the long form for the default assignment because of an extremely
25945# bizarre bug on SunOS 4.1.3.
25946if $ac_need_defaults; then
25947 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25948 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25949fi
25950
Skip Montanaro6dead952003-09-25 14:50:04 +000025951# Have a temporary directory for convenience. Make it in the build tree
Martin v. Löwiseba40652007-08-30 20:10:57 +000025952# simply because there is no reason against having it here, and in addition,
Skip Montanaro6dead952003-09-25 14:50:04 +000025953# creating and moving files from /tmp can sometimes cause problems.
Martin v. Löwiseba40652007-08-30 20:10:57 +000025954# Hook for its removal unless debugging.
25955# Note that there is a small window in which the directory will not be cleaned:
25956# after its creation but before its name has been assigned to `$tmp'.
Martin v. Löwis11437992002-04-12 09:54:03 +000025957$debug ||
25958{
Martin v. Löwiseba40652007-08-30 20:10:57 +000025959 tmp=
25960 trap 'exit_status=$?
25961 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25962' 0
Martin v. Löwis11437992002-04-12 09:54:03 +000025963 trap '{ (exit 1); exit 1; }' 1 2 13 15
25964}
Martin v. Löwis11437992002-04-12 09:54:03 +000025965# Create a (secure) tmp directory for tmp files.
Skip Montanaro6dead952003-09-25 14:50:04 +000025966
Martin v. Löwis11437992002-04-12 09:54:03 +000025967{
Martin v. Löwiseba40652007-08-30 20:10:57 +000025968 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
Martin v. Löwis11437992002-04-12 09:54:03 +000025969 test -n "$tmp" && test -d "$tmp"
25970} ||
25971{
Martin v. Löwiseba40652007-08-30 20:10:57 +000025972 tmp=./conf$$-$RANDOM
25973 (umask 077 && mkdir "$tmp")
Martin v. Löwis11437992002-04-12 09:54:03 +000025974} ||
25975{
Ronald Oussoren450d5612009-06-08 21:12:41 +000025976 echo "$me: cannot create a temporary directory in ." >&2
Martin v. Löwis11437992002-04-12 09:54:03 +000025977 { (exit 1); exit 1; }
25978}
25979
Ronald Oussoren450d5612009-06-08 21:12:41 +000025980#
25981# Set up the sed scripts for CONFIG_FILES section.
25982#
25983
25984# No need to generate the scripts if there are no CONFIG_FILES.
25985# This happens for instance when ./config.status config.h
Martin v. Löwiseba40652007-08-30 20:10:57 +000025986if test -n "$CONFIG_FILES"; then
Martin v. Löwis11437992002-04-12 09:54:03 +000025987
25988_ACEOF
25989
Martin v. Löwiseba40652007-08-30 20:10:57 +000025990
Ronald Oussoren450d5612009-06-08 21:12:41 +000025991
Martin v. Löwiseba40652007-08-30 20:10:57 +000025992ac_delim='%!_!# '
25993for ac_last_try in false false false false false :; do
Ronald Oussoren450d5612009-06-08 21:12:41 +000025994 cat >conf$$subs.sed <<_ACEOF
25995SHELL!$SHELL$ac_delim
25996PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
25997PACKAGE_NAME!$PACKAGE_NAME$ac_delim
25998PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
25999PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
26000PACKAGE_STRING!$PACKAGE_STRING$ac_delim
26001PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
26002exec_prefix!$exec_prefix$ac_delim
26003prefix!$prefix$ac_delim
26004program_transform_name!$program_transform_name$ac_delim
26005bindir!$bindir$ac_delim
26006sbindir!$sbindir$ac_delim
26007libexecdir!$libexecdir$ac_delim
26008datarootdir!$datarootdir$ac_delim
26009datadir!$datadir$ac_delim
26010sysconfdir!$sysconfdir$ac_delim
26011sharedstatedir!$sharedstatedir$ac_delim
26012localstatedir!$localstatedir$ac_delim
26013includedir!$includedir$ac_delim
26014oldincludedir!$oldincludedir$ac_delim
26015docdir!$docdir$ac_delim
26016infodir!$infodir$ac_delim
26017htmldir!$htmldir$ac_delim
26018dvidir!$dvidir$ac_delim
26019pdfdir!$pdfdir$ac_delim
26020psdir!$psdir$ac_delim
26021libdir!$libdir$ac_delim
26022localedir!$localedir$ac_delim
26023mandir!$mandir$ac_delim
26024DEFS!$DEFS$ac_delim
26025ECHO_C!$ECHO_C$ac_delim
26026ECHO_N!$ECHO_N$ac_delim
26027ECHO_T!$ECHO_T$ac_delim
26028LIBS!$LIBS$ac_delim
26029build_alias!$build_alias$ac_delim
26030host_alias!$host_alias$ac_delim
26031target_alias!$target_alias$ac_delim
26032VERSION!$VERSION$ac_delim
26033SOVERSION!$SOVERSION$ac_delim
26034CONFIG_ARGS!$CONFIG_ARGS$ac_delim
26035UNIVERSALSDK!$UNIVERSALSDK$ac_delim
26036ARCH_RUN_32BIT!$ARCH_RUN_32BIT$ac_delim
26037PYTHONFRAMEWORK!$PYTHONFRAMEWORK$ac_delim
26038PYTHONFRAMEWORKIDENTIFIER!$PYTHONFRAMEWORKIDENTIFIER$ac_delim
26039PYTHONFRAMEWORKDIR!$PYTHONFRAMEWORKDIR$ac_delim
26040PYTHONFRAMEWORKPREFIX!$PYTHONFRAMEWORKPREFIX$ac_delim
26041PYTHONFRAMEWORKINSTALLDIR!$PYTHONFRAMEWORKINSTALLDIR$ac_delim
26042FRAMEWORKINSTALLFIRST!$FRAMEWORKINSTALLFIRST$ac_delim
26043FRAMEWORKINSTALLLAST!$FRAMEWORKINSTALLLAST$ac_delim
26044FRAMEWORKALTINSTALLFIRST!$FRAMEWORKALTINSTALLFIRST$ac_delim
26045FRAMEWORKALTINSTALLLAST!$FRAMEWORKALTINSTALLLAST$ac_delim
26046FRAMEWORKUNIXTOOLSPREFIX!$FRAMEWORKUNIXTOOLSPREFIX$ac_delim
26047MACHDEP!$MACHDEP$ac_delim
26048SGI_ABI!$SGI_ABI$ac_delim
26049EXTRAPLATDIR!$EXTRAPLATDIR$ac_delim
26050EXTRAMACHDEPPATH!$EXTRAMACHDEPPATH$ac_delim
26051CONFIGURE_MACOSX_DEPLOYMENT_TARGET!$CONFIGURE_MACOSX_DEPLOYMENT_TARGET$ac_delim
26052EXPORT_MACOSX_DEPLOYMENT_TARGET!$EXPORT_MACOSX_DEPLOYMENT_TARGET$ac_delim
26053CC!$CC$ac_delim
26054CFLAGS!$CFLAGS$ac_delim
26055LDFLAGS!$LDFLAGS$ac_delim
26056CPPFLAGS!$CPPFLAGS$ac_delim
26057ac_ct_CC!$ac_ct_CC$ac_delim
26058EXEEXT!$EXEEXT$ac_delim
26059OBJEXT!$OBJEXT$ac_delim
26060CXX!$CXX$ac_delim
26061MAINCC!$MAINCC$ac_delim
26062CPP!$CPP$ac_delim
26063GREP!$GREP$ac_delim
26064EGREP!$EGREP$ac_delim
26065BUILDEXEEXT!$BUILDEXEEXT$ac_delim
26066LIBRARY!$LIBRARY$ac_delim
26067LDLIBRARY!$LDLIBRARY$ac_delim
26068DLLLIBRARY!$DLLLIBRARY$ac_delim
26069BLDLIBRARY!$BLDLIBRARY$ac_delim
26070LDLIBRARYDIR!$LDLIBRARYDIR$ac_delim
26071INSTSONAME!$INSTSONAME$ac_delim
26072RUNSHARED!$RUNSHARED$ac_delim
26073LINKCC!$LINKCC$ac_delim
26074GNULD!$GNULD$ac_delim
26075RANLIB!$RANLIB$ac_delim
26076AR!$AR$ac_delim
26077ARFLAGS!$ARFLAGS$ac_delim
26078SVNVERSION!$SVNVERSION$ac_delim
26079INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
26080INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
26081INSTALL_DATA!$INSTALL_DATA$ac_delim
26082LN!$LN$ac_delim
26083OPT!$OPT$ac_delim
26084BASECFLAGS!$BASECFLAGS$ac_delim
26085UNIVERSAL_ARCH_FLAGS!$UNIVERSAL_ARCH_FLAGS$ac_delim
26086OTHER_LIBTOOL_OPT!$OTHER_LIBTOOL_OPT$ac_delim
26087LIBTOOL_CRUFT!$LIBTOOL_CRUFT$ac_delim
26088SO!$SO$ac_delim
26089LDSHARED!$LDSHARED$ac_delim
26090BLDSHARED!$BLDSHARED$ac_delim
26091CCSHARED!$CCSHARED$ac_delim
26092_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000026093
Ronald Oussoren450d5612009-06-08 21:12:41 +000026094 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
Martin v. Löwiseba40652007-08-30 20:10:57 +000026095 break
26096 elif $ac_last_try; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000026097 { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26098echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026099 { (exit 1); exit 1; }; }
26100 else
26101 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
Martin v. Löwis11437992002-04-12 09:54:03 +000026102 fi
Martin v. Löwiseba40652007-08-30 20:10:57 +000026103done
26104
Ronald Oussoren450d5612009-06-08 21:12:41 +000026105ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
26106if test -n "$ac_eof"; then
26107 ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
26108 ac_eof=`expr $ac_eof + 1`
26109fi
26110
26111cat >>$CONFIG_STATUS <<_ACEOF
26112cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
26113/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
Martin v. Löwiseba40652007-08-30 20:10:57 +000026114_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000026115sed '
26116s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
26117s/^/s,@/; s/!/@,|#_!!_#|/
26118:n
26119t n
26120s/'"$ac_delim"'$/,g/; t
26121s/$/\\/; p
26122N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
26123' >>$CONFIG_STATUS <conf$$subs.sed
26124rm -f conf$$subs.sed
26125cat >>$CONFIG_STATUS <<_ACEOF
26126CEOF$ac_eof
Martin v. Löwiseba40652007-08-30 20:10:57 +000026127_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000026128
26129
26130ac_delim='%!_!# '
26131for ac_last_try in false false false false false :; do
26132 cat >conf$$subs.sed <<_ACEOF
26133LINKFORSHARED!$LINKFORSHARED$ac_delim
26134CFLAGSFORSHARED!$CFLAGSFORSHARED$ac_delim
26135SHLIBS!$SHLIBS$ac_delim
26136USE_SIGNAL_MODULE!$USE_SIGNAL_MODULE$ac_delim
26137SIGNAL_OBJS!$SIGNAL_OBJS$ac_delim
26138USE_THREAD_MODULE!$USE_THREAD_MODULE$ac_delim
26139LDLAST!$LDLAST$ac_delim
26140THREADOBJ!$THREADOBJ$ac_delim
26141DLINCLDIR!$DLINCLDIR$ac_delim
26142DYNLOADFILE!$DYNLOADFILE$ac_delim
26143MACHDEP_OBJS!$MACHDEP_OBJS$ac_delim
26144TRUE!$TRUE$ac_delim
26145LIBOBJS!$LIBOBJS$ac_delim
26146HAVE_GETHOSTBYNAME_R_6_ARG!$HAVE_GETHOSTBYNAME_R_6_ARG$ac_delim
26147HAVE_GETHOSTBYNAME_R_5_ARG!$HAVE_GETHOSTBYNAME_R_5_ARG$ac_delim
26148HAVE_GETHOSTBYNAME_R_3_ARG!$HAVE_GETHOSTBYNAME_R_3_ARG$ac_delim
26149HAVE_GETHOSTBYNAME_R!$HAVE_GETHOSTBYNAME_R$ac_delim
26150HAVE_GETHOSTBYNAME!$HAVE_GETHOSTBYNAME$ac_delim
26151LIBM!$LIBM$ac_delim
26152LIBC!$LIBC$ac_delim
26153UNICODE_OBJS!$UNICODE_OBJS$ac_delim
26154THREADHEADERS!$THREADHEADERS$ac_delim
26155SRCDIRS!$SRCDIRS$ac_delim
26156LTLIBOBJS!$LTLIBOBJS$ac_delim
26157_ACEOF
26158
26159 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 24; then
26160 break
26161 elif $ac_last_try; then
26162 { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
26163echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026164 { (exit 1); exit 1; }; }
Ronald Oussoren450d5612009-06-08 21:12:41 +000026165 else
26166 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
26167 fi
26168done
26169
26170ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
26171if test -n "$ac_eof"; then
26172 ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
26173 ac_eof=`expr $ac_eof + 1`
26174fi
26175
26176cat >>$CONFIG_STATUS <<_ACEOF
26177cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
26178/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
Martin v. Löwiseba40652007-08-30 20:10:57 +000026179_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000026180sed '
26181s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
26182s/^/s,@/; s/!/@,|#_!!_#|/
26183:n
26184t n
26185s/'"$ac_delim"'$/,g/; t
26186s/$/\\/; p
26187N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
26188' >>$CONFIG_STATUS <conf$$subs.sed
26189rm -f conf$$subs.sed
26190cat >>$CONFIG_STATUS <<_ACEOF
26191:end
26192s/|#_!!_#|//g
26193CEOF$ac_eof
26194_ACEOF
26195
Martin v. Löwiseba40652007-08-30 20:10:57 +000026196
26197# VPATH may cause trouble with some makes, so we remove $(srcdir),
26198# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
26199# trailing colons and then remove the whole line if VPATH becomes empty
26200# (actually we leave an empty line to preserve line numbers).
26201if test "x$srcdir" = x.; then
26202 ac_vpsub='/^[ ]*VPATH[ ]*=/{
26203s/:*\$(srcdir):*/:/
26204s/:*\${srcdir}:*/:/
26205s/:*@srcdir@:*/:/
26206s/^\([^=]*=[ ]*\):*/\1/
26207s/:*$//
26208s/^[^=]*=[ ]*$//
26209}'
26210fi
26211
Ronald Oussoren450d5612009-06-08 21:12:41 +000026212cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000026213fi # test -n "$CONFIG_FILES"
26214
Martin v. Löwiseba40652007-08-30 20:10:57 +000026215
Ronald Oussoren450d5612009-06-08 21:12:41 +000026216for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS
Martin v. Löwiseba40652007-08-30 20:10:57 +000026217do
26218 case $ac_tag in
26219 :[FHLC]) ac_mode=$ac_tag; continue;;
26220 esac
26221 case $ac_mode$ac_tag in
26222 :[FHL]*:*);;
Ronald Oussoren450d5612009-06-08 21:12:41 +000026223 :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
26224echo "$as_me: error: Invalid tag $ac_tag." >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026225 { (exit 1); exit 1; }; };;
26226 :[FH]-) ac_tag=-:-;;
26227 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
26228 esac
26229 ac_save_IFS=$IFS
26230 IFS=:
26231 set x $ac_tag
26232 IFS=$ac_save_IFS
26233 shift
26234 ac_file=$1
26235 shift
26236
26237 case $ac_mode in
26238 :L) ac_source=$1;;
26239 :[FH])
26240 ac_file_inputs=
26241 for ac_f
26242 do
26243 case $ac_f in
26244 -) ac_f="$tmp/stdin";;
26245 *) # Look for the file first in the build tree, then in the source tree
26246 # (if the path is not absolute). The absolute path cannot be DOS-style,
26247 # because $ac_f cannot contain `:'.
26248 test -f "$ac_f" ||
26249 case $ac_f in
26250 [\\/$]*) false;;
26251 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
26252 esac ||
Ronald Oussoren450d5612009-06-08 21:12:41 +000026253 { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
26254echo "$as_me: error: cannot find input file: $ac_f" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026255 { (exit 1); exit 1; }; };;
26256 esac
Ronald Oussoren450d5612009-06-08 21:12:41 +000026257 ac_file_inputs="$ac_file_inputs $ac_f"
Martin v. Löwiseba40652007-08-30 20:10:57 +000026258 done
26259
26260 # Let's still pretend it is `configure' which instantiates (i.e., don't
26261 # use $as_me), people would be surprised to read:
26262 # /* config.h. Generated by config.status. */
Ronald Oussoren450d5612009-06-08 21:12:41 +000026263 configure_input="Generated from "`IFS=:
26264 echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
Martin v. Löwiseba40652007-08-30 20:10:57 +000026265 if test x"$ac_file" != x-; then
26266 configure_input="$ac_file. $configure_input"
Ronald Oussoren450d5612009-06-08 21:12:41 +000026267 { echo "$as_me:$LINENO: creating $ac_file" >&5
26268echo "$as_me: creating $ac_file" >&6;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026269 fi
26270
26271 case $ac_tag in
Ronald Oussoren450d5612009-06-08 21:12:41 +000026272 *:-:* | *:-) cat >"$tmp/stdin";;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026273 esac
26274 ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000026275 esac
26276
Martin v. Löwiseba40652007-08-30 20:10:57 +000026277 ac_dir=`$as_dirname -- "$ac_file" ||
Martin v. Löwis11437992002-04-12 09:54:03 +000026278$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
Skip Montanarof0d5f792004-08-15 14:08:23 +000026279 X"$ac_file" : 'X\(//\)[^/]' \| \
26280 X"$ac_file" : 'X\(//\)$' \| \
Martin v. Löwiseba40652007-08-30 20:10:57 +000026281 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
Ronald Oussoren450d5612009-06-08 21:12:41 +000026282echo X"$ac_file" |
Martin v. Löwiseba40652007-08-30 20:10:57 +000026283 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26284 s//\1/
26285 q
26286 }
26287 /^X\(\/\/\)[^/].*/{
26288 s//\1/
26289 q
26290 }
26291 /^X\(\/\/\)$/{
26292 s//\1/
26293 q
26294 }
26295 /^X\(\/\).*/{
26296 s//\1/
26297 q
26298 }
26299 s/.*/./; q'`
26300 { as_dir="$ac_dir"
26301 case $as_dir in #(
26302 -*) as_dir=./$as_dir;;
26303 esac
26304 test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
Skip Montanaro6dead952003-09-25 14:50:04 +000026305 as_dirs=
Martin v. Löwiseba40652007-08-30 20:10:57 +000026306 while :; do
26307 case $as_dir in #(
Ronald Oussoren450d5612009-06-08 21:12:41 +000026308 *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
Martin v. Löwiseba40652007-08-30 20:10:57 +000026309 *) as_qdir=$as_dir;;
26310 esac
26311 as_dirs="'$as_qdir' $as_dirs"
26312 as_dir=`$as_dirname -- "$as_dir" ||
Skip Montanaro6dead952003-09-25 14:50:04 +000026313$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
Skip Montanarof0d5f792004-08-15 14:08:23 +000026314 X"$as_dir" : 'X\(//\)[^/]' \| \
26315 X"$as_dir" : 'X\(//\)$' \| \
Martin v. Löwiseba40652007-08-30 20:10:57 +000026316 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
Ronald Oussoren450d5612009-06-08 21:12:41 +000026317echo X"$as_dir" |
Martin v. Löwiseba40652007-08-30 20:10:57 +000026318 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
26319 s//\1/
26320 q
26321 }
26322 /^X\(\/\/\)[^/].*/{
26323 s//\1/
26324 q
26325 }
26326 /^X\(\/\/\)$/{
26327 s//\1/
26328 q
26329 }
26330 /^X\(\/\).*/{
26331 s//\1/
26332 q
26333 }
26334 s/.*/./; q'`
26335 test -d "$as_dir" && break
Skip Montanaro6dead952003-09-25 14:50:04 +000026336 done
Martin v. Löwiseba40652007-08-30 20:10:57 +000026337 test -z "$as_dirs" || eval "mkdir $as_dirs"
Ronald Oussoren450d5612009-06-08 21:12:41 +000026338 } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
26339echo "$as_me: error: cannot create directory $as_dir" >&2;}
Skip Montanaro6dead952003-09-25 14:50:04 +000026340 { (exit 1); exit 1; }; }; }
Martin v. Löwis11437992002-04-12 09:54:03 +000026341 ac_builddir=.
26342
Martin v. Löwiseba40652007-08-30 20:10:57 +000026343case "$ac_dir" in
26344.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
26345*)
Ronald Oussoren450d5612009-06-08 21:12:41 +000026346 ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
Martin v. Löwiseba40652007-08-30 20:10:57 +000026347 # A ".." for each directory in $ac_dir_suffix.
Ronald Oussoren450d5612009-06-08 21:12:41 +000026348 ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
Martin v. Löwiseba40652007-08-30 20:10:57 +000026349 case $ac_top_builddir_sub in
26350 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
26351 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
26352 esac ;;
26353esac
26354ac_abs_top_builddir=$ac_pwd
26355ac_abs_builddir=$ac_pwd$ac_dir_suffix
26356# for backward compatibility:
26357ac_top_builddir=$ac_top_build_prefix
Martin v. Löwis11437992002-04-12 09:54:03 +000026358
26359case $srcdir in
Martin v. Löwiseba40652007-08-30 20:10:57 +000026360 .) # We are building in place.
Martin v. Löwis11437992002-04-12 09:54:03 +000026361 ac_srcdir=.
Martin v. Löwiseba40652007-08-30 20:10:57 +000026362 ac_top_srcdir=$ac_top_builddir_sub
26363 ac_abs_top_srcdir=$ac_pwd ;;
26364 [\\/]* | ?:[\\/]* ) # Absolute name.
Martin v. Löwis11437992002-04-12 09:54:03 +000026365 ac_srcdir=$srcdir$ac_dir_suffix;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026366 ac_top_srcdir=$srcdir
26367 ac_abs_top_srcdir=$srcdir ;;
26368 *) # Relative name.
26369 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
26370 ac_top_srcdir=$ac_top_build_prefix$srcdir
26371 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000026372esac
Martin v. Löwiseba40652007-08-30 20:10:57 +000026373ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
Skip Montanarof0d5f792004-08-15 14:08:23 +000026374
Martin v. Löwis11437992002-04-12 09:54:03 +000026375
Martin v. Löwiseba40652007-08-30 20:10:57 +000026376 case $ac_mode in
26377 :F)
26378 #
26379 # CONFIG_FILE
26380 #
Martin v. Löwis11437992002-04-12 09:54:03 +000026381
26382 case $INSTALL in
26383 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
Martin v. Löwiseba40652007-08-30 20:10:57 +000026384 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
Martin v. Löwis11437992002-04-12 09:54:03 +000026385 esac
Brett Cannon19fab762007-06-02 03:02:29 +000026386_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000026387
Ronald Oussoren450d5612009-06-08 21:12:41 +000026388cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000026389# If the template does not know about datarootdir, expand it.
26390# FIXME: This hack should be removed a few years after 2.60.
26391ac_datarootdir_hack=; ac_datarootdir_seen=
26392
Ronald Oussoren450d5612009-06-08 21:12:41 +000026393case `sed -n '/datarootdir/ {
Martin v. Löwiseba40652007-08-30 20:10:57 +000026394 p
26395 q
26396}
26397/@datadir@/p
26398/@docdir@/p
26399/@infodir@/p
26400/@localedir@/p
26401/@mandir@/p
Ronald Oussoren450d5612009-06-08 21:12:41 +000026402' $ac_file_inputs` in
Martin v. Löwiseba40652007-08-30 20:10:57 +000026403*datarootdir*) ac_datarootdir_seen=yes;;
26404*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
Ronald Oussoren450d5612009-06-08 21:12:41 +000026405 { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
26406echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
Martin v. Löwiseba40652007-08-30 20:10:57 +000026407_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000026408cat >>$CONFIG_STATUS <<_ACEOF
Martin v. Löwiseba40652007-08-30 20:10:57 +000026409 ac_datarootdir_hack='
26410 s&@datadir@&$datadir&g
26411 s&@docdir@&$docdir&g
26412 s&@infodir@&$infodir&g
26413 s&@localedir@&$localedir&g
26414 s&@mandir@&$mandir&g
26415 s&\\\${datarootdir}&$datarootdir&g' ;;
26416esac
26417_ACEOF
26418
26419# Neutralize VPATH when `$srcdir' = `.'.
26420# Shell code in configure.ac might set extrasub.
26421# FIXME: do we really want to maintain this feature?
Ronald Oussoren450d5612009-06-08 21:12:41 +000026422cat >>$CONFIG_STATUS <<_ACEOF
26423 sed "$ac_vpsub
Martin v. Löwis11437992002-04-12 09:54:03 +000026424$extrasub
26425_ACEOF
Ronald Oussoren450d5612009-06-08 21:12:41 +000026426cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000026427:t
26428/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
Ronald Oussoren450d5612009-06-08 21:12:41 +000026429s&@configure_input@&$configure_input&;t t
Martin v. Löwiseba40652007-08-30 20:10:57 +000026430s&@top_builddir@&$ac_top_builddir_sub&;t t
26431s&@srcdir@&$ac_srcdir&;t t
26432s&@abs_srcdir@&$ac_abs_srcdir&;t t
26433s&@top_srcdir@&$ac_top_srcdir&;t t
26434s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
26435s&@builddir@&$ac_builddir&;t t
26436s&@abs_builddir@&$ac_abs_builddir&;t t
26437s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
26438s&@INSTALL@&$ac_INSTALL&;t t
26439$ac_datarootdir_hack
Ronald Oussoren450d5612009-06-08 21:12:41 +000026440" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026441
Martin v. Löwiseba40652007-08-30 20:10:57 +000026442test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
26443 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
26444 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
Ronald Oussoren450d5612009-06-08 21:12:41 +000026445 { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
Martin v. Löwiseba40652007-08-30 20:10:57 +000026446which seems to be undefined. Please make sure it is defined." >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000026447echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
Martin v. Löwiseba40652007-08-30 20:10:57 +000026448which seems to be undefined. Please make sure it is defined." >&2;}
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026449
Martin v. Löwiseba40652007-08-30 20:10:57 +000026450 rm -f "$tmp/stdin"
Martin v. Löwis11437992002-04-12 09:54:03 +000026451 case $ac_file in
Ronald Oussoren450d5612009-06-08 21:12:41 +000026452 -) cat "$tmp/out"; rm -f "$tmp/out";;
26453 *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
26454 esac
Martin v. Löwiseba40652007-08-30 20:10:57 +000026455 ;;
26456 :H)
26457 #
26458 # CONFIG_HEADER
26459 #
Ronald Oussoren450d5612009-06-08 21:12:41 +000026460_ACEOF
26461
26462# Transform confdefs.h into a sed script `conftest.defines', that
26463# substitutes the proper values into config.h.in to produce config.h.
26464rm -f conftest.defines conftest.tail
26465# First, append a space to every undef/define line, to ease matching.
26466echo 's/$/ /' >conftest.defines
26467# Then, protect against being on the right side of a sed subst, or in
26468# an unquoted here document, in config.status. If some macros were
26469# called several times there might be several #defines for the same
26470# symbol, which is useless. But do not sort them, since the last
26471# AC_DEFINE must be honored.
26472ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
26473# These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
26474# NAME is the cpp macro being defined, VALUE is the value it is being given.
26475# PARAMS is the parameter list in the macro definition--in most cases, it's
26476# just an empty string.
26477ac_dA='s,^\\([ #]*\\)[^ ]*\\([ ]*'
26478ac_dB='\\)[ (].*,\\1define\\2'
26479ac_dC=' '
26480ac_dD=' ,'
26481
26482uniq confdefs.h |
26483 sed -n '
26484 t rset
26485 :rset
26486 s/^[ ]*#[ ]*define[ ][ ]*//
26487 t ok
26488 d
26489 :ok
26490 s/[\\&,]/\\&/g
26491 s/^\('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
26492 s/^\('"$ac_word_re"'\)[ ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
26493 ' >>conftest.defines
26494
26495# Remove the space that was appended to ease matching.
26496# Then replace #undef with comments. This is necessary, for
26497# example, in the case of _POSIX_SOURCE, which is predefined and required
26498# on some systems where configure will not decide to define it.
26499# (The regexp can be short, since the line contains either #define or #undef.)
26500echo 's/ $//
26501s,^[ #]*u.*,/* & */,' >>conftest.defines
26502
26503# Break up conftest.defines:
26504ac_max_sed_lines=50
26505
26506# First sed command is: sed -f defines.sed $ac_file_inputs >"$tmp/out1"
26507# Second one is: sed -f defines.sed "$tmp/out1" >"$tmp/out2"
26508# Third one will be: sed -f defines.sed "$tmp/out2" >"$tmp/out1"
26509# et cetera.
26510ac_in='$ac_file_inputs'
26511ac_out='"$tmp/out1"'
26512ac_nxt='"$tmp/out2"'
26513
26514while :
26515do
26516 # Write a here document:
26517 cat >>$CONFIG_STATUS <<_ACEOF
26518 # First, check the format of the line:
26519 cat >"\$tmp/defines.sed" <<\\CEOF
26520/^[ ]*#[ ]*undef[ ][ ]*$ac_word_re[ ]*\$/b def
26521/^[ ]*#[ ]*define[ ][ ]*$ac_word_re[( ]/b def
26522b
26523:def
26524_ACEOF
26525 sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
26526 echo 'CEOF
26527 sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
26528 ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
26529 sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
26530 grep . conftest.tail >/dev/null || break
26531 rm -f conftest.defines
26532 mv conftest.tail conftest.defines
26533done
26534rm -f conftest.defines conftest.tail
26535
26536echo "ac_result=$ac_in" >>$CONFIG_STATUS
26537cat >>$CONFIG_STATUS <<\_ACEOF
Martin v. Löwis11437992002-04-12 09:54:03 +000026538 if test x"$ac_file" != x-; then
Ronald Oussoren450d5612009-06-08 21:12:41 +000026539 echo "/* $configure_input */" >"$tmp/config.h"
26540 cat "$ac_result" >>"$tmp/config.h"
26541 if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
26542 { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
26543echo "$as_me: $ac_file is unchanged" >&6;}
Martin v. Löwis11437992002-04-12 09:54:03 +000026544 else
Ronald Oussoren450d5612009-06-08 21:12:41 +000026545 rm -f $ac_file
26546 mv "$tmp/config.h" $ac_file
Martin v. Löwis11437992002-04-12 09:54:03 +000026547 fi
26548 else
Ronald Oussoren450d5612009-06-08 21:12:41 +000026549 echo "/* $configure_input */"
26550 cat "$ac_result"
Martin v. Löwis11437992002-04-12 09:54:03 +000026551 fi
Ronald Oussoren450d5612009-06-08 21:12:41 +000026552 rm -f "$tmp/out12"
Martin v. Löwiseba40652007-08-30 20:10:57 +000026553 ;;
Guido van Rossum7f43da71994-08-01 12:15:30 +000026554
Martin v. Löwiseba40652007-08-30 20:10:57 +000026555
26556 esac
26557
26558done # for ac_tag
26559
Guido van Rossum627b2d71993-12-24 10:39:16 +000026560
Martin v. Löwis11437992002-04-12 09:54:03 +000026561{ (exit 0); exit 0; }
26562_ACEOF
Guido van Rossum76be6ed1995-01-02 18:33:54 +000026563chmod +x $CONFIG_STATUS
Martin v. Löwis11437992002-04-12 09:54:03 +000026564ac_clean_files=$ac_clean_files_save
26565
26566
26567# configure is writing to config.log, and then calls config.status.
26568# config.status does its own redirection, appending to config.log.
26569# Unfortunately, on DOS this fails, as config.log is still kept open
26570# by configure, so config.status won't be able to write to it; its
26571# output is simply discarded. So we exec the FD to /dev/null,
26572# effectively closing config.log, so it can be properly (re)opened and
26573# appended to by config.status. When coming back to configure, we
26574# need to make the FD available again.
26575if test "$no_create" != yes; then
26576 ac_cs_success=:
Skip Montanaro6dead952003-09-25 14:50:04 +000026577 ac_config_status_args=
26578 test "$silent" = yes &&
26579 ac_config_status_args="$ac_config_status_args --quiet"
Martin v. Löwis11437992002-04-12 09:54:03 +000026580 exec 5>/dev/null
Skip Montanaro6dead952003-09-25 14:50:04 +000026581 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
Martin v. Löwis11437992002-04-12 09:54:03 +000026582 exec 5>>config.log
26583 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
26584 # would make configure fail if this is the last instruction.
26585 $ac_cs_success || { (exit 1); exit 1; }
26586fi
Guido van Rossum627b2d71993-12-24 10:39:16 +000026587
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000026588
Martin v. Löwisf7afe952006-04-14 15:16:15 +000026589echo "creating Modules/Setup"
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000026590if test ! -f Modules/Setup
26591then
26592 cp $srcdir/Modules/Setup.dist Modules/Setup
26593fi
26594
Martin v. Löwisf7afe952006-04-14 15:16:15 +000026595echo "creating Modules/Setup.local"
Neil Schemenauer3ecf0aa2001-01-26 16:15:20 +000026596if test ! -f Modules/Setup.local
26597then
26598 echo "# Edit this file for local setup changes" >Modules/Setup.local
26599fi
26600
26601echo "creating Makefile"
26602$SHELL $srcdir/Modules/makesetup -c $srcdir/Modules/config.c.in \
26603 -s Modules Modules/Setup.config \
Neil Schemenauerf8b71c52001-04-21 17:41:16 +000026604 Modules/Setup.local Modules/Setup
Skip Montanaro89e975f2007-08-22 19:05:21 +000026605
26606case $ac_sys_system in
26607BeOS)
Ronald Oussoren450d5612009-06-08 21:12:41 +000026608 { echo "$as_me:$LINENO: WARNING:
Skip Montanaro89e975f2007-08-22 19:05:21 +000026609
26610 Support for BeOS is deprecated as of Python 2.6.
26611 See PEP 11 for the gory details.
26612 " >&5
Ronald Oussoren450d5612009-06-08 21:12:41 +000026613echo "$as_me: WARNING:
Skip Montanaro89e975f2007-08-22 19:05:21 +000026614
26615 Support for BeOS is deprecated as of Python 2.6.
26616 See PEP 11 for the gory details.
26617 " >&2;}
26618 ;;
26619*) ;;
26620esac
26621
Neil Schemenauerc761fc82001-02-19 04:50:49 +000026622mv config.c Modules